API 概要
DocsAPI 概要

API 概要

RaxyProxy REST API の認証、リクエスト形式、レスポンスエンベロープと全エンドポイントマップ。

ベース URL

https://raxyproxy.com/api/v1

すべてのエンドポイントは /api/v1. HTTPS is required.

認証

すべてのリクエストには Authorization ヘッダーに Bearer トークン形式で API キーを含めます。キーは API Keys page.

Authorization: Bearer raxy_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
example.sh
curl https://raxyproxy.com/api/v1/account \
     -H "Authorization: Bearer raxy_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

キーは秘密に

API キーはアカウントへの完全アクセスを付与します — リポジトリにコミットしないでください。環境変数またはシークレットマネージャーを使用してください。

エンドポイント

v1 のすべての公開エンドポイント。各行は詳細ページへのリンク。

メソッドパス目的
GET/accountProfile, balance, 30d traffic, API key info
GET/packagesList active and suspended packages
GET/packages/{id}Detailed package (includes proxy password)
GET/packages/{id}/proxiesGenerate ready-to-use proxy strings
GET/packages/{id}/statsTime-series usage (minute / hour / day)
GET/packages/{id}/stats/hostsTop destinations by traffic
GET/packages/{id}/stats/errorsRecent error events per host / code
POST/packages/{id}/rotate-passwordGenerate a new proxy password
PATCH/packages/{id}/threadsUpdate max concurrent connections
PATCH/packages/{id}/protocolsEnable/disable HTTP & SOCKS5
GET/packages/{id}/allowed-ipsList whitelisted client IPs
POST/packages/{id}/allowed-ipsAdd an IP to the whitelist
DELETE/packages/{id}/allowed-ips/{ip}Remove an IP from the whitelist
GET/packages/{id}/blocked-hostsList domains the package may not reach
PUT/packages/{id}/blocked-hostsReplace the blocked-hosts list
GET/packages/{id}/default-geoDefault geo applied without per-request params
PUT/packages/{id}/default-geoUpdate default geo (countries/states/cities/ASNs…)
POST/packages/{id}/top-upAdd GB to the package using wallet balance
GET/packages/{id}/top-upsHistory of top-ups for this package
GET/locations/countriesAvailable countries for a pool type
GET/locations/statesStates within selected countries
GET/locations/citiesCities within selected countries/states
GET/locations/zipcodesZIP codes within selected countries/states
GET/locations/asnsASNs within selected countries/states/cities

レスポンスエンベロープ

すべての成功レスポンスは標準エンベロープでラップされます:

response.json
{
  "data": { ... },
  "meta": {
    "version": "v1"
  }
}

data field contains the actual payload (object or array depending on the endpoint). Paginated endpoints include additional keys inside meta.

エラー

エラー時、HTTP ステータスコードは問題のカテゴリを示します。ボディには機械可読コードと人間可読メッセージを含む error key with a machine-readable code and a human-readable message.

ステータスコード意味
400invalid_request不正なリクエスト — 無効なパラメータ
401unauthorizedAPI キーが欠落または無効
402payment_required残高不足 — ウォレットをチャージしてください
403forbidden / insufficient_scope禁止 — キーに scope がない
404not_foundリソースが見つかりません
409conflict競合 — 状態が操作を妨げる(例: IP がすでに whitelist 済み)
422validation_failedバリデーション失敗 — errors オブジェクトを確認
429rate_limitedレート制限超過 — Retry-After ヘッダーを参照
500http_error内部サーバーエラー
502provider_errorアップストリームプロバイダーエラー — 一時的、後で再試行
error.validation.json
{
  "error": {
    "code":    "validation_failed",
    "message": "Validation failed",
    "errors":  { "threads": ["The threads field must be between 1 and 2000."] }
  },
  "meta": { "version": "v1" }
}

レート制限

API キーごとの制限、エンドポイント種類別。到達時は 429 + Retry-After。

グループ制限エンドポイント
api120 / min/account, /packages, /packages/{id}
stats-api60 / min/stats, /stats/hosts, /stats/errors, /top-ups
proxies-api30 / min/proxies
settings-api30 / minall package mutations (rotate-password, allowed-ips, …)
locations-api60 / min/locations/*
topup-api10 / min/packages/{id}/top-up
HTTP/1.1 429 Too Many Requests
Retry-After: 12
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 0

OpenAPI / AI 仕様

ツール、SDK、AI アシスタント用の機械可読仕様:

フォーマットURLユースケース
OpenAPI 3.0 JSON/openapi.jsonSwagger UI、Postman、SDK ジェネレーター
Plain text (LLM)/llms-api.txtChatGPT、Claude、Cursor コンテキスト