Skip to main content

Check residential traffic & spend

See how much traffic a residential package used and what it cost through the API.

This guide shows you how to see how much traffic a residential package used and what it cost.

Every request uses your personal API key from your account dashboard (how to get your API key). In the examples below, replace YOUR_API_KEY with your own key. To pay from your account balance, use paymentId = 1.

Step 1 — Get the package info

Get the package status and overall traffic left. Copy the package_key.

Endpoint

GET https://proxy-seller.com/personal/api/v1/YOUR_API_KEY/resident/package

Response

{
  "status": "success",
  "data": {
    "rotation": 60,
    "traffic_limit": "7516192768",
    "traffic_usage": "10",
    "traffic_left": "10",
    "package_key": "1234567890abcdefedcb",
    "expired_at": "d.m.Y",
    "is_active": true,
    "tarif_id": 2
  },
  "errors": []
}

Step 2 — Get the traffic usage

Get detailed traffic usage for the package. You can filter by list login or a date range.

Endpoint

POST https://proxy-seller.com/personal/api/v1/YOUR_API_KEY/resident/traffic/details

Request body

Name

Type

Description

packageKey

String

Package key (from package info).

login (optional)

String

Optional: filter by list login.

date_start (optional)

String

Optional date filter, format DD.MM.YYYY.

date_end (optional)

String

Optional date filter, format DD.MM.YYYY.

Response

{
  "status": "success",
  "data": {
    "package_key": "1234567890abcdefedcb",
    "traffic_usage": "275414777856",
    "traffic_usage_formated": "256.5 GB"
  },
  "errors": []
}

Step 3 — Get the spend report

Get the spend report: amount, price per GB and the breakdown by list.

Endpoint

POST https://proxy-seller.com/personal/api/v1/YOUR_API_KEY/resident/consumption

Request body

Name

Type

Description

login (optional)

String

Optional: filter by list login.

date_start (optional)

String

Optional date filter, format DD.MM.YYYY.

date_end (optional)

String

Optional date filter, format DD.MM.YYYY.

Response

{
  "status": "success",
  "data": {
    "package_key": "1234567890abcdefedcb",
    "orders_amount": "$557.99",
    "orders_bytes_formated": "256.5 GB",
    "price_per_gb": "$2.17"
  },
  "errors": []
}

Full API reference

Did this answer your question?