Skip to content

Create order batch

POST/v1/order-batches

Creates 1–20 orders for distinct patients in one practice, each with 1–20 prescriptions. Each accepts patientId or inline patient details. Orders and newly created patients commit atomically; any failure saves none. Requires orders:write and Idempotency-Key; inline patients also require patients:write. Omitted actor context defaults to the authenticated service account as a system actor. Sign and submit each resulting order separately using orders:sign.

Request example

Replace example values with your Test data. Check the field rules below before you send a request.

{
  "practiceId": "prac_01j2y8m6jcc9tt24af5pw9x1bc",
  "userId": "user_01j2y8m6jcc9tt24af5pw9x1bc",
  "prescriber": {
    "id": "prov_01j2y8m6jcc9tt24af5pw9x1bc",
    "npi": "<string>",
    "externalId": "<string>",
    "profile": {
      "email": "<string>",
      "phone": "<string>"
    }
  },
  "orders": [
    {
      "otcItems": [
        {
          "catalogItemId": "cat_01j2y8m6jcc9tt24af5pw9x1bc",
          "quantity": 1
        }
      ],
      "externalOrderId": "<string>",
      "metadata": "<string>",
      "patientId": "pat_01j2y8m6jcc9tt24af5pw9x1bc",
      "patient": {
        "address": {
          "city": null,
          "line1": null,
          "line2": null,
          "postalCode": "<string>",
          "state": "<string>",
          "country": null
        },
        "clinicalProfile": {
          "currentMedications": [
            "<string>"
          ],
          "heightInches": null,
          "reviewedAt": null,
          "weightPounds": null
        },
        "dateOfBirth": "<string>",
        "email": "<string>",
        "externalId": "<string>",
        "externalIdentities": [
          {
            "source": "<string>",
            "value": "<string>"
          }
        ],
        "addresses": [
          {
            "id": null,
            "address": {
              "city": null,
              "country": null,
              "line1": null,
              "line2": null,
              "postalCode": null,
              "state": null
            },
            "label": "<string>",
            "preferredShipping": false,
            "recipientName": null
          }
        ],
        "encounters": [
          {
            "notes": null,
            "occurredAt": "<string>",
            "providerName": null,
            "type": "<string>"
          }
        ],
        "gender": "f",
        "locationId": "loc_01j2y8m6jcc9tt24af5pw9x1bc",
        "metadata": "<string>",
        "medicalRecordNumber": "<string>",
        "measurements": [
          {
            "heightCentimeters": null,
            "recordedAt": "<string>",
            "source": "<string>",
            "weightKilograms": null
          }
        ],
        "name": {
          "first": "<string>",
          "last": "<string>",
          "middle": null,
          "preferred": null
        },
        "phone": "<string>",
        "programs": [
          {
            "endedAt": null,
            "name": "<string>",
            "startedAt": "<string>",
            "status": "active"
          }
        ]
      },
      "shippingAddressId": "addr_01j2y8m6jcc9tt24af5pw9x1bc",
      "prescriptions": [
        {
          "externalPrescriptionId": "<string>",
          "clinical": {
            "compoundingReason": {
              "category": null,
              "context": null
            },
            "medicationReviewStatus": "not_reviewed",
            "diagnosisReviewStatus": "not_reviewed",
            "currentMedications": [
              null
            ],
            "diagnoses": [
              null
            ],
            "observations": [
              null
            ]
          },
          "pharmacyId": "pharm_01j2y8m6jcc9tt24af5pw9x1bc",
          "daysSupply": 1,
          "dispensing": {
            "dispenseUponAcceptance": false,
            "shippingOptionId": "shp_01j2y8m6jcc9tt24af5pw9x1bc",
            "shippingAmountCents": 0,
            "shippingDestinationType": "patient",
            "pharmacyNotes": "<string>",
            "requestedFillDate": "<string>",
            "substitutionPermitted": false
          },
          "directions": "<string>",
          "medicationId": "cat_01j2y8m6jcc9tt24af5pw9x1bc",
          "quantity": 0,
          "quantityUnit": "<string>",
          "refills": 0,
          "structuredSig": {
            "dose": "<string>",
            "doseUnit": "<string>",
            "duration": "<string>",
            "frequency": "<string>",
            "indication": "<string>",
            "maxDailyUse": "<string>",
            "prn": false,
            "route": "<string>",
            "titrationSchedule": "<string>"
          }
        }
      ]
    }
  ]
}
curl -X POST 'https://api.affinityrx.com/v1/order-batches' \
  -H "Authorization: Bearer $AFFINITY_API_KEY" \
  -H 'Affinity-Version: 2026-09-28' \
  -H 'Idempotency-Key: <Idempotency-Key>' \
  -H 'Content-Type: application/json' \
  --data @request.json

