Orion Health · Capability

Orion Health FHIR API — Encounter

Orion Health FHIR API — Encounter. 2 operations. Lead operation: Orion Health Search for encounters. Self-contained Naftiko capability covering one Orion business surface.

Run with Naftiko OrionEncounter

What You Can Do

GET
Searchencounters — Orion Health Search for encounters
/v1/encounter
GET
Getencounter — Orion Health Read an encounter by ID
/v1/encounter/{id}

MCP Tools

orion-health-search-encounters

Orion Health Search for encounters

read-only idempotent
orion-health-read-encounter-id

Orion Health Read an encounter by ID

read-only idempotent

Capability Spec

fhir-encounter.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Orion Health FHIR API — Encounter
  description: 'Orion Health FHIR API — Encounter. 2 operations. Lead operation: Orion Health Search for encounters. Self-contained
    Naftiko capability covering one Orion business surface.'
  tags:
  - Orion
  - Encounter
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    ORION_API_KEY: ORION_API_KEY
capability:
  consumes:
  - type: http
    namespace: fhir-encounter
    baseUri: https://api.orionhealth.com/fhir
    description: Orion Health FHIR API — Encounter business capability. Self-contained, no shared references.
    resources:
    - name: Encounter
      path: /Encounter
      operations:
      - name: searchencounters
        method: GET
        description: Orion Health Search for encounters
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: patient
          in: query
          type: string
          description: Reference to the patient
        - name: date
          in: query
          type: string
          description: Encounter date or date range
        - name: status
          in: query
          type: string
          description: Encounter status
        - name: class
          in: query
          type: string
          description: Classification of the encounter (e.g., ambulatory, inpatient)
        - name: type
          in: query
          type: string
          description: Specific type of encounter
    - name: Encounter-id
      path: /Encounter/{id}
      operations:
      - name: getencounter
        method: GET
        description: Orion Health Read an encounter by ID
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: bearer
      token: '{{env.ORION_API_KEY}}'
  exposes:
  - type: rest
    namespace: fhir-encounter-rest
    port: 8080
    description: REST adapter for Orion Health FHIR API — Encounter. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/encounter
      name: encounter
      description: REST surface for Encounter.
      operations:
      - method: GET
        name: searchencounters
        description: Orion Health Search for encounters
        call: fhir-encounter.searchencounters
        with:
          patient: rest.patient
          date: rest.date
          status: rest.status
          class: rest.class
          type: rest.type
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/encounter/{id}
      name: encounter-id
      description: REST surface for Encounter-id.
      operations:
      - method: GET
        name: getencounter
        description: Orion Health Read an encounter by ID
        call: fhir-encounter.getencounter
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: fhir-encounter-mcp
    port: 9090
    transport: http
    description: MCP adapter for Orion Health FHIR API — Encounter. One tool per consumed operation, routed inline through
      this capability's consumes block.
    tools:
    - name: orion-health-search-encounters
      description: Orion Health Search for encounters
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: fhir-encounter.searchencounters
      with:
        patient: tools.patient
        date: tools.date
        status: tools.status
        class: tools.class
        type: tools.type
      outputParameters:
      - type: object
        mapping: $.
    - name: orion-health-read-encounter-id
      description: Orion Health Read an encounter by ID
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: fhir-encounter.getencounter
      outputParameters:
      - type: object
        mapping: $.