> For the complete documentation index, see [llms.txt](https://doc.thordata.com/interface-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.thordata.com/interface-documentation/zh-hk/gong-gong-api/api-ti-qu-lian-jie/zhu-zhai-dai-li.md).

# 住宅代理

### 基礎信息

**接口說明：**&#x901A;過接口獲取住宅代理IP

**請求地址：**<https://get-ip.thordata.net/api>

**請求方式：**<mark style="color:green;">GET</mark>

{% hint style="info" %}
**請注意：**&#x4F7F;用API​​鏈接功能前需要將使用者IP加入IP白名單中，[**點擊此處**](https://doc.thordata.com/doc/zh-hk/dai-li/zhu-zhai-dai-li/duan-dian-chan-sheng-qi/ip-bai-ming-dan/api-lian-jie)了解如何添加IP白名單
{% endhint %}

### 請求參數

**Params：**

| 參數名稱          | 參數类型   | 是否必須 | 描述                                                                                     |
| ------------- | ------ | ---- | -------------------------------------------------------------------------------------- |
| `td-customer` | string | 必須   | 配置您的賬戶名稱，[**請登入儀表板-菜單-我的賬戶**](https://dashboard.thordata.com/account-settings)查看您的賬戶名稱 |
| `sesstype`    | string | 必須   | 配置會話類型：1為黏性會話，2為輪換會話。                                                                  |
| `number`      | number | 必須   | 配置提取的IP數量                                                                              |
| `country`     | string | 必須   | 配置需要提取的國家/地區代碼                                                                         |

{% hint style="info" %}
[**點擊此處**](https://doc.thordata.com/doc/zh-hk/dai-li/zhu-zhai-dai-li/guo-jia-di-qu-lie-biao)查看支持的國家/地區列表及代碼
{% endhint %}

### 響應示例

{% hint style="info" %}
**請注意：**&#x5C55;示IP並非實際使用的IP，所以展示的IP相同，實際使用時，使用不同的端口，IP不同
{% endhint %}

```
43.130.47.112: 19914
43.130.47.112: 14453
43.130.47.112: 17679
43.130.47.112: 14613
43.130.47.112: 11747
```

### 錯誤碼說明

| 錯誤碼 | 返回說明                                                      | 描述        |
| --- | --------------------------------------------------------- | --------- |
| 111 | Please request again in 2 seconds                         | 提取頻率太快    |
| 118 | Your account is abnormal, please contact customer service | 賬戶名稱不正確   |
| 114 | The extracted IP is empty                                 | 沒有符合條件的IP |
