Skip to the page

Search the titles, headings and text of every guide and API reference page.

    Chapters

    Attachments

    Discard an open attachment

    DELETE/api/v1/attachments/{id}

    Deletes an open attachment you no longer want (the wrong office or patient, or a payer that stopped taking attachments), with its documents and their images. A payer request it was answering can then be answered again, and the claim it was made for notes it on its timeline. A closed attachment cannot be discarded (409), nor one on a claim (take it off the claim first, 409), nor one being closed (409). Discarding one that is already gone is not found. Needs a key with submit.

    Needs a key with submit permission.

    Request

    Path parameters

    Path parameters
    NameTypeRequiredDescription
    idstringrequiredAn attachment ID (att_...).

    Response

    The attachment that was discarded. Status 200.

    Response fields
    NameTypeDescription
    idstringAn ID that starts with att_.
    objectstringAlways `attachment`.
    deletedbooleanAlways `true`.

    Errors

    Errors
    HTTP statusCodeWhat it means
    401UNAUTHORIZEDA valid API key is required. Send it as "Authorization: Bearer <key>".
    403PERMISSION_DENIEDThis API key is not allowed to do that.
    404NOT_FOUNDNot found.
    422INVALID_REQUESTThe request is not valid.
    429TOO_MANY_REQUESTSToo many requests of this kind lately. Wait, then try again.
    504TIMEOUTThe request took too long. Send it again with the same Idempotency-Key and body after Retry-After seconds: a 409 means it is still finishing (wait and send again), and any other answer is final. If this 504 comes back, find what the request made by listing with ?idempotency_key=<the key>.
    503ATTACHMENTS_UNAVAILABLEAttachments are not available in live mode yet. Use a test key.
    502ATTACHMENTS_NETWORK_ERRORThe attachment network did not finish. The attachment is still open and nothing was lost: close it again.
    409CONFLICTThe resource is not in a state that allows this, or it changed while the request was handled. Read it, then decide whether to send the request again.
    500INTERNALSomething went wrong on our side. Quote the request ID if you contact us.

    Example

    Example request

    Shell
    curl -X DELETE "https://app.myclaimhouse.com/api/v1/attachments/att_01JM000000E00800000000003G" \
      -H "Authorization: Bearer $CLAIMHOUSE_KEY"

    Example response: 200

    JSON
    {
      "id": "att_01JM000000E00800000000003G",
      "object": "attachment",
      "deleted": true
    }