Metriport Patient API

Medical API patient management.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 6

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

POST /medical/v1/patient Create a patient record · Create Patient #
Ask an LLM
“How do I add a new patient to Metriport for a facility?”
“Can I set a patient's contact and address when creating them?”
Tell an agent
Create patient {firstName} {lastName} born {dob} at facility {facilityId}.
Add patient {firstName} {lastName} with gender {genderAtBirth} and address {address} at facility {facilityId}.
GET /medical/v1/patient List patients at a facility · List Patients #
Ask an LLM
“Which patients are receiving care at a given facility?”
“Can I get a list of all patients at one facility?”
Tell an agent
List patients receiving care at facility {facilityId}.
Show every patient at facility {facilityId}.
GET /medical/v1/patient/{id} Get a patient record · Get Patient #
Ask an LLM
“What demographics are stored for a patient?”
“Can I fetch one patient by their Metriport ID?”
Tell an agent
Get patient {id}.
Show the demographics of patient {id}.
PUT /medical/v1/patient/{id} Update a patient's demographics · Update Patient #
Ask an LLM
“How do I correct a patient's name or date of birth?”
“Can I change a patient's contact details?”
Tell an agent
Update patient {id} at facility {facilityId} to {firstName} {lastName}, DOB {dob}, gender {genderAtBirth}, address {address}.
Correct patient {id} at facility {facilityId} to contact {contact}.
DELETE /medical/v1/patient/{id} Delete a patient record · Delete Patient #
Ask an LLM
“How do I remove a patient from a facility?”
“Can I delete a patient record entirely?”
Tell an agent destructive · confirm first
Delete patient {id} at facility {facilityId}.
Remove patient {id} from facility {facilityId}.
POST /medical/v1/patient/match Find an existing patient by demographics · Match Patient #
Ask an LLM
“Is there already a patient with these demographics before I create one?”
“Can I search for a patient without creating a duplicate?”
Tell an agent
Match patient {firstName} {lastName} born {dob} with gender {genderAtBirth} and address {address}.
Find an existing patient matching {firstName} {lastName}, DOB {dob}, gender {genderAtBirth}, address {address}.

Documentation

Specifications

Schemas & Data

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/metriport:metriport-patient-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

metriport-patient-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Metriport Patient API
  description: Metriport is an open-source, universal API for healthcare data. The Medical API exchanges patient medical records across the CommonWell and Carequality networks and returns consolidated FHIR R4 data; the Devices API hydrates activity, biometrics, nutrition, and sleep data from connected wearables and mHealth apps. This specification documents the hosted Metriport cloud surface at https://api.metriport.com. The same code may be self-hosted from the open-source repository.
  termsOfService: https://www.metriport.com/terms
  contact:
    name: Metriport Support
    email: contact@metriport.com
    url: https://docs.metriport.com
  version: '1.0'
servers:
- url: https://api.metriport.com
  description: Metriport hosted production API
- url: https://api.sandbox.metriport.com
  description: Metriport sandbox API
security:
- ApiKeyAuth: []
tags:
- name: Patient
  description: Medical API patient management.
paths:
  /medical/v1/patient:
    post:
      operationId: createPatient
      tags:
      - Patient
      summary: Create Patient
      description: Creates a Patient in Metriport for the specified Facility where the patient is receiving care.
      parameters:
      - name: facilityId
        in: query
        required: true
        description: The ID of the Facility where the patient is receiving care.
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BasePatient'
      responses:
        '200':
          description: The created Patient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Patient'
    get:
      operationId: listPatients
      tags:
      - Patient
      summary: List Patients
      description: Lists all Patients receiving care at the specified Facility.
      parameters:
      - name: facilityId
        in: query
        required: false
        schema:
          type: string
      responses:
        '200':
          description: A list of Patients.
          content:
            application/json:
              schema:
                type: object
                properties:
                  patients:
                    type: array
                    items:
                      $ref: '#/components/schemas/Patient'
  /medical/v1/patient/{id}:
    get:
      operationId: getPatient
      tags:
      - Patient
      summary: Get Patient
      description: Gets a Patient by their Metriport ID.
      parameters:
      - $ref: '#/components/parameters/PatientId'
      responses:
        '200':
          description: The requested Patient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Patient'
    put:
      operationId: updatePatient
      tags:
      - Patient
      summary: Update Patient
      description: Updates the specified Patient's demographics.
      parameters:
      - $ref: '#/components/parameters/PatientId'
      - name: facilityId
        in: query
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BasePatient'
      responses:
        '200':
          description: The updated Patient.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Patient'
    delete:
      operationId: deletePatient
      tags:
      - Patient
      summary: Delete Patient
      description: Removes the specified Patient.
      parameters:
      - $ref: '#/components/parameters/PatientId'
      - name: facilityId
        in: query
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Patient deleted.
  /medical/v1/patient/match:
    post:
      operationId: matchPatient
      tags:
      - Patient
      summary: Match Patient
      description: Searches for an existing Patient that matches the provided demographics without creating a new one.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BasePatient'
      responses:
        '200':
          description: The matched Patient, if found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Patient'
components:
  schemas:
    Patient:
      allOf:
      - type: object
        properties:
          id:
            type: string
          facilityIds:
            type: array
            items:
              type: string
      - $ref: '#/components/schemas/BasePatient'
    Contact:
      type: object
      properties:
        phone:
          type: string
        email:
          type: string
          format: email
    BasePatient:
      type: object
      required:
      - firstName
      - lastName
      - dob
      - genderAtBirth
      - address
      properties:
        firstName:
          type: string
        lastName:
          type: string
        dob:
          type: string
          format: date
          description: Date of birth in YYYY-MM-DD format.
        genderAtBirth:
          type: string
          enum:
          - M
          - F
          - O
          - U
        externalId:
          type: string
        contact:
          type: array
          items:
            $ref: '#/components/schemas/Contact'
        address:
          type: array
          items:
            $ref: '#/components/schemas/Address'
    Address:
      type: object
      required:
      - addressLine1
      - city
      - state
      - zip
      - country
      properties:
        addressLine1:
          type: string
        addressLine2:
          type: string
        city:
          type: string
        state:
          type: string
        zip:
          type: string
        country:
          type: string
          default: USA
  parameters:
    PatientId:
      name: id
      in: path
      required: true
      description: The Metriport Patient ID.
      schema:
        type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key