# Get KYC Rules

This API endpoint allows clients to retrieve the rules associated with a specific KYC workflow based on the document type. The KYC rules provide clients with the necessary information on the mandatory fields and additional requirements for the KYC process.

### Request Header:

* `Authorization`: Bearer \[token] (required): The authentication token for accessing the API.

Response: Upon a successful request, the API will return a response containing the KYC rules associated with the specified document type.

### Base URL

```
sdk.faceki.com
```

### KYC Rules End Point API

```
https://sdk.faceki.com/kycrules/api/kycrules
```

<mark style="color:blue;">`GET`</mark> `https://sdk.faceki.com/kycrules/api/kycrules`

#### Headers

| Name                                             | Type   | Description      |
| ------------------------------------------------ | ------ | ---------------- |
| Content-Type:<mark style="color:red;">\*</mark>  | String | application/json |
| Authorization:<mark style="color:red;">\*</mark> | String | Bearer \[token]  |

{% tabs %}
{% tab title="200: OK " %}

```json
{
    "responseCode": 0,
    "data": {
        "_id": "123",
        "companyId": "1234",
        "__v": 0,
        "allowedCountries": [],
        "allowedKycDocuments": [
            "Passport"
        ],
        "allowedNationalities": [],
        "createdAt": "2023-06-08T06:50:21.354Z",
        "dataStorageTime": "FOREVER",
        "declined": {
            "redirect_url": "https://www.faceki.com",
            "message": "Declined!"
        },
        "invalid": {
            "redirect_url": "https://www.faceki.com",
            "message": "Invalid!"
        },
        "invalidDocuments": [],
        "isRecapturedDocumentInvalid": false,
        "link": "",
        "livenessCheckType": "MODERATE",
        "multiKYCEnabled": true,
        "status": "ACTIVE",
        "storedData": true,
        "success": {
            "redirect_url": "https://www.faceki.com",
            "message": "Success!"
        },
        "updatedAt": "2023-06-10T12:01:25.835Z",
        "validAge": 18
    }
}
```

{% endtab %}

{% tab title="400: Bad Request " %}

```javascript
{
    // Response
}
```

{% endtab %}

{% tab title="401: Unauthorized " %}

```javascript
{
    // Response
}
```

{% endtab %}

{% tab title="403: Forbidden " %}

```javascript
{
    // Response
}
```

{% endtab %}

{% tab title="404: Not Found " %}

```javascript
{
    // Response
}
```

{% endtab %}

{% tab title="500: Internal Server Error " %}

```javascript
{
    // Response
}
```

{% endtab %}
{% endtabs %}

{% hint style="info" %}
Method: GET

Authorization: Bearer Token
{% endhint %}

<figure><img src="https://3621714085-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQdiwjdAaMBpDtolO59Ll%2Fuploads%2FRi9nZzTbgIFLjR4BTxM9%2FUntitled.png?alt=media&#x26;token=b9b3ba83-4099-4ea7-8875-d5e7ce64c36e" alt=""><figcaption></figcaption></figure>

By utilizing the "Get KYC Rules" API, clients can retrieve the specific rules and requirements associated with different KYC workflows, allowing them to tailor their user interfaces and data collection processes accordingly. This enhances the overall user experience and ensures compliance with KYC regulations.

<br>

<br>
