# Check if the customer has granted calling permission

{% hint style="info" %}
**Note:**

* For APIs used for Shop, the API key is: [`<api_key>`](https://docs.etelecom.vn/api-etelecom-english/api-integration/shop/account). The base\_url information of the [Shop](https://docs.etelecom.vn/api-etelecom-english/api-integration/shop/account).
* For APIs used for Partner, the API key is: [`<shop_key>`](https://docs.etelecom.vn/api-etelecom-english/partner/usage#retrieve-the-shop_key-information). The base\_url information of the [Partner](https://docs.etelecom.vn/api-etelecom-english/api-integration/partner/account).
  {% endhint %}

{% openapi src="<https://1712041776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzzTMjVbVjwTuSbEGC7Ya%2Fuploads%2FNLBGmSfXAFhmMhDpTH4x%2FZalo-API__eTelecom.json?alt=media&token=0852e2bf-0fae-48a2-9d4f-7af244665d34>" path="$BASE\_URL.Zalo/CheckConsent" method="post" %}
[Zalo-API\_\_eTelecom.json](https://1712041776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzzTMjVbVjwTuSbEGC7Ya%2Fuploads%2FNLBGmSfXAFhmMhDpTH4x%2FZalo-API__eTelecom.json?alt=media\&token=0852e2bf-0fae-48a2-9d4f-7af244665d34)
{% endopenapi %}

**Request:**

```
curl --location '$BASE_URL.Zalo/CheckConsent' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer $API-KEY' \
--data '{
  "oa_id": "<int64>",
  "phone": "<string>"
}'
```

**Response:**

```
{
  "error": 0,
  "expired_time": "2019-08-24T14:15:22Z",
  "message": "string"
}
```

**Request body structure**

| Parameters | Data type | Describe               |
| ---------- | --------- | ---------------------- |
| id         | int64     | OA ID                  |
| phone      | string    | Recipient phone number |

**Return data attribute structure**

| Parameters    | Data type          | Describe        |
| ------------- | ------------------ | --------------- |
| error\_code   | int                | Error code      |
| message       | string             | Error message   |
| expired\_time | string\<date-time> | Expiration date |
