# Find-or-create the patient's current open encounter; on an Athena-integrated tenant, also books a walk-in-now Athena appointment, attaches default insurance, and checks in

Operation ID: `patient.checkEncounter`

Find-or-create the patient's current open encounter; on an Athena-integrated tenant, also books a walk-in-now Athena appointment, attaches default insurance, and checks in

## Public method

`checkEncounter`

Signature: `patient.checkEncounter(request)`

Return type: `Promise<CheckEncounterResponse>`

## Authentication

Classification: **AUTHENTICATED**

Schemes: `bearerAuth`

## Prerequisites

None documented.

## HTTP

`POST /encounters/check`

## Path parameters

None.

## Query parameters

None.

## Body parameters

| Name | Type | Required | Format | Allowed values | Default | Nullable | Description |
|---|---|---:|---|---|---|---:|---|
| `body` | [`CheckEncounterRequest`](../models/CheckEncounterRequest.md) | Yes |  |  |  | No |  |

Request model: [`CheckEncounterRequest`](../models/CheckEncounterRequest.md)

## Request example

```json
{
  "notes": "Synthetic visit note",
  "patient_id": "patient-example-001"
}
```

## Success responses

| Status | Shape | Content type | Description |
|---|---|---|---|
| `200` | [`CheckEncounterResponse`](../models/CheckEncounterResponse.md) | application/json | Current or newly created encounter, with Athena walk-in status |

## Success response examples

### 200

```json
{
  "athena_appointment_id": "athena-appointment-example-001",
  "athena_encounter_error": null,
  "athena_encounter_id": "athena-encounter-example-001",
  "athena_encounter_status": "linked",
  "athena_insurance_error": null,
  "athena_insurance_status": "linked",
  "athena_patient_id": "athena-patient-example-001",
  "created": true,
  "encounter": {
    "appointment_id": "appointment-example-001",
    "athena_appointment_id": null,
    "athena_encounter_id": null,
    "created_by": "self",
    "created_date": "2026-08-10T23:36:57Z",
    "diagnoses": [
      {
        "condition_display": "Acute upper respiratory infection",
        "condition_id": "condition-example-001",
        "rank": 1,
        "use_code": "AD"
      }
    ],
    "encounter_class": "AMB",
    "encounter_id": "167dd34e-1833-4260-a8b1-ea0b38229a1b",
    "fhir_id": "6e0d484f-4f8b-4025-b6ef-abedf69f0f91",
    "hospitalization": {
      "admit_source_code": "physician-referral",
      "destination_id": "location-example-002",
      "discharge_disposition": "home",
      "origin_id": "location-example-001",
      "pre_admission_id": "encounter-example-prior",
      "re_admission_code": "N"
    },
    "length_minutes": 30,
    "locations": [
      {
        "location_display": "Example Clinic, Room 101",
        "location_id": "location-example-001",
        "period_end": "2026-08-10T10:30:00Z",
        "period_start": "2026-08-10T10:00:00Z",
        "status": "completed"
      }
    ],
    "notes": null,
    "openloop_appointment_id": null,
    "openloop_encounter_id": null,
    "participants": [
      {
        "participant_type": "ATND",
        "period_end": "2026-08-10T10:30:00Z",
        "period_start": "2026-08-10T10:00:00Z",
        "practitioner_display": "Dr. Alex Smith",
        "practitioner_id": "provider-example-001"
      }
    ],
    "patient_id": "patient-example-001",
    "period_end": "2026-08-10T10:30:00Z",
    "period_start": "2026-08-10T10:00:00Z",
    "priority_code": "R",
    "priority_display": "Routine",
    "reason_code": "386661006",
    "reason_display": "Fever",
    "service_provider_display": "Example Health Clinic",
    "service_provider_id": "organization-example-001",
    "service_type_code": "124",
    "service_type_display": "General practice",
    "status": "finished",
    "steadymd_consult_guid": null,
    "steadymd_episode_guid": null,
    "type_code": "99213",
    "type_display": "Office outpatient visit"
  },
  "notes_athena_sections": {
    "status": "linked"
  },
  "notes_fhir_error": null,
  "notes_fhir_status": "linked",
  "openloop_appointment_id": null,
  "openloop_encounter_error": null,
  "openloop_encounter_id": null,
  "openloop_encounter_status": "skipped_no_openloop",
  "steadymd_consult_guid": null,
  "steadymd_encounter_error": null,
  "steadymd_encounter_status": "skipped_no_steadymd",
  "steadymd_episode_guid": null
}
```

## Common errors

None declared in canonical OpenAPI.

## Error examples

None declared in canonical OpenAPI.

## NodeJS / TypeScript implementation

```ts
import { HCSDK } from "@healthcloudai/hc-sdk";
import type { CheckEncounterRequest } from "@healthcloudai/hc-sdk";
```

```ts
const request = {
  "notes": "Synthetic visit note",
  "patient_id": "patient-example-001"
};

const result = await patient.checkEncounter(request);
```

## cURL

```bash
curl -X POST \
  -H 'Authorization: Bearer <ACCESS_TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{"notes":"Synthetic visit note","patient_id":"patient-example-001"}' \
  'https://dev-api-patient.health.cloud/encounters/check'
```

## Notes

None.

## Prepared Test Console scenario

No canonical scenario is currently associated.

## Real response

No approved real integration response is currently published. Unapproved candidates are never rendered as examples.
