Create a proxy
Create a custom or api proxy and return its full details. API proxies use auth_type, which defaults to whitelist if omitted. Both username and password are required when credential is selected. The Local API resolves the current IP address and port locally. integ and syt proxies cannot be created through this endpoint. Usernames, passwords, and extraction URLs are sensitive and must not be written to caller logs.
Request parameters
Authorization Bearer Token
Include your API Key as a Bearer token in the Authorization request header.
Authorization: Bearer <api-key>Body parameters
requiredapplication/jsonProxyCreateRequestobject
Generated from the schema; not a live response.
{
"name": "string",
"mode": "custom",
"config": {
"host": "string",
"port": 0
}
}Request code examples
JavaScript / TypeScript: Node.js 18+ with fetch; PHP: cURL extension; Go: 1.16+; Java: JDK 11+. Replace the token and example parameter values before running.
curl -X POST -H 'Authorization: Bearer <TOKEN>' -H 'Content-Type: application/json' -d '{
"name": "string",
"mode": "custom",
"config": {
"host": "string",
"port": 0
}
}' 'http://local.zhongyibrowser.com:39025/api/v1/proxies'Responses
Success: code = 0. Failure: code > 0. Select a status to view its fields and example. Expand objects to inspect nested fields. Optional fields may be omitted.
Details of the created proxy
Body
application/jsonProxyDetailSuccessResponseobjectrequiredEndpoint business data
Generated from the schema; not a live response.
{
"code": 0,
"message": "success",
"data": {
"id": "string",
"name": "string",
"remark": "string",
"status": "unchecked",
"checked_at": "2024-01-15T09:30:00Z",
"browser_count": 0,
"is_expired": true,
"created_at": "2024-01-15T09:30:00Z",
"updated_at": "2024-01-15T09:30:00Z",
"mode": "custom",
"config": {
"protocol": "http",
"ip_protocol": "ipv4",
"host": "string",
"port": 0,
"username": "string",
"password": "string"
},
"browser_ids": [
"env_01JABCDEF1234567890"
]
}
}