Response example

These examples show the body structure. Values can differ. Select a status code to see its response.

{
  "object": "order_batch",
  "practiceId": "prac_01j2y8m6jcc9tt24af5pw9x1bc",
  "userId": "user_01j2y8m6jcc9tt24af5pw9x1bc",
  "livemode": false,
  "orders": [
    {
      "revision": "<string>",
      "otcItems": [
        {
          "catalogItemId": "cat_01j2y8m6jcc9tt24af5pw9x1bc",
          "name": "<string>",
          "quantity": 0,
          "unitPriceCents": 0,
          "subtotalCents": 0
        }
      ],
      "externalOrderId": "<string>",
      "metadata": "<string>",
      "createdAt": "<string>",
      "id": "ord_01j2y8m6jcc9tt24af5pw9x1bc",
      "livemode": false,
      "object": "order",
      "patientId": "pat_01j2y8m6jcc9tt24af5pw9x1bc",
      "practiceId": "prac_01j2y8m6jcc9tt24af5pw9x1bc",
      "prescriptions": [
        {
          "pharmacyId": "pharm_01j2y8m6jcc9tt24af5pw9x1bc",
          "externalPrescriptionId": "<string>",
          "createdAt": "<string>",
          "directions": "<string>",
          "version": "<string>",
          "id": "rx_01j2y8m6jcc9tt24af5pw9x1bc",
          "medicationId": "cat_01j2y8m6jcc9tt24af5pw9x1bc",
          "medicationName": "<string>",
          "object": "prescription",
          "quantity": 0,
          "quantityUnit": "<string>",
          "refills": 0,
          "status": "requires_provider_signature"
        }
      ],
      "userId": "user_01j2y8m6jcc9tt24af5pw9x1bc",
      "status": "requires_provider_signature"
    }
  ]
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 400,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 401,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 403,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 404,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 409,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 422,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 429,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}
{
  "code": "<string>",
  "data": "<string>",
  "detail": "<string>",
  "instance": "<string>",
  "requestId": "<string>",
  "status": 503,
  "title": "<string>",
  "traceId": "<string>",
  "type": "<string>"
}

Implementation specification

Use these field types and limits to build your integration. Download the OpenAPI document for the complete contract.

Headers

Affinity-Versionstring

Selects the HTTP API contract for this request only. When omitted, API-key requests use their service account’s stored version. Does not change the stored default.

Pin requests to 2026-09-28.

Idempotency-Keystringrequired
Affinity-Actor-Idstring

Required for user actors and optional for system actors. Omit both actor headers to use the authenticated service account as a system actor.

Affinity-Actor-Typestring

Use user when a person initiated the action and system for autonomous work. Omit both actor headers to default to system.

Request body specification application/json

practiceIdstringrequired

Pattern: ^prac_[0-7][0-9a-hjkmnp-tv-z]{25}$

userIdstring | null
Show userId fields
Any of · 1: string

string

Pattern: ^user_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

prescriberobject | null
Show prescriber fields
Any of · 1: object
idstring | null
Show id fields
Any of · 1: string

string

Pattern: ^prov_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

npistring | null
Show npi fields
Any of · 1: string

string

Any of · 2: null

null

externalIdstring | null
Show externalId fields
Any of · 1: string

string

Any of · 2: null

null

profileobject | null
Show profile fields
Any of · 1: object
emailstring | null
Show email fields
Any of · 1: string

string

Pattern: ^[^\s@]+@[^\s@]+\.[^\s@]+$

Any of · 2: null

null

phonestring | null
Show phone fields
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

Any of · 2: null

null

ordersobject[]required

Minimum items: 1

Maximum items: 20

Show orders fields

Array items · object

otcItemsobject[] | null
Show otcItems fields
Any of · 1: object[]

Array items · object

catalogItemIdstringrequired

Pattern: ^cat_[0-7][0-9a-hjkmnp-tv-z]{25}$

quantityintegerrequired

Minimum: 1

Maximum: 100

Any of · 2: null

null

externalOrderIdany | null
Show externalOrderId fields
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\p{Cs}]*$

Any of · 2: null

null

metadataobject | null
Show metadata fields
Any of · 1: object
Additional properties
Any of · 1: string

string

Maximum length: 500

Pattern: ^[^\p{Cs}]*$

Any of · 2: number

number

Any of · 3: boolean

boolean

Any of · 4: null

null

object

