# Download Patient Document

> Perform Download Patient Document through NikoHealth.

Source: [https://genhealth.ai/docs/workflows/integrations/nikohealth/nikohealth_download_patient_document](https://genhealth.ai/docs/workflows/integrations/nikohealth/nikohealth_download_patient_document)

Integration: [NikoHealth](https://genhealth.ai/docs/workflows/integrations/nikohealth.md)

- Handler: `nikohealth_download_patient_document`

- Connection type: `nikohealth`

## Inputs

- `patient_document_id` — Patient Document Id (text, required)
  Required text value.
- `document` — Document (json)
  Optional JSON value.

## Outputs

- `success` — Success
- `status` — Status
- `document_id` — Document Id
- `niko_patient_document_id` — Niko Patient Document Id
- `downloaded` — Downloaded
- `was_existing` — Was Existing
- `title` — Title
- `sha256` — Sha256
- `size` — Size
- `error` — Error

Output schema completeness: `best_effort_declared`

## Safety

- External effect: `write`
- Confirmation recommended: no
- Retry safe: no
- Dry run supported: no

## Schemas

These schemas are first-pass authoring guidance. Runtime validation remains authoritative.

### Input schema

```json
{
  "type": "object",
  "required": [
    "patient_document_id"
  ],
  "properties": {
    "document": {
      "description": "Optional JSON value.",
      "x-workflow-field-type": "json"
    },
    "patient_document_id": {
      "type": "string",
      "description": "Required text value.",
      "x-workflow-field-type": "text"
    }
  },
  "additionalProperties": false
}
```

### Output schema

```json
{
  "type": "object",
  "properties": {
    "size": {},
    "error": {},
    "title": {},
    "sha256": {},
    "status": {},
    "success": {},
    "downloaded": {},
    "document_id": {},
    "was_existing": {},
    "niko_patient_document_id": {}
  },
  "additionalProperties": true
}
```
