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

# Create Patient

> Creates a Patient in Metriport for the specified Facility where the patient is receiving care.

## Query Params

<ParamField query="facilityId" type="string" required>
  The ID of the Facility where the Patient is receiving care.
</ParamField>

## Body

<Snippet file="patient.mdx" />

## Response

<Snippet file="patient-response.mdx" />

<ResponseField name="networkQuery" type="object">
  The status of the [network query](/medical-api/api-reference/network/start-network-query) that was
  kicked off for the patient. Only present when the `networkQuery` field is included in the request.

  <Expandable title="networkQuery properties">
    <Snippet file="network-query-response.mdx" />
  </Expandable>
</ResponseField>

<ResponseExample>
  ```javascript Metriport SDK theme={null}
  import { MetriportMedicalApi, USState } from "@metriport/api-sdk";

  const metriport = new MetriportMedicalApi("YOUR_API_KEY");

  const facilityId = "00000000-00000000-00000000-00000000";
  const patient = await metriport.createPatient(
    {
      firstName: "Jose",
      lastName: "Juarez",
      dob: "1951-05-05",
      genderAtBirth: "M",
      personalIdentifiers: [
        {
          type: "driversLicense",
          state: USState.CA,
          value: "51227265",
        },
      ],
      address: [
        {
          zip: "12345",
          city: "San Diego",
          state: USState.CA,
          country: "USA",
          addressLine1: "Guadalajara Street"
        },
      ],
      contact: [
        {
          phone: "1234567899",
          email: "jose@domain.com",
        },
      ],
      externalId: "123456789",
      status: { 
        hieOptOut: false,
        treatmentRelationship: true
      },
      cohorts: ["00000000-00000000-00000000-00000000"]
    },
    facilityId
  );
  ```
</ResponseExample>

<Snippet file="patient-response-json.mdx" />

## Rate Limits

See [limits and throttling](/medical-api/more-info/limits#rate-limits)