Any of · 2: null

null

patientIdstring | null
Show patientId fields
Any of · 1: string

string

Pattern: ^pat_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

patientobject | null
Show patient fields
Any of · 1: object
addressobject | null | null
Show address fields
Any of · 1: object | null
Any of · 1: object
cityanyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show city fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

line1anyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show line1 fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

line2any | null | null
Show line2 fields
Any of · 1: any | null
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

Any of · 2: null

null

Any of · 2: null

null

postalCodestringrequired
statestringrequired
countrystring | null
Show country fields
Any of · 1: string

string

Allowed: "US"

Any of · 2: null

null

Any of · 2: null

null

Any of · 2: null

null

clinicalProfileobject | null
Show clinicalProfile fields
Any of · 1: object
currentMedicationsstring[]required

Maximum items: 100

Show currentMedications fields

Array items · string

string

Pattern: ^[^\u0000\p{Cs}]*$

heightInchesnumber | string | null | null
Show heightInches fields
Any of · 1: number | string | null
Any of · 1: number | string
Any of · 1: number

number

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

Any of · 2: null

null

Any of · 2: null

null

reviewedAtstring | null | null
Show reviewedAt fields
Any of · 1: string | null
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

weightPoundsnumber | string | null | null
Show weightPounds fields
Any of · 1: number | string | null
Any of · 1: number | string
Any of · 1: number

number

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

Any of · 2: null

null

Any of · 2: null

null

Any of · 2: null

null

dateOfBirthstringrequired

Pattern: ^\d{4}-\d{2}-\d{2}$

emailstring | null | null
Show email fields
Any of · 1: string | null
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

externalIdstring | null
Show externalId fields
Any of · 1: string

string

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

externalIdentitiesobject[] | null
Show externalIdentities fields
Any of · 1: object[]

Array items · object

sourcestringrequired

Pattern: ^[^\u0000\p{Cs}]*$

valuestringrequired

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

addressesobject[] | null
Show addresses fields
Any of · 1: object[]

Array items · object

idstring | null
Show id fields
Any of · 1: string

string

Pattern: ^addr_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

addressobjectrequired

No additional properties

Show address fields
cityanyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show city fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

countrystring | null
Show country fields
Any of · 1: string

string

Allowed: "US"

Any of · 2: null

null

line1anyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show line1 fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

line2any | null | null
Show line2 fields
Any of · 1: any | null
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

Any of · 2: null

null

Any of · 2: null

null

postalCodestringrequired
statestringrequired
labelstringrequired

Pattern: ^[^\u0000\p{Cs}]*$

preferredShippingbooleanrequired
recipientNameany | nullrequired
Show recipientName fields
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

Any of · 2: null

null

Any of · 2: null

null

encountersobject[] | null
Show encounters fields
Any of · 1: object[]

Array items · object

notesstring | nullrequired
Show notes fields
Any of · 1: string

string

Maximum length: 5000

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

occurredAtstringrequired
providerNamestring | nullrequired
Show providerName fields
Any of · 1: string

string

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

typestringrequired

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

genderstring | null
Show gender fields
Any of · 1: string

string

Allowed: "f", "m", "o", "u"

Any of · 2: null

null

locationIdstring | null
Show locationId fields
Any of · 1: string

string

Pattern: ^loc_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

metadataobject | null
Show metadata fields
Any of · 1: object

object

Any of · 2: null

null

medicalRecordNumberstring | null | null
Show medicalRecordNumber fields
Any of · 1: string | null
Any of · 1: string

string

Pattern: ^[^\u0000\p{Cs}]*$

Any of · 2: null

null

Any of · 2: null

null

measurementsobject[] | null
Show measurements fields
Any of · 1: object[]

Array items · object

heightCentimetersnumber | string | nullrequired
Show heightCentimeters fields
Any of · 1: number | string
Any of · 1: number

number

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

Any of · 2: null

null

recordedAtstringrequired
sourcestringrequired

Pattern: ^[^\u0000\p{Cs}]*$

weightKilogramsnumber | string | nullrequired
Show weightKilograms fields
Any of · 1: number | string
Any of · 1: number

number

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

Any of · 2: null

null

Any of · 2: null

null

nameobjectrequired

No additional properties

Show name fields
firstanyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show first fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

lastanyrequired

Pattern: ^[^\u0000\p{Cs}]*$

Show last fields
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

middleany | null | null
Show middle fields
Any of · 1: any | null
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

Any of · 2: null

null

Any of · 2: null

null

preferredany | null | null
Show preferred fields
Any of · 1: any | null
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\u200B\u2028-\u202E\u2066-\u2069]*$

