NPI API
Look up National Provider Identifier (NPI) information for healthcare providers.
Overview
The NPI is a unique 10-digit identification number for healthcare providers in the United States. FHIRfly provides fast lookups against the CMS NPPES database enriched with NUCC taxonomy data.
Endpoints
| Method | Path | Description |
|---|---|---|
| GET | /v1/npi/:npi | Single NPI lookup |
| POST | /v1/npi/_batch | Batch NPI lookup (up to 100) |
| GET | /v1/npi/shapes | List available response shapes |
Single Lookup
Look up a healthcare provider by NPI
Request
curl -X GET "https://api.fhirfly.io/v1/npi/1679576722" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN"Response
Provider Types
| Type | Description |
|---|---|
individual | Individual healthcare provider (Type 1) |
organization | Healthcare organization (Type 2) |
Batch Lookup
Look up multiple NPIs in a single request (up to 100):
Look up multiple providers
Request
curl -X POST "https://api.fhirfly.io/v1/npi/_batch" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"npis": [
"1679576722",
"1588667638",
"1215930367"
]
}'Response
Response Shapes
Control the level of detail in responses with the shape query parameter:
| Shape | Description |
|---|---|
compact | Minimal data for lists and autocomplete |
standard | Core structured data (default) |
full | Complete data with provenance for AI agents |
# Minimal data
GET /v1/npi/1679576722?shape=compact
# Standard data (default)
GET /v1/npi/1679576722?shape=standard
# Full data with provenance
GET /v1/npi/1679576722?shape=full
See Response Shapes for field details.
Required Scopes
npi:read- Single lookupsnpi:batch- Batch lookups