# Upload Document To Chart

> Perform Upload Document To Chart through athenahealth.

Source: [https://genhealth.ai/docs/workflows/integrations/athenahealth/athena_upload_document_to_chart](https://genhealth.ai/docs/workflows/integrations/athenahealth/athena_upload_document_to_chart)

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

- Handler: `athena_upload_document_to_chart`

## Inputs

- `patient_id` — Patient Id (expression, required)
  Required literal value or workflow expression.
- `chart_id` — Chart Id (expression, required)
  Required literal value or workflow expression.
- `file_path` — File Path (expression, required)
  Required literal value or workflow expression.
- `file_name` — File Name (expression)
  Optional literal value or workflow expression.
- `document_class` — Document Class (expression)
  Optional literal value or workflow expression.
  Default: `"ADMIN"`
- `content_type` — Content Type (expression)
  Optional literal value or workflow expression.
- `close_document` — Close Document (boolean)
  Optional true-or-false value.
  Default: `false`
- `write_enabled` — Write Enabled (boolean)
  Optional true-or-false value.
  Default: `false`

## Outputs

- `success` — Success
- `submitted` — Submitted
- `write_skipped` — Write Skipped
- `skip_reason` — Skip Reason
- `document_id` — Document Id
- `attachment_document_id` — Attachment Document Id
- `document_class` — Document Class
- `patient_id` — Patient Id
- `chart_id` — Chart Id
- `department_id` — Department Id
- `file_path` — File Path
- `filename` — Filename
- `content_type` — Content Type
- `close_document` — Close Document
- `error` — Error
- `error_message` — Error Message

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_id",
    "chart_id",
    "file_path"
  ],
  "properties": {
    "chart_id": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "file_name": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "file_path": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "patient_id": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "content_type": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "write_enabled": {
      "type": "boolean",
      "default": false,
      "description": "Optional true-or-false value.",
      "x-workflow-field-type": "boolean"
    },
    "close_document": {
      "type": "boolean",
      "default": false,
      "description": "Optional true-or-false value.",
      "x-workflow-field-type": "boolean"
    },
    "document_class": {
      "default": "ADMIN",
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    }
  },
  "additionalProperties": false
}
```

### Output schema

```json
{
  "type": "object",
  "properties": {
    "error": {},
    "success": {},
    "chart_id": {},
    "filename": {},
    "file_path": {},
    "submitted": {},
    "patient_id": {},
    "document_id": {},
    "skip_reason": {},
    "content_type": {},
    "department_id": {},
    "error_message": {},
    "write_skipped": {},
    "close_document": {},
    "document_class": {},
    "attachment_document_id": {}
  },
  "additionalProperties": true
}
```
