curl --request POST \
--url https://api.decodahealth.com/billing/cart/{cart_id}/items \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--header 'TENANT: <tenant>' \
--data '
{
"itemId": "<string>",
"packageId": "<string>",
"quantity": 1,
"unitPrice": 123,
"discountAmount": 0,
"discountPercentage": 0,
"notes": "<string>"
}
'{
"id": "<string>",
"patient": {
"id": "<string>",
"type": "PROVIDER",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"patientSource": "SELF_SCHEDULING",
"leadSource": "<string>",
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"dosespotPatientId": "<string>"
},
"status": "DRAFT",
"discountAmount": 123,
"discountPercentage": 123,
"taxAmount": 123,
"total": 123,
"subtotal": 123,
"creator": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "<string>",
"createdDate": "2023-11-07T05:31:56Z"
},
"items": [],
"quotes": [
{
"id": "<string>",
"patientId": "<string>",
"status": "DRAFT",
"discountAmount": 123,
"discountPercentage": 123,
"taxAmount": 123,
"total": 123,
"creatorId": "<string>",
"cartId": "<string>",
"title": "<string>",
"itemCount": 0,
"packageCount": 0,
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"validUntilDate": "2023-11-07T05:31:56Z",
"sentDate": "2023-11-07T05:31:56Z",
"viewedDate": "2023-11-07T05:31:56Z",
"respondedDate": "2023-11-07T05:31:56Z",
"internalNotes": "<string>",
"creator": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "<string>",
"createdDate": "2023-11-07T05:31:56Z"
},
"patient": {
"id": "<string>",
"type": "PROVIDER",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"patientSource": "SELF_SCHEDULING",
"leadSource": "<string>",
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"dosespotPatientId": "<string>"
}
}
],
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"expiresDate": "2023-11-07T05:31:56Z",
"notes": "<string>",
"convertedChargeId": "<string>"
}Add an item to cart with quantity, pricing, and discounts. Automatically recalculates cart totals.
curl --request POST \
--url https://api.decodahealth.com/billing/cart/{cart_id}/items \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--header 'TENANT: <tenant>' \
--data '
{
"itemId": "<string>",
"packageId": "<string>",
"quantity": 1,
"unitPrice": 123,
"discountAmount": 0,
"discountPercentage": 0,
"notes": "<string>"
}
'{
"id": "<string>",
"patient": {
"id": "<string>",
"type": "PROVIDER",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"patientSource": "SELF_SCHEDULING",
"leadSource": "<string>",
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"dosespotPatientId": "<string>"
},
"status": "DRAFT",
"discountAmount": 123,
"discountPercentage": 123,
"taxAmount": 123,
"total": 123,
"subtotal": 123,
"creator": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "<string>",
"createdDate": "2023-11-07T05:31:56Z"
},
"items": [],
"quotes": [
{
"id": "<string>",
"patientId": "<string>",
"status": "DRAFT",
"discountAmount": 123,
"discountPercentage": 123,
"taxAmount": 123,
"total": 123,
"creatorId": "<string>",
"cartId": "<string>",
"title": "<string>",
"itemCount": 0,
"packageCount": 0,
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"validUntilDate": "2023-11-07T05:31:56Z",
"sentDate": "2023-11-07T05:31:56Z",
"viewedDate": "2023-11-07T05:31:56Z",
"respondedDate": "2023-11-07T05:31:56Z",
"internalNotes": "<string>",
"creator": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"email": "<string>",
"createdDate": "2023-11-07T05:31:56Z"
},
"patient": {
"id": "<string>",
"type": "PROVIDER",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"patientSource": "SELF_SCHEDULING",
"leadSource": "<string>",
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"dosespotPatientId": "<string>"
}
}
],
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"expiresDate": "2023-11-07T05:31:56Z",
"notes": "<string>",
"convertedChargeId": "<string>"
}The tenant you are making this request on behalf of
Your api key
Schema for creating cart items (can be either items or packages).
ID of the item to add to cart
ID of the package to add to cart
Quantity of the item/package
Custom unit price in cents (if different from item/package price)
Discount amount in cents
Discount percentage (0-100)
Notes about this item/package
Successful Response
Summary schema for cart with basic details.
Cart ID
Patient details
Show child attributes
Cart status
DRAFT, ABANDONED, ACCEPTED, REJECTED, CONVERTED, EXPIRED Total discount in cents
Overall discount percentage
Total tax in cents
Final total in cents
Calculate subtotal from items after item-level discounts.
Creator details
Show child attributes
Items and packages in the cart
Show child attributes
Quotes created from this cart
Show child attributes
Date the cart was created
Date the cart was last updated
When the cart expires
Notes about the cart
ID of charge if cart was converted