Patient billing

Change a charge

  • Sandbox: available
  • On your own host? Choose https://{host} in the playground.
PATCH
/v1/patient-billing/charges/{chargeId}

Changes a charge that is not billed yet: its status, its quantity or its price. Fields left out stay as they are.

Scope: the caller's project, with PATIENT_BILLING_ENABLED on.

Behaviour

  • Your access policy must grant patient_billing_charges update and let you read the charge's patient, else 403 PATIENT_BILLING_NOT_ALLOWED. A charge you cannot see answers 404 CHARGE_NOT_FOUND.
  • status is billable, not-billable (not to be billed) or entered-in-error. A billed charge no longer changes: 409 CHARGE_BILLED.
  • priceOverride sets the unit price and needs an overrideReason; priceOverride: null returns the charge to the price list, as it applies on the day of the service, else 422 CHARGE_PRICE_MISSING.
  • Changes to one patient's charges run one at a time: another still running answers 409; send yours again.
  • If-Match: W/"<version>" is optional. With it, the change lands only on that version, else 412 CHARGE_VERSION_MISMATCH.

Example

curl -X PATCH 'https://api.sandbox.ovok.com/v1/patient-billing/charges/<chargeId>' \  -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3NjcyNjg4MDAsImV4cCI6MTc2NzI3MjQwMH0.Ql3B_ztDvctlyZ2z0vp4sl3ExXRQGkzmxdmTAqxNzZk' \  -H 'If-Match: W/"1"' \  -H 'Content-Type: application/json' \  -d '{ "status": "not-billable" }'

Authorization

bearer
headerAuthorizationBearer <JWT>

Path Parameters

chargeId*string

The charge id.

Match^[A-Za-z0-9\-.]{1,64}$

Request Body

application/json
  1. body
status?string
Value in"billable""not-billable""entered-in-error"
quantity?integer
Range1 <= value <= 9999
priceOverride?

null returns the charge to the price list.

overrideReason?string

Why the price list does not apply. Required with priceOverride.

Length1 <= length <= 200
Defaultnull

Response Body

The charge as changed.

application/json
  1. response
id*string
version*string

Send it as If-Match: W/"<version>" to change only this version.

patientId*string
clinicId*string
accountId*string
identifier*
status*string

billable until billed; billed, not-billable or entered-in-error.

code*
occurredAt*string
quantity*number
unitPrice*
total*

Unit price times quantity.

overrideReason*string

Why the price list did not apply; null when it did.

enteredAt*string
Example Request
curl -X PATCH 'https://api.sandbox.ovok.com/v1/patient-billing/charges/string' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "id": "string",  "version": "string",  "patientId": "string",  "clinicId": "string",  "accountId": "string",  "identifier": {    "system": "string",    "value": "string"  },  "status": "string",  "code": {    "system": "string",    "code": "string",    "display": "string"  },  "occurredAt": "string",  "quantity": 0,  "unitPrice": {    "value": 0,    "currency": "string"  },  "total": {    "value": 0,    "currency": "string"  },  "overrideReason": "string",  "enteredAt": "string"}