meditech · Capability

Meditech Expanse FHIR R4 API — Patient

Meditech Expanse FHIR R4 API — Patient. 3 operations. Lead operation: Search patients. Self-contained Naftiko capability covering one Meditech business surface.

Run with Naftiko MeditechPatient

What You Can Do

GET
Searchpatients — Search patients
/v1/patient
GET
Getpatient — Get patient by ID
/v1/patient/{id}
GET
Getpatienteverything — Get all patient data (Patient $everything)
/v1/patient/{id}/everything

MCP Tools

search-patients

Search patients

read-only idempotent
get-patient-id

Get patient by ID

read-only idempotent
get-all-patient-data-patient

Get all patient data (Patient $everything)

read-only idempotent

Capability Spec

fhir-patient.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Meditech Expanse FHIR R4 API — Patient
  description: 'Meditech Expanse FHIR R4 API — Patient. 3 operations. Lead operation: Search patients. Self-contained Naftiko
    capability covering one Meditech business surface.'
  tags:
  - Meditech
  - Patient
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    MEDITECH_API_KEY: MEDITECH_API_KEY
capability:
  consumes:
  - type: http
    namespace: fhir-patient
    baseUri: https://{facility}.meditech.com/fhir/r4
    description: Meditech Expanse FHIR R4 API — Patient business capability. Self-contained, no shared references.
    resources:
    - name: Patient
      path: /Patient
      operations:
      - name: searchpatients
        method: GET
        description: Search patients
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: identifier
          in: query
          type: string
          description: MRN or other identifier (e.g., identifier=MR|12345)
        - name: family
          in: query
          type: string
        - name: given
          in: query
          type: string
        - name: birthdate
          in: query
          type: string
          description: FHIR date parameter (e.g., birthdate=1980-01-01)
        - name: gender
          in: query
          type: string
        - name: _count
          in: query
          type: integer
        - name: _format
          in: query
          type: string
    - name: Patient-id
      path: /Patient/{id}
      operations:
      - name: getpatient
        method: GET
        description: Get patient by ID
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
    - name: Patient-id-$everything
      path: /Patient/{id}/$everything
      operations:
      - name: getpatienteverything
        method: GET
        description: Get all patient data (Patient $everything)
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: id
          in: path
          type: string
          required: true
        - name: start
          in: query
          type: string
        - name: end
          in: query
          type: string
    authentication:
      type: bearer
      token: '{{env.MEDITECH_API_KEY}}'
  exposes:
  - type: rest
    namespace: fhir-patient-rest
    port: 8080
    description: REST adapter for Meditech Expanse FHIR R4 API — Patient. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/patient
      name: patient
      description: REST surface for Patient.
      operations:
      - method: GET
        name: searchpatients
        description: Search patients
        call: fhir-patient.searchpatients
        with:
          identifier: rest.identifier
          family: rest.family
          given: rest.given
          birthdate: rest.birthdate
          gender: rest.gender
          _count: rest._count
          _format: rest._format
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/patient/{id}
      name: patient-id
      description: REST surface for Patient-id.
      operations:
      - method: GET
        name: getpatient
        description: Get patient by ID
        call: fhir-patient.getpatient
        with:
          id: rest.id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/patient/{id}/everything
      name: patient-id-everything
      description: REST surface for Patient-id-$everything.
      operations:
      - method: GET
        name: getpatienteverything
        description: Get all patient data (Patient $everything)
        call: fhir-patient.getpatienteverything
        with:
          id: rest.id
          start: rest.start
          end: rest.end
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: fhir-patient-mcp
    port: 9090
    transport: http
    description: MCP adapter for Meditech Expanse FHIR R4 API — Patient. One tool per consumed operation, routed inline through
      this capability's consumes block.
    tools:
    - name: search-patients
      description: Search patients
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: fhir-patient.searchpatients
      with:
        identifier: tools.identifier
        family: tools.family
        given: tools.given
        birthdate: tools.birthdate
        gender: tools.gender
        _count: tools._count
        _format: tools._format
      outputParameters:
      - type: object
        mapping: $.
    - name: get-patient-id
      description: Get patient by ID
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: fhir-patient.getpatient
      with:
        id: tools.id
      outputParameters:
      - type: object
        mapping: $.
    - name: get-all-patient-data-patient
      description: Get all patient data (Patient $everything)
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: fhir-patient.getpatienteverything
      with:
        id: tools.id
        start: tools.start
        end: tools.end
      outputParameters:
      - type: object
        mapping: $.