# Add Insurance Policy

> Perform Add Insurance Policy through athenahealth.

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

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

- Handler: `athena_add_patient_insurance`

- Connection type: `athenahealth`

## Inputs

- `patient_id` — Patient Id (expression, required)
  Required literal value or workflow expression.
- `insurance_package_id` — Insurance Package Id (expression, required)
  Required literal value or workflow expression.
- `id_number` — Id Number (expression, required)
  Required literal value or workflow expression.
- `sequence_number` — Sequence Number (select)
  Optional selected identifier or value.
  Default: `"1"`
  Options: Primary ("1"), Secondary ("2"), Tertiary ("3")
- `policy_number` — Policy Number (expression)
  Optional literal value or workflow expression.
- `issue_date` — Issue Date (expression)
  Optional literal value or workflow expression.
- `expiration_date` — Expiration Date (expression)
  Optional literal value or workflow expression.
- `insurance_product_type_id` — Insurance Product Type Id (select)
  Optional selected identifier or value.
  Options: Leave unset (""), HMO ("1"), PPO ("2"), POS ("3"), EPO ("6"), INDEMNITY ("4"), OTHER ("5"), Behavioral health ("8"), Contracts ("19"), Legal ("20"), MVA ("18"), Medicaid CHIP ("12"), Medicaid HMO ("10"), Medicaid PCCM ("11"), Medicaid-Traditional ("13"), Medicare B-Traditional ("21"), Medicare HMO ("14"), Medicare POS ("23"), Medicare PPO ("15"), Medicare Private FFS ("22"), Medicare Supplemental Plan ("16"), Radiology ("9"), Vision ("7"), Workers Comp ("17")
- `copay_type_id` — Copay Type Id (expression)
  Optional literal value or workflow expression.
- `copay` — Copay (expression)
  Optional literal value or workflow expression.
- `coinsurance_percent` — Coinsurance Percent (expression)
  Optional literal value or workflow expression.
- `notes` — Notes (textarea)
  Optional text value.
- `relationship_to_insured_id` — Relationship To Insured Id (select)
  Optional selected identifier or value.
  Default: `"1"`
  Options: Self ("1"), Spouse ("2"), Child ("3"), Child (Mother's Insurance) ("27"), Child (Father's Insurance) ("28"), Child (Ins. not Financially Respons.) ("25"), Child (Mother's Ins., Ins. not Financially Respons.) ("29"), Child (Father's Ins., Ins. not Financially Respons.) ("30"), Stepson or Stepdaughter ("11"), Stepson or Stepdaughter (Stepmother's Insurance) ("31"), Stepson or Stepdaughter (Stepfather's Insurance) ("32"), Foster Child ("9"), Mother ("18"), Father ("19"), Parent ("34"), Stepparent ("35"), Grandparent ("5"), Grandchild ("6"), Sibling ("33"), Aunt or Uncle ("36"), Nephew or Niece ("7"), Life Partner ("26"), Significant Other ("17"), Employee ("12"), Ward ("10"), Charge of a Caretaker ("37"), Handicapped Dependent ("14"), Sponsored Dependent ("15"), Dependent of a Minor Dependent ("16"), Emancipated Minor ("21"), Organ Donor ("22"), Cadaver Donor ("23"), Injured Plaintiff ("24"), Other ("4"), Unknown ("13")
- `insured_entity_type_id` — Insured Entity Type Id (select)
  Optional selected identifier or value.
  Options: Leave unset (""), Person ("1"), Non-person entity ("2")
- `insured_id_number` — Insured Id Number (expression)
  Optional literal value or workflow expression.
- `insured_first_name` — Insured First Name (expression)
  Optional literal value or workflow expression.
- `insured_last_name` — Insured Last Name (expression)
  Optional literal value or workflow expression.
- `insured_middle_initial` — Insured Middle Initial (expression)
  Optional literal value or workflow expression.
- `insured_name_suffix` — Insured Name Suffix (expression)
  Optional literal value or workflow expression.
- `insured_date_of_birth` — Insured Date Of Birth (expression)
  Optional literal value or workflow expression.
- `insured_sex` — Insured Sex (select)
  Optional selected identifier or value.
  Options: Leave unset (""), Female ("F"), Male ("M")
- `insured_ssn` — Insured Ssn (expression)
  Optional literal value or workflow expression.
