CMS Blue Button 2.0 Metadata API

FHIR capability statement.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/cms-blue-button-metadata-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no email required.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

cms-blue-button-metadata-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: CMS Blue Button 2.0 Coverage Metadata API
  description: Blue Button 2.0 is the Centers for Medicare & Medicaid Services (CMS) patient-facing API that lets Medicare beneficiaries share their Parts A, B, and D claims data with applications they authorize. The v2 API is FHIR R4 (4.0.1) and conforms to the CARIN Blue Button Implementation Guide (CARIN Consumer Directed Payer Data Exchange, CDPDE). It exposes three FHIR resource types - ExplanationOfBenefit (claims), Patient (demographics), and Coverage (Part A/B/D enrollment) - plus a capability statement and an OpenID Connect userinfo endpoint. Every request is scoped to the single beneficiary who authorized the application through the OAuth 2.0 authorization-code flow (PKCE S256 required) on Medicare.gov. The sandbox at sandbox.bluebutton.cms.gov mirrors production with synthetic data for 10,000 enrollees.
  version: '2.0'
  contact:
    name: CMS Blue Button 2.0
    url: https://bluebutton.cms.gov
  termsOfService: https://bluebutton.cms.gov/terms/
servers:
- url: https://api.bluebutton.cms.gov/v2/fhir
  description: Production (approved applications only)
- url: https://sandbox.bluebutton.cms.gov/v2/fhir
  description: Sandbox (synthetic Medicare enrollee data, self-serve)
security:
- oauth2:
  - patient/ExplanationOfBenefit.read
  - patient/Patient.read
  - patient/Coverage.read
tags:
- name: Metadata
  description: FHIR capability statement.
paths:
  /metadata:
    get:
      operationId: getCapabilityStatement
      tags:
      - Metadata
      summary: Retrieve the FHIR capability statement
      description: Returns the server CapabilityStatement (FHIR 4.0.1) describing the supported resources, interactions, and search parameters. Does not require authorization.
      security: []
      responses:
        '200':
          description: A CapabilityStatement resource.
          content:
            application/fhir+json:
              schema:
                type: object
                description: FHIR CapabilityStatement resource.
components:
  securitySchemes:
    oauth2:
      type: oauth2
      description: OAuth 2.0 authorization-code flow with mandatory PKCE (S256 only). Beneficiaries log in with their Medicare.gov credentials and choose whether to share demographic data. Access tokens expire after 1 hour. One-time-use refresh tokens are issued only to approved 13-month and research application types. Sandbox uses https://sandbox.bluebutton.cms.gov/v2/o/authorize/ and https://sandbox.bluebutton.cms.gov/v2/o/token/.
      flows:
        authorizationCode:
          authorizationUrl: https://api.bluebutton.cms.gov/v2/o/authorize/
          tokenUrl: https://api.bluebutton.cms.gov/v2/o/token/
          refreshUrl: https://api.bluebutton.cms.gov/v2/o/token/
          scopes:
            patient/Patient.read: Read the beneficiary's Patient demographic resource.
            patient/ExplanationOfBenefit.read: Read the beneficiary's Medicare claims.
            patient/Coverage.read: Read the beneficiary's Medicare coverage.
            openid: OpenID Connect authentication.
            profile: Access the userinfo profile endpoint.
            launch/patient: Receive the patient FHIR id in the token response.