Skip to main content
When your product already knows what should be prescribed (a protocol, a plan or a refill), your backend drafts the whole order. The prescriber opens it in Prescribe, already filled in, and only reviews, signs and sends. Before you start, sync the patient so you have their pat_… id, and find your organization’s template ids under Settings → Templates.

1. Draft a prescription from each template

Use your own rules to choose the templates, then sync a prescription for each one. A template fills in the drug, sig and dispense, and Photon screens the draft against the patient’s record.
Variables
The result is an unsigned draft, rx_…. Its status is READY, WARNING or BLOCKED based on screening.
Always send a templateId or a treatment. If the patient already has drafts in progress, Photon may continue one of them, or return AmbiguousPrescriptionMatch so you can say which by sending its id.

2. Put the prescriptions on an order

Variables
The order stays a DRAFT, and nothing goes to the patient yet. Store its ord_… id.

3. Open the order in Prescribe

The prescriber sees the patient and each prescription, with screening alerts. They can adjust a draft, then sign each prescription and click Send.

Without a backend

If your frontend already knows the templates, skip steps 1 and 2. Pass the templates in the order and Prescribe drafts the prescriptions itself:
Add another prescription starts from the same template as the order’s first line.