Any of · 2: null

null

Any of · 2: null

null

phonestring | null | null
Show phone fields
Any of · 1: string | null
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

programsobject[] | null
Show programs fields
Any of · 1: object[]

Array items · object

endedAtstring | nullrequired
Show endedAt fields
Any of · 1: string

string

Any of · 2: null

null

namestringrequired

Pattern: ^[^\u0000\p{Cs}]*$

startedAtstringrequired
statusstringrequired

Allowed: "active", "completed", "paused"

Any of · 2: null

null

Any of · 2: null

null

shippingAddressIdstring | null
Show shippingAddressId fields
Any of · 1: string

string

Pattern: ^addr_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

prescriptionsobject[]required

Minimum items: 1

Maximum items: 20

Show prescriptions fields

Array items · object

externalPrescriptionIdany | null
Show externalPrescriptionId fields
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\p{Cs}]*$

Any of · 2: null

null

clinicalobject | null
Show clinical fields
Any of · 1: object
compoundingReasonobject | null
Show compoundingReason fields
Any of · 1: object
categorystring | null
Show category fields
Any of · 1: string

string

Allowed: "alcohol_free", "drug_shortage", "commercial_product_discontinued", "modified_release", "inactive_ingredient_sensitivity", "inactive_ingredient_toxicity", "concentration_adjustment", "alternate_route", "dosage_form_unavailable", "flavor_adjustment", "tablet_burden", "patient_cannot_use_commercial_product", "no_approved_product_available", "no_rationale_required", "other_patient_specific_need"

Any of · 2: null

null

contextstring | null
Show context fields
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

medicationReviewStatusstring | null
Show medicationReviewStatus fields
Any of · 1: string

string

Allowed: "not_reviewed", "none", "recorded"

Any of · 2: null

null

diagnosisReviewStatusstring | null
Show diagnosisReviewStatus fields
Any of · 1: string

string

Allowed: "not_reviewed", "none", "recorded"

Any of · 2: null

null

currentMedicationsstring[] | null
Show currentMedications fields
Any of · 1: string[]

Array items · string

string

Any of · 2: null

null

diagnosesobject[] | null
Show diagnoses fields
Any of · 1: object[]

Array items · object

codestringrequired
displaystringrequired
Any of · 2: null

null

observationsobject[] | null
Show observations fields
Any of · 1: object[]

Array items · object

displaystringrequired
unitstringrequired
valuenumber | stringrequired
Show value fields
Any of · 1: number

number

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

Any of · 2: null

null

Any of · 2: null

null

pharmacyIdstring | null
Show pharmacyId fields
Any of · 1: string

string

Pattern: ^pharm_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

daysSupplyintegerrequired

Minimum: 1

Maximum: 365

dispensingobjectrequired

No additional properties

Show dispensing fields
dispenseUponAcceptanceboolean | null
Show dispenseUponAcceptance fields
Any of · 1: boolean

boolean

Any of · 2: null

null

shippingOptionIdstring | null
Show shippingOptionId fields
Any of · 1: string

string

Pattern: ^shp_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

shippingAmountCentsinteger | null

Reviewed customer shipping rate for the selected service. Preview supplies this value. Shared group rates must not be summed per prescription.

Show shippingAmountCents fields
Any of · 1: integer

integer

Minimum: 0

Any of · 2: null

null

shippingDestinationTypestring | null
Show shippingDestinationType fields
Any of · 1: string

string

Allowed: "patient"

Any of · 2: null

null

pharmacyNotesstring | null
Show pharmacyNotes fields
Any of · 1: string

string

Any of · 2: null

null

requestedFillDatestring | null
Show requestedFillDate fields
Any of · 1: string

string

Pattern: ^\d{4}-\d{2}-\d{2}$

Any of · 2: null

null

substitutionPermittedboolean | null
Show substitutionPermitted fields
Any of · 1: boolean

boolean

Any of · 2: null

null

directionsstringrequired
medicationIdstringrequired

Pattern: ^cat_[0-7][0-9a-hjkmnp-tv-z]{25}$

quantitynumber | stringrequired
Show quantity fields
Any of · 1: number

number

Maximum: 100000

Greater than: 0

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

quantityUnitstringrequired
refillsintegerrequired

Minimum: 0

Maximum: 99

structuredSigobject | null
Show structuredSig fields
Any of · 1: object
dosestringrequired
doseUnitstringrequired
durationstring | null
Show duration fields
Any of · 1: string

string

Any of · 2: null

null

frequencystringrequired
indicationstring | null
Show indication fields
Any of · 1: string

