跳转到主要内容
POST
/
v2
/
sub-users
创建子用户
curl --request POST \
  --url https://api.decodo.com/v2/sub-users \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "username": "<string>",
  "password": "<string>",
  "service_type": "residential_proxies",
  "traffic_limit": 123,
  "auto_disable": false,
  "traffic_count_from": "2023-12-25"
}
'
"{}"

授权

Authorization
string
header
必填

请求体

application/json
username
string<json>
必填

长度为 6 到 64 个字符。仅允许使用字母、数字和下划线。

password
string<json>
必填

必须包含:12 个或更多字符;至少一个大写字母;一个小写字母;一个数字;以下符号之一 _ ~ + =(不允许使用 @:)。

service_type
enum<string>
默认值:residential_proxies
必填
可用选项:
residential_proxies
traffic_limit
number<float>
auto_disable
boolean
默认值:false

当流量限额用完时禁用子用户

traffic_count_from
string<date>

从指定日期开始计算子用户订阅流量。使用日期格式 yyyy-mm-dd hh:mm:ss。

响应

201

The response is of type object.