# Check health-record import status

Operation ID: `patient.initHealthRecordImport`

Return whether the authenticated patient has already completed a health-record import (via the `imported` boolean flag on the patient). Takes no request body; used by the client to decide whether to prompt for import. Requires a patient Bearer JWT.

## Public method

`initHealthRecordImport`

Signature: `patient.initHealthRecordImport()`

Return type: `Promise<InitHealthRecordImportResponse>`

## Authentication

Classification: **AUTHENTICATED**

Schemes: `bearerAuth`

## Prerequisites

None documented.

## HTTP

`POST /patients/health-record/initimport`

## Path parameters

None.

## Query parameters

None.

## Body parameters

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

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

## Request example

```json
{}
```

## Success responses

| Status | Shape | Content type | Description |
|---|---|---|---|
| `200` | [`InitHealthRecordImportResponse`](../models/InitHealthRecordImportResponse.md) | application/json | Health-record import status |

## Success response examples

### 200

```json
{
  "imported": true,
  "run_id": "string",
  "status": "string"
}
```

## Common errors

| Status | Shape | Content type | Description |
|---|---|---|---|
| `401` | [`patient.ErrorResponse`](../models/patient.ErrorResponse.md) | application/json | Authorization required — missing, invalid, expired, or non-patient Bearer JWT |
| `404` | [`patient.ErrorResponse`](../models/patient.ErrorResponse.md) | application/json | The authenticated patient has no FHIR Patient record |

## Error examples

### 401 — Missing or invalid access token

```json
{
  "error": "Authorization required"
}
```

### 404 — Patient not found

```json
{
  "error": "Patient not found"
}
```

## NodeJS / TypeScript implementation

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

```ts
const result = await patient.initHealthRecordImport();
```

## cURL

```bash
curl -X POST \
  -H 'Authorization: Bearer <ACCESS_TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{}' \
  'https://dev-api-patient.health.cloud/patients/health-record/initimport'
```

## 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.
