Upsert Patient Case Attachment
Perform Upsert Patient Case Attachment through athenahealth.
athena_upsert_patient_case_attachmentwrite
Inputs
- Document Id
document_idexpressionrequiredRequired literal value or workflow expression.
- Patient Id
patient_idexpressionrequiredRequired literal value or workflow expression.
- Chart Id
chart_idexpressionrequiredRequired literal value or workflow expression.
- File Path
file_pathexpressionOptional literal value or workflow expression.
- S3 Path
s3_pathexpressionOptional literal value or workflow expression.
- Source Document Id
source_document_idexpressionOptional literal value or workflow expression.
- Document Class
document_classexpressionOptional literal value or workflow expression.
Default:
"ADMIN" - Content Type
content_typeexpressionOptional literal value or workflow expression.
- Idempotency Key
idempotency_keyexpressionrequiredRequired literal value or workflow expression.
- Close Document
close_documentbooleanOptional true-or-false value.
Default:
false - Max Pdf Pages Per Attachment
max_pdf_pages_per_attachmentnumberOptional numeric value.
Default:
33 - Write Enabled
write_enabledbooleanOptional true-or-false value.
Default:
false
Outputs
successSuccesssubmittedSubmittedwrite_skippedWrite Skippedskip_reasonSkip Reasondocument_idDocument Idattachment_document_idAttachment Document Idattachment_document_idsAttachment Document Idsattachment_countAttachment Countpart_countPart CountuploadedUploadeduploaded_countUploaded CountreusedReusedreused_countReused CountattachedAttachedattached_countAttached Countattach_call_countAttach Call Countdocument_completeDocument Completematch_countMatch Countfailure_phaseFailure Phaseerror_codeError CoderetryableRetryableerrorErrorerror_messageError 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
{
"type": "object",
"required": [
"document_id",
"patient_id",
"chart_id",
"idempotency_key"
],
"properties": {
"s3_path": {
"description": "Optional literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"chart_id": {
"description": "Required literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"file_path": {
"description": "Optional literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"patient_id": {
"description": "Required literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"document_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"
},
"idempotency_key": {
"description": "Required literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"source_document_id": {
"description": "Optional literal value or workflow expression.",
"x-workflow-field-type": "expression"
},
"max_pdf_pages_per_attachment": {
"type": "number",
"default": 33,
"description": "Optional numeric value.",
"x-workflow-field-type": "number"
}
},
"additionalProperties": false
}Output schema
{
"type": "object",
"properties": {
"error": {},
"reused": {},
"success": {},
"attached": {},
"uploaded": {},
"retryable": {},
"submitted": {},
"error_code": {},
"part_count": {},
"document_id": {},
"match_count": {},
"skip_reason": {},
"reused_count": {},
"error_message": {},
"failure_phase": {},
"write_skipped": {},
"attached_count": {},
"uploaded_count": {},
"attachment_count": {},
"attach_call_count": {},
"document_complete": {},
"attachment_document_id": {},
"attachment_document_ids": {}
},
"additionalProperties": true
}