Order quote; no debit
/account/api/v1/quoteAuthorization
| Authorization | Bearer YOUR_ARNPROXY_API_KEY |
|---|---|
| Required permission | read |
| Accept | application/json |
| Content-Type | application/json |
Parameters
| Name | Type | Description |
|---|---|---|
product_id | integer | Product ID from products; 1–2147483647. |
lines | object[] | 1–20 distinct location lines for one product. No duplicate location_id; at most 100000 proxies in total. |
lines[].location_id | integer | Location ID from the selected product catalog. |
lines[].time_id | integer | Period ID offered for that location. |
lines[].quantity | integer | 1–100000, also subject to product.minimum_quantity. |
promo_code | string | Optional promo, up to 100 bytes. Keep it identical between quote and purchase/renewal. Default: "" |
Request body
Replace YOUR_/FROM_ placeholders with values from the relevant catalog, quote or scope. Examples leave consent false; only approve a real operation intentionally.
{
"product_id": "FROM_PRODUCTS",
"lines": [
{
"location_id": "FROM_CATALOG",
"time_id": "FROM_CATALOG",
"quantity": 1
}
],
"promo_code": ""
}Additional usage examples
IDs and prices are illustrative; use real values from the catalog and the same quote. JSON IDs and expected_total_minor must be numbers. Examples deliberately keep terms=false; submit terms=true only after explicit customer approval for the real paid operation.
One product type, two countries
Quote lines do not take a purpose: location_id, time_id and quantity are sufficient. Purpose fields are required at the purchase stage.
{
"product_id": 5,
"lines": [
{
"location_id": 10,
"time_id": 101,
"quantity": 1
},
{
"location_id": 11,
"time_id": 102,
"quantity": 1
}
],
"promo_code": ""
}Request example
printf 'Authorization: Bearer %s\n' "$ARNPROXY_API_KEY" |
curl --silent --show-error --header @- \
--header 'Accept: application/json' \
--connect-timeout 10 --max-time 30 \
--request POST --header 'Content-Type: application/json' \
--data-binary @request.json \
'https://www.arnproxy.com/account/api/v1/quote'Examples are not executed on this page. Keep the API key in a server-side environment variable; do not put real keys in URLs or browser code. Prepare request.json for POST examples.
{"curl":"printf \u0027Authorization: Bearer %s\\n\u0027 \u0022$ARNPROXY_API_KEY\u0022 |\n curl --silent --show-error --header @- \\\n --header \u0027Accept: application\/json\u0027 \\\n --connect-timeout 10 --max-time 30 \\\n --request POST --header \u0027Content-Type: application\/json\u0027 \\\n --data-binary @request.json \\\n \u0027https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0027","python":"import os, requests\n\nheaders = {\u0022Authorization\u0022: \u0022Bearer \u0022 + os.environ[\u0022ARNPROXY_API_KEY\u0022]}\nimport json\nwith open(\u0022request.json\u0022, encoding=\u0022utf-8\u0022) as f:\n payload = json.load(f)\nresponse = requests.post(\n \u0022https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0022,\n headers=headers, json=payload,\n timeout=(10, 30), allow_redirects=False\n)\nprint(response.status_code, response.text)\n# No automatic write retry.","javascript":"const headers = { Authorization: `Bearer ${process.env.ARNPROXY_API_KEY}` };\nconst { readFile } = await import(\u0027node:fs\/promises\u0027);\nheaders[\u0027Content-Type\u0027] = \u0027application\/json\u0027;\nconst body = await readFile(\u0027request.json\u0027, \u0027utf8\u0027);\nconst response = await fetch(\u0022https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0022, {\n method: \u0027POST\u0027, headers, redirect: \u0027error\u0027,\n signal: AbortSignal.timeout(30000), body\n});\nconsole.log(response.status, await response.text());\n\/\/ A write timeout is ambiguous; query its saved operation.","php":"\u003C?php\n$headers = [\u0027Accept: application\/json\u0027,\n \u0027Authorization: Bearer \u0027.getenv(\u0027ARNPROXY_API_KEY\u0027)];\n$headers[] = \u0027Content-Type: application\/json\u0027;\n$ch = curl_init(\u0027https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0027);\ncurl_setopt_array($ch, [\n CURLOPT_RETURNTRANSFER =\u003E true,\n CURLOPT_HTTPHEADER =\u003E $headers,\n CURLOPT_FOLLOWLOCATION =\u003E false,\n CURLOPT_SSL_VERIFYPEER =\u003E true, CURLOPT_SSL_VERIFYHOST =\u003E 2,\n CURLOPT_CONNECTTIMEOUT =\u003E 10, CURLOPT_TIMEOUT =\u003E 30,\n CURLOPT_POST =\u003E true,\n CURLOPT_POSTFIELDS =\u003E file_get_contents(\u0027request.json\u0027),\n]);\n$result = curl_exec($ch);\nif ($result === false) {\n \/\/ Do not repeat a write; use the original operation key.\n throw new RuntimeException(\u0027Transport result unknown\u0027);\n}\necho curl_getinfo($ch, CURLINFO_HTTP_CODE).PHP_EOL.$result;\ncurl_close($ch);","go":"package main\n\nimport (\n \u0022fmt\u0022\n \u0022io\u0022\n \u0022net\/http\u0022\n \u0022os\u0022\n \u0022time\u0022\n)\n\nfunc main() {\n client := \u0026http.Client{Timeout: 30*time.Second,\n CheckRedirect: func(req *http.Request, via []*http.Request) error {\n return http.ErrUseLastResponse\n }}\n var body io.Reader\n file, err := os.Open(\u0022request.json\u0022); if err != nil { panic(err) }\n defer file.Close(); body = file\n req, err := http.NewRequest(\u0022POST\u0022, \u0022https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0022, body)\n if err != nil { panic(err) }\n req.Header.Set(\u0022Authorization\u0022, \u0022Bearer \u0022+os.Getenv(\u0022ARNPROXY_API_KEY\u0022))\n req.Header.Set(\u0022Content-Type\u0022, \u0022application\/json\u0022)\n res, err := client.Do(req); if err != nil { panic(err) }\n defer res.Body.Close()\n data, err := io.ReadAll(res.Body); if err != nil { panic(err) }\n fmt.Println(res.StatusCode, string(data))\n}","csharp":"using System;\nusing System.IO;\nusing System.Net.Http;\nusing System.Net.Http.Headers;\nusing System.Text;\n\nusing var handler = new HttpClientHandler { AllowAutoRedirect = false };\nusing var client = new HttpClient(handler) { Timeout = TimeSpan.FromSeconds(30) };\nusing var request = new HttpRequestMessage(HttpMethod.Post,\n \u0022https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0022);\nrequest.Headers.Authorization = new AuthenticationHeaderValue(\n \u0022Bearer\u0022, Environment.GetEnvironmentVariable(\u0022ARNPROXY_API_KEY\u0022));\nrequest.Content = new StringContent(\n await File.ReadAllTextAsync(\u0022request.json\u0022), Encoding.UTF8, \u0022application\/json\u0022);\nusing var response = await client.SendAsync(request);\nConsole.WriteLine((int)response.StatusCode);\nConsole.WriteLine(await response.Content.ReadAsStringAsync());\n\/\/ Never automatically retry an ambiguous write.","java":"import java.net.URI;\nimport java.net.http.*;\nimport java.nio.charset.StandardCharsets;\nimport java.nio.file.*;\n\n\/\/ Inside your application method:\nvar client = HttpClient.newHttpClient();\nvar request = HttpRequest.newBuilder(URI.create(\u0022https:\/\/www.arnproxy.com\/account\/api\/v1\/quote\u0022))\n .header(\u0022Authorization\u0022, \u0022Bearer \u0022 + System.getenv(\u0022ARNPROXY_API_KEY\u0022))\n .header(\u0022Accept\u0022, \u0022application\/json\u0022)\n .header(\u0022Content-Type\u0022, \u0022application\/json\u0022)\n .POST(HttpRequest.BodyPublishers.ofString(\n Files.readString(Path.of(\u0022request.json\u0022), StandardCharsets.UTF_8)))\n .build();\nvar response = client.send(request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.statusCode());"}Responses
{
"ok": true,
"data": {
"product": {
"id": 5,
"name": "IPv4 Proxy",
"minimum_quantity": 1
},
"currency": "TRY",
"quantity": 1,
"base_total": "10.00",
"quantity_discount_amount": "0.00",
"subtotal": "10.00",
"promotion": {
"code": "",
"rate": "0.00",
"amount": "0.00"
},
"total": "10.00",
"total_minor": 1000,
"lines": [
{
"location_id": 10,
"country": "Example country",
"time_id": 101,
"period": "7 days",
"days": 7,
"quantity": 1,
"base_unit_price": "10.0000",
"quantity_discount_rate": "0.00",
"unit_price": "10.0000",
"base_total": "10.00",
"subtotal": "10.00",
"promotion_amount": "0.00",
"total": "10.00",
"total_minor": 1000
}
],
"discount_scope": "country",
"estimate_only": true,
"stock_checked": false,
"purchase_available": false,
"calculated_at": "2030-01-01T12:00:00+00:00"
},
"meta": {
"request_id": "000000000000000000000001",
"phase": "public_v1",
"source": "arnproxy_records"
}
}Response fields and types
| Name | Type | Description |
|---|---|---|
ok | boolean | Success envelope flag; on false inspect error.code. |
data | object | Operation-specific result; examples are illustrative and synthetic. |
data.product | object | Operation-specific product value; preserve its demonstrated type and consult the behavior notes. |
data.product.id | integer | Relevant ARNPROXY record ID; use it instead of the upstream internal ID. |
data.product.name | string | Operation-specific name value; preserve its demonstrated type and consult the behavior notes. |
data.product.minimum_quantity | integer | Minimum quantity for each order line of this product. |
data.currency | string | Account transaction currency: TRY or USD. |
data.quantity | integer | Selected or ordered proxy quantity. |
data.base_total | string | Money amount; preserve the returned string/integer representation for precision. |
data.quantity_discount_amount | string | Operation-specific quantity discount amount value; preserve its demonstrated type and consult the behavior notes. |
data.subtotal | string | Money amount; preserve the returned string/integer representation for precision. |
data.promotion | object | Operation-specific promotion value; preserve its demonstrated type and consult the behavior notes. |
data.promotion.code | string | Operation-specific code value; preserve its demonstrated type and consult the behavior notes. |
data.promotion.rate | string | Operation-specific rate value; preserve its demonstrated type and consult the behavior notes. |
data.promotion.amount | string | Money amount; preserve the returned string/integer representation for precision. |
data.total | string | Money amount; preserve the returned string/integer representation for precision. |
data.total_minor | integer | Integer minor units: 1000 means 10.00 TRY/USD. |
data.lines | array | Operation-specific lines value; preserve its demonstrated type and consult the behavior notes. |
data.lines[] | object | Operation-specific lines value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].location_id | integer | Local catalog location or product-type ID. |
data.lines[].country | string | Operation-specific country value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].time_id | integer | Local period/GB-plan record ID, not a day or GB count. |
data.lines[].period | string | Human-readable catalog period name. |
data.lines[].days | integer | Plan duration in days, separate from a GB plan’s traffic amount. |
data.lines[].quantity | integer | Selected or ordered proxy quantity. |
data.lines[].base_unit_price | string | Operation-specific base unit price value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].quantity_discount_rate | string | Operation-specific quantity discount rate value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].unit_price | string | Operation-specific unit price value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].base_total | string | Money amount; preserve the returned string/integer representation for precision. |
data.lines[].subtotal | string | Money amount; preserve the returned string/integer representation for precision. |
data.lines[].promotion_amount | string | Operation-specific promotion amount value; preserve its demonstrated type and consult the behavior notes. |
data.lines[].total | string | Money amount; preserve the returned string/integer representation for precision. |
data.lines[].total_minor | integer | Integer minor units: 1000 means 10.00 TRY/USD. |
data.discount_scope | string | Operation-specific discount scope value; preserve its demonstrated type and consult the behavior notes. |
data.estimate_only | boolean | Operation-specific estimate only value; preserve its demonstrated type and consult the behavior notes. |
data.stock_checked | boolean | A price/local result is not by itself a provider or stock guarantee. |
data.purchase_available | boolean | Availability under the result’s conditions/permissions, not a stock or provider guarantee. |
data.calculated_at | string | Timestamp in the API’s returned representation; example dates are synthetic. |
meta | object | Request correlation and data-source metadata. |
meta.request_id | string | This HTTP request’s correlation ID, not an operation key or order ID. |
meta.phase | string | Operation-specific phase value; preserve its demonstrated type and consult the behavior notes. |
meta.source | string | Data source; local records and a live provider lookup are different evidence. |
Error response
{
"ok": false,
"error": { "code": "INVALID_API_KEY" },
"meta": { "request_id": "000000000000000000000001" }
}Authentication and validation may reject a request before execution. Consult the error reference and retain request_id when contacting support. Never send keys or passwords. Errors & limits →
Behavior & important notes
- Take identifiers from products/catalog. Quote lines contain only location_id, time_id and quantity. Purchase lines additionally require purpose_id=201 and the selected subpurpose_id.
- Quote lines do not take a purpose: location_id, time_id and quantity are sufficient. Purpose fields are required at the purchase stage.
- Use up to 20 distinct location_id values under one product_id. Each country creates a separate order record; the linked checkout is handled as one invoice. Quantity discounts are calculated independently per country.