---
title: "Transaction breakdown"
method: GET
path: "/v1/analytics/transactions/breakdown"
tags: ["Analytics"]
---

# Transaction breakdown

`GET /v1/analytics/transactions/breakdown`

## Request

- Base URL: `https://api.subscriby.net`
- URL: `https://api.subscriby.net/v1/analytics/transactions/breakdown`
- Auth: HTTP bearer

USD-normalised successful-payment totals grouped by one `dimension`: `plan`, `payment_provider`, `currency` or `project`. `dimension` is **required**.

```bash
curl "https://api.subscriby.net/v1/analytics/transactions/breakdown?dimension=payment_provider&period=90d" \
  -H "Authorization: Bearer $SUBSCRIBY_TOKEN"
```

## Query parameters

- `dimension` string, required
- `project_id` string, uuid
- `period` string
- `from` string, date
- `to` string, date
- `plan_ids[]` string[]
- `statuses[]` string[]
- `payment_method_ids[]` string[]

## Response `200`

Gross revenue grouped by the dimension.

- object
  - `data` object, required: The response's payload.
    - `range` object, required: The window the preset resolved to.
      - `from` string, required: The first day of the window, `YYYY-MM-DD`.
      - `to` string, required: The last day of the window, `YYYY-MM-DD`.
    - `dimension` string, required: The dimension the payments were grouped by: `plan`, `payment_provider`, `currency` or `project`.
    - `total_gross_usd` number, required: Every settled payment in the window, in USD; the base `share_percent` is measured against.
    - `groups` object[], required: One row per distinct value of the dimension, largest gross first.
      - `key` string, required: The value's identifier: a plan or project id, a provider key or a currency code.
      - `label` string, required: The value's display name, in the creator's language where it has one.
      - `gross_usd` number, required: The group's settled payments in the window, converted to USD.
      - `transactions` integer, required: How many settled payments the group holds.
      - `share_percent` number, required: The group's part of `total_gross_usd`, two decimals.
  - `meta` object, required: The request's window, dimension and scope, echoed back.
    - `period` string, required: The preset the window resolved from, as requested.
    - `dimension` string, required: The dimension, as requested.
    - `project_id` string, nullable, required: The project the figures were scoped to, or `null` for every project the token may see.

## Other responses

- `401`: `AUTHENTICATION_REQUIRED`: the request carries no bearer token, or one that is revoked, malformed, or minted for another environment (an `sbt_test_` token on production).
- `403`: `TOKEN_MISSING_ABILITY`: the token is valid but does not carry the ability this endpoint requires; `error.context.required_ability` names the one to grant. An endpoint that also checks who owns a row or which tier the account is on answers `FORBIDDEN`, `TEAM_TIER_REQUIRED` or `CONNECTOR_TIER_REQUIRED` with the same status, and says so in its own description.
- `422`: `VALIDATION_FAILED`: when `dimension` is missing or not one of the four, or `project_id` is not a UUID.
- `429`: `RATE_LIMITED`: the token has spent its 300 requests a minute or 10,000 an hour; `Retry-After` says when the next one is accepted.

---

[API](https://skmtc.dev/memberpass/apis/subscriby-rest-api.md) · [All operations](https://skmtc.dev/memberpass/apis/subscriby-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/memberpass/apis/subscriby-rest-api/revisions/59c4df91d764?raw)
