Proxy API and Username Builder Reference
The MobileProxy API lets your own scripts check the balance, list lines, place orders, rotate mobile IPs and manage the allowlist. This page also explains the proxy username format, rotation and error codes.
How do I authenticate?
The API lives at https://api.mobileproxy.live/v1, takes and returns JSON, and shows money as US dollar strings. Send your API key in an Authorization: Bearer mp_sk_... header with every request.
You create the key on the developer page of your account after your first top-up. It starts with mp_sk_ and is shown only once, so copy it when it appears. Creating a new key replaces the old one.
Which endpoints can I call?
GET /v1/balance
Returns the spendable balance and the bonus part of it.
curl https://api.mobileproxy.live/v1/balance \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY"{
"balance_usd": "50.00",
"bonus_usd": "2.50",
"currency": "USD"
}GET /v1/lines
Lists your lines with product, country, carrier, status, remaining traffic and the ready username.
curl https://api.mobileproxy.live/v1/lines \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY"{
"lines": [
{
"line_id": "ln_7q2m9x",
"product": "4g-5g-mobile-proxies",
"country": "us",
"carrier": "tmobile",
"status": "active",
"traffic_left_gb": "18.40",
"username": "mp4x9q2.mobile.us.carrier-tmobile.sid-a1b2.rot-10"
}
]
}POST /v1/orders
Buys a product from your balance. Send the product slug and a whole number quantity; the price is always calculated by MobileProxy from the current price list. For per-IP products you can add months (1, 3, 6 or 12).
| Field | Type | Meaning |
|---|---|---|
product | string | One of: 4g-5g-mobile-proxies, residential-ip-proxies, unlimited-traffic-proxies, fixed-isp-proxies, exclusive-datacenter-ips, datacenter-ip-packs. |
quantity | integer | Units to buy: GB, IPs or days, depending on the product. |
months | integer | Optional, per-IP products only. |
curl -X POST https://api.mobileproxy.live/v1/orders \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"product":"4g-5g-mobile-proxies","quantity":10}'{
"order_id": "MP8B21D07E5A",
"status": "processing",
"total_usd": "7.30",
"balance_usd": "42.70"
}POST /v1/lines/{line_id}/rotate
Gives a mobile line a new IP right away. It does the same as opening the line's change-IP link.
curl -X POST https://api.mobileproxy.live/v1/lines/ln_7q2m9x/rotate \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY"{
"line_id": "ln_7q2m9x",
"new_ip": "172.58.**.**",
"next_rotation_in_s": 600
}PUT /v1/allowlist
Replaces the list of IP addresses that may use your lines without a password: up to 10 public IPv4 addresses. An empty list clears it.
curl -X PUT https://api.mobileproxy.live/v1/allowlist \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"ips":["203.0.113.24","198.51.100.7"]}'{
"allowlist": ["203.0.113.24", "198.51.100.7"]
}GET /v1/usage
Daily traffic in GB for the number of days you ask for, up to 90.
curl "https://api.mobileproxy.live/v1/usage?days=30" \
-H "Authorization: Bearer mp_sk_YOUR_API_KEY"{
"days": [
{ "date": "2026-11-22", "gb": "0.41" },
{ "date": "2026-11-23", "gb": "0.38" }
]
}How is the proxy username built?
The proxy username is a list of parts separated by dots. Connect to gw.mobileproxy.live on port 9000 for HTTP and HTTPS or port 9100 for SOCKS5, and use YOUR_PASSWORD as the stand in for your own password. The order is fixed:
account.type.country[.city-value][.carrier-value][.sid-value][.rot-value]
| Part | Needed | Example | Meaning |
|---|---|---|---|
account | Required | mp4x9q2 | Your proxy account name. It always comes first. |
type | Required | mobile | Product type. One of: mobile, resi, unl, isp, dc, pack. Mobile is the default. |
country | Required | us | Two letter lowercase country code. The default is us. |
city- | Optional | city-new-york | City in lowercase with hyphens for spaces. Residential targeting goes down to the city. |
carrier- | Optional | carrier-tmobile | Mobile carrier, written in lowercase with only letters. |
sid- | Optional | sid-a1b2 | Session id. Requests that use the same id on a line keep the same IP until the timer ends or you change it. |
rot- | Optional | rot-10 | Minutes between IP changes, from 1 to 60. Left out, the product default applies. |
Which type values exist?
| Type | Product | IP behavior |
|---|---|---|
mobile | 4G and 5G Mobile Proxies | New IP on a timer from 1 to 60 minutes, or on demand with your change-IP link |
resi | Residential IP Proxies | New IP per request, or the same IP for up to 60 minutes |
unl | Unlimited Traffic Proxies | New IP per request, or the same IP for up to 60 minutes |
isp | Fixed ISP Proxies | Fixed for the whole rental period |
dc | Exclusive Datacenter IPs | Fixed for the whole rental period |
pack | Datacenter IP Packs | Fixed for the whole rental period |
What do finished usernames look like?
- Mobile, United States, T-Mobile, new IP every 10 minutes
mp4x9q2.mobile.us.carrier-tmobile.sid-a1b2.rot-10 - Residential, Germany, Berlin
mp4x9q2.resi.de.city-berlin.sid-c3d4 - Fixed ISP, United Kingdom
mp4x9q2.isp.gb
Not every part applies to every product. City targeting is for products that list it, and the carrier part is for mobile lines. The country pages and the line builder in My lines show what each country offers.
How do rotation and the change-IP link work?
A mobile line changes its IP in two ways. The first is a timer: add rot-N to the username, with N from 1 to 60 minutes. The second is on demand: every mobile line has its own change-IP link in your account, or you can call the rotate endpoint above. Use the timer for steady jobs and the link when a task needs a fresh address right now.
The change-IP link has the shape below. The one here is only an example, since the real link is private to each line and appears in your account.
curl "https://gw.mobileproxy.live/rotate/k7Qm2xV9"The session part sid- keeps requests on one IP while the timer allows it, so give each task its own id. For connection guides for your tool, see the setup guides.
What do the errors mean?
Failures answer with an HTTP status and a short error code, for example:
{
"error": "insufficient_balance",
"message": "The balance is lower than the order total."
}| Status | Code | Meaning |
|---|---|---|
401 | invalid_key | The API key is missing, wrong or was replaced by a newer one. |
400 | invalid_product | The product slug is not one of the products listed above. |
400 | invalid_quantity | The quantity is not a whole number inside the product range. |
402 | insufficient_balance | The balance is lower than the order total. Nothing is charged. |
404 | line_not_found | The line id does not belong to your account. |
400 | invalid_ip | An allowlist entry is not a public IPv4 address, or there are more than 10. |
429 | rate_limited | Too many requests in a short time. Wait a moment and try again. |
Ready to build?
Open your account to get your lines and your key, then try the examples above.