Skip to content

Install and use the SDKs

The official SDKs handle REST authentication, typed requests and responses, pagination, and API errors. Use them in your backend to create customers, record purchases, allocate quotas, generate credentials, and read usage. They do not send HTTP or SOCKS traffic through the proxy.

Run the command in your backend project. Use your normal lockfile to keep deployments reproducible.

Use Node.js 22 or later. The same package supports JavaScript and TypeScript, with bundled types. Choose your package manager:

Terminal window
npm install @proxyrequest/sdk

The examples use ESM imports: use an .mjs file or set "type": "module" in package.json. TypeScript uses the same calls. See the official npm package.

Replace {api_host} with your API hostname, without a scheme or path. Replace {api_key} with a backend-only static key. The SDK sets the Authorization: Static … header for you.

RequestGET /profile
curl 'https://{api_host}/api/v1/profile' \
--header 'Authorization: Static {api_key}'
Response200 OK

Selected fields

{
"id": "550e8400-e29b-41d4-a716-446655440001",
"username": "customer_demo_42",
"is_reseller": false,
"is_superuser": false,
"orders": []
}
Show full responseShow selected fields
{
"id": "550e8400-e29b-41d4-a716-446655440001",
"username": "customer_demo_42",
"email": "",
"is_reseller": false,
"is_marketer": false,
"is_superuser": false,
"date_joined": "2026-09-16T12:00:00Z",
"date_joined_ts": 1789560000,
"first_name": "",
"last_name": "",
"balance": 0,
"language": "en",
"country": "",
"state": "",
"city": "",
"address": "",
"zip": "",
"company_name": "",
"company_address": "",
"company_city": "",
"company_postal_code": "",
"company_country": "",
"company_vat_number": "",
"allowed_ips": [],
"blocked_domains": [],
"connection_limit": 100,
"parent_id": "550e8400-e29b-41d4-a716-446655440010",
"sub_users": 0,
"referrals": 0,
"referral_id": "",
"referral_code": "example42",
"referral_data_earned": 0,
"referral_data_pending": 0,
"referral_balance_pending": 0,
"referral_balance_earned": 0,
"currency": {
"code": "USD",
"symbol": "$"
},
"coupons": [],
"orders": []
}

Replace placeholders in braces with your values. Responses use synthetic example data.Install SDKsAPI reference →

Select a language in any Request window. The choice carries across the guides. Each snippet includes imports, a client, and one operation; reuse a client in your application instead of creating one for every call.

The Response window shows example HTTP JSON, not a second request to execute. Python and PHP return typed models; JavaScript and TypeScript return the corresponding typed data. Expand Show full response for fields omitted from the preview. Some SDKs also send documented default values for optional fields; omitting those fields in cURL has the same effect. In proxy-generation examples, leave the format string’s tokens unchanged: the generator replaces them with the resulting proxy credentials.

For an account session, select the JWT example in API fundamentals. Use withBearerToken in JavaScript/PHP or with_bearer_token in Python. A proxy username/password is not an API credential.

SDKs do not change permissions or accounting rules. Only an administrator can create an invoice with status: paid. Adding data to a virtual child order assigns a quota; it does not buy data or move purchased ledgers.

The SDK automatically protects supported writes during a small number of transient network retries in the same call. If the call still fails or the application restarts before saving the result, treat the outcome as uncertain: inspect the affected invoice, order, user or webhook before submitting another write.

Pass the current ETag as {etag} for examples using If-Match, including its quotes. A conflict requires re-reading the resource and deciding whether the write is still appropriate. See retries and concurrency.

The generated API Reference remains the HTTP contract, with its own raw HTTP examples. Use the SDK tabs in these guides for client-library examples. Once credentials are generated, use your application’s HTTP/SOCKS client or the cURL proxy smoke test to send traffic.