> For the complete documentation index, see [llms.txt](https://docs.etelecom.vn/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.etelecom.vn/api-etelecom-english/api-integration/vpbx/pbx-rest-apis/change-hotline-for-extension.md).

# Change hotline for extension

This API is used to change the hotline for the extension.

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

* API used for integration case as Partner.
* API\_KEY: [`<shop_key>`](/api-etelecom-english/api-integration/partner/usage.md#retrieve-the-shop_key-information)
* [Partner](/api-etelecom-english/api-integration/partner/account.md) base\_url information
  {% endhint %}

{% openapi src="/files/98tvgFAALfk6gcxXW2re" path="$BASE\_URL.ETelecom/UpdateHotlineForExtension" method="post" %}
[Etelecom.swagger.json](https://1712041776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzzTMjVbVjwTuSbEGC7Ya%2Fuploads%2Fgit-blob-a79f1cdcdf6c0710885851e38f1e6c641fafb69b%2FEtelecom.swagger.json?alt=media)
{% endopenapi %}

**Request:**

```
curl --location '$BASE_URL.Etelecom/UpdateHotlineForExtension' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer $API_KEY' \
--data '{
  "hotline_id": "string",
  "user_id": "string"
}'
```

**Response:**

```
{
  "updated": 0
}
```

**Request body structure:**

| School name                                                    | Data type | Describe    |
| -------------------------------------------------------------- | --------- | ----------- |
| <p>hotline\_id<br><mark style="color:red;">required</mark></p> | string    | ID hotline  |
| <p>user\_id</p><p><mark style="color:red;">required</mark></p> | string    | Employee ID |

**Return data attribute structure:**

| School name | Data type | Describe                                                                                                      |
| ----------- | --------- | ------------------------------------------------------------------------------------------------------------- |
| updated     | int       | <p>Status</p><p><strong><code>0</code></strong>: Failed</p><p><strong><code>1</code></strong>: Successful</p> |
