Referral Summary
curl --request GET \
--url https://backend-global.gains.trade/api/referrals/summary/{address}import requests
url = "https://backend-global.gains.trade/api/referrals/summary/{address}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://backend-global.gains.trade/api/referrals/summary/{address}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://backend-global.gains.trade/api/referrals/summary/{address}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://backend-global.gains.trade/api/referrals/summary/{address}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://backend-global.gains.trade/api/referrals/summary/{address}")
.asString();require 'uri'
require 'net/http'
url = URI("https://backend-global.gains.trade/api/referrals/summary/{address}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"result": {
"account": "<string>",
"code": "<string>",
"referralsCount": {
"l1": 123,
"l2": 123
},
"rewards": {
"account": "<string>",
"lifetimeUsd": "<string>",
"l1Usd": "<string>",
"l2Usd": "<string>",
"cashbackUsd": "<string>",
"claimableMicroUsdc": "<string>",
"settledMicroUsdc": "<string>",
"unpaidMicroUsdc": "<string>"
},
"effectiveRate": {
"l1RateBps": 123,
"l2RateBps": 123
},
"vip": {
"tier": 123,
"cashbackBps": 123,
"stakedGns": "<string>",
"volume30dUsd": "<string>",
"stakeTier": 123,
"volumeTier": 123,
"next": {
"tier": 123,
"stakedGns": "<string>",
"volumeUsd": "<string>"
}
}
}
}{
"error": "<string>",
"message": "<string>",
"success": true
}{
"error": "<string>",
"message": "<string>",
"success": true
}Referrals
Referral Summary
Dashboard composite for one address.
GET
/
api
/
referrals
/
summary
/
{address}
Referral Summary
curl --request GET \
--url https://backend-global.gains.trade/api/referrals/summary/{address}import requests
url = "https://backend-global.gains.trade/api/referrals/summary/{address}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://backend-global.gains.trade/api/referrals/summary/{address}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://backend-global.gains.trade/api/referrals/summary/{address}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://backend-global.gains.trade/api/referrals/summary/{address}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://backend-global.gains.trade/api/referrals/summary/{address}")
.asString();require 'uri'
require 'net/http'
url = URI("https://backend-global.gains.trade/api/referrals/summary/{address}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"result": {
"account": "<string>",
"code": "<string>",
"referralsCount": {
"l1": 123,
"l2": 123
},
"rewards": {
"account": "<string>",
"lifetimeUsd": "<string>",
"l1Usd": "<string>",
"l2Usd": "<string>",
"cashbackUsd": "<string>",
"claimableMicroUsdc": "<string>",
"settledMicroUsdc": "<string>",
"unpaidMicroUsdc": "<string>"
},
"effectiveRate": {
"l1RateBps": 123,
"l2RateBps": 123
},
"vip": {
"tier": 123,
"cashbackBps": 123,
"stakedGns": "<string>",
"volume30dUsd": "<string>",
"stakeTier": 123,
"volumeTier": 123,
"next": {
"tier": 123,
"stakedGns": "<string>",
"volumeUsd": "<string>"
}
}
}
}{
"error": "<string>",
"message": "<string>",
"success": true
}{
"error": "<string>",
"message": "<string>",
"success": true
}Endpoint
GET /api/referrals/summary/{address}
Dashboard composite for one address.
Parameters
| Parameter | Location | Required | Type | Description |
|---|---|---|---|---|
address | path | Yes | string | EVM address. |
vip is null when no tier snapshot exists. effectiveRate reports the standard programme rate; a negotiated partner rate is applied to earnings but is not reflected in this field.
Usage Example
curl -X GET "https://backend-global.gains.trade/api/referrals/summary/0x1111111111111111111111111111111111111111"
Response Structure
The generated API panel lists the response schema for status codes: 200, 400, 500. Error responses return anerror field.⌘I
