SHOW_SIMULATION in the reference
webapp. If your integration doesn’t need bulk ingest, skip it.
What you’ll build
- A drag-and-drop file picker (
.csvand.xlsx). - An upload action with progress feedback.
- A success / row-level error screen.
- A “download template” link (static asset).
Prerequisites
- An authenticated user.
X-Preferred-Partner-Idset.- The user has
Permissions.prisma(selectsprisma) orPermissions.fdlive(selectsfdlive). Determines theevent_typequery param.
The call chain
On upload:| Method | URL | Host | Notes |
|---|---|---|---|
| POST | events/bulk_upload?event_type=prisma|fdlive | CR API | multipart/form-data with file field. Manually attach Authorization and X-Preferred-Partner-Id headers — the reference webapp doesn’t use its axios instance here. |
Request
Response
The endpoint returns either of two shapes — the reference webapp branches on the response shape, not on status code: Success / partial success (row-level errors):400 is just a sentinel inside the array body, not the HTTP status.
The HTTP response is 200. If the inner array is empty (or absent), the
upload fully succeeded.
Top-level error:
Reference implementation
XMLHttpRequest is the simplest way to get onUploadProgress in the
browser; fetch only got it in 2024 and support is uneven. Switch to
fetch with ReadableStream if you control the runtime.
Template
Provide a downloadable template so users know the column layout:| Column | Type | Notes |
|---|---|---|
title | string | Required. |
start_date_time | ISO 8601 | Required. UTC or with offset. |
city | string | Required. |
venue | string | Required. |
category | string | One of the partner’s registered event categories. |
capacity | integer | Optional. |
currency | ISO 4217 | Optional; falls back to partner default. |
price_min / price_max | number | Optional. |
Gotchas
CR API host, not main API
CR API host, not main API
Just like Event Editor. Sending this to
the main API returns 404.
Manually attach auth headers
Manually attach auth headers
The reference webapp bypasses its axios instance (so no automatic
transformRequest), and manually adds Authorization and
X-Preferred-Partner-Id. Replicate, or you’ll get 401.Two error shapes — handle both
Two error shapes — handle both
[400, [...]] array vs { detail: [...] } object. The HTTP status is
200 for both successful and partial-failure responses; you must
inspect the body.onUploadProgress is required UX for large files
onUploadProgress is required UX for large files
Without it, users will refresh the page mid-upload. Surface a percent.
Path concatenation has no leading slash in the reference webapp
Path concatenation has no leading slash in the reference webapp
${crURL}events/bulk_upload — assumes crURL ends in /. If you build
your URL differently, double-check there’s exactly one slash.Related
- Event editor — same host, single-event flow.
- Simulation — same host, creates a single event.
- File uploads cookbook.