3.Proxy Management
3.1 New proxy
Basic info
Interface description:Add a self-owned proxy.Only supported on system versions between V1.9.7.18 ~ V1.9.20.18 (currently only supported on Windows computers).
Request parameters
Header parameters
Parameter name | Type | Required | Default value | Sample | Desc_ |
x-api-key | string | Yes | - | - | Each MoreLogin user has their own special API-key, you can see in the system api page |
Body Parameters, Optional Parameters can be omitted. The parameter format is JSON.
Parameter name | Type | Required | Default value | Sample | Desc_ |
addr | string | N | - | - | Proxy address is required except when the provider is 11/12/13, in which case it is invalid. |
is_detect_proxy | number | N | - | - | Not providing or setting the value to 0 indicates that there is no need to check the proxy's availability. Setting the value to 1 or any other value indicates that the proxy's availability needs to be checked. |
port | integer | N | - | - | port(Only numbers from 1 to 65535 are supported) The port number is required unless the provider value is 11, 12, or 13. In those cases, the port number is not applicable. |
proxy_type | integer | N | - | 1 | Proxy type:
Please note that both the proxy_type and provider cannot be empty at the same time. |
provider | integer | N | - | - | Proxy providers:
If the provider is set to 3 (Luminati) or 4 (Lumauto), the proxy type (proxy_type) must be specified, and it can only be 1 (HTTP) or 2 (HTTPS). In other cases, if the provider has a value, the proxy type is not applicable. |
encryption_type | integer | N | - | - | Encryption methods:
If the provider is set to 7 (Shadowsocks), the encryption type (encryption_type) must be specified. In other cases, the encryption type is not applicable. |
username | string | N | - | - | Username(Maximum 100 characters) |
passwd | string | N | - | - | Password(Maximum 100 characters) |
refresh_url | string | N | Refresh url(Limit to 600 characters; only URL format supported: “https://\* http://\*”) | ||
country | string | N | - | - | Country(For specific country codes, refer to the appendix), when provider is 11/12/13, it is required to fill in. Otherwise, it is optional. |
state | string | N | - | - | State; Province |
city | string | N | - | - | City |
Return data
{
"ret": 0, //Result: 0 - Success, 500 - Server error
"data": {
"id": 0 //proxy id
},
"error": {
"code": "string", //error code
"msg": "string" //error reason
}
}
Error codes
biz_code exception | Desc_ |
1003 | Proxy detection failed |
-1 | Proxy program failed to start |
3.2 Edit proxy
Basic info
Interface description:To modify proxy-related information.Only supported on system versions between V1.9.7.18 ~ V1.9.20.18 (currently only supported on Windows computers).
Request parameters
Header parameters
Parameter name | Type | Required | Default value | Sample | Desc_ |
x-api-key | string | Yes | - | - | Each MoreLogin user has their own special API-key, you can see in the system api page |
Body Parameters, Optional Parameters can be omitted. The parameter format is JSON.
Parameter name | Type | Required | Default value | Sample | Desc_ |
id | integer | Y | - | - | Proxy id |
name | string | N | - | proxy1 | Proxy name |
addr | string | N | - | - | Proxy address is not applicable when the provider is set to 11, 12, or 13. |
is_detect_proxy | number | N | - | - | Not specifying or passing 0 means no need to check proxy availability. Specifying 1 or any other value indicates the need to check proxy availability. |
port | integer | N | - | - | port(Only numbers from 1 to 65535 are supported) The port is irrelevant when the proxy port provider is set to 11, 12, or 13. |
proxy_type | integer | N | - | 1 | Proxy type:
Please note that both the proxy_type and provider cannot be empty at the same time. |
provider | integer | N | - | - | Proxy providers:
When the provider is set to 3 or 4, the proxy_type field is required, and it can only be set to 1 or 2. In other cases, when the provider has a value, the proxy_type field is not applicable. |
encryption_type | integer | N | - | - | Encryption methods:
When the provider is set to 7, the encryption_type field is required. In other cases, the encryption_type field is not applicable. |
username | string | N | - | - | Username(Maximum 100 characters) |
passwd | string | N | - | - | Password(Maximum 100 characters) |
refresh_url | string | N | Refresh url(Limit to 600 characters; only URL format supported: “https://\* http://\*”) | ||
country | string | N | - | - | Country(For specific country codes, refer to the appendix) |
state | string | N | - | - | State、Province |
city | string | N | - | - | City |
Return data
{
"ret": 0,
"msg": "string"
}
Error codes
biz_code exception | Desc_ |
1003 | Proxy detection failed |
-1 | Proxy program failed to start |
3.3 Delete proxy
Basic info
Interface description:Delete unwanted proxy supports deleting only one proxy at a time. Only supported on system versions between V1.9.7.18 ~ V1.9.20.18 (currently only supported on Windows computers).
Request parameters
Header parameters
Parameter name | Type | Required | Default value | Sample | Desc_ |
x-api-key | string | Yes | - | - | Each MoreLogin user has their own special API-key, you can see in the system api page |
Body Parameters, Optional Parameters can be omitted. The parameter format is JSON.
Parameter name | Type | Required | Default value | Sample | Desc_ |
id | integer | Yes | - | - | Proxy ID |
Return data
{
"ret": 0, //error code
"msg": "string" //error information
}
3.4 Get proxy list
Basic info
Interface description:The API for querying added proxy information allows users to retrieve information about the proxies they have permission to access. Only supported on system versions between V1.9.7.18 ~ V1.9.20.18 (currently only supported on Windows computers).
Request parameters
Header parameters
Parameter name | Type | Required | Default value | Sample | Desc_ |
x-api-key | string | Yes | - | - | Each MoreLogin user has their own special API-key, you can see in the system api page |
Query Parameters, Optional Parameters can be omitted.
Parameter name | Type | Required | Default value | Sample | Desc_ |
id | integer | N | - | - | Proxy id |
name | string | N | - | proxy1 | Proxy name |
addr | string | N | - | - | Proxy address |
platform_type | integer | N | - | 1 | Proxy type: 0: platform IP 1: self-owned IP |
proxy_type | integer | N | - | 1 | Proxy type:
|
provider | integer | N | - | 1 | Proxy providers:
|
status | integer | N | - | 0 | Proxy status 0: Normal 1: Expired 2: to be assigned 3: about to expire 4: Unknown 5: Failed detection |
page | integer | N | 1 | 1 | Page number: Default 1, used when the number of pages large and needs to be turned |
page_size | integer | N | 10 | 20 | Page size: Default 10 per page, maximum 100 |
Return data
{
"ret": 0, //erro code
"msg": "string",
"count": 0, //total count number
"data": [ //proxy list
{
"id": 0, //proxy id
"name": "string", //proxy name
"addr": "string", //proxy address
"platform_type": 0, //proxy platform type 0:platform IP 1:self-ownedIP
"proxy_type": 0, //proxy type 1:http 2:https 3:socks5 4:ssh
"provider": 0, //proxy provider
"status": 0, //proxy status
"expiry": 0 //expiration time
}
]
}