Centers for Medicare and Medicaid Services ExplanationOfBenefit API

Medicare claims expressed as ExplanationOfBenefit resources.

OpenAPI Specification

centers-for-medicare-and-medicaid-services-explanationofbenefit-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: CMS Blue Button 2.0 Capability ExplanationOfBenefit API
  description: Blue Button 2.0 is a standards-based HL7 FHIR R4 API that delivers Medicare Part A, B, and D claims data for over 60 million beneficiaries to registered third-party applications. Beneficiaries authorize sharing via OAuth 2.0. Blue Button 2.0 anchors CMS's Patient Access API program under the 21st Century Cures Act.
  version: v2
  contact:
    name: CMS Blue Button Developer Support
    url: https://bluebutton.cms.gov/developers/
  termsOfService: https://bluebutton.cms.gov/terms/
servers:
- url: https://api.bluebutton.cms.gov/v2/fhir
  description: Blue Button 2.0 production FHIR server
- url: https://sandbox.bluebutton.cms.gov/v2/fhir
  description: Blue Button 2.0 sandbox FHIR server
security:
- oauth2: []
tags:
- name: ExplanationOfBenefit
  description: Medicare claims expressed as ExplanationOfBenefit resources.
paths:
  /ExplanationOfBenefit:
    get:
      operationId: searchExplanationOfBenefit
      summary: Search ExplanationOfBenefit
      description: Returns ExplanationOfBenefit (claims) records for the authenticated beneficiary.
      tags:
      - ExplanationOfBenefit
      parameters:
      - name: patient
        in: query
        description: Patient resource reference.
        schema:
          type: string
      - name: _lastUpdated
        in: query
        description: Filter by last-updated timestamp.
        schema:
          type: string
      responses:
        '200':
          description: A FHIR Bundle of ExplanationOfBenefit resources.
          content:
            application/fhir+json:
              schema:
                $ref: '#/components/schemas/FHIRBundle'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /ExplanationOfBenefit/{id}:
    get:
      operationId: readExplanationOfBenefit
      summary: Read ExplanationOfBenefit
      description: Returns a single ExplanationOfBenefit resource by ID.
      tags:
      - ExplanationOfBenefit
      parameters:
      - name: id
        in: path
        required: true
        description: FHIR ExplanationOfBenefit resource ID.
        schema:
          type: string
      responses:
        '200':
          description: A FHIR ExplanationOfBenefit resource.
          content:
            application/fhir+json:
              schema:
                $ref: '#/components/schemas/FHIRResource'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  schemas:
    FHIRBundle:
      type: object
      description: A FHIR R4 Bundle resource wrapping a collection of resources.
      properties:
        resourceType:
          type: string
          const: Bundle
        type:
          type: string
        total:
          type: integer
        entry:
          type: array
          items:
            type: object
            additionalProperties: true
      additionalProperties: true
    FHIRResource:
      type: object
      description: A generic FHIR R4 resource.
      properties:
        resourceType:
          type: string
        id:
          type: string
      additionalProperties: true
  responses:
    NotFound:
      description: The requested resource was not found.
      content:
        application/fhir+json:
          schema:
            $ref: '#/components/schemas/FHIRResource'
    Unauthorized:
      description: Authentication credentials are missing or invalid.
      content:
        application/fhir+json:
          schema:
            $ref: '#/components/schemas/FHIRResource'
  securitySchemes:
    oauth2:
      type: oauth2
      description: OAuth 2.0 authorization code flow used by Medicare beneficiaries to grant access to a third-party application.
      flows:
        authorizationCode:
          authorizationUrl: https://api.bluebutton.cms.gov/v2/o/authorize/
          tokenUrl: https://api.bluebutton.cms.gov/v2/o/token/
          scopes:
            patient/Patient.read: Read beneficiary Patient resource.
            patient/Coverage.read: Read beneficiary Coverage resources.
            patient/ExplanationOfBenefit.read: Read beneficiary claims.
externalDocs:
  description: CMS Blue Button 2.0 API Documentation
  url: https://bluebutton.cms.gov/api-documentation/
x-generated-from: https://bluebutton.cms.gov/api-documentation/
x-generated-by: claude-crawl-2026-05-08