Confirm the target FHIR server supports $import by checking the CapabilityStatement for the operation definition or server documentation; $import is defined in the FHIR Bulk Data Access IG as an asymmetric counterpart to $export
POST /$import with a Parameters resource containing: inputFormat (application/fhir+ndjson), inputSource (base URL of the source), storageDetail (type and credentials if applicable), and input parameters listing resource type and URL for each NDJSON file
Include Prefer: respond-async in the request header; receive a 202 Accepted response with a Content-Location header pointing to the import status endpoint
Poll Content-Location with GET until the response is 200 OK; parse the completed response body for outcome details including counts of resources created, updated, or failed
Review any error file URLs in the response to retrieve NDJSON-formatted OperationOutcome resources describing individual resource import failures
Verify a sample of imported resources by querying them directly on the FHIR server using their expected IDs or search parameters
Known gotchas
$import is not universally implemented; it is proposed in the Bulk Data IG but marked experimental — many production FHIR servers require vendor-specific import mechanisms instead
The storageDetail parameter must match what the server's backend can access (e.g., Azure Blob, AWS S3, GCS); providing a URL scheme the server cannot reach will fail silently or return a generic error after the async kick-off
NDJSON files for $import must contain only one resource type per file as indicated in the corresponding input.type parameter; mixing resource types in a single file typically causes validation failures during import
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp