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

# Quickstart

> Your first inference call from FHIR resources in under a minute.

<Info>
  Two ways into MedListIQ. This quickstart covers **`POST
      /v1/medications/infer`** — for FHIR `MedicationRequest` /
  `MedicationDispense` / `MedicationStatement` resources. If your input
  is clinical PDFs (referrals, H\&Ps, discharge summaries, progress
  notes), see the [PDFs quickstart](/from-documents).
</Info>

<Steps>
  <Step title="Get an API key">
    [Sign up for free](https://medlistiq.com), create an organization, then go to
    [**Dashboard → API Keys**](https://medlistiq.com/dashboard/keys) and click
    **Create key**. The full key is shown exactly once — copy it before closing the dialog.

    Free tier: 50 requests/month, 2/min. Sized for evaluation, not production workloads.
  </Step>

  <Step title="Make a request">
    Replace `ml_YOUR_KEY` with the key you just minted.

    <CodeGroup>
      ```bash curl theme={null}
      curl -X POST https://api.medlistiq.com/v1/medications/infer \
        -H 'Authorization: Bearer ml_YOUR_KEY' \
        -H 'Content-Type: application/json' \
        -d '{
          "resources": [
            {
              "resourceType": "MedicationRequest",
              "id": "mr-1",
              "status": "active",
              "intent": "order",
              "authoredOn": "2026-03-05",
              "medicationCodeableConcept": {
                "coding": [{
                  "system": "http://www.nlm.nih.gov/research/umls/rxnorm",
                  "code": "617312",
                  "display": "Atorvastatin 40 MG Oral Tablet"
                }]
              }
            },
            {
              "resourceType": "MedicationDispense",
              "id": "md-1",
              "status": "completed",
              "whenHandedOver": "2026-04-09",
              "medicationCodeableConcept": {
                "coding": [{
                  "system": "http://www.nlm.nih.gov/research/umls/rxnorm",
                  "code": "617312",
                  "display": "Atorvastatin 40 MG Oral Tablet"
                }]
              }
            }
          ]
        }'
      ```

      ```python Python theme={null}
      import httpx

      response = httpx.post(
          "https://api.medlistiq.com/v1/medications/infer",
          headers={"Authorization": "Bearer ml_YOUR_KEY"},
          json={
              "resources": [
                  {
                      "resourceType": "MedicationRequest",
                      "id": "mr-1",
                      "status": "active",
                      "intent": "order",
                      "authoredOn": "2026-03-05",
                      "medicationCodeableConcept": {
                          "coding": [{
                              "system": "http://www.nlm.nih.gov/research/umls/rxnorm",
                              "code": "617312",
                              "display": "Atorvastatin 40 MG Oral Tablet",
                          }]
                      },
                  },
                  {
                      "resourceType": "MedicationDispense",
                      "id": "md-1",
                      "status": "completed",
                      "whenHandedOver": "2026-04-09",
                      "medicationCodeableConcept": {
                          "coding": [{
                              "system": "http://www.nlm.nih.gov/research/umls/rxnorm",
                              "code": "617312",
                              "display": "Atorvastatin 40 MG Oral Tablet",
                          }]
                      },
                  },
              ]
          },
      )
      print(response.json())
      ```

      ```typescript TypeScript theme={null}
      const response = await fetch(
        "https://api.medlistiq.com/v1/medications/infer",
        {
          method: "POST",
          headers: {
            Authorization: "Bearer ml_YOUR_KEY",
            "Content-Type": "application/json",
          },
          body: JSON.stringify({
            resources: [
              {
                resourceType: "MedicationRequest",
                id: "mr-1",
                status: "active",
                intent: "order",
                authoredOn: "2026-03-05",
                medicationCodeableConcept: {
                  coding: [
                    {
                      system: "http://www.nlm.nih.gov/research/umls/rxnorm",
                      code: "617312",
                      display: "Atorvastatin 40 MG Oral Tablet",
                    },
                  ],
                },
              },
              {
                resourceType: "MedicationDispense",
                id: "md-1",
                status: "completed",
                whenHandedOver: "2026-04-09",
                medicationCodeableConcept: {
                  coding: [
                    {
                      system: "http://www.nlm.nih.gov/research/umls/rxnorm",
                      code: "617312",
                      display: "Atorvastatin 40 MG Oral Tablet",
                    },
                  ],
                },
              },
            ],
          }),
        },
      );
      const data = await response.json();
      console.log(data);
      ```
    </CodeGroup>
  </Step>

  <Step title="Read the response">
    ```json theme={null}
    {
      "medications": [
        {
          "display_name": "Atorvastatin 40 MG Oral Tablet",
          "status": "active",
          "confidence": 0.95,
          "sig": "Take 1 tablet by mouth daily",
          "indication": null
        }
      ],
      "meta": {
        "request_id": "a1b2c3d4-...",
        "ruleset_version": "2026-04-15.v5",
        "as_of": "2026-04-18T12:00:00Z",
        "processing_time_ms": 187,
        "input_resource_count": 2,
        "output_medication_count": 1
      }
    }
    ```

    The order and the recent dispense were deduplicated into one `active` medication.
    Confidence is high because the two signals corroborate.

    By default you get our `inferred_list` shape with `verbosity=minimal`. You
    can also request `format=fhir_bundle` or `format=fhir_array` if your
    consumer is FHIR-native — see [Output formats](/guides/output-formats).
  </Step>
</Steps>

## Next

<CardGroup cols={2}>
  <Card title="Have PDFs instead?" icon="file-pdf" href="/from-documents">
    Submit clinical PDFs to the same engine and get the same kind of
    deduplicated med list.
  </Card>

  <Card title="Understanding the output" icon="book" href="/guides/understanding-output">
    Every field, every status, and how `confidence` should be interpreted.
  </Card>

  <Card title="Output formats" icon="shapes" href="/guides/output-formats">
    Pick the envelope shape: `inferred_list`, `fhir_bundle`, or `fhir_array`.
  </Card>

  <Card title="API reference" icon="code" href="/api-reference">
    Full schema, every parameter, all error codes.
  </Card>
</CardGroup>
