# Download Written Order PDF

> Perform Download Written Order PDF through ClearPathMD.

Source: [https://genhealth.ai/docs/workflows/integrations/clear-path-md/clearpath_download_written_order](https://genhealth.ai/docs/workflows/integrations/clear-path-md/clearpath_download_written_order)

Integration: [ClearPathMD](https://genhealth.ai/docs/workflows/integrations/clear-path-md.md)

- Handler: `clearpath_download_written_order`

- Connection type: `clearpathmd`

## Inputs

- `order_id` — Order Id (expression, required)
  Required literal value or workflow expression.
- `cmn_form_id` — Cmn Form Id (expression)
  Optional literal value or workflow expression.
  Default: `"0"`
- `show_in_inbox` — Show In Inbox (boolean)
  Optional true-or-false value.
  Default: `false`

## Outputs

- `success` — Success
- `status` — Status
- `order_id` — Order Id
- `document_id` — Document Id
- `filename` — Filename
- `content_type` — Content Type
- `size_bytes` — Size Bytes
- `was_existing` — Was Existing
- `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": [
    "order_id"
  ],
  "properties": {
    "order_id": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "cmn_form_id": {
      "default": "0",
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "show_in_inbox": {
      "type": "boolean",
      "default": false,
      "description": "Optional true-or-false value.",
      "x-workflow-field-type": "boolean"
    }
  },
  "additionalProperties": false
}
```

### Output schema

```json
{
  "type": "object",
  "properties": {
    "error": {},
    "status": {},
    "success": {},
    "filename": {},
    "order_id": {},
    "size_bytes": {},
    "document_id": {},
    "content_type": {},
    "was_existing": {}
  },
  "additionalProperties": true
}
```