string

Any of · 2: null

null

maxDailyUsestring | null
Show maxDailyUse fields
Any of · 1: string

string

Any of · 2: null

null

prnboolean | null
Show prn fields
Any of · 1: boolean

boolean

Any of · 2: null

null

routestringrequired
titrationSchedulestring | null
Show titrationSchedule fields
Any of · 1: string

string

Any of · 2: null

null

Any of · 2: null

null

Response specifications

200Successful response

application/json

objectstringrequired

Allowed: "order_batch"

practiceIdstringrequired

Pattern: ^prac_[0-7][0-9a-hjkmnp-tv-z]{25}$

userIdstring | nullrequired
Show userId fields
Any of · 1: string

string

Pattern: ^user_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

livemodebooleanrequired
ordersobject[]required

Minimum items: 1

Maximum items: 20

Show orders fields

Array items · object

revisionstringrequired

Opaque revision of the complete order prescription set. Send the revision you reviewed as expectedRevision; never replace it automatically after a conflict.

Pattern: ^rev_[a-f0-9]{64}$

otcItemsobject[]required
Show otcItems fields

Array items · object

catalogItemIdanyrequired
Show catalogItemId fields
All of · 1: any

any

Pattern: ^cat_[0-7][0-9a-hjkmnp-tv-z]{25}$

namestringrequired
quantityintegerrequired
unitPriceCentsintegerrequired
subtotalCentsintegerrequired
externalOrderIdany | nullrequired
Show externalOrderId fields
Any of · 1: any
All of · 1: any

any

Pattern: ^[^\p{Cc}\p{Cs}]*$

Any of · 2: null

null

metadataany & anyrequired
Show metadata fields
All of · 1: any

any

All of · 2: any

any

Additional properties
Any of · 1: any & any
All of · 1: any

any

Pattern: ^[^\p{Cs}]*$

All of · 2: any

any

Maximum length: 500

Any of · 2: number

number

Any of · 3: boolean

boolean

Any of · 4: null

null

createdAtstringrequired
idstringrequired

Pattern: ^ord_[0-7][0-9a-hjkmnp-tv-z]{25}$

livemodebooleanrequired
objectstringrequired

Allowed: "order"

patientIdstringrequired

Pattern: ^pat_[0-7][0-9a-hjkmnp-tv-z]{25}$

practiceIdstringrequired

Pattern: ^prac_[0-7][0-9a-hjkmnp-tv-z]{25}$

prescriptionsobject[]required
Show prescriptions fields

Array items · object

pharmacyIdanyrequired
Show pharmacyId fields
All of · 1: any

any

Pattern: ^pharm_[0-7][0-9a-hjkmnp-tv-z]{25}$

externalPrescriptionIdany & any & any & any | nullrequired
Show externalPrescriptionId fields
Any of · 1: any & any & any & any
All of · 1: any

any

Minimum length: 1

All of · 2: any

any

Maximum length: 200

All of · 3: any

any

Pattern: \S

All of · 4: any

any

Pattern: ^[^\p{Cc}\p{Cs}]*$

Any of · 2: null

null

createdAtstringrequired
directionsstringrequired
versionanyrequired
Show version fields
All of · 1: any

any

Minimum: 1

idanyrequired
Show id fields
All of · 1: any

any

Pattern: ^rx_[0-7][0-9a-hjkmnp-tv-z]{25}$

medicationIdany | nullrequired
Show medicationId fields
Any of · 1: any
All of · 1: any

any

Pattern: ^cat_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

medicationNamestringrequired
objectstringrequired

Allowed: "prescription"

quantitynumber | stringrequired
Show quantity fields
Any of · 1: number

number

Any of · 2: string

string

Allowed: "Infinity", "-Infinity", "NaN"

quantityUnitstringrequired
refillsintegerrequired
statusstringrequired

Allowed: "requires_provider_signature"

userIdstring | nullrequired
Show userId fields
Any of · 1: string

string

Pattern: ^user_[0-7][0-9a-hjkmnp-tv-z]{25}$

Any of · 2: null

null

statusstringrequired

Allowed: "requires_provider_signature"

400HTTP 400

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

401Unauthorized

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

403Forbidden

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

404Not found

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

409Conflict

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

422Validation error

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

429Too many requests

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

503HTTP 503

application/json

codestringrequired
dataobject
detailstringrequired
instancestringrequired
requestIdstringrequired
statusintegerrequired

Minimum: 400

Maximum: 599

titlestringrequired
traceIdstring
typestringrequired

Format: uri

Type to search…

↑↓ navigate↵ selectEsc close