Skip to main content

Support configuration

Support configuration is the ruleset that says, for each of a provider's product codes, which support documents are required. It's what seeds the PENDING document placeholders on a pre-appointment: when a charge references a provider_product_code that has required supports configured, those placeholders appear automatically.

In the pilot there is no admin UI for this — the configuration is loaded in bulk from a CSV.

Asynchronous CSV upload

POST /v1/checkin/support-configs/upload
Content-Type: multipart/form-data (part: file, text/csv)

The upload is validated synchronously, then processed asynchronously:

  1. The provider is resolved from the authenticated token — never from the request or the CSV content.
  2. The file is validated up front: correct MIME type (text/csv) and the required header columns. A failure returns 400 with no side effect — nothing is stored, nothing is queued.
  3. On success the CSV is stored in S3, a SupportConfigUploadProcess is persisted with status PENDING, and a message is published to pre-attendance-worker for background parsing / validation / upsert.
  4. The endpoint returns 202 Accepted with a process_id. Maximum file size: 25 MB.

Tracking the process

GET /v1/checkin/support-configs/process/{processId}

Returns the current status and metrics of the process. The response always includes errors_file_url — a presigned download URL for the validation-errors CSV, or null when there were no row-level errors. Only the process owned by the authenticated provider is visible; another provider's process returns 404.

To download the errors CSV directly (as a text/csv attachment):

GET /v1/checkin/support-configs/process/{processId}/errors

Because parsing is per-row, a process can partially succeed: valid rows are upserted while invalid rows are collected into the errors CSV. Always check errors_file_url after the process finishes.

Endpoints

OperationEndpoint
Upload CSVPOST /v1/checkin/support-configs/upload
Get process statusGET /v1/checkin/support-configs/process/{processId}
Download errors CSVGET /v1/checkin/support-configs/process/{processId}/errors

For a step-by-step walk-through see Upload a support-config CSV.

Common pitfalls

  • Wrong MIME type. The part must be text/csv. Exporting from a spreadsheet as .xlsx won't work.
  • Missing header columns400, before anything is stored. Fix the header and re-upload.
  • Not polling for row errors. A 202 means accepted, not fully applied. Poll the process and download the errors CSV to see which rows were rejected.
  • Reading another provider's process404. Processes are provider-scoped.