- `insured_address_line_1` — Insured Address Line 1 (expression)
  Optional literal value or workflow expression.
- `insured_address_line_2` — Insured Address Line 2 (expression)
  Optional literal value or workflow expression.
- `insured_city` — Insured City (expression)
  Optional literal value or workflow expression.
- `insured_state` — Insured State (select)
  Optional selected identifier or value.
  Options: Leave unset (""), AA-Armed Forces Americas ("AA"), AE-Armed Forces Africa ("AE"), AK-Alaska ("AK"), AL-Alabama ("AL"), AP-Armed Forces Pacific ("AP"), AR-Arkansas ("AR"), AS-American Samoa ("AS"), AZ-Arizona ("AZ"), CA-California ("CA"), CO-Colorado ("CO"), CT-Connecticut ("CT"), DC-District of Columbia ("DC"), DE-Delaware ("DE"), FL-Florida ("FL"), FM-Federated States of Micronesia ("FM"), GA-Georgia ("GA"), GU-Guam ("GU"), HI-Hawaii ("HI"), IA-Iowa ("IA"), ID-Idaho ("ID"), IL-Illinois ("IL"), IN-Indiana ("IN"), KS-Kansas ("KS"), KY-Kentucky ("KY"), LA-Louisiana ("LA"), MA-Massachusetts ("MA"), MD-Maryland ("MD"), ME-Maine ("ME"), MH-Marshall Islands ("MH"), MI-Michigan ("MI"), MN-Minnesota ("MN"), MO-Missouri ("MO"), MP-Northern Mariana Islands ("MP"), MS-Mississippi ("MS"), MT-Montana ("MT"), NC-North Carolina ("NC"), ND-North Dakota ("ND"), NE-Nebraska ("NE"), NH-New Hampshire ("NH"), NJ-New Jersey ("NJ"), NM-New Mexico ("NM"), NV-Nevada ("NV"), NY-New York ("NY"), OH-Ohio ("OH"), OK-Oklahoma ("OK"), OR-Oregon ("OR"), PA-Pennsylvania ("PA"), PR-Puerto Rico ("PR"), PW-Palau ("PW"), RI-Rhode Island ("RI"), SC-South Carolina ("SC"), SD-South Dakota ("SD"), TN-Tennessee ("TN"), TX-Texas ("TX"), UT-Utah ("UT"), VA-Virginia ("VA"), VI-Virgin Islands ("VI"), VT-Vermont ("VT"), WA-Washington ("WA"), WI-Wisconsin ("WI"), WV-West Virginia ("WV"), WY-Wyoming ("WY")
- `insured_zip` — Insured Zip (expression)
  Optional literal value or workflow expression.
- `insured_country_id` — Insured Country Id (expression)
  Optional literal value or workflow expression.
- `eligibility_mode` — Eligibility Mode (select)
  Optional selected identifier or value.
  Default: `"CHECKELIGIBILITYTODAY"`
  Options: Check eligibility today ("CHECKELIGIBILITYTODAY"), Check eligibility for a date of service ("CHECKELIGIBILITY"), Record an eligibility answer we already have ("SETELIGIBILITY")
- `eligibility_service_date` — Eligibility Service Date (expression)
  Optional literal value or workflow expression.
- `eligible` — Eligible (select)
  Optional selected identifier or value.
  Options: Leave unset (""), Eligible ("Y"), Ineligible ("N")
- `eligibility_reason_id` — Eligibility Reason Id (select)
  Optional selected identifier or value.
  Options: Leave unset (""), In Process ("INPROCESS"), Patient Call ("PATIENTCALL"), Payer Call ("PAYORCALL"), Payer Report ("PAYORREPORT"), Payer Website ("PAYORWEBSITE"), Practice Override ("PRACTICEOVERRIDE")
- `additional_form_fields` — Additional Form Fields (json)
  Optional JSON value.
