> ## Documentation Index
> Fetch the complete documentation index at: https://photonhealth.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Prescribe from your own app in the Neutron sandbox.

In a few minutes you'll render Photon's order card in your app, prescribe for a test patient, and send it. Everything here runs in **Neutron**, the sandbox, where nothing reaches a real pharmacy.

<Steps>
  <Step title="Get a sandbox">
    [Sign up for Neutron](https://photonhealth.com/onboard#developer). Your account is ready right away.

    In the [dashboard](https://app.neutron.health/settings/developers), open **Settings → Developers**. Copy your **Application** `client_id`, and add your app's URL (for example, `http://localhost:5173`) to its allowed URLs.
  </Step>

  <Step title="Install">
    ```bash theme={"dark"}
    npm install @photon-rx/react
    ```

    ⚠️ Not published to npm yet.
  </Step>

  <Step title="Render the order card">
    Pass a test patient. Photon finds them or adds them.

    ```tsx Prescribe.tsx theme={"dark"}
    import { PhotonOrder, PhotonProvider } from "@photon-rx/react";
    import "@photon-rx/react/styles.css";

    export function Prescribe() {
      return (
        <PhotonProvider clientId="YOUR_CLIENT_ID" environment="neutron">
          <PhotonOrder
            patient={{
              demographic: {
                name: { first: "Paige", last: "Turner" },
                dateOfBirth: "1990-01-01",
                sex: "FEMALE",
                phone: "+13175550142",
              },
            }}
            onSent={(order) => console.log("Sent", order.id)}
          />
        </PhotonProvider>
      );
    }
    ```
  </Step>

  <Step title="Prescribe">
    1. Click **Sign in to Photon** and sign in with your Neutron account.
    2. Search for a drug, such as `amlodipine`, and fill in the sig and quantity. Screening runs as you go.
    3. Click **Sign**, then **Send prescription to patient**.

    Photon now texts the patient a link to choose a pharmacy, in Neutron too. To get the text yourself, use your own mobile number as the patient's `phone`. In Neutron, the order stops there: it's never sent to a pharmacy.
  </Step>

  <Step title="Check it worked">
    Your console logs `Sent ord_…`. That id is the order you just sent: its `state` is now `SUBMITTED`. Open it in the Prescribe app at `https://rx.neutron.health/order/ord_…`, or read it with the [`order` mutation](/docs/network/order).
  </Step>
</Steps>

## What you just did

| You | Photon |
| - | - |
| Passed a patient | Found or added the patient record (`pat_…`) |
| Searched for a drug and filled in the sig | Created a draft prescription (`rx_…`) on a draft order (`ord_…`), and screened it |
| Clicked **Sign** | Recorded the prescriber's approval. The prescription can't change now. |
| Clicked **Send** | Submitted the order and texted the patient. **This is the send.** In production, Photon transmits it to a pharmacy once one is chosen. |

See [From draft to pharmacy](/docs/architecture#from-draft-to-pharmacy) for every step after the send.

<Tip>
  Not using React? The [iframe](/docs/prescribe/embed/iframe) does the same with a URL. Want to try Photon without code? [Connect Claude](/docs/network/mcp/connect) to the sandbox and ask it to prescribe.
</Tip>

Building from your backend instead? The smallest backend path is four calls and a link: get a machine token, sync the patient, draft a prescription from a template, draft the order, then send the prescriber a [deep link](/docs/prescribe/app/deep-links) to sign and send it. Follow [One-click orders](/docs/integrations/one-click-orders).

## Next

<CardGroup cols={2}>
  <Card title="Use cases" icon="map" href="/docs/use-cases">
    What you can build on each plan, and where prescribers work.
  </Card>

  <Card title="Architecture" icon="sitemap" href="/docs/architecture">
    Patients, prescriptions and orders, and how Photon decides.
  </Card>

  <Card title="Choose an integration" icon="route" href="/docs/integrations/overview">
    From one component to backend-drafted and agent-drafted orders.
  </Card>

  <Card title="Authentication" icon="lock" href="/docs/authentication">
    User and machine tokens, and who can sign.
  </Card>

  <Card title="Environments" icon="server" href="/docs/environments">
    Neutron for building, Photon for production.
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.