Referral

A list of all publicly available methods for interacting with the API.

GET

Summary statistics

/user/referral-summary
This method requires authorization!
You can use your own API key, which can be obtained at control panel.
This method - requires permissions -packages.read
When creating an API token in your control panel, you can choose certain permissions (for example: prevent the token from placing orders).
You can also find a list of permissions in our documentation.

Query method

GEThttps://api.stableproxy.com/v2/user/referral-summary

Code examples

1const baseUrl = "https://api.stableproxy.com/v2";
2const response = await fetch(baseUrl + "/user/referral-summary", {
3 method: "GET",
4 headers: {
5 "Authorization": "API-Token [YOUR TOKEN]",
6 "Content-Type": "application/json"
7 }
8});
9const data = await response.json();

Examples of answers

Success response200application/json
{
  "data": {
    "referred_count": 4,
    "transactions": {
      "total": 636,
      "total_paid": 634,
      "total_on_hold": 2,
      "paid_sum_in_usd": 875.7261312969324,
      "on_hold_sum_in_usd": 1.7534466911764706,
      "paid_sum": 38111.6012340425,
      "on_hold_sum": 76.31,
      "currency": "UAH"
    }
  },
  "good": true,
  "timestamp": 1731402566,
  "cause": {
    "type": "user",
    "user_id": 1,
    "token_id": 9845,
    "token_sign": "edd87db549cd52292a47ad455bbea947"
  }
}