- `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
- `patient_insurance_id` — Patient Insurance Id
- `patient_id` — Patient Id
- `insurance_package_id` — Insurance Package Id
- `insurance_package_name` — Insurance Package Name
- `sequence_number` — Sequence Number
- `athena` — Athena
- `submitted_field_count` — Submitted Field Count
- `error` — Error
- `error_message` — Error Message
- `failure_phase` — Failure Phase
- `error_code` — Error Code
- `retryable` — Retryable

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",
    "insurance_package_id",
    "id_number"
  ],
  "properties": {
    "copay": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "notes": {
      "type": "string",
      "description": "Optional text value.",
      "x-workflow-field-type": "textarea"
    },
    "eligible": {
      "enum": [
        "",
        "Y",
        "N"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "id_number": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "issue_date": {
      "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"
    },
    "insured_sex": {
      "enum": [
        "",
        "F",
        "M"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "insured_ssn": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_zip": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_city": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "copay_type_id": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_state": {
      "enum": [
        "",
        "AA",
        "AE",
        "AK",
        "AL",
        "AP",
        "AR",
        "AS",
        "AZ",
        "CA",
        "CO",
        "CT",
        "DC",
        "DE",
        "FL",
        "FM",
        "GA",
        "GU",
        "HI",
        "IA",
        "ID",
        "IL",
        "IN",
        "KS",
        "KY",
        "LA",
        "MA",
        "MD",
        "ME",
        "MH",
        "MI",
        "MN",
        "MO",
        "MP",
        "MS",
        "MT",
        "NC",
        "ND",
        "NE",
        "NH",
        "NJ",
        "NM",
        "NV",
        "NY",
        "OH",
        "OK",
        "OR",
        "PA",
        "PR",
        "PW",
        "RI",
        "SC",
        "SD",
        "TN",
        "TX",
        "UT",
        "VA",
        "VI",
        "VT",
        "WA",
        "WI",
        "WV",
        "WY"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "policy_number": {
      "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"
    },
    "expiration_date": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "sequence_number": {
      "enum": [
        "1",
        "2",
        "3"
      ],
      "type": "string",
      "default": "1",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "eligibility_mode": {
      "enum": [
        "CHECKELIGIBILITYTODAY",
        "CHECKELIGIBILITY",
        "SETELIGIBILITY"
      ],
      "type": "string",
      "default": "CHECKELIGIBILITYTODAY",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "insured_id_number": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_last_name": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_country_id": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_first_name": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "coinsurance_percent": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_name_suffix": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insurance_package_id": {
      "description": "Required literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "eligibility_reason_id": {
      "enum": [
        "",
        "INPROCESS",
        "PATIENTCALL",
        "PAYORCALL",
        "PAYORREPORT",
        "PAYORWEBSITE",
        "PRACTICEOVERRIDE"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "insured_date_of_birth": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "additional_form_fields": {
      "description": "Optional JSON value.",
      "x-workflow-field-type": "json"
    },
    "insured_address_line_1": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_address_line_2": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insured_entity_type_id": {
      "enum": [
        "",
        "1",
        "2"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "insured_middle_initial": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "eligibility_service_date": {
      "description": "Optional literal value or workflow expression.",
      "x-workflow-field-type": "expression"
    },
    "insurance_product_type_id": {
      "enum": [
        "",
        "1",
        "2",
        "3",
        "6",
        "4",
        "5",
        "8",
        "19",
        "20",
        "18",
        "12",
        "10",
        "11",
        "13",
        "21",
        "14",
        "23",
        "15",
        "22",
        "16",
        "9",
        "7",
        "17"
      ],
      "type": "string",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    },
    "relationship_to_insured_id": {
      "enum": [
        "1",
        "2",
        "3",
        "27",
        "28",
        "25",
        "29",
        "30",
        "11",
        "31",
        "32",
        "9",
        "18",
        "19",
        "34",
        "35",
        "5",
        "6",
        "33",
        "36",
        "7",
        "26",
        "17",
        "12",
        "10",
        "37",
        "14",
        "15",
        "16",
        "21",
        "22",
        "23",
        "24",
        "4",
        "13"
      ],
      "type": "string",
      "default": "1",
      "description": "Optional selected identifier or value.",
      "x-workflow-field-type": "select"
    }
  },
  "additionalProperties": false
}
```

### Output schema

```json
{
  "type": "object",
  "properties": {
    "error": {},
    "athena": {},
    "success": {},
    "retryable": {},
    "submitted": {},
    "error_code": {},
    "patient_id": {},
    "skip_reason": {},
    "error_message": {},
    "failure_phase": {},
    "write_skipped": {},
    "sequence_number": {},
    "insurance_package_id": {},
    "patient_insurance_id": {},
    "submitted_field_count": {},
    "insurance_package_name": {}
  },
  "additionalProperties": true
}
```
