Reports

Tenant-scoped analytics and MATRADE Annex 2 reporting.

All report queries resolve the selected live organiser membership before reading attendees, points, or ledger entries.

OperationPurpose
GET /api/reports/analyticsSignup buckets, attendance, registration-backed ticket revenue and refunds, points, categories, and events for the selected day window.
GET /api/reports/matradeEvent-scoped MATRADE Annex 2 visitor, exhibitor, space, sales, and qualification data.
PATCH /api/reports/matrade/exhibitorSave one event exhibitor's country and net space, and optionally its booth, registered company name, registration number and whether it counts for MATRADE totals.
PATCH /api/reports/matrade/salesSave reported sales and notes; unknown sales remains null, distinct from verified zero.
PATCH /api/reports/matrade/readinessSave the organiser's MATRADE endorsement reference and appointed external auditor; blank clears a value.

All routes require an organiser session. Missing session returns 401, a caller outside the tenant returns 403, and mutations require an exact configured Origin. Money fields are integer cents; nullable sales are not coerced to zero.

MATRADE evidence retrieval

GET /api/reports/matrade?event=<event UUID or slug> returns { eventId, report }. Use an authenticated organiser session; crew and unauthorised event access are rejected. Responses are private, no-store.

Contract 4.2.0 adds optional generatedAt, registrationRows, population and classificationWarnings. Rows contain registration/attendee IDs, recorded name, company, job title, country and nationality, visitor type/source/purpose, participant category, registration and first entrance-check-in timestamps, and whether a registration snapshot exists. Email addresses and phone numbers are not added to this export. The read uses one repeatable-read database snapshot.

population reconciles confirmed registrations against distinct people and separates visitor, staff, exhibitor and unclassified people. Only captured visitor categories feed visitor figures. A missing or conflicting historical category remains unclassified; an attended unclassified person makes the visitor criterion indeterminate. The API does not mutate historical records to guess a category.

The retained foreignBuyers field means foreign trade visitors with unverified buyer status for compatibility. It must not be represented as a verified buyer list. Country may reflect travel origin; nationality is separate evidence. Exhibitors still come from the legacy event merchant roster and require review.

These are live drafts, not certified reports or evidence of MATRADE endorsement. Studio can download the full JSON response and formula-safe CSV tables. Preserve exports securely; subsequent source changes or synchronised scans can change a later response.

Contract 4.6.0

Adds optional endorsementRef and auditorName to the report, and optional boothLabel, registeredName, registrationNumber and excluded to each exhibitorRows entry. PATCH /api/reports/matrade/exhibitor accepts the same directory fields plus counted ("true" or "false"); omitted fields are left unchanged. Excluded exhibitors remain in exhibitorRows but are left out of every exhibitors total and criterion. New PATCH /api/reports/matrade/readiness accepts { eventId, endorsementRef, auditorName } and replaces both values on every call (a blank value clears it), so send the current value of the field you are not changing. The service enforces limits stricter than the published maxima: booth and readiness entries up to 200 characters, registered name up to 200, and registration number up to 50 using letters, numbers, spaces, brackets, dots, slashes or dashes. Violations return an { error } body.

On this page