{
"code": "server_unresponsive",
"message": "EHR integration is not available for this note",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}
Patients
Attach insurance to an existing patient
Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.
The policyholder's relationship to the patient. SELF (the default) means the patient is the policyholder. Anything else — SPOUSE, CHILD, … — REQUIRES the subscriber* fields below; without them the request is rejected with subscriber_required rather than writing a policy whose policyholder is unknown.
Policyholder's date of birth, YYYY-MM-DD. Required when subscriberRelationship is not SELF — a claim identifies the subscriber by name AND date of birth, so a name alone still sends the biller back to the patient.
Policyholder's sex, as the payer knows it. A professional claim's 2010BA loop carries the subscriber's DMG demographics — date of birth AND gender — so omitting it leaves a correctable rejection on the table. NOT required: unlike name and date of birth, a missing gender does not make the policyholder unidentifiable, so it is never a reason to refuse the write.
Policyholder's address, for the claim's 2010BA N3/N4 segments. Omit and set subscriberAddressSameAsPatient instead when the policyholder lives with the patient — the common case for a spouse or dependant, and the one ModMed models natively.
true when the policyholder lives at the patient's address. Maps to ModMed's own policyHolderAddressSameAsPatients, so the EHR resolves the address itself rather than us copying it and creating a second copy that can drift. Mutually exclusive with subscriberAddress; supplying both is rejected.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Max AI Developer Docs","colors":{"primary":"#7C3AED","light":"#A78BFA","dark":"#6D28D9"},"logo":{"light":"https://mintcdn.com/maxaiinc-02a56fd1/3kDaJXdVQ62Q_li2/logo/logo.png?fit=max\u0026auto=format\u0026n=3kDaJXdVQ62Q_li2\u0026q=85\u0026s=593e8b0c409b58f620609de6e29ebb79","dark":"https://mintcdn.com/maxaiinc-02a56fd1/3kDaJXdVQ62Q_li2/logo/logo.png?fit=max\u0026auto=format\u0026n=3kDaJXdVQ62Q_li2\u0026q=85\u0026s=593e8b0c409b58f620609de6e29ebb79"},"favicon":"https://mintcdn.com/maxaiinc-02a56fd1/3kDaJXdVQ62Q_li2/logo/logo.png?fit=max\u0026auto=format\u0026n=3kDaJXdVQ62Q_li2\u0026q=85\u0026s=593e8b0c409b58f620609de6e29ebb79","api":{},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"maxaiinc-02a56fd1","hasAudioNarration":false,"actualSubdomain":"maxaiinc-02a56fd1","customDomains":["docs.maxcare.ai"],"gitSource":{"type":"github","owner":"maxcare-ai","repo":"monorepo","deployBranch":"staging","contentDirectory":"workloads/api-docs-mintlify","isPrivate":true,"mountPath":"","label":""},"entitlements":{},"buildId":"6aedf59db961f3bf48d52094","clientVersion":"0.0.4076","searchFilterCounts":[{"language":"default","tag":"API Reference","count":914},{"language":"default","tag":"Patients","count":74},{"language":"default","tag":"Schedule","count":40},{"language":"default","tag":"EHR live reads","count":30},{"language":"default","tag":"Appointments","count":28},{"language":"default","tag":"Inventory","count":28},{"language":"default","tag":"Notes","count":28},{"language":"default","tag":"Tasks","count":28},{"language":"default","tag":"Guides","count":24},{"language":"default","tag":"Payers","count":20}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/v1/patients/attach-insurance-to-an-existing-patient","slug":"/api-reference/v1/patients/attach-insurance-to-an-existing-patient","pageMetadata":{"title":"Attach insurance to an existing patient","description":"Adds coverage to a chart that already exists — the returning-patient counterpart to the `insurance` block on `POST /patients`. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and `conflictPolicy` does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the `subscriber*` fields and is rejected with `subscriber_required` without them. Send an `Idempotency-Key` header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 `idempotency_unavailable` rather than proceeding unguarded.","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/insurance","href":"/api-reference/v1/patients/attach-insurance-to-an-existing-patient","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"Adds coverage to a chart that already exists — the returning-patient counterpart to the \", _jsx(_components.code, {\n children: \"insurance\"\n }), \" block on \", _jsx(_components.code, {\n children: \"POST /patients\"\n }), \". ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and \", _jsx(_components.code, {\n children: \"conflictPolicy\"\n }), \" does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the \", _jsx(_components.code, {\n children: \"subscriber*\"\n }), \" fields and is rejected with \", _jsx(_components.code, {\n children: \"subscriber_required\"\n }), \" without them. Send an \", _jsx(_components.code, {\n children: \"Idempotency-Key\"\n }), \" header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 \", _jsx(_components.code, {\n children: \"idempotency_unavailable\"\n }), \" rather than proceeding unguarded.\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Attach insurance to an existing patient","description":"Adds coverage to a chart that already exists — the returning-patient counterpart to the `insurance` block on `POST /patients`. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and `conflictPolicy` does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the `subscriber*` fields and is rejected with `subscriber_required` without them. Send an `Idempotency-Key` header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 `idempotency_unavailable` rather than proceeding unguarded.","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/insurance","href":"/api-reference/v1/patients/attach-insurance-to-an-existing-patient","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"description":"Adds coverage to a chart that already exists — the returning-patient counterpart to the `insurance` block on `POST /patients`. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and `conflictPolicy` does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the `subscriber*` fields and is rejected with `subscriber_required` without them. Send an `Idempotency-Key` header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 `idempotency_unavailable` rather than proceeding unguarded.","operationId":"PatientsPublicController_addPatientInsurance","parameters":["d06fe876-b467-4ff4-9969-797e2103ae08","f872a7b4-e946-4e59-bb40-a32964139be3","00adff08-2806-4cc1-9b1f-c2279450beaa"],"requestBody":"d3ab6fda-6b51-4071-8780-590a9bd15807","responses":{"200":"4a955dfb-afad-4ab4-9bea-9270e13ca583","400":"209ed7a0-c2b7-45ad-aa06-2a98c65a47ad","401":"efcea4b2-58ac-4615-ba02-cf8311c6be15","403":"c4d85efb-6da7-4c4b-a0ba-6119818146c9","404":"a2946613-062a-49e1-b064-caefe38b2e3d","429":"9544cb17-2579-4eb7-84c0-fa3ea4b2213b","502":"0018c7fb-c94f-470f-b697-8ba817883dd5","503":"7296e0de-6142-463e-9747-dfb1d869d9c4"},"security":["28734efd-f94c-4da3-a11f-2406792d60f2"],"summary":"Attach insurance to an existing patient","tags":["Patients"],"method":"post","type":"path","servers":["64ac812c-c324-4d68-841e-ea28946b3b50"],"path":"/patients/{id}/insurance","baseUrlOptions":["https://api.maxcare.ai/v1"],"title":"Attach insurance to an existing patient","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"d06fe876-b467-4ff4-9969-797e2103ae08":{"name":"id","required":true,"in":"path","description":"Patient ID","schema":{"type":"string","isRequired":true,"description":"Patient ID","uniqueKey":"","typeLabel":"string"}},"f872a7b4-e946-4e59-bb40-a32964139be3":{"name":"idempotency-key","required":false,"in":"header","description":"Client-generated key protecting retries for 24 hours","schema":{"type":"string","isRequired":false,"description":"Client-generated key protecting retries for 24 hours","uniqueKey":"","typeLabel":"string"}},"00adff08-2806-4cc1-9b1f-c2279450beaa":{"name":"X-Organization-Id","in":"header","required":true,"schema":{"type":"string","isRequired":true,"description":"Target clinic organization ID","uniqueKey":"","typeLabel":"string"},"description":"Target clinic organization ID"}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"payerName":{"type":"string","example":"BCBS of Michigan","isRequired":true,"uniqueKey":"payerName","typeLabel":"string"},"memberId":{"type":"string","example":"XYZ123456","isRequired":true,"uniqueKey":"memberId","typeLabel":"string"},"groupNumber":{"type":"string","example":"0009","uniqueKey":"groupNumber","typeLabel":"string"},"subscriberRelationship":{"type":"string","description":"The policyholder's relationship to the patient. `SELF` (the default) means the patient is the policyholder. Anything else — `SPOUSE`, `CHILD`, … — REQUIRES the `subscriber*` fields below; without them the request is rejected with `subscriber_required` rather than writing a policy whose policyholder is unknown.","example":"SELF","uniqueKey":"subscriberRelationship","typeLabel":"string"},"subscriberFirstName":{"type":"string","description":"Policyholder's first name. Required when `subscriberRelationship` is not `SELF`.","example":"Robert","uniqueKey":"subscriberFirstName","typeLabel":"string"},"subscriberLastName":{"type":"string","description":"Policyholder's last name. Required when `subscriberRelationship` is not `SELF`.","example":"Doe","uniqueKey":"subscriberLastName","typeLabel":"string"},"subscriberDateOfBirth":{"type":"string","description":"Policyholder's date of birth, YYYY-MM-DD. Required when `subscriberRelationship` is not `SELF` — a claim identifies the subscriber by name AND date of birth, so a name alone still sends the biller back to the patient.","example":"1968-03-14","uniqueKey":"subscriberDateOfBirth","typeLabel":"string"},"subscriberSex":{"type":"string","description":"Policyholder's sex, as the payer knows it. A professional claim's 2010BA loop carries the subscriber's `DMG` demographics — date of birth AND gender — so omitting it leaves a correctable rejection on the table. NOT required: unlike name and date of birth, a missing gender does not make the policyholder unidentifiable, so it is never a reason to refuse the write.","enum":["M","F","U"],"example":"M","uniqueKey":"subscriberSex","typeLabel":"enum\u003cstring>"},"subscriberAddress":{"type":"object","description":"Policyholder's address, for the claim's 2010BA `N3`/`N4` segments. Omit and set `subscriberAddressSameAsPatient` instead when the policyholder lives with the patient — the common case for a spouse or dependant, and the one ModMed models natively.","required":["line1","city","state","zip"],"properties":{"line1":{"type":"string","example":"1200 Miller Rd","isRequired":true,"uniqueKey":"subscriberAddress.line1","typeLabel":"string"},"city":{"type":"string","example":"Flint","isRequired":true,"uniqueKey":"subscriberAddress.city","typeLabel":"string"},"state":{"type":"string","description":"Two-letter state code. The adapters translate to each vendor's form (EZDerm `FLORIDA`, ModMed `FL`).","example":"MI","isRequired":true,"uniqueKey":"subscriberAddress.state","typeLabel":"string"},"zip":{"type":"string","example":"48507","isRequired":true,"uniqueKey":"subscriberAddress.zip","typeLabel":"string"},"line2":{"type":"string","example":"Apt 4","uniqueKey":"subscriberAddress.line2","typeLabel":"string"},"country":{"type":"string","example":"US","uniqueKey":"subscriberAddress.country","typeLabel":"string"}},"uniqueKey":"subscriberAddress","typeLabel":"object"},"subscriberAddressSameAsPatient":{"type":"boolean","description":"`true` when the policyholder lives at the patient's address. Maps to ModMed's own `policyHolderAddressSameAsPatients`, so the EHR resolves the address itself rather than us copying it and creating a second copy that can drift. Mutually exclusive with `subscriberAddress`; supplying both is rejected.","example":true,"uniqueKey":"subscriberAddressSameAsPatient","typeLabel":"boolean"},"planName":{"type":"string","description":"Plan name as printed on the card (e.g. `PPO Gold`). Previously always written as null; supply it when the card shows it.","example":"PPO Gold","uniqueKey":"planName","typeLabel":"string"}},"required":["payerName","memberId"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"payerName":"BCBS of Michigan","memberId":"XYZ123456","groupNumber":"0009","subscriberRelationship":"SELF","subscriberFirstName":"Robert","subscriberLastName":"Doe","subscriberDateOfBirth":"1968-03-14","subscriberSex":"M","subscriberAddressSameAsPatient":true,"planName":"PPO Gold"}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"4a955dfb-afad-4ab4-9bea-9270e13ca583":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Response code","example":"success","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"data":{"type":"object","properties":{"patientId":{"type":"string","description":"The patient the coverage was attached to","example":"pat_c56103bcd39c46d39f3138dd2b5e05f6","isRequired":true,"uniqueKey":"data.patientId","typeLabel":"string"},"coverageOrder":{"type":"number","description":"Coverage order written — 1 is primary","example":1,"isRequired":true,"uniqueKey":"data.coverageOrder","typeLabel":"number"},"payerName":{"type":"string","description":"Payer name as resolved by the EHR","example":"BCBS of Michigan","isRequired":true,"uniqueKey":"data.payerName","typeLabel":"string"}},"required":["patientId","coverageOrder","payerName"],"isRequired":true,"uniqueKey":"data","typeLabel":"object"}},"required":["code","data"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"success","data":{"patientId":"pat_c56103bcd39c46d39f3138dd2b5e05f6","coverageOrder":1,"payerName":"BCBS of Michigan"}}}},"exampleType":"generated"}},"exampleType":"generated"},"209ed7a0-c2b7-45ad-aa06-2a98c65a47ad":{"description":"Missing or invalid request parameter","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"bad_request","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"'id' must be a valid UUID","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"bad_request","message":"'id' must be a valid UUID","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"efcea4b2-58ac-4615-ba02-cf8311c6be15":{"description":"Invalid or missing API key","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"unauthorized","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"Invalid or missing API key","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"unauthorized","message":"Invalid or missing API key","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"c4d85efb-6da7-4c4b-a0ba-6119818146c9":{"description":"Insufficient scope","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"forbidden","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"Insufficient scope","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"forbidden","message":"Insufficient scope","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"a2946613-062a-49e1-b064-caefe38b2e3d":{"description":"Resource not found","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"not_found","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"Resource not found","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"not_found","message":"Resource not found","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"9544cb17-2579-4eb7-84c0-fa3ea4b2213b":{"description":"Rate limit exceeded","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"rate_limit_exceeded","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"Rate limit exceeded. Maximum 1000 requests per 60 seconds.","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"rate_limit_exceeded","message":"Rate limit exceeded. Maximum 1000 requests per 60 seconds.","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"0018c7fb-c94f-470f-b697-8ba817883dd5":{"description":"EHR sync failed","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"unexpected_integration_error","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"EHR sync failed","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"unexpected_integration_error","message":"EHR sync failed","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"},"7296e0de-6142-463e-9747-dfb1d869d9c4":{"description":"EHR integration unavailable","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error code","example":"server_unresponsive","isRequired":true,"uniqueKey":"code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"EHR integration is not available for this note","isRequired":true,"uniqueKey":"message","typeLabel":"string"},"trace_id":{"type":"string","description":"Trace ID for debugging","example":"550e8400-e29b-41d4-a716-446655440000","isRequired":true,"uniqueKey":"trace_id","typeLabel":"string"}},"required":["code","message","trace_id"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"server_unresponsive","message":"EHR integration is not available for this note","trace_id":"550e8400-e29b-41d4-a716-446655440000"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"28734efd-f94c-4da3-a11f-2406792d60f2":{"api-key":{"scheme":"bearer","bearerFormat":"JWT","type":"http","description":"Marketplace API key","scopes":[],"schemeName":"api-key"}}},"servers":{"64ac812c-c324-4d68-841e-ea28946b3b50":{"url":"https://api.maxcare.ai/v1"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"scheme":"bearer","bearerFormat":"JWT","type":"http","description":"Marketplace API key","scopes":[],"schemeName":"api-key"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Marketplace API key","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"api-key","name":"Authorization"}],"title":"api-key"}]},"originalFileLocation":"openapi-v1.json"},"subdomain":"maxaiinc-02a56fd1","siteName":"Max AI Developer Docs","title":"Attach insurance to an existing patient - Max AI Developer Docs","navMaps":{"firstHrefInVersion":{"v4":{"href":"/api-reference/v4/patients/attach-insurance-to-an-existing-patient","matchLevel":1},"v3":{"href":"/api-reference/v3/patients/attach-insurance-to-an-existing-patient","matchLevel":1},"v2":{"href":"/api-reference/v2/patients/attach-insurance-to-an-existing-patient","matchLevel":1},"v1":{"href":"/api-reference/v1/patients/attach-insurance-to-an-existing-patient","matchLevel":0}},"firstHrefInLanguage":{}},"lastModified":"2026-11-06T15:43:54.784Z","originalFileLocation":"api-reference/v1/patients/attach-insurance-to-an-existing-patient.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Max AI Developer Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Attach insurance to an existing patient - Max AI Developer Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Max AI Developer Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://maxaiinc-02a56fd1.mintlify.site/_mintlify/api/og/v2?division=Patients\u0026amp;title=Attach+insurance+to+an+existing+patient\u0026amp;description=Adds+coverage+to+a+chart+that+already+exists+%E2%80%94+the+returning-patient+counterpart+to+the+%60insurance%60+block+on+%60POST+%2Fpatients%60.+ADDITIVE%3A+the+EHR+keeps+existing+\u0026amp;theme=02e0b3646d3b285707db65d5\u0026amp;signature=efb3cec096526786ab4fcf21dce1478b349d279bb26faca505d96246d3cec915\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Attach insurance to an existing patient - Max AI Developer Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://maxaiinc-02a56fd1.mintlify.site/_mintlify/api/og/v2?division=Patients\u0026amp;title=Attach+insurance+to+an+existing+patient\u0026amp;description=Adds+coverage+to+a+chart+that+already+exists+%E2%80%94+the+returning-patient+counterpart+to+the+%60insurance%60+block+on+%60POST+%2Fpatients%60.+ADDITIVE%3A+the+EHR+keeps+existing+\u0026amp;theme=02e0b3646d3b285707db65d5\u0026amp;signature=efb3cec096526786ab4fcf21dce1478b349d279bb26faca505d96246d3cec915\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/maxaiinc-02a56fd1/qw7ccI6uMOHd5Iws/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Max AI Developer Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#7C3AED\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/v1/patients/attach-insurance-to-an-existing-patient.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.maxcare.ai/#organization\",\"name\":\"Max AI Developer Docs\",\"url\":\"https://docs.maxcare.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/maxaiinc-02a56fd1/3kDaJXdVQ62Q_li2/logo/logo.png?fit=max\u0026auto=format\u0026n=3kDaJXdVQ62Q_li2\u0026q=85\u0026s=593e8b0c409b58f620609de6e29ebb79\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.maxcare.ai#website\",\"name\":\"Max AI Developer Docs\",\"url\":\"https://docs.maxcare.ai\",\"publisher\":{\"@id\":\"https://docs.maxcare.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient#webpage\",\"url\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient\",\"name\":\"Attach insurance to an existing patient\",\"description\":\"Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.\",\"dateModified\":\"2026-11-06T15:43:54.784Z\",\"isPartOf\":{\"@id\":\"https://docs.maxcare.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API Reference\",\"item\":\"https://docs.maxcare.ai/api-reference/v1/appointment-types/list-appointment-types\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Patients\",\"item\":\"https://docs.maxcare.ai/api-reference/v1/patients/where-each-document-category-is-filed\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Attach insurance to an existing patient\",\"item\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient#apireference\",\"headline\":\"Attach insurance to an existing patient\",\"name\":\"Attach insurance to an existing patient\",\"description\":\"Adds coverage to a chart that already exists — the returning-patient counterpart to the insurance block on POST /patients. ADDITIVE: the EHR keeps existing policies, so this never replaces coverage and conflictPolicy does not apply. Coverage is written as primary; secondary coverage remains an intake concern. A non-self policy REQUIRES the subscriber* fields and is rejected with subscriber_required without them. Send an Idempotency-Key header to make a retry safe: it is honoured for 24 hours per app+organization, a repeat of the SAME request replays the original result, and a key reused for a DIFFERENT request is refused with 409. The guarantee fails closed — if the idempotency store is unreachable the request is refused with 503 idempotency_unavailable rather than proceeding unguarded.\",\"url\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient\",\"mainEntityOfPage\":{\"@id\":\"https://docs.maxcare.ai/api-reference/v1/patients/attach-insurance-to-an-existing-patient#webpage\"},\"dateModified\":\"2026-11-06T15:43:54.784Z\",\"publisher\":{\"@id\":\"https://docs.maxcare.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.maxcare.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Max AI Developer Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Max AI Developer Docs","nav":{"global":null,"tabs":[{"tab":"Guides","pages":[{"title":"Guides","href":"/guides"}]},{"tab":"API Reference","versions":[{"version":"v4","tag":"Latest","pages":[{"title":"v4","href":"/api-reference/v4/patients/attach-insurance-to-an-existing-patient"}]},{"version":"v3","pages":[{"title":"v3","href":"/api-reference/v3/patients/attach-insurance-to-an-existing-patient"}]},{"version":"v2","pages":[{"title":"v2","href":"/api-reference/v2/patients/attach-insurance-to-an-existing-patient"}]},{"version":"v1","groups":[{"group":"API Reference","pages":[{"group":"Appointment Types","pages":[{"title":"List appointment types","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /appointment-types","href":"/api-reference/v1/appointment-types/list-appointment-types"}]},{"group":"Appointments","pages":[{"title":"List appointments","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /appointments","href":"/api-reference/v1/appointments/list-appointments"},{"title":"Book an appointment","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /appointments","href":"/api-reference/v1/appointments/book-an-appointment"},{"title":"List cancellation reasons","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /appointments/cancel-reasons","href":"/api-reference/v1/appointments/list-cancellation-reasons"},{"title":"List appointment statuses","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /appointments/statuses","href":"/api-reference/v1/appointments/list-appointment-statuses"},{"title":"Get appointment by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /appointments/{id}","href":"/api-reference/v1/appointments/get-appointment-by-id"},{"title":"Reschedule an appointment","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /appointments/{id}","href":"/api-reference/v1/appointments/reschedule-an-appointment"},{"title":"Cancel an appointment","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /appointments/{id}/cancel","href":"/api-reference/v1/appointments/cancel-an-appointment"}]},{"group":"Bills","pages":[{"title":"List bills","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /bills","href":"/api-reference/v1/bills/list-bills"},{"title":"Get bill by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /bills/{id}","href":"/api-reference/v1/bills/get-bill-by-id"}]},{"group":"Cancel Reasons","pages":[{"title":"List appointment cancellation reasons","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /cancel-reasons","href":"/api-reference/v1/cancel-reasons/list-appointment-cancellation-reasons"}]},{"group":"Claims","pages":[{"title":"List claims","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /claims","href":"/api-reference/v1/claims/list-claims"},{"title":"Get claim by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /claims/{id}","href":"/api-reference/v1/claims/get-claim-by-id"}]},{"group":"Patients","pages":[{"title":"Where each document category is filed","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /documents/categories","href":"/api-reference/v1/patients/where-each-document-category-is-filed"},{"title":"List patients","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients","href":"/api-reference/v1/patients/list-patients"},{"title":"Create a patient","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients","href":"/api-reference/v1/patients/create-a-patient"},{"title":"Match a patient by demographics","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/match","href":"/api-reference/v1/patients/match-a-patient-by-demographics"},{"title":"Get patient by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients/{id}","href":"/api-reference/v1/patients/get-patient-by-id"},{"title":"Update a patient","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /patients/{id}","href":"/api-reference/v1/patients/update-a-patient"},{"title":"List a patient's allergies","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients/{id}/allergies","href":"/api-reference/v1/patients/list-a-patients-allergies"},{"title":"List a patient's chart documents","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients/{id}/documents","href":"/api-reference/v1/patients/list-a-patients-chart-documents"},{"title":"File a document on a patient's chart","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/documents","href":"/api-reference/v1/patients/file-a-document-on-a-patients-chart"},{"title":"Refresh a patient's chart-document list","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/documents/refresh","href":"/api-reference/v1/patients/refresh-a-patients-chart-document-list"},{"title":"Download one chart document's bytes","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients/{id}/documents/{documentId}/content","href":"/api-reference/v1/patients/download-one-chart-documents-bytes"},{"title":"Pull one chart document's bytes from the EHR","description":"Stages the bytes of a document `GET /patients/{id}/documents` reported with `downloaded: false`, so it becomes downloadable. Returns when the pull is done, so there is nothing to poll — one file is typically a sub-second EHR call, but a cold session or a large attachment can take considerably longer and the request is held for as long as the download runs. Set a client timeout accordingly: a retry after one lands on the in-flight 409 rather than starting a second download. The response carries the document exactly as the list endpoint now reports it, with `downloaded: true`, a signed `url` and `expiresInSeconds`. Already-staged bytes are served from cache with no EHR call, so this is safe to call again for a fresh URL. `status: \"unavailable\"` is NOT a failure: it means this platform cannot pull the bytes on its own and `reason` says what a human has to do (`needs_user_session` — a clinic user must open the patient's Documents panel once; `ehr_auth` — the practice's EHR connection needs reconnecting). A second call while one pull is in flight is normally a 409 — though if the platform's coordination store is briefly unavailable it may instead join the running pull and answer 200 with the same result, or 409 if that pull is still running after a short wait — and a document that has since been removed from the chart and was never staged is a 404. Requires read:patient_documents scope.","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/documents/{documentId}/fetch","href":"/api-reference/v1/patients/pull-one-chart-documents-bytes-from-the-ehr"},{"title":"Attach insurance to an existing patient","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/insurance","href":"/api-reference/v1/patients/attach-insurance-to-an-existing-patient"},{"title":"Attach an insurance card image","description":"Multipart upload of one side of an insurance card, filed against the patient's coverage in the EHR. The vendor mechanics differ and are absorbed here: ModMed fills the POLICY's own card slots (so the coverage must exist first — otherwise 404 `insurance_not_found`), while other EHRs file a typed chart document. Accepts PNG, JPEG, WEBP or HEIC up to 10 MB. The declared content type is treated as a hint only — the BYTES are sniffed, and a mismatch is rejected with 415 `unsupported_media_type`. No durable copy is kept on our side: the bytes are held in memory for the request, pushed to the EHR, and dropped. Nothing is written to storage, and the request body is not logged. Because there is no stored copy there is also NO RETRY on our side — if the attachment fails, re-upload. The platform does NOT strip EXIF metadata or run malware scanning — a phone photo can carry GPS coordinates, so do both before uploading.","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/insurance/cards","href":"/api-reference/v1/patients/attach-an-insurance-card-image"},{"title":"Attach insurance with an exact payer","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /patients/{id}/insurance:exact","href":"/api-reference/v1/patients/attach-insurance-with-an-exact-payer"},{"title":"List a patient's lab / pathology results","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /patients/{id}/lab-results","href":"/api-reference/v1/patients/list-a-patients-lab-pathology-results"},{"title":"Set a patient's referring provider","deprecated":null,"version":null,"openapi":"/openapi-v1.json put /patients/{id}/referring-provider","href":"/api-reference/v1/patients/set-a-patients-referring-provider"},{"title":"Change an insurance policy's type","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /patients/{patientId}/insurance-policies/{policyId}","href":"/api-reference/v1/patients/change-an-insurance-policys-type"}]},{"group":"Eligibility Checks","pages":[{"title":"List eligibility checks","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /eligibility-checks","href":"/api-reference/v1/eligibility-checks/list-eligibility-checks"},{"title":"Run an eligibility check","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /eligibility-checks","href":"/api-reference/v1/eligibility-checks/run-an-eligibility-check"},{"title":"Get eligibility check by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /eligibility-checks/{id}","href":"/api-reference/v1/eligibility-checks/get-eligibility-check-by-id"}]},{"group":"Emails","pages":[{"title":"List sent emails","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /emails","href":"/api-reference/v1/emails/list-sent-emails"},{"title":"Send emails","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /emails/send","href":"/api-reference/v1/emails/send-emails"},{"title":"Get email by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /emails/{id}","href":"/api-reference/v1/emails/get-email-by-id"}]},{"group":"ERA Service Lines","pages":[{"title":"List ERA service lines","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /era-service-lines","href":"/api-reference/v1/era-service-lines/list-era-service-lines"},{"title":"Get ERA service line by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /era-service-lines/{id}","href":"/api-reference/v1/era-service-lines/get-era-service-line-by-id"}]},{"group":"Facilities","pages":[{"title":"List facilities","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /facilities","href":"/api-reference/v1/facilities/list-facilities"},{"title":"Get facility by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /facilities/{id}","href":"/api-reference/v1/facilities/get-facility-by-id"}]},{"group":"Faxes","pages":[{"title":"List faxes","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /faxes","href":"/api-reference/v1/faxes/list-faxes"},{"title":"Send a fax","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /faxes/send","href":"/api-reference/v1/faxes/send-a-fax"},{"title":"List fax cover-page templates","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /faxes/templates","href":"/api-reference/v1/faxes/list-fax-cover-page-templates"},{"title":"Get fax by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /faxes/{id}","href":"/api-reference/v1/faxes/get-fax-by-id"}]},{"group":"Insurance Policies","pages":[{"title":"List insurance policies","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /insurance-policies","href":"/api-reference/v1/insurance-policies/list-insurance-policies"},{"title":"Get insurance policy by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /insurance-policies/{id}","href":"/api-reference/v1/insurance-policies/get-insurance-policy-by-id"},{"title":"List a policy's insurance card images","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /insurance-policies/{id}/attachments","href":"/api-reference/v1/insurance-policies/list-a-policys-insurance-card-images"}]},{"group":"Inventory","pages":[{"title":"List inventory changes","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/changes","href":"/api-reference/v1/inventory/list-inventory-changes"},{"title":"Get inventory change by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/changes/{id}","href":"/api-reference/v1/inventory/get-inventory-change-by-id"},{"title":"List products in an inventory change","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/changes/{id}/products","href":"/api-reference/v1/inventory/list-products-in-an-inventory-change"},{"title":"List products","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/products","href":"/api-reference/v1/inventory/list-products"},{"title":"Get product by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/products/{id}","href":"/api-reference/v1/inventory/get-product-by-id"},{"title":"Get stock levels","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/stock-levels","href":"/api-reference/v1/inventory/get-stock-levels"},{"title":"Get stock levels with per-lot breakdown","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /inventory/stock-levels/detail","href":"/api-reference/v1/inventory/get-stock-levels-with-per-lot-breakdown"}]},{"group":"Marketplace","pages":[{"title":"List this app's installations","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /marketplace/installations","href":"/api-reference/v1/marketplace/list-this-apps-installations"},{"title":"Get current app context","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /marketplace/me","href":"/api-reference/v1/marketplace/get-current-app-context"},{"title":"List the organization's members","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /marketplace/members","href":"/api-reference/v1/marketplace/list-the-organizations-members"},{"title":"Verify a session token and resolve its organization","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /marketplace/verify-session","href":"/api-reference/v1/marketplace/verify-a-session-token-and-resolve-its-organization"}]},{"group":"Notes","pages":[{"title":"List patient notes","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /notes","href":"/api-reference/v1/notes/list-patient-notes"},{"title":"Get note by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /notes/{id}","href":"/api-reference/v1/notes/get-note-by-id"},{"title":"Edit SOAP note fields","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /notes/{noteId}","href":"/api-reference/v1/notes/edit-soap-note-fields"},{"title":"Upload image to note","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /notes/{noteId}/images","href":"/api-reference/v1/notes/upload-image-to-note"},{"title":"Delete image from note","deprecated":null,"version":null,"openapi":"/openapi-v1.json delete /notes/{noteId}/images/{imageId}","href":"/api-reference/v1/notes/delete-image-from-note"},{"title":"Get signed URL for a note image","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /notes/{noteId}/images/{imageId}/url","href":"/api-reference/v1/notes/get-signed-url-for-a-note-image"},{"title":"Edit impression fields","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /notes/{noteId}/impressions/{impressionId}","href":"/api-reference/v1/notes/edit-impression-fields"}]},{"group":"Organization","pages":[{"title":"List the organization's members","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /org/members","href":"/api-reference/v1/organization/list-the-organizations-members"}]},{"group":"Payers","pages":[{"title":"Search payers","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /payers","href":"/api-reference/v1/payers/search-payers"},{"title":"Add a directory payer to the practice","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /payers","href":"/api-reference/v1/payers/add-a-directory-payer-to-the-practice"},{"title":"Payer capabilities","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /payers/capabilities","href":"/api-reference/v1/payers/payer-capabilities"},{"title":"Search the EHR's national payer directory","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /payers/directory","href":"/api-reference/v1/payers/search-the-ehrs-national-payer-directory"},{"title":"Get payer by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /payers/{id}","href":"/api-reference/v1/payers/get-payer-by-id"}]},{"group":"Phone Numbers","pages":[{"title":"List organization phone numbers","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /phone-numbers","href":"/api-reference/v1/phone-numbers/list-organization-phone-numbers"}]},{"group":"Prior Authorizations","pages":[{"title":"List prior authorizations","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /prior-authorizations","href":"/api-reference/v1/prior-authorizations/list-prior-authorizations"},{"title":"Get prior authorization by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /prior-authorizations/{id}","href":"/api-reference/v1/prior-authorizations/get-prior-authorization-by-id"},{"title":"List source documents for a prior authorization","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /prior-authorizations/{id}/documents","href":"/api-reference/v1/prior-authorizations/list-source-documents-for-a-prior-authorization"}]},{"group":"Providers","pages":[{"title":"List providers","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /providers","href":"/api-reference/v1/providers/list-providers"},{"title":"Get provider by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /providers/{id}","href":"/api-reference/v1/providers/get-provider-by-id"}]},{"group":"Schedule","pages":[{"title":"List appointment types","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/appointment-types","href":"/api-reference/v1/schedule/list-appointment-types"},{"title":"List availability templates","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/availability-templates","href":"/api-reference/v1/schedule/list-availability-templates"},{"title":"List calendar events","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/calendar-events","href":"/api-reference/v1/schedule/list-calendar-events"},{"title":"What this organization's EHR supports","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/capabilities","href":"/api-reference/v1/schedule/what-this-organizations-ehr-supports"},{"title":"Search the EHR's appointment finder","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/finder","href":"/api-reference/v1/schedule/search-the-ehrs-appointment-finder"},{"title":"Providers and facilities that take an appointment type","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/finder/provider-locations","href":"/api-reference/v1/schedule/providers-and-facilities-that-take-an-appointment-type"},{"title":"Hold a slot","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /schedule/holds","href":"/api-reference/v1/schedule/hold-a-slot"},{"title":"Release a slot hold","deprecated":null,"version":null,"openapi":"/openapi-v1.json delete /schedule/holds/{holdId}","href":"/api-reference/v1/schedule/release-a-slot-hold"},{"title":"Find bookable slots","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /schedule/slots","href":"/api-reference/v1/schedule/find-bookable-slots"},{"title":"List visit reasons","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /visit-reasons","href":"/api-reference/v1/schedule/list-visit-reasons"}]},{"group":"Sync Requests","pages":[{"title":"Request a re-sync of a resource with the EHR","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /sync-requests","href":"/api-reference/v1/sync-requests/request-a-re-sync-of-a-resource-with-the-ehr"},{"title":"Request a re-sync of several resources in one call","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /sync-requests/batch","href":"/api-reference/v1/sync-requests/request-a-re-sync-of-several-resources-in-one-call"},{"title":"Get a sync request by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /sync-requests/{id}","href":"/api-reference/v1/sync-requests/get-a-sync-request-by-id"}]},{"group":"Tasks","pages":[{"title":"List tasks","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /tasks","href":"/api-reference/v1/tasks/list-tasks"},{"title":"Create a task","deprecated":null,"version":null,"openapi":"/openapi-v1.json post /tasks","href":"/api-reference/v1/tasks/create-a-task"},{"title":"List task assignee groups","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /tasks/assignee-groups","href":"/api-reference/v1/tasks/list-task-assignee-groups"},{"title":"List task assignees","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /tasks/assignees","href":"/api-reference/v1/tasks/list-task-assignees"},{"title":"Task capabilities","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /tasks/capabilities","href":"/api-reference/v1/tasks/task-capabilities"},{"title":"Get task by ID","deprecated":null,"version":null,"openapi":"/openapi-v1.json get /tasks/{id}","href":"/api-reference/v1/tasks/get-task-by-id"},{"title":"Update task status","deprecated":null,"version":null,"openapi":"/openapi-v1.json patch /tasks/{id}","href":"/api-reference/v1/tasks/update-task-status"}]}]}]}]}]},"basePath":"","title":"Attach insurance to an existing patient - Max AI Developer Docs","buildId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","deploymentId":"dpl_8LJbrAiZvr1K98WQNZXCyY5AvT34","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-i2a3QZ8E.js","utils-ChLwp8m0.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-DRktVTDc.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-CA2pEs4T.js","snippetPresets-ClQ6XrKD.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-Ct_Lv36y.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-Cn2PYw9e.js","shallow-rkyymjXQ.js","getApiPlaygroundDisplay-BB9vkXtE.js","CodeSnippet-Bm5RU7m1.js","CodeSnippets-BgU9Deuz.js","Page-BUDYNlhG.js","getPastedJson-BD-6NNum.js","icon-8Z6tud2e.js","MethodPill-Tuzr4g3V.js","DuplicateIcon-0ceWFYhN.js","createIcon-FBXow_ST.js","DynamicMarkdown-CD8713Yy.js","SectionHeading-7zgzQbH-.js","axios-vUo_bRtp.js","Markdown-D7Ofw1oz.js","clsx-eKJ4rcii.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-CwjSCXIK.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-9EK5IAXV.js"]}