GET /v1/referrals/rewards — List referral rewards
https://api.triport.io/v1/referrals/rewards?status=pending,available&limit=50&offset=0Lists the calling user's referral rewards — one row per qualifying payment event — with optional status filtering and pagination.
Returns the referral rewards that belong to the authenticated user. Each reward
is a snapshot of a single qualifying payment made by one of your invitees: the
rate_bps and tier are frozen at the moment the reward is created and are
not recalculated if your tier later changes.
Use this endpoint to render the rewards ledger in the Console — the detailed
breakdown behind the aggregate balance shown by
GET /v1/referrals/me. Filter by status to drive views
such as "pending unlock", "available to spend", or "paid out".
This route is authenticated by the Console session cookie, not by an API key — it is a first-party Console endpoint and requests must be sent with credentials included. There is no bearer token or scope on this route.
Parameters
All parameters are query-string parameters.
statusstringoptionalpending, available, spent, paid_out, reversed. Unknown values are passed through and simply match nothing. Omit to return all statuses.limitintegeroptional1–200. Defaults to 50; values outside the range (or non-numeric) are ignored and the default is used.offsetintegeroptional>= 0. Defaults to 0; invalid values are ignored and the default is used.Response
200 OK
When the user has no matching rewards, items is an empty array ([]), never
null.
itemsarrayErrors
| Code | Meaning | When it happens |
|---|---|---|
401 | unauthenticated | No valid Console session cookie was supplied. |
500 | internal | An unexpected server-side error occurred while listing rewards. |
Errors use the shared error envelope: { "error": "<code>" }. See
errors.md for the full envelope and handling guidance.
Examples
JavaScript (fetch)
const params = new URLSearchParams({
status: "pending,available",
limit: "50",
offset: "0",
});
const res = await fetch(
`https://api.triport.io/v1/referrals/rewards?${params}`,
{ credentials: "include" } // send the Console session cookie
);
if (!res.ok) throw new Error(`HTTP ${res.status}`);
const { items } = await res.json();
console.log(`${items.length} rewards`);TypeScript SDK (@triport/sdk)
import { TriportClient } from "@triport/sdk";
const client = new TriportClient({ baseUrl: "https://api.triport.io" });
const { items } = await client.referrals.listRewards({
status: ["pending", "available"],
limit: 50,
offset: 0,
});
for (const reward of items) {
console.log(reward.id, reward.status, reward.amount_micro);
}Python (triport-sdk)
from triport import TriportClient
client = TriportClient(base_url="https://api.triport.io")
rewards = client.referrals.list_rewards(
status=["pending", "available"],
limit=50,
offset=0,
)
for reward in rewards["items"]:
print(reward["id"], reward["status"], reward["amount_micro"])Notes
- Pagination. Page through results with
limitandoffset. The response contains onlyitems(no total count) — when a page returns fewer thanlimitrows, you have reached the end. - Amounts are micro-units. Divide
amount_microby 1,000,000 to get the display value. - Frozen snapshot.
rate_bpsandtierreflect the values in effect when the reward was created and do not change retroactively. - Related endpoints:
GET /v1/referrals/mefor the aggregate balance,GET /v1/referrals/inviteesfor the invitee list, andGET /v1/referrals/payoutsfor payout history.