B7RDevelopers
ReferenceReports
Reference / Reports

Reports

View .md

Ids, figures and times in the examples are samples. Read the real values from the API.

The reads below need the key area reports:read. They answer the figures your dashboard, profit page and first steps show in the app, for every order of your account. A period is today, 7d or 30d (that many days ending today) or total (the default), counted in Riyadh days: today starts at midnight in Riyadh. Money is SAR with two decimals; a profit can be negative. The figures are what B7R charged you, as your pages show them, never a cost inside B7R. When B7R cannot read them right now, a read answers 503 try_again_later: wait the Retry-After seconds and send it again.

Read your dashboard

GET/v1/reports/dashboard

The stat cards of the period: what customers paid for your paid sales (revenue, products and the shipping they paid), your profit after what B7R charged, the orders and products_sold. An order cancelled with its money kept counts its charge against your profit and nothing else, as on your dashboard. chart counts the orders by hour for today, by day for 7 days, by week for 30 days and by month for the total; each point gives the app’s label and its start in starts_at.

wallet is your balance and the low-balance warning your dashboard shows; it needs wallet:read beside reports:read, and is null without it. low_balance is false when no low-balance threshold is set; when the threshold cannot be read, the whole read answers 503 try_again_later rather than a line without its warning. welcome_bonus is the state of your welcome bonus and its amount.

Headers

Authorizationstringrequired

Bearer b7r_live_.... A key with the reports:read area. X-B7R-Key works too; send one, never both.

Accept-Languagestring

ar for Arabic error titles; anything else gives English. Codes never change.

Query

periodstring

One of today, 7d, 30d, total.

Answer

periodstringrequired

One of today, 7d, 30d, total.

revenuestringrequired
profitstringrequired
ordersintegerrequired
products_soldintegerrequired
chartarray of objectrequired
Child fields
labelstringrequired
starts_atstringrequired
ordersintegerrequired
walletobject or nullrequired
Child fields
balancestringrequired
low_balance_thresholdstring or nullrequired
low_balancebooleanrequired
welcome_bonusobjectrequired
Child fields
statestringrequired

One of not_eligible, pending_verify, crediting, stuck_pending, credited, unknown.

amountstring or nullrequired

Errors

Request
curl "https://api.b7r.app/v1/reports/dashboard?period=7d" \
  -H "Authorization: Bearer $B7R_API_KEY"
const res = await fetch("https://api.b7r.app/v1/reports/dashboard?period=7d", {
  headers: {
    Authorization: `Bearer ${process.env.B7R_API_KEY}`,
  },
});
const data = await res.json();
import os, requests

res = requests.get(
    "https://api.b7r.app/v1/reports/dashboard?period=7d",
    headers={
        "Authorization": f"Bearer {os.environ['B7R_API_KEY']}",
    },
    timeout=30,
)
data = res.json()
200 OK
{
  "period": "7d",
  "revenue": "1450.00",
  "profit": "410.00",
  "orders": 12,
  "products_sold": 17,
  "chart": [
    {
      "label": "Fri",
      "starts_at": "2026-11-19T21:00:00.000Z",
      "orders": 1
    },
    {
      "label": "Sat",
      "starts_at": "2026-11-20T21:00:00.000Z",
      "orders": 3
    }
  ],
  "wallet": {
    "balance": "320.00",
    "low_balance_threshold": null,
    "low_balance": false
  },
  "welcome_bonus": {
    "state": "not_eligible",
    "amount": null
  }
}

Read your profit

GET/v1/reports/profit

Your profit page for the period, between the Riyadh days from and to: what customers paid, what B7R charged (split into the products, the carrier fee and the B7R store fee) and the profit, then by store and by product at each price. A connected store’s line is its orders; b7rStore is your B7R store; manual orders have no customer price, so their customers_paid and profit are null and they stay out of the totals.

Headers

Authorizationstringrequired

Bearer b7r_live_.... A key with the reports:read area. X-B7R-Key works too; send one, never both.

Accept-Languagestring

ar for Arabic error titles; anything else gives English. Codes never change.

Query

periodstring

One of today, 7d, 30d, total.

Answer

periodstringrequired

One of today, 7d, 30d, total.

