Phenoml API · Reference
Clinical text in.
Structured data out.
10 services, one REST API. Every endpoint speaks JSON over HTTPS, authenticates with a bearer token, and returns citations you can trace back to the source. 73 endpoints across 10 groups.
https://experiment.app.pheno.mlErrors
Conventional HTTP status codes: 2xx for success, 4xx for problems with the request, and 5xx for problems on our side. Failed platform endpoints return a JSON envelope with success: false and a human-readable message.
Status codes
200 · 201 · 202Success. Creates usually return 201; asynchronous work such as code-system uploads and bulk operations may return 202.
400Invalid request: malformed body, missing required fields, or values that fail validation.
401Missing or expired bearer token.
403Forbidden: plan limits, ownership rules, or modifying sandbox or built-in resources.
404Resource not found.
409Conflict, such as uploading a code system whose name and version already exist without replace.
422Semantically invalid, such as FHIR that fails profile validation.
500Server error. It is safe to retry idempotent reads.
Common headers
These platform headers thread identity and EHR credentials through FHIR-touching calls, including tools, agents, the FHIR proxy, and the platform MCP endpoint.
Headers
AuthorizationrequiredBearer token from the auth endpoint. The SDKs attach and refresh it automatically.
X-Phenoml-On-Behalf-OfoptionalAct in a user context: Patient/{uuid} or Practitioner/{uuid}. Required for patient-facing apps so requests are scoped accordingly.
X-Phenoml-Fhir-ProvideroptionalPer-request FHIR provider credentials, formatted as {fhir_provider_id}:{oauth2_token}, for apps where users bring their own EHR tokens instead of stored provider credentials.
Authentication
Manage API credentials, generate authentication tokens, and handle authorization.
Generate authentication token
/auth/tokenGenerates a JWT token using Basic Authentication with API credential client ID and secret.
Successfully generated token
Response fields
tokenstringrequiredJWT token to be used for subsequent authenticated requests
Request an access token
/v2/auth/tokenOAuth 2.0 client credentials token endpoint (RFC 6749 §4.4). Accepts client_id and client_secret in the request body (JSON or form-encoded) or via Basic Auth header (RFC 6749 §2.3.1), and returns an access token with expiration information.
Body parameters
grant_typestringoptionalMust be "client_credentials" if provided
client_idstringoptionalThe client ID (credential username)
client_secretstringoptionalThe client secret (credential password)
Successfully generated token
Response fields
access_tokenstringrequiredJWT access token for subsequent authenticated requests
token_typestringrequiredToken type (always "Bearer")
expires_inintegerrequiredToken lifetime in seconds
Construe
Extract medical codes from natural language clinical text. Supports SNOMED CT, ICD-10, RxNorm, LOINC, and more.
/construe/feedbackGET/construe/codes/systemsGET/construe/codes/systems/{codesystem}DELETE/construe/codes/systems/{codesystem}GET/construe/codes/systems/{codesystem}/exportPOST/construe/uploadGET/construe/codes/{codesystem}GET/construe/codes/{codesystem}/{codeID}GET/construe/codes/{codesystem}/search/semanticGET/construe/codes/{codesystem}/search/textPOST/construe/extractSubmit feedback on extraction results
/construe/feedbackSubmits user feedback on results from the Construe extraction endpoint. Feedback includes the full extraction result received and the result the user expected.
Body parameters
textstringrequiredThe natural language text that was used for code extraction
received_resultobjectrequiredsystemobjectrequirednamestringoptionalCode system name. Can be a built-in system or a custom system name.
Built-in systems:
- SNOMED_CT_US_LITE - version 20240901
- RXNORM - version 11042024
- ICD-10-CM - version 2025
- ICD-10-PCS - version 2025
- LOINC - version 2.78
- HPO - version 2025
- CPT - version 2025
Custom systems:
- Any valid system name uploaded via /construe/upload. Requires a paid plan.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
versionstringoptionalCode system version. Must match the version available in your environment.
codesobject[]requiredcodestringrequiredThe extracted code
descriptionstringrequiredShort description of the code
validbooleanrequiredWhether the code passed validation. Always true unless include_invalid is set to true, in which case invalid codes will have this set to false.
reasonstringoptionalExplanation for why this code was extracted (if include_rationale is true)
is_ancestorbooleanoptionalWhether this code is an ancestor (parent) of an extracted code rather than directly extracted. Only present when include_ancestors is true.
citationsobject[]optionalSource text references showing where this code was found in the input. Only present when include_citations is true and chunking method supports it. Ancestor codes do not receive citations.
categoriesobject[]optionalHigher-level groupings the extracted code belongs to (e.g. HPO category terms). Only populated by full-extraction chunking methods such as "fasthpocr".
expected_resultobjectrequiredsystemobjectrequirednamestringoptionalCode system name. Can be a built-in system or a custom system name.
Built-in systems:
- SNOMED_CT_US_LITE - version 20240901
- RXNORM - version 11042024
- ICD-10-CM - version 2025
- ICD-10-PCS - version 2025
- LOINC - version 2.78
- HPO - version 2025
- CPT - version 2025
Custom systems:
- Any valid system name uploaded via /construe/upload. Requires a paid plan.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
versionstringoptionalCode system version. Must match the version available in your environment.
codesobject[]requiredcodestringrequiredThe extracted code
descriptionstringrequiredShort description of the code
validbooleanrequiredWhether the code passed validation. Always true unless include_invalid is set to true, in which case invalid codes will have this set to false.
reasonstringoptionalExplanation for why this code was extracted (if include_rationale is true)
is_ancestorbooleanoptionalWhether this code is an ancestor (parent) of an extracted code rather than directly extracted. Only present when include_ancestors is true.
citationsobject[]optionalSource text references showing where this code was found in the input. Only present when include_citations is true and chunking method supports it. Ancestor codes do not receive citations.
categoriesobject[]optionalHigher-level groupings the extracted code belongs to (e.g. HPO category terms). Only populated by full-extraction chunking methods such as "fasthpocr".
detailstringoptionalOptional details explaining the feedback
Feedback saved successfully
Response fields
idstringrequiredThe ID of the saved feedback
List available code systems
/construe/codes/systemsReturns the terminology server's catalog of available code systems, including both built-in standard terminologies and custom uploaded systems.
List of available code systems
Response fields
systemsobject[]requirednamestringrequiredCode system name
versionstringrequiredCode system version
code_countintegerrequiredTotal number of codes in the system
builtinbooleanrequiredWhether this is a built-in system (vs custom uploaded)
Get code system detail
/construe/codes/systems/{codesystem}Returns full metadata for a single code system, including timestamps and builtin status.
Path parameters
codesystemstringrequiredCode system name (e.g., "ICD-10-CM", "SNOMED_CT_US_LITE")
Query parameters
versionstringoptionalSpecific version of the code system. Required if multiple versions exist.
Code system detail
Response fields
namestringrequiredCode system name
versionstringrequiredCode system version
code_countintegerrequiredTotal number of codes in the system
builtinbooleanrequiredWhether this is a built-in system (vs custom uploaded)
statusstringrequiredProcessing status of the code system.
- "processing": embeddings are being generated
- "ready": code system is ready for use
- "failed": processing failed (re-upload with replace=true to retry)
processingreadyfailedcreated_atstring (date-time)requiredWhen the code system was created
updated_atstring (date-time)requiredWhen the code system was last updated
Delete custom code system
/construe/codes/systems/{codesystem}Deletes a custom (non-builtin) code system and all its codes. Builtin systems cannot be deleted. Only available on dedicated instances. Large systems may take up to a minute to delete.
Path parameters
codesystemstringrequiredCode system name
Query parameters
versionstringoptionalSpecific version of the code system. Required if multiple versions exist.
Code system deleted successfully
Response fields
messagestringrequiredConfirmation message
Export custom code system
/construe/codes/systems/{codesystem}/exportExports a custom (non-builtin) code system as a JSON file compatible with the upload format. The exported file can be re-uploaded directly via POST /construe/upload with format "json". Only available on dedicated instances. Builtin systems cannot be exported.
Path parameters
codesystemstringrequiredCode system name
Query parameters
versionstringoptionalSpecific version of the code system. Required if multiple versions exist.
Exported code system as JSON file
Response fields
namestringrequiredCode system name
versionstringrequiredCode system version
formatstringrequiredUpload format (always "json")
jsoncodesobject[]requiredAll codes in the system
codestringrequiredThe code identifier
descriptionstringrequiredShort description of the code
definitionstringoptionalExtended definition of the code (if available)
Upload custom code system
/construe/uploadUpload a custom medical code system with codes and descriptions for use in code extraction. Requires a paid plan. Returns 202 immediately; embedding generation runs asynchronously. Poll GET /construe/codes/systems/{codesystem}?version={version} to check when status transitions from "processing" to "ready" or "failed".
Body parameters
namestringrequiredName of the code system. Names are case-insensitive and stored uppercase. Builtin system names (e.g. ICD-10-CM, SNOMED_CT_US_LITE, LOINC, CPT, etc.) are reserved and cannot be used for custom uploads; attempts return HTTP 403 Forbidden.
versionstringrequiredVersion of the code system
revisionnumberoptionalOptional revision number
formatstringrequiredUpload format
csvjsonfilestring (byte)optionalThe file contents as a base64-encoded string. For CSV format, this is the CSV file contents. For JSON format, this is a base64-encoded JSON array; prefer using 'codes' instead.
code_colstringoptionalColumn name containing codes (required for CSV format)
desc_colstringoptionalColumn name containing descriptions (required for CSV format)
defn_colstringoptionalOptional column name containing long definitions (for CSV format)
codesobject[]optionalThe codes to upload as a JSON array (JSON format only). This is the preferred way to upload JSON codes, as it avoids unnecessary base64 encoding. If both 'codes' and 'file' are provided, 'codes' takes precedence.
codestringrequiredThe code identifier
descriptionstringrequiredShort description of the code
definitionstringoptionalExtended definition of the code (if available)
replacebooleanoptionaldefault falseIf true, replaces an existing code system with the same name and version. Builtin systems cannot be replaced; attempts to do so return HTTP 403 Forbidden. When false (default), uploading a duplicate returns 409 Conflict.
Upload accepted for asynchronous processing
Response fields
statusstringoptionalnamestringoptionalversionstringoptionalList codes in a code system
/construe/codes/{codesystem}Returns a paginated list of all codes in the specified code system from the terminology server.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
Path parameters
codesystemstringrequiredCode system name (e.g., "ICD-10-CM", "SNOMED_CT_US_LITE")
Query parameters
versionstringoptionalSpecific version of the code system. Required if multiple versions exist.
cursorstringoptionalPagination cursor from previous response
limitintegeroptionaldefault 20Maximum number of codes to return (default 20)
Paginated list of codes
Response fields
systemobjectrequirednamestringrequiredCode system name
versionstringrequiredCode system version
codesobject[]requiredcodestringrequiredThe code identifier
descriptionstringrequiredShort description of the code
definitionstringoptionalExtended definition of the code (if available)
next_cursorstringoptionalCursor for fetching the next page (null if no more results)
has_morebooleanrequiredWhether there are more results available
Get a specific code
/construe/codes/{codesystem}/{codeID}Looks up a specific code in the terminology server and returns its details.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
Path parameters
codesystemstringrequiredCode system name
codeIDstringrequiredThe code identifier. ICD-10-CM codes are stored without their cosmetic dot (use "E1165", not "E11.65").
Query parameters
versionstringoptionalSpecific version of the code system
Code details
Response fields
systemobjectrequirednamestringrequiredCode system name
versionstringrequiredCode system version
codestringrequiredThe code identifier
descriptionstringrequiredShort description of the code
definitionstringoptionalExtended definition of the code (if available)
Semantic search (embedding-based)
/construe/codes/{codesystem}/search/semanticPerforms semantic similarity search using vector embeddings.
Availability: This endpoint works for both built-in and custom code systems.
When to use: Best for natural language queries where you want to find conceptually related codes, even when different terminology is used. The search understands meaning, not just keywords.
Examples:
- Query "trouble breathing at night" finds codes like "Sleep apnea", "Orthopnea", "Nocturnal dyspnea" — semantically related but no exact keyword matches
- Query "heart problems" finds "Myocardial infarction", "Cardiac arrest", "Arrhythmia"
Trade-offs: Slower than text search (requires embedding generation), but finds conceptually similar results that keyword search would miss.
See also: /search/text for faster keyword-based lookup with typo tolerance.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
Path parameters
codesystemstringrequiredCode system name
Query parameters
textstringrequiredNatural language text to find semantically similar codes for
versionstringoptionalSpecific version of the code system
limitintegeroptionaldefault 10Maximum number of results (default 10, max 50)
Semantic search results ordered by similarity
Response fields
systemobjectrequirednamestringrequiredCode system name
versionstringrequiredCode system version
resultsobject[]requiredCodes ordered by semantic similarity (most similar first)
codestringrequireddescriptionstringrequiredText search (keyword-based)
/construe/codes/{codesystem}/search/textPerforms fast full-text search over code IDs and descriptions.
Availability: This endpoint is only available for built-in code systems.
Custom code systems uploaded via /construe/upload are not indexed for full-text search
and will return empty results. Use /search/semantic to search custom code systems.
When to use: Best for autocomplete UIs, code lookup, or when users know part of the code ID or specific keywords. Fast response times suitable for typeahead interfaces.
Features:
- Substring matching on code IDs (e.g., "11.65" finds "E11.65")
- Typo tolerance on descriptions (not on code IDs)
- Fast response times (~10-50ms)
Examples:
- Query "E11" finds all codes starting with E11 (diabetes codes)
- Query "diabtes" (typo) still finds "diabetes" codes
Trade-offs: Faster than semantic search, but only matches keywords/substrings. Won't find conceptually related codes with different terminology.
See also: /search/semantic for finding conceptually similar codes.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
Path parameters
codesystemstringrequiredCode system name
Query parameters
qstringrequiredSearch query (searches code IDs and descriptions)
versionstringoptionalSpecific version of the code system
limitintegeroptionaldefault 20Maximum number of results (default 20, max 100)
Text search results
Response fields
systemobjectrequirednamestringrequiredCode system name
versionstringrequiredCode system version
resultsobject[]requiredCodes matching the search query
codestringrequireddescriptionstringrequiredfoundintegerrequiredTotal number of matching results (may exceed results array due to pagination)
Extract medical codes from text
/construe/extractConverts natural language text into structured medical codes.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
Body parameters
textstringrequiredNatural language text to extract codes from
systemobjectoptionalnamestringoptionalCode system name. Can be a built-in system or a custom system name.
Built-in systems:
- SNOMED_CT_US_LITE - version 20240901
- RXNORM - version 11042024
- ICD-10-CM - version 2025
- ICD-10-PCS - version 2025
- LOINC - version 2.78
- HPO - version 2025
- CPT - version 2025
Custom systems:
- Any valid system name uploaded via /construe/upload. Requires a paid plan.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
versionstringoptionalCode system version. Must match the version available in your environment.
configobjectoptionalchunking_methodstringoptionaldefault sentencesMethod for splitting input text into chunks before code extraction.
- none - Treat the full input as a single chunk.
- sentences - Split on sentence boundaries (supports citations).
- paragraphs / topics / soap_note - LLM-based chunking.
- clinical_ner_extract - Extract clinical concepts (problems, tests, treatments) and use each as a chunk (supports citations).
- fasthpocr - Extract HPO concepts directly with category
annotations (supports citations). Requires
system: HPO; other systems are rejected. Causes most other config options to be ignored.
nonesentencesparagraphstopicssoap_noteclinical_ner_extractfasthpocrmax_codes_per_chunkintegeroptionalMaximum number of codes to extract per chunk. If not specified, uses system-specific defaults:
- SNOMED: 10
- LOINC, HPO, RXNORM: 20
- All other systems: 5
code_similarity_filternumber (float)optionaldefault 0.9Threshold for filtering similar codes (0.0-1.0)
validation_methodstringoptionaldefault simpleMethod for validating extracted codes:
- none - No validation, returns all candidate codes
- simple - LLM-based validation
- medication_search - LLM-based validation tailored for medication concepts
- chunk_code_jaccard_similarity - Token-level Jaccard similarity between source text chunk and code description
nonesimplemedication_searchchunk_code_jaccard_similaritychunk_code_jaccard_similarity_filtering_thresholdnumber (float)optionaldefault 0.2Minimum Jaccard similarity (0.0-1.0) for a code to be considered valid when using the "chunk_code_jaccard_similarity" validation method. Ignored by other methods.
include_rationalebooleanoptionaldefault trueWhether to include explanations for why each code was extracted
include_ancestorsbooleanoptionaldefault falseWhether to include ancestor/parent codes in the results
include_invalidbooleanoptionaldefault falseWhether to include codes that failed validation in the results
include_citationsbooleanoptionaldefault falseWhether to include source text citations for each extracted code. Citations show the exact text spans (with character offsets) that led to each code. Supported when chunking_method is "sentences", "clinical_ner_extract", or "fasthpocr".
extraction_contextstringoptionalOptional context describing the goal of the extraction. Required when min_context_relevance is greater than 0.
min_context_relevancenumber (double)optionaldefault 0Minimum relevance score (0.0–1.0) a chunk must reach to proceed to code extraction. Chunks are scored by an LLM against the extraction_context goal. Chunks below this threshold are dropped, reducing noise and extraction cost. Set to 0 (the default) to disable relevance filtering and extract from all chunks. Requires the "extraction_context" field when set above 0.
consistency_effortstringoptionaldefault noneHow much effort to spend ensuring consistent results across repeated requests. Higher levels apply stricter filtering to remove borderline results that may vary between calls, improving determinism at the cost of additional latency.
When validation_method is set to a value other than "none", consistency is applied to the validation step: codes must be unanimously validated across multiple rounds to be included.
When validation_method is "none" and min_context_relevance is set above 0, consistency is applied to the relevance ranking step instead: chunks must pass the relevance threshold in every round to be included.
nonelowmediumhighSuccessfully extracted codes
Response fields
systemobjectrequirednamestringoptionalCode system name. Can be a built-in system or a custom system name.
Built-in systems:
- SNOMED_CT_US_LITE - version 20240901
- RXNORM - version 11042024
- ICD-10-CM - version 2025
- ICD-10-PCS - version 2025
- LOINC - version 2.78
- HPO - version 2025
- CPT - version 2025
Custom systems:
- Any valid system name uploaded via /construe/upload. Requires a paid plan.
Usage of CPT is subject to AMA requirements: see PhenoML Terms of Service.
versionstringoptionalCode system version. Must match the version available in your environment.
codesobject[]requiredcodestringrequiredThe extracted code
descriptionstringrequiredShort description of the code
validbooleanrequiredWhether the code passed validation. Always true unless include_invalid is set to true, in which case invalid codes will have this set to false.
reasonstringoptionalExplanation for why this code was extracted (if include_rationale is true)
is_ancestorbooleanoptionalWhether this code is an ancestor (parent) of an extracted code rather than directly extracted. Only present when include_ancestors is true.
citationsobject[]optionalSource text references showing where this code was found in the input. Only present when include_citations is true and chunking method supports it. Ancestor codes do not receive citations.
textstringrequiredThe exact text span containing evidence for the code
begin_offsetintegerrequiredStarting byte offset in the original input text (0-indexed)
end_offsetintegerrequiredEnding byte offset (exclusive), such that input[begin_offset:end_offset] == text
categoriesobject[]optionalHigher-level groupings the extracted code belongs to (e.g. HPO category terms). Only populated by full-extraction chunking methods such as "fasthpocr".
uristringrequiredIdentifier for the category term (e.g. an HPO URI).
labelstringrequiredHuman-readable label for the category term.
Lang2FHIR
Convert natural language clinical text into structured FHIR resources including Patient, Condition, MedicationRequest, and more.
Analyze text for patient cohort criteria
/cohortConverts natural language text into structured FHIR search queries for patient cohort analysis
Body parameters
textstringrequiredNatural language text describing patient cohort criteria
Successfully analyzed cohort criteria
Response fields
successbooleanoptionalWhether the cohort analysis was successful
messagestringoptionalHuman-readable message about the analysis result
queriesobject[]optionalArray of search concepts converted to FHIR search queries
resource_typestringoptionalThe FHIR resource type for this search concept
search_paramsstringoptionalFHIR search parameters in standard format
conceptstringoptionalThe original concept description
excludebooleanoptionalWhether this concept should be excluded from the search
Create FHIR resource from text
/lang2fhir/createConverts natural language text into a structured FHIR resource.
Patient identifier handling. When generating a patient (or patient-canvas) resource, US Core requires Patient.identifier (a business identifier such as an MRN). When the source text contains an identifier, it is extracted with an appropriate URI system. When the source text does not contain a detectable identifier, a synthetic one is generated with system: "urn:phenoml:lang2fhir-generated-id" and a UUID value so the resource remains FHIR-valid and US Core conformant. Callers who need a tenant-specific namespace should rewrite the synthetic system after extraction.
Body parameters
versionstringrequireddefault R4FHIR version to use
resourcestringrequiredType of FHIR resource to create. Use 'auto' for automatic resource type detection, or specify a supported US Core profile. Recommended to use the supported US Core Profiles for validated results but you can also use any custom profile you've uploaded (if you're a develop or launch customer)
autoappointmentcondition-encounter-diagnosismedicationrequestcareplancondition-problems-health-concernscoverageencounterobservation-clinical-resultobservation-labpatientprocedurequestionnairequestionnaireresponseservicerequestsimple-observationvital-signstextstringrequiredNatural language text to convert
Successfully created FHIR resource
Response fields
resourceTypestringoptionalclinicalStatusobjectoptionalcodingarray<object>optionalsystemstringoptionalcodestringoptionalcodeobjectoptionalcodingarray<object>optionalsystemstringoptionalcodestringoptionaldisplaystringoptionaltextstringoptionalseverityobjectoptionalcodingarray<object>optionalsystemstringoptionalcodestringoptionaldisplaystringoptionalExtract multiple FHIR resources from text
/lang2fhir/create/multiAnalyzes natural language text and extracts multiple FHIR resources, returning them as a transaction Bundle. Automatically detects Patient, Condition, MedicationRequest, Observation, and other resource types from the text. Resources are linked with proper references (e.g., Conditions reference the Patient).
Patient identifier handling. US Core requires Patient.identifier (a business identifier such as an MRN). When the source text contains an identifier, it is extracted with an appropriate URI system. When the source text does not contain a detectable identifier, a synthetic one is generated with system: "urn:phenoml:lang2fhir-generated-id" and a UUID value so the bundle remains FHIR-valid and US Core conformant. Callers who need a tenant-specific namespace should rewrite the synthetic system after extraction.
Body parameters
textstringrequiredNatural language text containing multiple clinical concepts to extract
versionstringoptionaldefault R4FHIR version to use
providerstringoptionalOptional FHIR provider name for provider-specific profiles
implementation_guidestringoptionalCustom Implementation Guide name. When specified, profiles from this IG are included alongside US Core profiles during resource detection. US Core is always the base layer; custom IG profiles are additive.
detection_effortstringoptionaldefault standardDetection effort. 'standard' runs detection once, 'deep' runs detection multiple times for higher recall.
standarddeepvalidation_methodstringoptionaldefault noneFHIR validation method to apply to the generated bundle. 'none' skips validation (default). 'check' runs the bundle through a FHIR structure validator and includes the results in the response. 'fix' runs validation and attempts to auto-correct errors using an LLM (up to 3 validation passes). The response includes results from each pass. Warning: 'fix' can significantly increase latency due to multiple LLM and validation round-trips.
nonecheckfixSuccessfully extracted FHIR resources
Response fields
successbooleanoptionalWhether extraction was successful
messagestringoptionalStatus message
bundleobjectoptionalFHIR transaction Bundle containing all extracted resources
resourceTypestringoptionaltypestringoptionalentryobject[]optionalfullUrlstringoptionalresourceobjectoptionalrequestobjectoptionalresourcesobject[]optionalSummary of extracted resources
tempIdstringoptionalTemporary UUID for the resource
resourceTypestringoptionalFHIR resource type
descriptionstringoptionalContext-enriched rewritten text excerpt for this resource
originalTextstringoptionalVerbatim text excerpt from the original clinical document
validationobjectoptionalFHIR validation results. Present when validation_method is 'check' or 'fix'. Contains results from each validation pass. For 'check', there is one pass. For 'fix', there may be up to 3 passes as the system attempts auto-correction.
passesobject[]optionalResults from each validation pass, in chronological order
issuesobject[]optionalValidation issues found in this pass
statsobjectoptionalValidation statistics for this pass
fixedbooleanoptionalWhether validation errors were successfully fixed by the LLM. Always false for 'check' mode. For 'fix' mode, true if errors were resolved and the returned bundle is the corrected version.
attemptsintegeroptionalTotal number of validation passes run (1 for check, 1-3 for fix)
summarystringoptionalHuman-readable summary of the validation outcome
Convert document to FHIR resource
/lang2fhir/documentExtracts text from a document (PDF or image) and converts it into a structured FHIR resource.
Patient identifier handling. When generating a patient (or patient-canvas) resource, US Core requires Patient.identifier (a business identifier such as an MRN). When the source text contains an identifier, it is extracted with an appropriate URI system. When the source text does not contain a detectable identifier, a synthetic one is generated with system: "urn:phenoml:lang2fhir-generated-id" and a UUID value so the resource remains FHIR-valid and US Core conformant. Callers who need a tenant-specific namespace should rewrite the synthetic system after extraction.
Body parameters
versionstringrequiredFHIR version to use
resourcestringrequiredType of FHIR resource to create. Accepts any FHIR resource type or US Core profile name.
contentstringrequiredBase64 encoded file content. Supported file types: PDF (application/pdf), PNG (image/png), JPEG (image/jpeg). File type is auto-detected from content magic bytes.
configobjectoptionalOptional processing configuration shared across document endpoints.
page_filterobjectoptionalConfigures per-page pre-extraction filtering. When set, each page of text extracted from the document is classified by an LLM, and pages classified as irrelevant to the supplied context are dropped before FHIR extraction.
contextstringrequiredNatural-language description of what IS relevant to the extraction goal. Pages that do not match are dropped from downstream FHIR extraction.
Successfully created FHIR resource from document
Extract multiple FHIR resources from a document
/lang2fhir/document/multiExtracts text from a document (PDF or image) and converts it into multiple FHIR resources, returned as a transaction Bundle. Combines document text extraction with multi-resource detection. Automatically detects Patient, Condition, MedicationRequest, Observation, and other resource types. Resources are linked with proper references (e.g., Conditions reference the Patient).
Patient identifier handling. US Core requires Patient.identifier (a business identifier such as an MRN). When the source text contains an identifier, it is extracted with an appropriate URI system. When the source text does not contain a detectable identifier, a synthetic one is generated with system: "urn:phenoml:lang2fhir-generated-id" and a UUID value so the bundle remains FHIR-valid and US Core conformant. Callers who need a tenant-specific namespace should rewrite the synthetic system after extraction.
Body parameters
versionstringrequiredFHIR version to use
contentstringrequiredBase64 encoded file content. Supported file types: PDF (application/pdf), PNG (image/png), JPEG (image/jpeg). File type is auto-detected from content magic bytes.
providerstringoptionalOptional FHIR provider name for provider-specific profiles
implementation_guidestringoptionalCustom Implementation Guide name. When specified, profiles from this IG are included alongside US Core profiles during resource detection. US Core is always the base layer; custom IG profiles are additive.
detection_effortstringoptionaldefault standardDetection effort. 'standard' runs detection once, 'deep' runs detection multiple times for higher recall.
standarddeepvalidation_methodstringoptionaldefault noneFHIR validation method to apply to the generated bundle. 'none' skips validation (default). 'check' runs the bundle through a FHIR structure validator and includes the results in the response. 'fix' runs validation and attempts to auto-correct errors using an LLM (up to 3 validation passes). The response includes results from each pass. Warning: 'fix' can significantly increase latency due to multiple LLM and validation round-trips.
nonecheckfixconfigobjectoptionalOptional processing configuration shared across document endpoints.
page_filterobjectoptionalConfigures per-page pre-extraction filtering. When set, each page of text extracted from the document is classified by an LLM, and pages classified as irrelevant to the supplied context are dropped before FHIR extraction.
contextstringrequiredNatural-language description of what IS relevant to the extraction goal. Pages that do not match are dropped from downstream FHIR extraction.
Successfully extracted FHIR resources from document
Response fields
successbooleanoptionalmessagestringoptionalbundleobjectoptionalresourceTypestringoptionaltypestringoptionalentryarray<object>optionalfullUrlstringoptionalresourceobjectoptionalrequestobjectoptionalmethodstringoptionalurlstringoptionalresourcesarray<object>optionaltempIdstringoptionalresourceTypestringoptionaldescriptionstringoptionaloriginalTextstringoptionalvalidationobjectoptionalpassesarray<object>optionalissuesarray<object>optionalseveritystringoptionalcodestringoptionaldiagnosticsstringoptionalexpressionarray<string>optionalsourcestringoptionalstatsobjectoptionalresource_typestringoptionalprofile_urlstringoptionalis_custom_profilebooleanoptionalduration_msnumberoptionalfixedbooleanoptionalattemptsintegeroptionalsummarystringoptionalpage_classificationsarray<object>optionalpage_numberintegeroptionalincludebooleanoptionalreasonstringoptionalUpload custom FHIR profile
/lang2fhir/profile/uploadUpload a custom FHIR StructureDefinition profile for use with the lang2fhir service.
All metadata is derived from the StructureDefinition JSON itself. The lowercase id field
from the StructureDefinition is used as the profile's unique identifier and lookup key.
To use the uploaded profile with /lang2fhir/create, pass this id as the resource parameter.
Uploads will be rejected if:
- A built-in US Core or R4 base profile already exists with the same id
- A custom profile with the same id has already been uploaded
- A custom profile with the same url has already been uploaded
Body parameters
profilestringrequiredBase64 encoded JSON string of a FHIR StructureDefinition. The profile must include id, url, type, and a snapshot with elements. All metadata (version, resource type, identifier) is derived from the StructureDefinition itself. The lowercase id from the StructureDefinition becomes the profile's lookup key.
implementation_guidestringoptionalImplementation Guide name to group this profile under. Defaults to "custom" if omitted. Cannot be "us_core" (reserved). Use this to organize custom profiles into named IGs that can be referenced when calling create/multi or document/multi endpoints.
profile_contextstringoptionalNatural language context that helps the LLM select the right profiles from this implementation guide during resource detection. For example, "When the text mentions phenotypic features or abnormalities, prefer the hpo-observation profile over Condition." This is stored as IG-level metadata and injected into the LLM prompt. Max 2000 characters. Providing this field on any upload will update the context for the entire IG (last write wins).
Profile successfully uploaded
Response fields
messagestringoptionalidstringoptionalThe lowercase StructureDefinition id, used as the profile's unique identifier and lookup key. Pass this value as the resource parameter to /lang2fhir/create or /lang2fhir/profile/json/:version/:resource to use this profile.
typestringoptionalThe FHIR resource type from the StructureDefinition
urlstringoptionalThe canonical URL from the StructureDefinition
Generate FHIR search parameters from text
/lang2fhir/searchConverts natural language text into FHIR search parameters. Automatically identifies the appropriate FHIR resource type and generates valid search query parameters.
Supported resource types include: AllergyIntolerance, Appointment, CarePlan, CareTeam, Condition, Coverage, Device, DiagnosticReport, DocumentReference, Encounter, Goal, Immunization, Location, Medication, MedicationRequest, Observation, Organization, Patient, PlanDefinition, Practitioner, PractitionerRole, Procedure, Provenance, Questionnaire, QuestionnaireResponse, RelatedPerson, Schedule, ServiceRequest, Slot, and Specimen.
Body parameters
textstringrequiredNatural language text to convert into FHIR search parameters. The system will automatically identify the appropriate resource type and generate valid search parameters.
Examples:
- "Appointments between March 2-9, 2025" → Appointment search with date range
- "Patients with diabetes" → Condition search with code parameter
- "Active medication requests for metformin" → MedicationRequest search
- "Lab results for creatinine" → DiagnosticReport search
- "Dr. Smith's schedule" → Practitioner or Schedule search
Successfully generated FHIR search parameters
Response fields
resource_typestringoptionalThe FHIR resource type identified for the search
AllergyIntoleranceAppointmentCarePlanCareTeamConditionCoverageDeviceDiagnosticReportDocumentReferenceEncounterGoalImmunizationLocationMedicationMedicationRequestObservationOrganizationPatientPlanDefinitionPractitionerPractitionerRoleProcedureProvenanceQuestionnaireQuestionnaireResponseRelatedPersonScheduleServiceRequestSlotSpecimensearch_paramsstringoptionalFHIR search parameters in standard query string format. Parameters are formatted according to the FHIR specification with appropriate operators. Code parameters are resolved to standard terminology codes (SNOMED CT, LOINC, RxNorm, ICD-10-CM).
Summary
Generate clinical summaries from FHIR resources. Supports narrative templates, flattening for RAG, and IPS generation.
Generate a summary from FHIR resources
/fhir2summary/createCreates a summary from FHIR resources using one of three modes:
- narrative: Uses a template to substitute FHIR data into placeholders (requires template_id)
- flatten: Flattens FHIR resources into a searchable format for RAG/search (no template needed)
- ips: Generates an International Patient Summary (IPS) narrative per ISO 27269/HL7 FHIR IPS IG. Requires a Bundle with exactly one Patient resource (returns 400 error if no Patient or multiple Patients are present). Automatically filters resources to those referencing the patient and generates sections for allergies, medications, problems, immunizations, procedures, and vital signs.
Body parameters
modestringoptionaldefault narrativeSummary generation mode:
- narrative: Substitute FHIR data into a template (requires template_id)
- flatten: Flatten FHIR resources for RAG/search (no template needed)
- ips: Generate International Patient Summary (IPS) narrative per ISO 27269/HL7 FHIR IPS IG
narrativeflattenipstemplate_idstring (uuid)optionalID of the template to use (required for narrative mode)
fhir_resourcesobjectrequiredFHIR resources (single resource or Bundle). For IPS mode, must be a Bundle containing exactly one Patient resource with at least one identifier (id, fullUrl, or identifier field). Returns an error if no Patient is found, if multiple Patients are present, or if the Patient has no identifiers. Resources are automatically filtered to only include those referencing the patient.
Summary generated successfully
Response fields
successbooleanoptionalmessagestringoptionalsummarystringoptionalGenerated summary text
warningsstring[]optionalUnresolved placeholders or issues (narrative mode only)
Create a new summary template
/fhir2summary/templateCreates a summary template from an example using LLM function calling
Body parameters
namestringrequiredName of the template
descriptionstringoptionalDescription of the template
example_summarystringrequiredExample summary note to generate template from
target_resourcesstring[]requiredList of target FHIR resources
example_fhir_dataobjectoptionalOptional example FHIR data that corresponds to the example summary
modestringrequiredTemplate mode (stored with the template)
Template created successfully
Response fields
successbooleanoptionalmessagestringoptionaltemplate_idstring (uuid)optionaltemplateobjectoptionalidstring (uuid)optionalnamestringoptionaldescriptionstringoptionaltemplatestringoptionalTemplate with {{resource.field}} placeholders
target_resourcesstring[]optionalList of FHIR resource types/profiles
modestringoptionalTemplate mode (stored value)
metadataobjectoptionalcreated_atstring (date-time)optionalupdated_atstring (date-time)optionalGet a summary template by ID
/fhir2summary/template/{id}Retrieves a specific summary template
Path parameters
idstringrequiredTemplate ID
Template retrieved successfully
Response fields
successbooleanoptionaltemplateobjectoptionalidstring (uuid)optionalnamestringoptionaldescriptionstringoptionaltemplatestringoptionalTemplate with {{resource.field}} placeholders
target_resourcesstring[]optionalList of FHIR resource types/profiles
modestringoptionalTemplate mode (stored value)
metadataobjectoptionalcreated_atstring (date-time)optionalupdated_atstring (date-time)optionalUpdate a summary template
/fhir2summary/template/{id}Updates an existing summary template
Path parameters
idstringrequiredTemplate ID
Body parameters
namestringrequireddescriptionstringoptionaltemplatestringrequiredUpdated template with placeholders
target_resourcesstring[]requiredmodestringrequiredTemplate mode
Template updated successfully
Response fields
successbooleanoptionalmessagestringoptionaltemplateobjectoptionalidstring (uuid)optionalnamestringoptionaldescriptionstringoptionaltemplatestringoptionalTemplate with {{resource.field}} placeholders
target_resourcesstring[]optionalList of FHIR resource types/profiles
modestringoptionalTemplate mode (stored value)
metadataobjectoptionalcreated_atstring (date-time)optionalupdated_atstring (date-time)optionalDelete a summary template
/fhir2summary/template/{id}Deletes a summary template
Path parameters
idstringrequiredTemplate ID
Template deleted successfully
Response fields
successbooleanoptionalmessagestringoptionalList all summary templates
/fhir2summary/templatesRetrieves all summary templates for the authenticated user
Templates retrieved successfully
Response fields
successbooleanoptionaltemplatesobject[]optionalidstring (uuid)optionalnamestringoptionaldescriptionstringoptionaltemplatestringoptionalTemplate with {{resource.field}} placeholders
target_resourcesstring[]optionalList of FHIR resource types/profiles
modestringoptionalTemplate mode (stored value)
metadataobjectoptionalcreated_atstring (date-time)optionalupdated_atstring (date-time)optionalFHIR2OMOP
Map FHIR R4 resources and bundles into OMOP Common Data Model (CDM v5.4) tables.
Map FHIR resources to OMOP CDM v5.4
/fhir2omop/createMaps a FHIR R4 resource or Bundle into OMOP Common Data Model v5.4 rows (person, visit_occurrence, condition_occurrence, drug_exposure, procedure_occurrence, measurement, observation).
Resource support is intentionally limited to the OMOP tables returned by this endpoint:
Patient->personEncounter->visit_occurrenceCondition->condition_occurrenceProcedure->procedure_occurrenceMedicationRequest,MedicationStatement, andMedicationAdministration->drug_exposureImmunization->drug_exposureObservationwith a numericvalueQuantity,valueInteger, or numeric-lookingvalueString(for example"<2") ->measurement- non-numeric
Observation->observation AllergyIntolerance->observation
Medication is supported only as reference data for medication
resources; it is not emitted as its own row because OMOP CDM has no
Medication table. Other reference/admin resources such as Practitioner,
Organization, Location, Coverage, and Claim, and clinical
workflow/document resources such as DiagnosticReport, ServiceRequest,
CarePlan, DocumentReference, Composition, Specimen, and
DeviceUseStatement, are currently accepted in a Bundle but are not
shaped into OMOP rows. Unsupported resource types are ignored rather than
listed under dropped; dropped is reserved for supported resource types
that were missing the subject/patient, code, or medication reference data
needed to produce a valid row.
Each resource's primary clinical coding is resolved to a standard OMOP
concept_id. Alongside the OMOP rows grouped by table (tables), the
response carries mappings (how each source coding resolved, linked back
to the row it produced), dropped (resources that could not be shaped
into a row), vocab_version (the OMOP vocabulary release codes were
resolved against), and a small summary of the resolution outcomes.
A concept_id of 0 is reported, not omitted (OMOP "no matching
concept" semantics): it covers both a coding with no standard match
(UNMAPPED) and an unverified suggestion for a text-only resource
(UNCHECKED). Only the primary clinical coding is resolved, so
gender/race/ethnicity/visit/value/unit concept_ids are
always 0; the one populated non-resolved concept is measurement
operator_concept_id, set from a value comparator (<, <=, >, >=)
rather than the resolver. Each *_source_value carries the verbatim FHIR
coding (system#code), and *_type_concept_id is set to 32817 (EHR).
Medication codes are resolved whether they appear inline
(medicationCodeableConcept) or via a medicationReference to a contained,
relative (Type/id), or bundle-entry (urn:uuid) Medication resource.
Resources that cannot be shaped into a row — a medication with no usable
code, resolvable reference, or display, or any clinical resource whose
subject/patient reference cannot be tied to a person — are reported under
dropped rather than emitted as blank rows. The
bundle must contain at least one Patient resource.
Body parameters
fhir_resourcesobjectrequiredFHIR resources (single resource or Bundle). Must contain at least one Patient resource. Supported row-producing resources are Patient, Encounter, Condition, Procedure, MedicationRequest, MedicationStatement, MedicationAdministration, Immunization, Observation, and AllergyIntolerance. Standalone Medication resources are consumed by medication references rather than mapped to their own table. Other resource types are accepted but ignored.
FHIR resources mapped to OMOP CDM v5.4
Response fields
successbooleanoptionalmessagestringoptionaltablesobjectoptionalOMOP CDM v5.4 rows grouped by destination table.
locationobject[]optionallocation_idinteger (int64)optionaladdress_1stringoptionaladdress_2stringoptionalcitystringoptionalstatestringoptionalzipstringoptionalcountystringoptionallocation_source_valuestringoptionalcountry_concept_idinteger (int64)optionalcountry_source_valuestringoptionallatitudenumber (double)optionallongitudenumber (double)optionalcare_siteobject[]optionalcare_site_idinteger (int64)optionalcare_site_namestringoptionalplace_of_service_concept_idinteger (int64)optionallocation_idinteger (int64)optionalcare_site_source_valuestringoptionalplace_of_service_source_valuestringoptionalproviderobject[]optionalprovider_idinteger (int64)optionalprovider_namestringoptionalnpistringoptionaldeastringoptionalspecialty_concept_idinteger (int64)optionalcare_site_idinteger (int64)optionalyear_of_birthintegeroptionalgender_concept_idinteger (int64)optionalprovider_source_valuestringoptionalspecialty_source_valuestringoptionalspecialty_source_concept_idinteger (int64)optionalgender_source_valuestringoptionalgender_source_concept_idinteger (int64)optionalpersonobject[]optionalperson_idinteger (int64)optionalgender_concept_idinteger (int64)optionalyear_of_birthintegeroptionalmonth_of_birthintegeroptionalday_of_birthintegeroptionalbirth_datetimestringoptionalrace_concept_idinteger (int64)optionalethnicity_concept_idinteger (int64)optionallocation_idinteger (int64)optionalperson_source_valuestringoptionalgender_source_valuestringoptionalrace_source_valuestringoptionalethnicity_source_valuestringoptionaldeathobject[]optionalperson_idinteger (int64)optionaldeath_datestringoptionaldeath_datetimestringoptionaldeath_type_concept_idinteger (int64)optionalcause_concept_idinteger (int64)optionalcause_source_valuestringoptionalcause_source_concept_idinteger (int64)optionalobservation_periodobject[]optionalobservation_period_idinteger (int64)optionalperson_idinteger (int64)optionalobservation_period_start_datestringoptionalobservation_period_end_datestringoptionalperiod_type_concept_idinteger (int64)optionalvisit_occurrenceobject[]optionalvisit_occurrence_idinteger (int64)optionalperson_idinteger (int64)optionalvisit_concept_idinteger (int64)optionalvisit_start_datestringoptionalvisit_start_datetimestringoptionalvisit_end_datestringoptionalvisit_end_datetimestringoptionalvisit_type_concept_idinteger (int64)optionalprovider_idinteger (int64)optionalcare_site_idinteger (int64)optionalvisit_source_valuestringoptionalcondition_occurrenceobject[]optionalcondition_occurrence_idinteger (int64)optionalperson_idinteger (int64)optionalcondition_concept_idinteger (int64)optionalcondition_start_datestringoptionalcondition_start_datetimestringoptionalcondition_end_datestringoptionalcondition_type_concept_idinteger (int64)optionalvisit_occurrence_idinteger (int64)optionalprovider_idinteger (int64)optionalcondition_source_valuestringoptionalcondition_source_concept_idinteger (int64)optionalcondition_status_source_valuestringoptionaldrug_exposureobject[]optionaldrug_exposure_idinteger (int64)optionalperson_idinteger (int64)optionaldrug_concept_idinteger (int64)optionaldrug_exposure_start_datestringoptionaldrug_exposure_start_datetimestringoptionaldrug_exposure_end_datestringoptionaldrug_type_concept_idinteger (int64)optionalstop_reasonstringoptionalsigstringoptionalvisit_occurrence_idinteger (int64)optionalprovider_idinteger (int64)optionaldrug_source_valuestringoptionaldrug_source_concept_idinteger (int64)optionalprocedure_occurrenceobject[]optionalprocedure_occurrence_idinteger (int64)optionalperson_idinteger (int64)optionalprocedure_concept_idinteger (int64)optionalprocedure_datestringoptionalprocedure_datetimestringoptionalprocedure_type_concept_idinteger (int64)optionalvisit_occurrence_idinteger (int64)optionalprovider_idinteger (int64)optionalprocedure_source_valuestringoptionalprocedure_source_concept_idinteger (int64)optionalmeasurementobject[]optionalmeasurement_idinteger (int64)optionalperson_idinteger (int64)optionalmeasurement_concept_idinteger (int64)optionalmeasurement_datestringoptionalmeasurement_datetimestringoptionalmeasurement_type_concept_idinteger (int64)optionalvalue_as_numbernumber (double)optionaloperator_concept_idinteger (int64)optionalOMOP "Meas Value Operator" standard concept qualifying value_as_number (<, <=, >, >=), parsed from a numeric-string value or a FHIR valueQuantity.comparator. 0 when no operator (a bare number).
value_as_concept_idinteger (int64)optionalunit_concept_idinteger (int64)optionalrange_lownumber (double)optionalrange_highnumber (double)optionalvisit_occurrence_idinteger (int64)optionalprovider_idinteger (int64)optionalmeasurement_source_valuestringoptionalmeasurement_source_concept_idinteger (int64)optionalunit_source_valuestringoptionalvalue_source_valuestringoptionalobservationobject[]optionalobservation_idinteger (int64)optionalperson_idinteger (int64)optionalobservation_concept_idinteger (int64)optionalobservation_datestringoptionalobservation_datetimestringoptionalobservation_type_concept_idinteger (int64)optionalvalue_as_numbernumber (double)optionalvalue_as_stringstringoptionalvalue_as_concept_idinteger (int64)optionalunit_concept_idinteger (int64)optionalvisit_occurrence_idinteger (int64)optionalprovider_idinteger (int64)optionalobservation_source_valuestringoptionalobservation_source_concept_idinteger (int64)optionalunit_source_valuestringoptionalvalue_source_valuestringoptionalmappingsobject[]optionalOne entry per source coding (or one entry for a text-only resource with no coding), describing how it resolved and linking back to the row it produced.
resource_typestringoptionalresource_idstringoptionalomop_tablestringoptionalomop_idinteger (int64)optionalThe id of the OMOP row this coding produced (e.g. condition_occurrence_id),
within omop_table. A resource with multiple codings yields one entry
per coding, all sharing this id.
source_systemstringoptionalsource_codestringoptionalsource_namestringoptionaltarget_vocabularystringoptionaltarget_codestringoptionalThe standard concept's own code: the source code itself for an ALREADY_STANDARD row, the standard concept's code for a MAPPED row, or the suggested code for an UNCHECKED row. Omitted for UNMAPPED rows.
target_namestringoptionalmapping_statusstringoptionalALREADY_STANDARD (source coding is already a standard OMOP concept),
MAPPED (source coding was mapped to a standard concept), UNCHECKED (a
standard code was suggested — e.g. for a text-only resource — but not
verified against the OMOP vocabulary, so concept_id stays 0), or
UNMAPPED (no standard concept found).
notestringoptionaldroppedobject[]optionalSupported resource instances that could not be shaped into an OMOP row because required subject/patient, code, or medication reference data was missing. Unsupported resource types are ignored and do not appear here.
resource_typestringoptionalresource_idstringoptionalreasonstringoptionalvocab_versionstringoptionalThe OMOP vocabulary release the clinical codes were resolved against (e.g. "v20240229"), for reproducibility. Present when at least one coded concept was resolved.
summaryobjectoptionalThe request's data-quality headline: how the coded concepts split across
resolution outcomes, and the share that was not already in a target
standard vocabulary. Each coded resource is counted once (per resolved
concept), even when it carried several codings — unlike mappings, which
has one entry per coding.
codes_already_standardintegeroptionalCoded concepts already a standard OMOP concept (ALREADY_STANDARD).
codes_normalizedintegeroptionalCoded concepts mapped or suggested to a standard concept (MAPPED or UNCHECKED).
codes_unmappedintegeroptionalCoded concepts with no standard concept found (UNMAPPED).
off_vocab_ratenumber (double)optionalShare of coded concepts not already standard ((normalized + unmapped) / total).
Agent
Create AI agents that can query and interact with electronic health records using natural language.
Get agent by ID
/agent/{id}Retrieves a specific agent by its ID
Path parameters
idstringrequiredAgent ID
Agent retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalAgent ID
namestringoptionalAgent name
descriptionstringoptionalAgent description
promptsstring[]optionalArray of prompt IDs used by this agent
toolsstring[]optionalArray of MCP server tool IDs used by this agent
workflowsstring[]optionalArray of workflow IDs exposed as tools by this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfoptionalFHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
Update agent
/agent/{id}Updates an existing agent's configuration
Path parameters
idstringrequiredAgent ID
Body parameters
namestringrequiredAgent name
descriptionstringoptionalAgent description
promptsstring[]requiredArray of prompt IDs to use for this agent
toolsstring[]optionalArray of MCP server tool IDs to use for this agent
workflowsstring[]optionalArray of workflow IDs to expose as tools for this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfrequiredFHIR provider ID(s) for this agent. Required. In shared/experiment environments, the default sandbox provider is used if a different provider is not explicitly specified.
Agent updated successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalAgent ID
namestringoptionalAgent name
descriptionstringoptionalAgent description
promptsstring[]optionalArray of prompt IDs used by this agent
toolsstring[]optionalArray of MCP server tool IDs used by this agent
workflowsstring[]optionalArray of workflow IDs exposed as tools by this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfoptionalFHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
Delete agent
/agent/{id}Deletes an existing agent
Path parameters
idstringrequiredAgent ID
Agent deleted successfully
Response fields
successbooleanoptionalmessagestringoptionalPatch agent
/agent/{id}Patches an existing agent's configuration
Path parameters
idstringrequiredAgent ID
Agent patched successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalAgent ID
namestringoptionalAgent name
descriptionstringoptionalAgent description
promptsstring[]optionalArray of prompt IDs used by this agent
toolsstring[]optionalArray of MCP server tool IDs used by this agent
workflowsstring[]optionalArray of workflow IDs exposed as tools by this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfoptionalFHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
Create a new agent
/agent/createCreates a new PhenoAgent with specified configuration
Body parameters
namestringrequiredAgent name
descriptionstringoptionalAgent description
promptsstring[]requiredArray of prompt IDs to use for this agent
toolsstring[]optionalArray of MCP server tool IDs to use for this agent
workflowsstring[]optionalArray of workflow IDs to expose as tools for this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfrequiredFHIR provider ID(s) for this agent. Required. In shared/experiment environments, the default sandbox provider is used if a different provider is not explicitly specified.
Agent created successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalAgent ID
namestringoptionalAgent name
descriptionstringoptionalAgent description
promptsstring[]optionalArray of prompt IDs used by this agent
toolsstring[]optionalArray of MCP server tool IDs used by this agent
workflowsstring[]optionalArray of workflow IDs exposed as tools by this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfoptionalFHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
List agents
/agent/listRetrieves a list of PhenoAgents belonging to the authenticated user
Query parameters
tagsstringoptionalFilter by tags
Agents retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionalagentsobject[]optionalidstringoptionalAgent ID
namestringoptionalAgent name
descriptionstringoptionalAgent description
promptsstring[]optionalArray of prompt IDs used by this agent
toolsstring[]optionalArray of MCP server tool IDs used by this agent
workflowsstring[]optionalArray of workflow IDs exposed as tools by this agent
tagsstring[]optionalTags for categorizing the agent
provideroneOfoptionalFHIR provider ID(s) - must be valid UUIDs from existing FHIR providers
Chat with agent
/agent/chatSend a message to an agent and receive a JSON response.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
messagestringrequiredThe message to send to the agent
contextstringoptionalOptional context for the conversation
session_idstringoptionalOptional session ID for conversation continuity. Only one request may be active for a session at a time; overlapping turns for the same session return 409 Conflict.
agent_idstringrequiredThe ID of the agent to chat with
enhanced_reasoningbooleanoptionaldefault falseEnable enhanced reasoning capabilities. Increases latency but improves response quality and reliability.
Chat response received successfully
Response fields
responsestringoptionalAgent's response
successbooleanoptionalmessagestringoptionalStatus message
session_idstringoptionalChat session ID
Get chat messages
/agent/chat/messagesRetrieves a list of chat messages for a given chat session
Query parameters
chat_session_idstringrequiredChat session ID
num_messagesintegeroptionaldefault 10Number of messages to return
rolestringoptionalFilter by one or more message roles. Multiple roles can be specified as a comma-separated string. If not specified, messages with all roles are returned.
Available roles:
user- Messages from the userassistant- Text responses from the AI assistantmodel- Function/tool call requests from the modelfunction- Function/tool call results
userassistantmodelfunctionorderstringoptionaldefault descOrder of messages
ascdescChat messages retrieved successfully
Response fields
messagesobject[]optionalidstringoptionalChat message ID
session_idstringoptionalChat session ID
rolestringoptionalMessage role indicating the source/type of the message:
user- Messages from the userassistant- Text responses from the AI assistantmodel- Function/tool call requests to the modelfunction- Function/tool call results
userassistantmodelfunctioncontentstringoptionalMessage content
createdstringoptionalMessage created time
updatedstringoptionalMessage updated time
function_namestringoptionalFunction name
function_argsobjectoptionalFunction arguments
function_resultobjectoptionalFunction result
message_orderintegeroptionalMessage order
totalintegeroptionalsession_idstringoptionalChat with agent (streaming)
/agent/stream-chatSend a message to an agent and receive the response as a Server-Sent Events (SSE) stream. Events include message_start, content_delta, tool_use, tool_result, message_end, and error.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
messagestringrequiredThe message to send to the agent
contextstringoptionalOptional context for the conversation
session_idstringoptionalOptional session ID for conversation continuity. Only one request may be active for a session at a time; overlapping turns for the same session return 409 Conflict.
agent_idstringrequiredThe ID of the agent to chat with
enhanced_reasoningbooleanoptionaldefault falseEnable enhanced reasoning capabilities. Increases latency but improves response quality and reliability.
Streaming chat response. Each frame is a standard SSE record
(event: line + data: JSON line). The example shows a single
content_delta payload — multiple frames stream until message_end.
Response fields
typestringoptionalThe event type
message_startcontent_deltatool_usetool_resultmessage_enderrorsession_idstringoptionalChat session ID
contentstringoptionalIncremental text content (present in content_delta events)
successbooleanoptionalWhether the operation was successful
messagestringoptionalStatus message
function_namestringoptionalTool/function name (present in tool_use and tool_result events)
function_argsobjectoptionalTool arguments (present in tool_use events)
function_resultobjectoptionalTool execution result (present in tool_result events)
Create agent prompt
/agent/promptsCreates a new agent prompt
Body parameters
namestringrequiredPrompt name
descriptionstringoptionalPrompt description
contentstringrequiredPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Prompt created successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalPrompt ID
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Get prompt by ID
/agent/prompts/{id}Retrieves a specific prompt by its ID
Path parameters
idstringrequiredPrompt ID
Prompt retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalPrompt ID
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Update prompt
/agent/prompts/{id}Updates an existing prompt
Path parameters
idstringrequiredPrompt ID
Body parameters
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Prompt updated successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalPrompt ID
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Delete prompt
/agent/prompts/{id}Deletes a prompt
Path parameters
idstringrequiredPrompt ID
Prompt deleted successfully
Response fields
successbooleanoptionalmessagestringoptionalPatch prompt
/agent/prompts/{id}Patches an existing prompt
Path parameters
idstringrequiredAgent Prompt ID
Prompt patched successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalidstringoptionalPrompt ID
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
List agent prompts
/agent/prompts/listRetrieves a list of agent prompts belonging to the authenticated user
Prompts retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionalpromptsobject[]optionalidstringoptionalPrompt ID
namestringoptionalPrompt name
descriptionstringoptionalPrompt description
contentstringoptionalPrompt content
is_defaultbooleanoptionalWhether this is a default prompt
tagsstring[]optionalTags for categorizing the prompt
Workflow
Create and execute clinical workflows. Define workflow logic and test execution with sample data.
List all workflows
/workflowsRetrieves all workflow definitions for the authenticated user
Query parameters
verbosebooleanoptionaldefault falseIf true, includes full workflow implementation details in workflow_details field
Successfully retrieved workflows
Response fields
successbooleanoptionalWhether the workflow list was retrieved successfully
messagestringoptionalStatus message
workflowsobject[]optionalArray of simplified workflow responses for the authenticated user
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalSimplified list of workflow steps without operation details
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
workflow_detailsobject[]optionalOnly included when verbose=true - contains full implementation details for all workflows
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalOrdered list of workflow execution steps
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
Create new workflow
/workflowsCreates a new workflow definition with graph generation from workflow instructions
Query parameters
verbosebooleanoptionaldefault falseIf true, includes full workflow implementation details in workflow_details field
Body parameters
namestringrequiredHuman-readable name for the workflow
workflow_instructionsstringrequiredNatural language instructions that define the workflow logic
sample_dataobjectrequiredSample data to use for workflow graph generation
fhir_provider_idoneOfrequiredFHIR provider ID(s) - must be valid UUID(s) from existing FHIR providers
dynamic_generationbooleanoptionalEnable dynamic lang2fhir calls instead of pre-populated templates
Successfully created workflow
Response fields
successbooleanoptionalWhether the workflow was created successfully
messagestringoptionalStatus message
workflow_idstring (uuid)optionalID of the created workflow
workflowobjectoptionalSimplified workflow representation without implementation details
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalSimplified list of workflow steps without operation details
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
workflow_detailsobjectoptionalOnly included when verbose=true - contains full implementation details including operation definitions and placeholders
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalOrdered list of workflow execution steps
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
Get workflow by ID
/workflows/{id}Retrieves a workflow definition by its ID
Path parameters
idstring (uuid)requiredID of the workflow to retrieve
Query parameters
verbosebooleanoptionaldefault falseIf true, includes full workflow implementation details in workflow_details field
Successfully retrieved workflow
Response fields
successbooleanoptionalworkflowobjectoptionalSimplified workflow representation without implementation details
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalSimplified list of workflow steps without operation details
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
workflow_detailsobjectoptionalOnly included when verbose=true - contains full implementation details
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalOrdered list of workflow execution steps
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
Update workflow
/workflows/{id}Updates an existing workflow definition
Path parameters
idstring (uuid)requiredID of the workflow to update
Query parameters
verbosebooleanoptionaldefault falseIf true, includes full workflow implementation details in workflow_details field
Body parameters
namestringrequiredHuman-readable name for the workflow
workflow_instructionsstringrequiredNatural language instructions that define the workflow logic
sample_dataobjectrequiredSample data to use for workflow graph generation
fhir_provider_idoneOfrequiredFHIR provider ID(s) - must be valid UUID(s) from existing FHIR providers
dynamic_generationbooleanoptionalEnable dynamic lang2fhir calls instead of pre-populated templates
Successfully updated workflow
Response fields
successbooleanoptionalmessagestringoptionalworkflowobjectoptionalSimplified workflow representation without implementation details
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalSimplified list of workflow steps without operation details
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
workflow_detailsobjectoptionalOnly included when verbose=true - contains full implementation details
idstring (uuid)optionalUnique identifier for the workflow
namestringoptionalHuman-readable name for the workflow
workflow_instructionsstringoptionalNatural language instructions that define the workflow logic
sample_dataobjectoptionalSample data used for workflow graph generation
configobjectoptionalfhir_provider_idsstring (uuid)[]optionalFHIR provider IDs for executing workflow steps
dynamic_generationbooleanoptionalWhether to use dynamic lang2fhir generation instead of pre-populated templates
graphobjectoptionalstepsobject[]optionalOrdered list of workflow execution steps
created_atstring (date-time)optionalTimestamp when the workflow was created
updated_atstring (date-time)optionalTimestamp when the workflow was last updated
Delete workflow
/workflows/{id}Deletes a workflow definition by its ID
Path parameters
idstring (uuid)requiredID of the workflow to delete
Successfully deleted workflow
Response fields
successbooleanoptionalmessagestringoptionalExecute workflow
/workflows/{id}/executeExecutes a workflow with provided input data and returns results
Path parameters
idstring (uuid)requiredID of the workflow to execute
Body parameters
input_dataobjectrequiredInput data for workflow execution
previewbooleanoptionaldefault falseIf true, create operations return mock resources instead of persisting to the FHIR server
Successfully executed workflow
Response fields
successbooleanoptionalWhether the workflow execution was successful
messagestringoptionalStatus message with execution details
resultsobjectoptionalstepsobjectoptionalResults for each executed workflow step, keyed by step ID
previewbooleanoptionalWhether the workflow was executed in preview mode
Tools
LLM tools that combine lang2fhir with FHIR server operations.
/tools/cohortPOST/tools/lang2fhir-and-createPOST/tools/lang2fhir-and-create-multiPOST/tools/lang2fhir-and-searchGET/tools/mcp-server/{mcp_server_id}DELETE/tools/mcp-server/{mcp_server_id}POST/tools/mcp-server/createGET/tools/mcp-server/listGET/tools/mcp-server/{mcp_server_id}/listGET/tools/mcp-server/tool/{mcp_server_tool_id}DELETE/tools/mcp-server/tool/{mcp_server_tool_id}Analyze patient cohorts
/tools/cohortUses LLM to extract search concepts from natural language and builds patient cohorts with inclusion/exclusion criteria
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
textstringrequiredNatural language text describing the patient cohort criteria
providerstring (uuid)requiredFHIR provider ID - must be a valid UUID from existing FHIR providers. also supports provider by name (e.g. medplum)
Successfully analyzed cohort and retrieved patient list
Response fields
successbooleanoptionalWhether the cohort analysis was successful
messagestringoptionalStatus message with details about the analysis
patientIdsstring[]optionalArray of patient IDs that match the cohort criteria
patientCountintegeroptionalTotal number of patients in the cohort
queriesobject[]optionalIndividual search concepts that were identified and executed
resource_typestringoptionalThe FHIR resource type identified for this concept
search_paramsstringoptionalFHIR search parameters for this concept
conceptstringoptionalDescription of what this search represents
excludebooleanoptionalWhether this is an exclusion criteria
Create FHIR resource from text and store it
/tools/lang2fhir-and-createConverts natural language to FHIR resource and optionally stores it in a FHIR server
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
resourcestringrequiredType of FHIR resource to create. Use 'auto' for automatic resource type detection, or specify a supported US Core profile.
autoappointmentcondition-encounter-diagnosismedicationrequestcareplancondition-problems-health-concernscoverageencounterobservation-clinical-resultobservation-labpatientprocedurequestionnairequestionnaireresponseservicerequestsimple-observationvital-signstextstringrequiredNatural language text to convert to FHIR resource
providerstring (uuid)optionalFHIR provider ID - must be a valid UUID from existing FHIR providers. also supports provider by name (e.g. medplum)
Successfully created FHIR resource
Response fields
fhir_resourceobjectoptionalThe created FHIR resource
fhir_idstringoptionalID of the resource in the FHIR server (if successfully stored)
successbooleanoptionalmessagestringoptionalStatus message
Extract and store multiple FHIR resources
/tools/lang2fhir-and-create-multiExtracts multiple FHIR resources from natural language text and stores them in a FHIR server. Automatically detects Patient, Condition, MedicationRequest, Observation, and other resource types. Resources are linked with proper references and submitted as a transaction bundle. For FHIR servers that don't auto-resolve urn:uuid references, this endpoint will automatically resolve them via PUT requests after the initial bundle creation.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
textstringrequiredNatural language text containing multiple clinical concepts to extract
versionstringoptionaldefault R4FHIR version to use
providerstringrequiredFHIR provider ID or name
Successfully created FHIR resources
Response fields
successbooleanoptionalWhether the resources were created successfully
messagestringoptionalStatus message
response_bundleobjectoptionalFHIR transaction-response Bundle from the server with resolved resource IDs
resourceTypestringoptionaltypestringoptionalentryobject[]optionalresource_infoobject[]optionalMetadata about created resources (temp IDs, types, descriptions)
tempIdstringoptionalOriginal temporary UUID
resourceTypestringoptionalFHIR resource type
descriptionstringoptionalText excerpt this resource was extracted from
Search FHIR resources from natural language
/tools/lang2fhir-and-searchConverts natural language to FHIR search parameters and executes search in FHIR server
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Body parameters
textstringrequiredNatural language text to convert to FHIR search parameters
patient_idstringoptionalPatient ID to filter results
countintegeroptionalMaximum number of results to return
providerstring (uuid)optionalFHIR provider ID - must be a valid UUID from existing FHIR providers. also supports provider by name (e.g. medplum)
Successfully generated search and retrieved results
Response fields
resource_typestringoptionalThe FHIR resource type identified for the search
search_paramsstringoptionalFHIR search parameters in standard format
fhir_resultsobject[]optionalArray of FHIR resources returned from the search
successbooleanoptionalmessagestringoptionalStatus message
Get MCP server by ID
/tools/mcp-server/{mcp_server_id}Gets a MCP server by ID
Path parameters
mcp_server_idstringrequiredID of the MCP server to retrieve
Successfully retrieved MCP server
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server (returned by GET /tools/mcp-server/{mcp_server_id}).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_serversobject[]optionalList of MCP servers. Returned by /tools/mcp-server/create (the newly created server) and /tools/mcp-server/list (all servers).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalTools loaded from the MCP server. Returned by /tools/mcp-server/create alongside the server record, since tool discovery happens at create time.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
Delete MCP server by ID
/tools/mcp-server/{mcp_server_id}Deletes a MCP server by ID
Path parameters
mcp_server_idstringrequiredID of the MCP server to delete
Successfully deleted MCP server
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server (returned by GET /tools/mcp-server/{mcp_server_id}).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_serversobject[]optionalList of MCP servers. Returned by /tools/mcp-server/create (the newly created server) and /tools/mcp-server/list (all servers).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalTools loaded from the MCP server. Returned by /tools/mcp-server/create alongside the server record, since tool discovery happens at create time.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
Create MCP server
/tools/mcp-server/createCreates a new MCP server
Body parameters
namestringrequiredName of the MCP server
mcp_server_urlstringrequiredURL of the MCP server
Successfully created MCP server
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server (returned by GET /tools/mcp-server/{mcp_server_id}).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_serversobject[]optionalList of MCP servers. Returned by /tools/mcp-server/create (the newly created server) and /tools/mcp-server/list (all servers).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalTools loaded from the MCP server. Returned by /tools/mcp-server/create alongside the server record, since tool discovery happens at create time.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
List MCP servers
/tools/mcp-server/listLists all MCP servers for a specific user
Successfully listed MCP servers
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server (returned by GET /tools/mcp-server/{mcp_server_id}).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_serversobject[]optionalList of MCP servers. Returned by /tools/mcp-server/create (the newly created server) and /tools/mcp-server/list (all servers).
idstringoptionalID of the MCP server
namestringoptionalName of the MCP server
descriptionstringoptionalDescription of the MCP server
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalTools loaded from the MCP server. Returned by /tools/mcp-server/create alongside the server record, since tool discovery happens at create time.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
List MCP server tools
/tools/mcp-server/{mcp_server_id}/listLists all MCP server tools for a specific MCP server
Path parameters
mcp_server_idstringrequiredID of the MCP server to list tools for
Successfully listed MCP server tools
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server tool (returned by GET /tools/mcp-server/tool/{mcp_server_tool_id}).
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalList of MCP server tools. Returned by /tools/mcp-server/{mcp_server_id}/list.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
Get MCP server tool by ID
/tools/mcp-server/tool/{mcp_server_tool_id}Gets a MCP server tool by ID
Path parameters
mcp_server_tool_idstringrequiredID of the MCP server tool to retrieve
Successfully retrieved MCP server tool
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server tool (returned by GET /tools/mcp-server/tool/{mcp_server_tool_id}).
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalList of MCP server tools. Returned by /tools/mcp-server/{mcp_server_id}/list.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
Delete MCP server tool by ID
/tools/mcp-server/tool/{mcp_server_tool_id}Deletes a MCP server tool by ID
Path parameters
mcp_server_tool_idstringrequiredID of the MCP server tool to delete
Successfully deleted MCP server tool
Response fields
successbooleanoptionalWhether the operation succeeded
messagestringoptionalStatus message
dataobjectoptionalSingle MCP server tool (returned by GET /tools/mcp-server/tool/{mcp_server_tool_id}).
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
mcp_server_toolsobject[]optionalList of MCP server tools. Returned by /tools/mcp-server/{mcp_server_id}/list.
idstringoptionalID of the MCP server tool
namestringoptionalName of the MCP server tool
descriptionstringoptionalDescription of the MCP server tool
input_schemaobjectoptionalInput schema of the MCP server tool
mcp_server_idstringoptionalID of the MCP server that the tool belongs to
mcp_server_urlstringoptionalURL of the MCP server
FHIR
FHIR server operations including resource CRUD, search, and batch operations.
/fhir-providerGET/fhir-provider/{fhir_provider_id}DELETE/fhir-provider/{fhir_provider_id}POST/fhir-provider/{fhir_provider_id}/fhirGET/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}PUT/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}POST/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}DELETE/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}PATCH/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}GET/fhir-provider/listPATCH/fhir-provider/{fhir_provider_id}/add-auth-configPATCH/fhir-provider/{fhir_provider_id}/remove-auth-configPATCH/fhir-provider/{fhir_provider_id}/set-active-auth-configCreate FHIR provider
/fhir-providerCreates a new FHIR provider configuration with authentication credentials.
Note: The "sandbox" provider type cannot be created via this API - it is managed internally.
Body parameters
namestringrequiredDisplay name for the FHIR provider
descriptionstringoptionalOptional description of the FHIR provider
providerstringrequiredType of FHIR server provider.
The "sandbox" provider type is managed internally and cannot be created via API. It is used on shared instances.
aidboxathenahealthcanvascernerelationepicgoogle_healthcarehapimeditechmedplumphenostoresandboxbase_urlstring (uri)requiredBase URL of the FHIR server
authoneOfrequiredFHIR provider created successfully
Response fields
successbooleanoptionalmessagestringoptionaldataoneOfoptionalProvider details. Sandbox providers return FhirProviderSandboxInfo.
Get FHIR provider by ID
/fhir-provider/{fhir_provider_id}Retrieves a specific FHIR provider configuration by its ID.
Sandbox providers return FhirProviderSandboxInfo. On shared instances, only sandbox providers can be accessed.
Path parameters
fhir_provider_idstringrequiredID of the FHIR provider to retrieve
FHIR provider retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionaldataoneOfoptionalProvider details. Sandbox providers return FhirProviderSandboxInfo.
Delete FHIR provider
/fhir-provider/{fhir_provider_id}Deletes a FHIR provider.
Note: Sandbox providers cannot be deleted.
Path parameters
fhir_provider_idstringrequiredID of the FHIR provider to delete
FHIR provider deleted successfully
Response fields
successbooleanoptionalmessagestringoptionalExecute FHIR bundle operation
/fhir-provider/{fhir_provider_id}/fhirExecutes a FHIR Bundle transaction or batch operation on the specified provider. This allows multiple FHIR resources to be processed in a single request.
The request body should contain a valid FHIR Bundle resource with transaction or batch type.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
Bundle executed successfully
Read or search FHIR resources
/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}Retrieves FHIR resources from the specified provider. Supports both individual resource retrieval (e.g. Patient/123 via the path) and search operations.
FHIR search parameters are passed through to the upstream server verbatim as native query-string parameters; this proxy does not model, validate, or transform them. Append standard FHIR search parameters directly to the request URL. Supported parameters include:
- Resource-specific search parameters (e.g.
namefor Patient,statusfor Observation) - Common search parameters (
_id,_lastUpdated,_tag,_profile,_security,_text,_content,_filter) - Result parameters (
_count,_offset,_sort,_include,_revinclude,_summary,_elements) - Search prefixes for dates, numbers, and quantities (
eq,ne,gt,ge,lt,le,sa,eb,ap)
Examples:
Patient?name=John%20Doe&_count=10&_sort=familyObservation?patient=Patient/123&date=ge2023-01-01&category=vital-signs&_sort=-date
When using a generated SDK, supply these via the client's request-level query-parameter option (the SDK escape hatch) rather than a typed argument.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
fhir_pathstringrequiredThe FHIR resource path to operate on. This follows FHIR RESTful API conventions. Examples:
- "Patient" (for resource type operations)
- "Patient/123" (for specific resource operations)
- "Patient/123/_history" (for history operations)
Successfully retrieved FHIR resource(s)
Response fields
resourceTypestringoptionaltotalintegeroptionalentryarray<object>optionalresourceobjectoptionalresourceTypestringoptionalidstringoptionalnamearray<object>optionalfamilystringoptionalgivenarray<string>optionalUpsert FHIR resource
/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}Creates or updates a FHIR resource on the specified provider. If the resource exists, it will be updated; otherwise, it will be created.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
fhir_pathstringrequiredThe FHIR resource path to operate on. This follows FHIR RESTful API conventions. Examples:
- "Patient" (for resource type operations)
- "Patient/123" (for specific resource operations)
- "Patient/123/_history" (for history operations)
Resource upserted successfully
Create FHIR resource
/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}Creates a new FHIR resource on the specified provider. The request body should contain a valid FHIR resource in JSON format.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
fhir_pathstringrequiredThe FHIR resource path to operate on. This follows FHIR RESTful API conventions. Examples:
- "Patient" (for resource type operations)
- "Patient/123" (for specific resource operations)
- "Patient/123/_history" (for history operations)
Resource created successfully
Delete FHIR resource
/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}Deletes a FHIR resource from the specified provider.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
fhir_pathstringrequiredThe FHIR resource path to operate on. This follows FHIR RESTful API conventions. Examples:
- "Patient" (for resource type operations)
- "Patient/123" (for specific resource operations)
- "Patient/123/_history" (for history operations)
Resource deleted successfully
Patch FHIR resource
/fhir-provider/{fhir_provider_id}/fhir/{fhir_path}Partially updates a FHIR resource on the specified provider.
Two body formats are supported, selected by request content type:
application/json-patch+json— an array of JSON Patch operations as defined in RFC 6902. Each operation specifies:op: The operation type (add, remove, replace, move, copy, test)path: JSON Pointer to the target location in the resourcevalue: The value to use (required for add, replace, and test operations)
application/fhir+json— a partial FHIR resource for merge-patch semantics.
Note: This proxy currently forwards the request body to the upstream FHIR server with Content-Type: application/fhir+json regardless of the declared request content type. JSON Patch (RFC 6902) therefore only succeeds against upstream servers that accept patch arrays under application/fhir+json; servers that strictly enforce patch media types may reject or misinterpret it. Support for either format ultimately depends on the upstream FHIR server.
The request is proxied to the configured FHIR server with appropriate authentication headers.
Header parameters
X-Phenoml-On-Behalf-OfstringoptionalOptional header for on-behalf-of authentication. Used when making requests on behalf of another user or entity. Must be in the format: Patient/{uuid} or Practitioner/{uuid}
X-Phenoml-Fhir-ProviderstringoptionalOptional header for FHIR provider authentication. Contains credentials in the format {fhir_provider_id}:{oauth2_token}. Multiple FHIR provider integrations can be provided as comma-separated values.
Path parameters
fhir_provider_idstringrequiredThe ID of the FHIR provider to use. Can be either:
- A UUID representing the provider ID
- A provider name (legacy support - will just use the most recently updated provider with this name)
fhir_pathstringrequiredThe FHIR resource path to operate on. This follows FHIR RESTful API conventions. Examples:
- "Patient" (for resource type operations)
- "Patient/123" (for specific resource operations)
- "Patient/123/_history" (for history operations)
Resource patched successfully
List FHIR providers
/fhir-provider/listRetrieves a list of all active FHIR providers for the authenticated user.
On shared instances, only sandbox providers are returned. Sandbox providers return FhirProviderSandboxInfo.
FHIR providers retrieved successfully
Response fields
successbooleanoptionalmessagestringoptionalfhir_providersoneOf[]optionalList of FHIR providers. Sandbox providers return FhirProviderSandboxInfo, other providers return FhirProviderTemplate.
Add authentication configuration
/fhir-provider/{fhir_provider_id}/add-auth-configAdds a new authentication configuration to an existing FHIR provider. This enables key rotation and multiple auth configurations per provider.
Note: Sandbox providers cannot be modified.
Path parameters
fhir_provider_idstringrequiredID of the FHIR provider to add auth config to
Auth configuration added successfully
Response fields
successbooleanoptionalmessagestringoptionaldataoneOfoptionalProvider details. Sandbox providers return FhirProviderSandboxInfo.
Remove authentication configuration
/fhir-provider/{fhir_provider_id}/remove-auth-configRemoves an authentication configuration from a FHIR provider. Cannot remove the currently active auth configuration.
Note: Sandbox providers cannot be modified.
Path parameters
fhir_provider_idstringrequiredID of the FHIR provider
Body parameters
auth_config_idstringrequiredID of the auth configuration to remove
Auth configuration removed successfully
Response fields
successbooleanoptionalmessagestringoptionaldataobjectoptionalFull FHIR provider configuration returned for non-sandbox providers.
auth_configs and last_updated are always populated, which is how
list responses distinguish this shape from FhirProviderSandboxInfo.
idstringrequiredUnique identifier for the FHIR provider
namestringrequiredDisplay name for the FHIR provider
descriptionstringoptionalOptional description of the FHIR provider
providerstringrequiredType of FHIR server provider.
The "sandbox" provider type is managed internally and cannot be created via API. It is used on shared instances.
aidboxathenahealthcanvascernerelationepicgoogle_healthcarehapimeditechmedplumphenostoresandboxbase_urlstring (uri)optionalBase URL of the FHIR server
client_idstringoptionalOAuth client ID. Deprecated: use client_id on FhirProviderAuthConfig instead. Retained for backward compatibility with existing providers.
auth_configsobjectrequiredMap of authentication configurations (key is auth_config_id)
last_updatedstring (date-time)requiredTimestamp when the provider was last updated
Set active authentication configuration
/fhir-provider/{fhir_provider_id}/set-active-auth-configSets which authentication configuration should be active for a FHIR provider. Only one auth config can be active at a time.
If the specified auth config is already active, the request succeeds without making any changes and returns a message indicating the config is already active.
Note: Sandbox providers cannot be modified.
Path parameters
fhir_provider_idstringrequiredID of the FHIR provider
Body parameters
auth_config_idstringrequiredID of the auth configuration to set as active
Active auth configuration set successfully, or the config was already active. Check the message field to determine which case occurred.
Response fields
successbooleanoptionalmessagestringoptionaldataoneOfoptionalProvider details. Sandbox providers return FhirProviderSandboxInfo.
Voice
Transcribe audio recordings into text with speech-to-text. Pair the transcript with Lang2FHIR to turn spoken clinical notes into structured FHIR resources.
Transcribe audio
/transcribeTranscribes an uploaded audio recording and returns the transcript. Send the raw audio bytes as the request body; the audio format is detected automatically (WAV, FLAC, MP3, OGG/WebM Opus).
Supports up to ~5 minutes of audio per request. This limit is on audio
duration regardless of file size or format, so a compressed recording
within the size limit can still be rejected for being too long. Pair the
transcript with a downstream text step (e.g. POST /lang2fhir/create)
to turn it into a FHIR resource.
Query parameters
languagestring[]optionalBCP-47 language tag, repeatable for up to 4 candidate languages. Defaults to en-US.
Transcription succeeded.
Response fields
transcriptstringrequiredThe full transcript of the audio.