Skip to content

Update user preferences

POST
/user/preferences
curl --request POST \
--url https://api.ltesocks.io/v2/user/preferences \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "vpnServer": "vpn1.ltesocks.io", "proxyServer": "ap1.ltesocks.io", "proxyProtocol": "http" }'

Updates supported preferences for the current account and returns the updated user object.

Idempotency-Key
string format: uuid

Optional UUID that identifies one mutation request. Reuse it only when retrying the same request.

User preferences object

Media typeapplication/json
object
vpnServer

Default server hostname to connect via OpenVPN

string format: host
Example
vpn1.ltesocks.io
proxyServer

Default server hostname to connect via proxy

string format: host
Example
ap1.ltesocks.io
proxyProtocol

Default proxy protocol

string
Allowed values: http https socks5
Example
socks5

Successful operation

Media typeapplication/json
object
login

User login

string
email

User email address

string format: email
balance

User balance in cents (100$ = 10000)

integer
portsCount

Total ports number

integer
portsLimit

Maximum allowed ports number

integer
discountPercent

User discount in percentage

integer
preferences
object
vpnServer

Default server hostname to connect via OpenVPN

string format: host
proxyServer

Default server hostname to connect via proxy

string format: host
proxyProtocol

Default proxy protocol

string
Allowed values: http https socks5
Example
{
"login": "user",
"email": "user@example.com",
"balance": 10000,
"portsCount": 3,
"portsLimit": 10,
"discountPercent": 10,
"preferences": {
"vpnServer": "vpn1.ltesocks.io",
"proxyServer": "ap1.ltesocks.io",
"proxyProtocol": "http"
}
}

The bearer token is missing, invalid, or no longer active.

Media typeapplication/json
object
error

Error text representation

string
Example
{
"error": "example error"
}

The configured request limit has been exceeded.

Media typeapplication/json
object
error

Error text representation

string
Example
{
"error": "example error"
}

Error

Media typeapplication/json
object
error

Error text representation

string
Example
{
"error": "example error"
}