Skip to main content
GET
/
inventory
/
packages
/
usage
/
{package_id}
Get Package Usage
curl --request GET \
  --url https://api.decodahealth.com/inventory/packages/usage/{package_id} \
  --header 'API-KEY: <api-key>' \
  --header 'TENANT: <tenant>'
[
  {
    "packageId": "<string>",
    "patientId": "<string>",
    "chargeItemId": "<string>",
    "status": "USED",
    "package": {
      "name": "<string>",
      "price": 123,
      "id": "<string>",
      "description": "<string>",
      "isArchived": false,
      "internalNotes": "<string>",
      "items": [
        {
          "packageId": "<string>",
          "itemId": "<string>",
          "price": 123,
          "id": "<string>",
          "quantity": 123,
          "item": {
            "name": "<string>",
            "price": 123,
            "id": "<string>",
            "brandName": "<string>",
            "description": "<string>",
            "category": "<string>",
            "unit": "AMPOULES",
            "isPhysical": true,
            "isArchived": false,
            "internalNotes": "<string>",
            "taxable": false,
            "sortOrder": 123,
            "allowCustomPricing": false,
            "type": "PRODUCT"
          }
        }
      ],
      "category": "<string>",
      "numberOfActivePatients": 0,
      "numberOfPatients": 0,
      "createdDate": "2023-11-07T05:31:56Z"
    },
    "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>"
      ],
      "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>"
    },
    "chargeItem": {
      "chargeId": "<string>",
      "quantity": 123,
      "price": 123,
      "id": "<string>",
      "itemId": "<string>",
      "name": "<string>",
      "description": "<string>",
      "discountAmount": 123,
      "discountPercentage": 123,
      "discountReason": "<string>",
      "soldPackageId": "<string>",
      "bankedQuantity": 123,
      "bankedItemId": "<string>",
      "issuedDiscountId": "<string>",
      "soldByProviderId": "<string>",
      "taxAmount": 123,
      "pricingId": "<string>",
      "shipmentIds": [
        "<string>"
      ]
    },
    "id": "<string>",
    "updatedDate": "2023-11-07T05:31:56Z",
    "items": [
      {
        "chargeId": "<string>",
        "quantity": 123,
        "price": 123,
        "charge": {
          "id": "<string>",
          "patientId": "<string>",
          "total": 123,
          "totalOutstanding": 123,
          "status": "OUTSTANDING",
          "description": "<string>",
          "createdDate": "2023-11-07T05:31:56Z"
        },
        "id": "<string>",
        "itemId": "<string>",
        "name": "<string>",
        "description": "<string>",
        "discountAmount": 123,
        "discountPercentage": 123,
        "discountReason": "<string>",
        "soldPackageId": "<string>",
        "bankedQuantity": 123,
        "bankedItemId": "<string>",
        "issuedDiscountId": "<string>",
        "soldByProviderId": "<string>",
        "taxAmount": 123,
        "pricingId": "<string>",
        "shipmentIds": [
          "<string>"
        ],
        "item": {
          "name": "<string>",
          "price": 123,
          "id": "<string>",
          "brandName": "<string>",
          "description": "<string>",
          "category": "<string>",
          "unit": "AMPOULES",
          "isPhysical": true,
          "isArchived": false,
          "internalNotes": "<string>",
          "taxable": false,
          "sortOrder": 123,
          "allowCustomPricing": false,
          "type": "PRODUCT"
        },
        "locationId": "<string>",
        "locationName": "<string>",
        "saleDate": "2023-11-07T05:31:56Z"
      }
    ]
  }
]

Headers

TENANT
string
required

The tenant you are making this request on behalf of

API-KEY
string
required

Your api key

Path Parameters

package_id
string
required

Query Parameters

patient_name
string | null

Filter by patient name

last_activity_date
string | null

Filter by last activity date

purchased_date
string | null

Filter by purchased date

status
string[] | null

Filter by package status

sort_by
string | null
default:created_date

Sort field

sort_direction
string | null
default:desc

Sort direction (asc or desc)

Response

Successful Response

packageId
string
required

Package ID that was sold

patientId
string
required

Patient ID who purchased the package

chargeItemId
string
required

Charge item ID associated with the package purchase

status
enum<string>
required

Status of the sold package

Available options:
USED,
ACTIVE,
CANCELLED
package
PackageDetail · object
required

Details of the package

createdDate
string<date-time>
required

Date the package was created

patient
PatientSummary · object
required

Details of the patient

chargeItem
ChargeItem · object
required

Details of the charge item

id
string

Unique identifier for the sold package

updatedDate
string<date-time> | null

Date the package was updated

items
ChargeItemDetailWithCharge · object[]

Items used in the package