For the complete documentation index, see llms.txt. This page is also available as Markdown.

API For Sub-Accounts

List sub accounts

get

Returns a list of sub accounts.

Authorizations
api-keystringRequired
Query parameters
limitintegerOptional

Maximum number of items returned. Default: 30.

pageintegerOptional

Page number of the requested data. Default: 1.

sort_bystringOptional

Field used for sorting: id, username, created_at, number_of_ips. Default: id.

order_bystringOptional

Sorting order: desc or asc. Default: desc.

usernamestringOptional

Filter by sub account username.

statusintegerOptional

Filter by sub account status: 1 = enabled, 2 = disabled.

keywordstringOptional

Search sub accounts by keyword.

Responses
200

Successful response.

application/json

Returns the list of sub accounts for the user.

successbooleanOptional

Indicates whether the request was successful.

messagestringOptional

Response message.

get/client/v1/subs/get-list
GET /client/v1/subs/get-list HTTP/1.1
Host: sandbox.9proxy.com
Accept: */*
{
  "success": true,
  "message": "text",
  "result": {
    "items": [
      {
        "id": 1,
        "username": "text",
        "note": null,
        "number_of_ips": 1,
        "traffic_data": 1,
        "status": 1,
        "created_at": 1,
        "setting": {
          "auto_add_ips": 1,
          "auto_add_when_number_ips": 1,
          "number_ips_auto_add": 1,
          "auto_disable_at": null,
          "auto_add_traffic": 1,
          "auto_add_when_traffic_bellow": 1,
          "amount_traffic_auto_add": 1,
          "traffic_plan_use_auto_add": null
        }
      }
    ],
    "total_items": 1,
    "total_pages": 1
  }
}

Create a sub account

post

Creates a new sub account.

Authorizations
api-keystringRequired
Body
number_of_ipsintegerOptional

Number of IPs allocated to the sub account.

Example: 10
auto_add_ipsintegerOptional

Enable or disable automatic IP allocation from the main account. 0 = disabled, 1 = enabled.

auto_add_when_number_ipsintegerOptional

Threshold for automatically adding IPs. When the sub account IP balance drops below this value, the main account will add IPs automatically.

Example: 50
number_ips_auto_addintegerOptional

Number of IPs to automatically add when auto-add is triggered.

Example: 100
auto_disable_atintegerOptional

Timestamp when the sub account will be automatically disabled.

amount_trafficintegerOptional

Traffic amount allocated to the sub account (in bytes).

Example: 1000000000
traffic_plan_idintegerOptional

ID of the traffic plan used for allocation.

Example: 10
auto_add_trafficintegerOptional

Enable or disable automatic traffic allocation. 0 = disabled, 1 = enabled.

auto_add_when_traffic_bellowintegerOptional

Threshold for automatically adding traffic. When the sub account traffic balance drops below this value, the main account will add traffic automatically.

Example: 1000000000
amount_traffic_auto_addintegerOptional

Amount of traffic to automatically add when auto-add is triggered (in bytes).

Example: 1000000000
traffic_plan_use_auto_addintegerOptional

ID of the traffic plan used when automatically adding traffic to the sub account.

Example: 11
passwordstringRequired

Password for the sub account.

Example: sub_password
notestringOptional

Note for the sub account.

Example: Note for sub
Responses
200

Successful response.

application/json

Returns the newly created sub account.

successbooleanOptional

Indicates whether the request was successful.

messagestringOptional

Response message.

post/client/v1/subs/create
POST /client/v1/subs/create HTTP/1.1
Host: sandbox.9proxy.com
Content-Type: application/json
Accept: */*
Content-Length: 341

{
  "number_of_ips": 10,
  "auto_add_ips": 0,
  "auto_add_when_number_ips": 50,
  "number_ips_auto_add": 100,
  "auto_disable_at": 0,
  "amount_traffic": 1000000000,
  "traffic_plan_id": 10,
  "auto_add_traffic": 0,
  "auto_add_when_traffic_bellow": 1000000000,
  "amount_traffic_auto_add": 1000000000,
  "traffic_plan_use_auto_add": 11,
  "password": "sub_password",
  "note": "Note for sub"
}
{
  "success": true,
  "message": "text",
  "result": {
    "id": 1,
    "username": "text",
    "note": null,
    "number_of_ips": 1,
    "traffic_data": 1,
    "status": 1,
    "created_at": 1,
    "setting": {
      "auto_add_ips": 1,
      "auto_add_when_number_ips": 1,
      "number_ips_auto_add": 1,
      "auto_disable_at": null,
      "auto_add_traffic": 1,
      "auto_add_when_traffic_bellow": 1,
      "amount_traffic_auto_add": 1,
      "traffic_plan_use_auto_add": null
    }
  }
}

Update a sub account

put

Updates an existing sub account.

Authorizations
api-keystringRequired
Body
sub_idintegerRequired

ID of the sub account.

Example: 27535
passwordstringOptional

New password for the sub account.

Example: sub_password
notestringOptional

Note for the sub account.

Example: Note for sub
auto_add_ipsintegerOptional

Enable or disable automatic IP allocation from the main account. 0 = disabled, 1 = enabled.

auto_add_when_number_ipsintegerOptional

Threshold for automatically adding IPs. When the sub account IP balance drops below this value, the main account will add IPs automatically.

Example: 50
number_ips_auto_addintegerOptional

Number of IPs to automatically add when auto-add is triggered.

Example: 100
auto_disable_atintegerOptional

Timestamp when the sub account will be automatically disabled.

auto_add_trafficintegerOptional

Enable or disable automatic traffic allocation. 0 = disabled, 1 = enabled.

auto_add_when_traffic_bellowintegerOptional

Threshold for automatically adding traffic. When the sub account traffic balance drops below this value, the main account will add traffic automatically.

Example: 1000000000
amount_traffic_auto_addintegerOptional

Amount of traffic to automatically add when auto-add is triggered (in bytes).

Example: 1000000000
traffic_plan_use_auto_addintegerOptional

ID of the traffic plan used when automatically adding traffic to the sub account.

Example: 11
Responses
200

Successful response.

application/json

Returns the update status of the sub account.

successbooleanOptional

Indicates whether the request was successful.

messagestringOptional

Response message.

put/client/v1/subs/update
PUT /client/v1/subs/update HTTP/1.1
Host: sandbox.9proxy.com
Content-Type: application/json
Accept: */*
Content-Length: 288

{
  "sub_id": 27535,
  "password": "sub_password",
  "note": "Note for sub",
  "auto_add_ips": 0,
  "auto_add_when_number_ips": 50,
  "number_ips_auto_add": 100,
  "auto_disable_at": 0,
  "auto_add_traffic": 0,
  "auto_add_when_traffic_bellow": 1000000000,
  "amount_traffic_auto_add": 1000000000,
  "traffic_plan_use_auto_add": 11
}
{
  "success": true,
  "message": "text",
  "result": {
    "updated": true
  }
}

Delete sub accounts

delete

Deletes one or more sub accounts.

Authorizations
api-keystringRequired
Body
idsinteger[]Required

ID of the sub account.

Responses
200

Successful response.

application/json

Returns the deletion status of the sub account.

successbooleanOptional

Indicates whether the request was successful.

messagestringOptional

Response message.

delete/client/v1/subs/bulk-delete
DELETE /client/v1/subs/bulk-delete HTTP/1.1
Host: sandbox.9proxy.com
Content-Type: application/json
Accept: */*
Content-Length: 11

{
  "ids": [
    1
  ]
}
{
  "success": true,
  "message": "text",
  "result": {
    "deleted": true
  }
}

Last updated

Was this helpful?