Skip to content

Reading responses

All authenticated requests to a valid URL will receive a subclass of Generic Response and an HTTP Status of 200 OK. Every response will supply a Status that indicates whether the request was successful and provides additional information in case of failure to help debug or troubleshoot issues. See the Response attributes “Status” and “Status Message” below for more details.

An invalid URL will still send an HTTP 404 Not Found error.

Certain requests, detailed below, use the typical REST design of using the HTTP Status code.

The Status Field

Most responses contain a status field, which states whether the request was processed successfully or if there was a problem with the request. The possible values for the Status of a response are as follows:

Status Meaning
SUCCESS The request was successful.
ERROR An unexpected error occurred. See the Status Message for a more detailed description of where the problem occurred.
NOT FOUND The request was valid, but the requested information could not be found based on the request data.
INVALID CRITERIA The request parameters were not valid. This result will be returned if, for example, the CollaborateMD customer number is not supplied or is not 8 digits long.

Other statuses are possible for certain endpoints; see the endpoint-specific documentation for full details. Because of that:

Write your handler defensively. Treat SUCCESS as the only success, and route every other value — including ones not listed here — to your error path rather than falling through silently. REPORT RUNNING is the one value that means “not finished, ask again” rather than “failed”, so handle it explicitly if you use the report endpoints.

The body also contains a StatusMessage field with a human-readable detail specific to the outcome. These messages are intended to be human-readable, so your code should generally not depend on them. The only exception is the Claim, Appointment, and Patient creation messages, which return the claim, patient, and/or appointment ID in the StatusMessage, as shown in the example response from the claim creation API below.

Example: Successful Response

HTTP/1.1 200 OK
<?xml version="1.0"?>
<GenericResponseXML xmlns="http://www.collaboratemd.com/api/v1/">
<Status>SUCCESS</Status>
<StatusMessage>10002002:10003003</StatusMessage>
<Identifier>12345</Identifier>
</GenericResponseXML>

Example: HTTP 200 with a Body-Level Error

This scenario can be confusing as it is not standard REST:

HTTP/1.1 200 OK
<?xml version="1.0"?>
<GenericResponseXML xmlns="http://www.collaboratemd.com/api/v1/">
<Status>ERROR</Status>
<StatusMessage>Your credentials do not have access to the requested customer.</StatusMessage>
</GenericResponseXML>

Your application must parse the Status field; HTTP 200 by itself is not a success indicator.

The Try-It Console Caveat

The try-it console (powered by Scalar) will display a green 200 OK indicator even when the response body contains Status: ERROR. This visual indicator does not reflect the true outcome. Always check the Status field in the response body, not the console’s status badge.

HTTP Status Exceptions

The binary-download endpoints break this rule and use real HTTP status codes for most errors:

  • GET /v1/customer/{custno}/claim/download-837 — archived claim files
  • GET /v1/customer/{custno}/payment/download-835 — ERA remittance files

For these endpoints only, the HTTP status code is authoritative, and there is no Status field. Their outcomes are:

Outcome Response
Files exist HTTP 200, a ZIP archive, with Content-Disposition set for download
No files for that date HTTP 200 and a plain-text message
Invalid date format HTTP 400
Invalid customer number HTTP 404

Be careful about the HTTP 200 for “no files found” — the request was successful, but the files don’t exist, so you have to check the response type. See Download ERA and 837 files for how to tell them apart.

Reading Your Response

  1. If you called a download endpoint, use the HTTP status code, then check whether the payload is a ZIP archive or the plain-text “no files” message.

  2. Otherwise parse the body and read Status first:

    • SUCCESS — use the response data.
    • REPORT RUNNING — not finished; poll again.
    • anything else — an error; read StatusMessage for the detail, and do not assume the value is one of the four common ones.

Common Issues and How to Resolve Them

See the Error Reference for guidance on specific error messages.