Plans & line generation
GET /plans lists the active plans a key owns. POST /plans/{id}/generate turns a residential plan into ready-to-use host:port:user:pass lines with country, city, ISP and sticky-session targeting.
GET
/api/v1/plansList plans
Your active plans: residential GB balances and dedicated allocations. The
id is what you pass to the generate endpoint below.curl https://hproxy.com/api/v1/plans -H "X-API-Key: hpx_your_key_here"POST
/api/v1/plans/{id}/generateGenerate proxy lines
Turn a residential plan you own into ready-to-use proxy lines, fully programmatic — the same hardened generator the dashboard uses. Lines come back as
host:port:username:password with the targeting baked into the username, so any HTTP or SOCKS5 client uses them as-is. Every field is optional; an empty body returns one rotating line with the plan's defaults. Generating lines is free and repeatable — traffic is only consumed when the lines are used. All generated lines draw from the SAME plan balance. Dedicated per-IP products don't generate; fetch them from GET /proxies instead.| Parameter | Type | Required | Description |
|---|---|---|---|
protocol | string | optional | "http" (default) or "socks5". |
count | integer | optional | Lines to return, 1 to 1000. Default 1. |
country | string | optional | Country targeting, e.g. "US" (letters only, 2 to 40 chars). |
state | string | optional | State / region targeting, where the pool supports it. |
city | string | optional | City targeting, where the pool supports it. |
isp | string | optional | ISP targeting — Residential Survey plans only (400 on other products). |
stickyMinutes | integer | optional | Sticky-session length in minutes. Omit for rotating IPs. |
curl -X POST https://hproxy.com/api/v1/plans/cmjfmhhpd004c4i4hqsk3mzrr/generate \
-H "X-API-Key: hpx_your_key_here" \
-H "Content-Type: application/json" \
-d '{"count": 3, "country": "US", "stickyMinutes": 30}'Ownership is strict: the plan must be yours and active, anything else is a plain 404 (an id never confirms another account's plan exists). Free-text targeting is validated before it touches the network — letters, digits, spaces and simple punctuation only — so a bad value is a clean 400 naming the rule. The exact host, port and username grammar in the response varies by pool; treat lines as opaque and use them verbatim.
Building a reseller integration? The reselling guide walks the whole loop: fund, buy, generate or fetch, deliver, renew.
Need a hand wiring this up? Email [email protected]. A real person reads every message.