Deal turnover (Turnover)
Daily PayIn/PayOut deal turnover for the merchant's cabinet charts — date window, grouping, and excluded statuses
Deal turnover (Turnover)
The turnover endpoint returns aggregated deal amounts for the merchant over
a date window — the data source for the turnover chart in the cabinet. It
reads from the same UNION surface as the deal
listing (orders amount → PAYIN, payouts
amount_fiat → PAYOUT). Read-only and dual-homed: the cabinet JWT or the
merchant HMAC pair.
Request
GET /api/v1/p2p/merchant/deals/turnover?date_from=...&date_to=...Parameters (Query Parameters)
| Field | Type | Required | Description |
|---|---|---|---|
date_from | string(RFC3339) | Yes | The window start (inclusive). |
date_to | string(RFC3339) | Yes | The window end (inclusive). Must not be earlier than date_from. |
deal_type | string | No | "PAYIN" (orders amounts) / "PAYOUT" (payouts amounts) / empty = both directions. |
Window constraints
- The window is at most 92 days wide
(
date_to − date_from ≤ 92 days), otherwise400. - Days without deals are simply absent from the response — the client fills in the axis when plotting.
Response (200 OK)
A live staging response (window 2026-08-01 … 2026-08-23):
{
"data": [
{ "date": "2026-08-23", "deal_type": "PAYIN", "amount_minor": "100000", "currency": "RUB" },
{ "date": "2026-08-23", "deal_type": "PAYIN", "amount_minor": "100000", "currency": "RUB" },
{ "date": "2026-08-23", "deal_type": "PAYOUT", "amount_minor": "96971", "currency": "RUB" },
{ "date": "2026-08-23", "deal_type": "PAYOUT", "amount_minor": "98980", "currency": "RUB" }
],
"next_page_token": ""
}TurnoverMerchantDealsRow fields
| Field | Type | Description |
|---|---|---|
date | string | The UTC calendar day the deal was created (YYYY-MM-DD). The day bucket is strictly UTC — the DB session timezone does not shift the boundaries. |
deal_type | string | "PAYIN" or "PAYOUT". |
amount_minor | int64 | The group's deal amount in minor units (kopecks). |
currency | string | ISO 4217 (for PayOut, the code resolves through p2p_currencies). |
Aggregate granularity. Grouping runs over the combination (type ×
currency × the deal's exact creation time), and the date in a row is
the calendar day of that time. In practice, this means that deals created
in different seconds of the same day produce separate rows sharing the
same date (see the live example above — 2 PAYIN rows for one day). Sum
amount_minor by the (date, deal_type, currency) key on the client
to get the daily total. Row order: date ASC, deal_type ASC,
currency ASC.
Which deals count toward turnover
Turnover measures traffic, not only completed deals: every status counts except the unsuccessful ones:
| Source | Excluded statuses |
|---|---|
PayIn (p2p_orders) | EXPIRED, SPAM_REJECTED |
PayOut (p2p_payouts) | FAILED, EXPIRED |
Errors (live staging responses)
400 — missing dates
{
"type": "about:blank",
"title": "Bad Request",
"status": 400,
"detail": "{\"code\":3,\"message\":\"date_from and date_to are required (RFC3339)\",\"details\":[]}",
"instance": "/api/v1/p2p-engine"
}400 — window wider than 92 days
{
"type": "about:blank",
"title": "Bad Request",
"status": 400,
"detail": "{\"code\":3,\"message\":\"date window too large: at most 92 days between date_from and date_to\",\"details\":[]}",
"instance": "/api/v1/p2p-engine"
}400 INVALID_ARGUMENT is also returned for: a non-RFC3339
date_from/date_to (invalid date_from (RFC3339): ...), date_to earlier
than date_from (date_to must not be earlier than date_from), and an
unknown deal_type (invalid deal_type "X": must be PAYIN, PAYOUT or empty (both)).
Related materials
- Deal listing — the paginated UNION listing.
- CSV export — the full deal export.
- Merchant limits —
daily_deal_amount_limitcounts against the same daily volume.
Wallet (USDT)
Withdrawing your balance in USDT over the TRON network, and the TRC-20 deposit address for topping up the merchant's collateral balance
Deposit promo bonuses
PayIn deposit promo bonuses: a sponsored bonus on top of the merchant's regular net, and the fee_breakdown object (merchant-side picture only) in the deal.completed webhook