动态代理账号
动态代理账号
生成动态代理连接凭据
POST /open-api/v1/dynamic/accounts/{id}/proxy-credentials 接口参考。
生成动态代理连接凭据
POST /open-api/v1/dynamic/accounts/{id}/proxy-credentials
Base URL:https://api.ipbunker.online/gin。
认证
在请求头传入 X-API-Key。
路径与查询参数
| 字段 | 位置 | 类型 | 必填 | 约束 | 说明 |
|---|---|---|---|---|---|
id |
path | string |
是 | — | 动态账号 ID |
JSON 请求体
| 字段 | 类型 | 必填 | 约束 | 说明 |
|---|---|---|---|---|
country_code |
string |
否 | — | 可选国家编码 |
province_code |
string |
否 | — | 可选省份编码 |
city_code |
string |
否 | — | 可选城市编码 |
rotation_type |
string |
是 | enum: ROTATING, STICKY | 轮换方式 |
session_duration_minutes |
integer |
否 | format: int32; minimum: 1; maximum: 120 | STICKY 会话时长(分钟),当前支持 1~120;超出范围的效果不作保证 |
请求示例
curl --request POST \
--url 'https://api.ipbunker.online/gin/open-api/v1/dynamic/accounts/1912345678901234567/proxy-credentials' \
--header 'Accept: application/json' \
--header 'X-API-Key: <YOUR_API_KEY>' \
--header 'Content-Type: application/json' \
--data '{
"rotation_type": "ROTATING"
}'
成功响应中的 data
接口使用 code、msg、data、next 响应结构。HTTP 200 也可能包含非零业务错误码;先检查 code。
| 字段 | 类型 | 必填 | 约束 | 说明 |
|---|---|---|---|---|
data.proxy_username |
string |
否 | — | 按地区和轮换方式生成的代理用户名 |
data.password |
string |
否 | — | 代理连接密码;敏感字段 |
data.host |
string |
否 | — | 代理网关主机名 |
data.http_port |
integer |
否 | format: int32 | HTTP 代理端口 |
data.socks5_port |
integer |
否 | format: int32 | SOCKS5 代理端口 |
接口说明
按地区和轮换方式生成完整代理连接凭据;返回用户名和密码,不产生持久化副作用