fromstringrequired
tostringrequired
customers_paidstringrequired
b7r_chargesstringrequired
charges_productsstringrequired
charges_shippingstringrequired
charges_store_feestringrequired
profitstringrequired
marginnumber or nullrequired
ordersintegerrequired
storesarray of objectrequired
Child fields
kindstringrequired

One of connected, b7rStore, manual.

store_connection_idstring (uuid) or nullrequired
ordersintegerrequired
customers_paidstring or nullrequired
b7r_chargesstringrequired
profitstring or nullrequired
productsarray of objectrequired
Child fields
product_idstring (uuid)required
soldintegerrequired
pricestringrequired
b7r_charge_per_itemstringrequired
profit_per_itemstringrequired
profitstringrequired

Errors

Request
curl "https://api.b7r.app/v1/reports/profit?period=30d" \
  -H "Authorization: Bearer $B7R_API_KEY"
const res = await fetch("https://api.b7r.app/v1/reports/profit?period=30d", {
  headers: {
    Authorization: `Bearer ${process.env.B7R_API_KEY}`,
  },
});
const data = await res.json();
import os, requests

res = requests.get(
    "https://api.b7r.app/v1/reports/profit?period=30d",
    headers={
        "Authorization": f"Bearer {os.environ['B7R_API_KEY']}",
    },
    timeout=30,
)
data = res.json()
200 OK
{
  "period": "30d",
  "from": "2026-10-28",
  "to": "2026-11-26",
  "customers_paid": "2400.00",
  "b7r_charges": "1650.00",
  "charges_products": "1200.00",
  "charges_shipping": "400.00",
  "charges_store_fee": "50.00",
  "profit": "750.00",
  "margin": 0.3125,
  "orders": 16,
  "stores": [
    {
      "kind": "connected",
      "store_connection_id": "8b9c0d1e-2f3a-4b4c-9d5e-6f7a8b9c0d1e",
      "orders": 14,
      "customers_paid": "2100.00",
      "b7r_charges": "1450.00",
      "profit": "650.00"
    },
    {
      "kind": "b7rStore",
      "store_connection_id": null,
      "orders": 2,
      "customers_paid": "300.00",
      "b7r_charges": "200.00",
      "profit": "100.00"
    }
  ],
  "products": [
    {
      "product_id": "4d5e6f7a-8b9c-4d0e-9f2a-3b4c5d6e7f8a",
      "sold": 20,
      "price": "120.00",
      "b7r_charge_per_item": "60.00",
      "profit_per_item": "60.00",
      "profit": "1200.00"
    }
  ]
}

Read your first steps

GET/v1/reports/setup

The six first steps of your dashboard, in order, each done or left: confirm your email, verification, a product, publish it, top up, the first order. They are answered even after you hid the guide in the app (dismissed: true).

Headers

Authorizationstringrequired

Bearer b7r_live_.... A key with the reports:read area. X-B7R-Key works too; send one, never both.

Accept-Languagestring

ar for Arabic error titles; anything else gives English. Codes never change.

Answer

dismissedbooleanrequired
stepsarray of objectrequired
Child fields
idstringrequired

One of email, verification, product, publish, topup, order.

donebooleanrequired

Errors

Request
curl https://api.b7r.app/v1/reports/setup \
  -H "Authorization: Bearer $B7R_API_KEY"
const res = await fetch("https://api.b7r.app/v1/reports/setup", {
  headers: {
    Authorization: `Bearer ${process.env.B7R_API_KEY}`,
  },
});
const data = await res.json();
import os, requests

res = requests.get(
    "https://api.b7r.app/v1/reports/setup",
    headers={
        "Authorization": f"Bearer {os.environ['B7R_API_KEY']}",
    },
    timeout=30,
)
data = res.json()
200 OK
{
  "dismissed": false,
  "steps": [
    {
      "id": "email",
      "done": true
    },
    {
      "id": "verification",
      "done": true
    },
    {
      "id": "product",
      "done": true
    },
    {
      "id": "publish",
      "done": false
    },
    {
      "id": "topup",
      "done": true
    },
    {
      "id": "order",
      "done": false
    }
  ]
}

Titles and headings of every page. llms-full.txt holds the full text.