Skip to content
RecipesDoc

Dashboard, API and CSV Export Show the Same Numbers

Certyn reads each source, recomputes the totals on its own in Python, and files each mismatch with the rows that cause it.

For teams whose app shows the same business number in several places, for example revenue.

Your setup

  • A dashboard with a total, for example last month's revenue.
  • An API endpoint and a CSV export with the same figure or its rows.
  • A test account that can see all three, on a test environment.

Say this to Certyn

Check that last month's revenue on /dashboard, the /api/reports/revenue response and the Orders CSV export agree. Recompute the total yourself and tell me where they differ and why.

What Certyn does

  1. If no test account is saved, opens the sign-in form (sign_in).
  2. Starts an explore run with your goal (app.run.create type explore), for example 30 minutes. A quick check can also run on the chat's Machine while you watch, but issues filed from the chat hold text only, no screenshots.
  3. Reads the dashboard figure in the browser and keeps a screenshot.
  4. In the shell, signs in with LOGIN_USERNAME and LOGIN_PASSWORD and saves the API response (curl or a short script).
  5. Gets the CSV with a short Playwright script that clicks Export and saves the download, or with curl on the export URL.
  6. Recomputes the total from the raw rows in Python, with exact decimals and the period, time zone and filters the dashboard uses. Compares the three numbers.
  7. When they differ, finds the cause: rounding per row versus on the total, orders near midnight on the wrong day, refunds or test orders counted in one place only, or records missing from one source.
  8. Files one issue per cause, with the three numbers, the rows that explain the gap and the script output.

What you get

  • A run report with each source's number and which ones agree.
  • One Certyn issue per cause, with rows as evidence.
  • On request, the script and a test case to repeat the check.

Limits

  • Certyn must know what the number means: gross or net, which statuses count, which time zone. Put it in your message or the wiki. Without it, a difference is reported as a question, not a bug.
  • Use a closed period. Data that changes during the run gives false differences.
  • It sees only what the test account can see.
  • An export sent only by email to the test account cannot be read. Use the download or the API.