## Introduction 
The [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) resource represents high-level insurance information for a patient, similar to what would be found on their insurance cards.
This guide will go over the most relevant elements of [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) for digital health providers and is primarily focused on the U.S. system.

The guide aligns with recommendations from two implementation guides

- [US Core Guidelines](/content/docs/fhir-datastore/understanding-uscdi-dataclasses/index.html) 
- [CARIN Digital Insurance Card Guide](http://hl7.org/fhir/us/insurance-card/)

## Subscribers vs. Beneficiaries 
In FHIR's [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) resource, a distinction is made between plan subscribers and beneficiaries.
The `Coverage.subscriber` element denotes the individual who has subscribed to the plan, often also known as the "policyholder".
The `Coverage.beneficiary` element, on the other hand, refers to the person who is eligible to receive healthcare services under the plan.
The `Coverage.relationship` element describes how the subscriber and beneficiary are related. The US Core guidelines recommend that this code should be selected from the [HL7 subscriber relationship valueset](http://hl7.org/fhir/R4/valueset-subscriber-relationship.html).

Example
Consider an example where Mr. John Doe, an employee at a company, has an insurance policy that covers his family, including his daughter, Jane Doe. When representing Jane's insurance coverage, she would be listed as the `Coverage.beneficiary`, John would be listed as the `Coverage.subscriber`, and the `Coverage.relationship` would be set to `'child'`.

## Insurance Member ID 
The US Core implementation of FHIR mandates every [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) to have an insurance member ID for the _subscriber_. This identifier can be included in one of two elements: `Coverage.subscriberId` or `Coverage.identifier`.
If you decide to use `Coverage.identifier`, US Core requires that `Coverage.identifier.type` is drawn from the [HL7 identifierType code system](https://terminology.hl7.org/5.2.0/CodeSystem-v2-0203.html) with code `MB`.

## Plan Types and Payors 
One of the most important fields in the Coverage resource is the plan type (`Coverage.type`). The United States offers many different types of insurance plans, including Health Maintenance Organizations (HMOs), Preferred Provider Organizations (PPOs), government employee programs, veteran's insurance, and many others. Each of these plan types has a distinct set of benefits and billing structures.
The US Core guidelines strongly encourage the use of the [Source of Payment Typology (SOPT)](https://www.nahdo.org/sopt) code system for classifying US plan types.

Another required field is `Coverage.payor` , which indicates the company or institution who will reimburse the provider for care. This should a reference to an [`Organization`](/content/docs/api/fhir/resources/organization/index.html) resource, to allow for search queries of all patients insured by the same payor.

## Representing self-pay / cash-pay 
Many digital providers have a significant patient population that pay out-of-pocket. It is a best practice to create [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) resources for these patients as well, to allow flexible handling of their [coverage stack](/content/docs/billing/patient-insurance#primary-vs-secondary-coverage/index.html) as their insurance situation evolves.

A self-pay patient's [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) should set `subscriber`, `beneficiary`, `relationship`, `type`, and `payor` as follows:

```ts
{
  resourceType: 'Coverage',
  type: {
    text: 'Self-pay',
    coding: [
      {
        system: 'https://nahdo.org/sopt',
        code: '81',
        display: 'Self-pay (Includes applicants for insurance and Medicaid applicants)',
      },
    ],
  },
  subscriber: {
    reference: 'Patient/example-patient',
  },
  beneficiary: {
    reference: 'Patient/example-patient',
  },
  relationship: {
    coding: [
      {
        system: 'http://terminology.hl7.org/CodeSystem/subscriber-relationship',
        code: 'self',
        display: 'Self'
      },
    ],
  },
  payor: [
    {
      reference: 'Patient/example-patient',
    },
  ],
};
```

## Plan Classifications: Group, Plan Name, RXBIN, RXPCN 
Most insurance cards have a set of codes, known as "classifiers", that identify important billing information for the subscriber's plan.
The `Coverage.class` is used to store these classification values in an array of (`type`, `value`, `name` ) tuples.
FHIR recommends using the [coverage class valueset](https://hl7.org/fhir/R4/codesystem-coverage-class.html) to represent the class type. Below is a table of the coverage class codes in this valueset.

| **Code** | **Definition** |
| --- | --- |
| [group](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-group) | An employee group |
| [subgroup](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-subgroup) | A sub-group of an employee group |
| [plan](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-plan) | A specific suite of benefits. |
| [subplan](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-subplan) | A subset of a specific suite of benefits. |
| [class](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-class) | A class of benefits. |
| [subclass](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-subclass) | A subset of a class of benefits. |
| [sequence](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-sequence) | A sequence number associated with a short-term continuance of the coverage. |
| [rxbin](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-rxbin) | Pharmacy benefit manager's Business Identification Number. |
| [rxpcn](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-rxpcn) | A Pharmacy Benefit Manager specified Processor Control Number. |
| [rxid](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-rxid) | A Pharmacy Benefit Manager specified Member ID. |
| [rxgroup](http://hl7.org/fhir/R4/codesystem-coverage-class.html#coverage-class-rxgroup) | A Pharmacy Benefit Manager specified Group number. |

## Patient Costs and Copays 
Healthcare in the U.S often involves cost-sharing measures with patients, commonly referred to as "copays" or "co-insurance". These measures represent the portion of healthcare costs that the patient is responsible for, separate from what the insurance covers.
In FHIR, these cost-sharing measures can be represented using the `Coverage.costToBeneficiary` field, which is an array of such cost-sharing provisions.

The [CARIN Digital Insurance Card guide](http://hl7.org/fhir/us/insurance-card/) recommends a set of standard codes for the `costToBeneficiary.type` field in the [C4DIC Extended Copay Type](http://hl7.org/fhir/us/insurance-card/CodeSystem-C4DICExtendedCopayTypeCS.html) value set. This value set provides a comprehensive list of codes to represent most common cost-sharing provisions in the U.S.

## A Detailed Example 
Below is a detailed example of a [`Coverage`](/content/docs/api/fhir/resources/coverage/index.html) resource, tagged with the appropriate code systems. This example conforms to the US Core guidelines.

This example has been tested as part of the [Medplum Candid Demo Bot](https://github.com/medplum/medplum/tree/main/examples/medplum-demo-bots/src/candid-health), a [Medplum Bot](/content/docs/bots/index.html) that submits insurance information to [Candid Health](https://www.joincandidhealth.com/) for reimbursement.

```ts
{
  resourceType: 'Coverage',
  identifier: [
    {
      type: {
        coding: [
          {
            system: 'http://terminology.hl7.org/CodeSystem/v2-0203',
            code: 'MB',
            display: 'Member Number',
          },
        ],
      },
      system: 'https://www.acmeinsurance.com/glossary/memberid',
      value: '102345672-01',
      assigner: {
        display: 'Acme Insurance Co',
      },
    },
  ],
  subscriberId: '102345672-01',
  status: 'active',
  type: {
    coding: [
      {
        system: 'https://nahdo.org/sopt',
        code: '512',
        display: 'Commercial Managed Care - PPO',
      },
      {
        system: 'http://terminology.hl7.org/CodeSystem/v3-ActCode',
        code: 'PPO',
        display: 'preferred provider organization policy',
      },
    ],
    text: 'health insurance plan policy',
  },
  subscriber: createReference(patient),
  beneficiary: createReference(patient),
  relationship: {
    coding: [
      {
        system: 'http://terminology.hl7.org/CodeSystem/subscriber-relationship',
        code: 'self',
        display: 'Self',
      },
    ],
  },
  period: {
    start: '2021-01-01',
  },
  payor: [
    {
      display: 'Acme Insurance Co',
    },
  ],
  class: [
    {
      type: {
        coding: [
          {
            system: 'http://terminology.hl7.org/CodeSystem/coverage-class',
            code: 'group',
          },
        ],
      },
      value: '993355',
      name: 'Stars Inc',
    },
    {
      type: {
        coding: [
          {
            system: 'http://terminology.hl7.org/CodeSystem/coverage-class',
            code: 'plan',
          },
        ],
      },
      value: '11461128',
      name: 'Acme Gold Plus',
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCoverageClassCS',
            code: 'division',
          },
        ],
      },
      value: '11',
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCoverageClassCS',
            code: 'network',
          },
        ],
      },
      value: '561490',
      name: 'Acme Gold Plus South',
    },
    {
      type: {
        coding: [
          {
            system: 'http://terminology.hl7.org/CodeSystem/coverage-class',
            code: 'rxbin',
          },
        ],
      },
      value: '100045',
    },
    {
      type: {
        coding: [
          {
            system: 'http://terminology.hl7.org/CodeSystem/coverage-class',
            code: 'rxpcn',
          },
        ],
      },
      value: '1234000',
    },
  ],
  costToBeneficiary: [
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamOutDed',
            display: 'Family Out of Network Deductible',
          },
        ],
      },
      valueMoney: {
        value: 10000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamInDed',
            display: 'Family In Network Deductible',
          },
        ],
      },
      valueMoney: {
        value: 8000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamRxOutDed',
            display: 'Family Pharmacy Out of Network Deductible',
          },
        ],
      },
      valueMoney: {
        value: 2000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamRxInDed',
            display: 'Family Pharmacy In Network Deductible',
          },
        ],
      },
      valueMoney: {
        value: 1500,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamOutMax',
            display: 'Family Out of Network Out of Pocket Maximum',
          },
        ],
      },
      valueMoney: {
        value: 12000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamInMax',
            display: 'Family In Network Out of Pocket Maximum',
          },
        ],
      },
      valueMoney: {
        value: 10000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamRxOutMax',
            display: 'Family Pharmacy Out of Network Out of Pocket Maximum',
          },
        ],
      },
      valueMoney: {
        value: 3000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'FamRxInMax',
            display: 'Family Pharmacy In Network Out of Pocket Maximum',
          },
        ],
      },
      valueMoney: {
        value: 2000,
        currency: 'USD',
      },
    },
    {
      type: {
        coding: [
          {
            system: 'http://hl7.org/fhir/us/insurance-card/CodeSystem/C4DICExtendedCopayTypeCS',
            code: 'rx',
          },
        ],
      },
      valueMoney: {
        extension: [
          {
            url: 'http://hl7.org/fhir/us/insurance-card/StructureDefinition/C4DIC-BeneficiaryCostString-extension',
            valueString: 'DED THEN $10/$40/$70/25%',
          },
        ],
      },
    },
  ],
}
```
