phenoml 17.7.0 → 17.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/BaseClient.d.ts +12 -0
- package/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/Client.d.ts +6 -0
- package/dist/cjs/Client.js +20 -10
- package/dist/cjs/api/resources/agent/client/Client.js +4 -3
- package/dist/cjs/api/resources/agent/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/ConflictError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/GatewayTimeoutError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/agent/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/agent/resources/chat/client/Client.js +3 -2
- package/dist/cjs/api/resources/agent/resources/prompts/client/Client.js +4 -3
- package/dist/cjs/api/resources/authtoken/client/Client.js +2 -1
- package/dist/cjs/api/resources/authtoken/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/authtoken/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/authtoken/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/cohort/client/Client.js +2 -1
- package/dist/cjs/api/resources/cohort/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/cohort/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/cohort/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/construe/client/Client.js +2 -1
- package/dist/cjs/api/resources/construe/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/ConflictError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/FailedDependencyError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/GatewayTimeoutError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/NotImplementedError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/ServiceUnavailableError.js +1 -1
- package/dist/cjs/api/resources/construe/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/construe/resources/codeSystems/client/Client.js +2 -1
- package/dist/cjs/api/resources/construe/resources/codeSystems/client/requests/DeleteRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codeSystems/client/requests/ExportRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codeSystems/client/requests/FindRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/Client.d.ts +47 -0
- package/dist/cjs/api/resources/construe/resources/codes/client/Client.js +97 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/CodesListRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/ExtractRequest.d.ts +12 -0
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/LookupRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/PhenoCrRequest.d.ts +16 -0
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/SearchSemanticRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/SearchTextRequest.d.ts +1 -1
- package/dist/cjs/api/resources/construe/resources/codes/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/construe/types/ExtractRequestSystem.d.ts +11 -8
- package/dist/cjs/api/resources/construe/types/PhenocrExtractRequestSystem.d.ts +6 -0
- package/dist/cjs/api/resources/construe/types/PhenocrExtractRequestSystem.js +3 -0
- package/dist/cjs/api/resources/construe/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/construe/types/index.js +1 -0
- package/dist/cjs/api/resources/fhir/client/Client.js +5 -4
- package/dist/cjs/api/resources/fhir2Omop/client/Client.js +2 -1
- package/dist/cjs/api/resources/fhir2Omop/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/fhir2Omop/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/fhir2Omop/errors/ServiceUnavailableError.js +1 -1
- package/dist/cjs/api/resources/fhir2Omop/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/fhir2Omop/types/CareSiteRow.d.ts +8 -0
- package/dist/cjs/api/resources/fhir2Omop/types/CareSiteRow.js +3 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ConditionOccurrenceRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/DeathRow.d.ts +9 -0
- package/dist/cjs/api/resources/fhir2Omop/types/DeathRow.js +3 -0
- package/dist/cjs/api/resources/fhir2Omop/types/DrugExposureRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/LocationRow.d.ts +14 -0
- package/dist/cjs/api/resources/fhir2Omop/types/LocationRow.js +3 -0
- package/dist/cjs/api/resources/fhir2Omop/types/MeasurementRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ObservationPeriodRow.d.ts +7 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ObservationPeriodRow.js +3 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ObservationRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/OmopTables.d.ts +5 -0
- package/dist/cjs/api/resources/fhir2Omop/types/PersonRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ProcedureOccurrenceRow.d.ts +1 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ProviderRow.d.ts +15 -0
- package/dist/cjs/api/resources/fhir2Omop/types/ProviderRow.js +3 -0
- package/dist/cjs/api/resources/fhir2Omop/types/VisitOccurrenceRow.d.ts +2 -0
- package/dist/cjs/api/resources/fhir2Omop/types/index.d.ts +5 -0
- package/dist/cjs/api/resources/fhir2Omop/types/index.js +5 -0
- package/dist/cjs/api/resources/fhirProvider/client/Client.js +2 -1
- package/dist/cjs/api/resources/fhirProvider/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/fhirProvider/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/fhirProvider/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/fhirProvider/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/fhirProvider/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/fhirProvider/resources/authConfig/client/Client.js +4 -3
- package/dist/cjs/api/resources/implementationGuides/client/Client.d.ts +12 -0
- package/dist/cjs/api/resources/implementationGuides/client/Client.js +16 -0
- package/dist/cjs/api/resources/implementationGuides/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/implementationGuides/client/index.js +2 -0
- package/dist/cjs/api/resources/implementationGuides/errors/BadRequestError.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/BadRequestError.js +54 -0
- package/dist/cjs/api/resources/implementationGuides/errors/ForbiddenError.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/ForbiddenError.js +54 -0
- package/dist/cjs/api/resources/implementationGuides/errors/InternalServerError.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/InternalServerError.js +54 -0
- package/dist/cjs/api/resources/implementationGuides/errors/NotFoundError.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/NotFoundError.js +54 -0
- package/dist/cjs/api/resources/implementationGuides/errors/UnauthorizedError.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/UnauthorizedError.js +54 -0
- package/dist/cjs/api/resources/implementationGuides/errors/index.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/errors/index.js +21 -0
- package/dist/cjs/api/resources/implementationGuides/exports.d.ts +3 -0
- package/dist/cjs/api/resources/implementationGuides/exports.js +22 -0
- package/dist/cjs/api/resources/implementationGuides/index.d.ts +4 -0
- package/dist/cjs/api/resources/implementationGuides/index.js +20 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/Client.d.ts +91 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/Client.js +316 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/index.js +17 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/requests/UpdateImplementationGuideRequest.d.ts +8 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/requests/UpdateImplementationGuideRequest.js +3 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/exports.d.ts +2 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/exports.js +21 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/index.d.ts +1 -0
- package/dist/cjs/api/resources/implementationGuides/resources/implementationGuides/index.js +17 -0
- package/dist/cjs/api/resources/implementationGuides/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/implementationGuides/resources/index.js +41 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideDetail.d.ts +5 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideDetail.js +3 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideListResponse.d.ts +4 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideListResponse.js +3 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideSummary.d.ts +15 -0
- package/dist/cjs/api/resources/implementationGuides/types/ImplementationGuideSummary.js +3 -0
- package/dist/cjs/api/resources/implementationGuides/types/index.d.ts +3 -0
- package/dist/cjs/api/resources/implementationGuides/types/index.js +19 -0
- package/dist/cjs/api/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/index.js +3 -1
- package/dist/cjs/api/resources/lang2Fhir/client/Client.d.ts +8 -0
- package/dist/cjs/api/resources/lang2Fhir/client/Client.js +15 -6
- package/dist/cjs/api/resources/lang2Fhir/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/ClientClosedRequestError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/GatewayTimeoutError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/UnprocessableEntityError.js +1 -1
- package/dist/cjs/api/resources/lang2Fhir/types/CreateMultiResponse.d.ts +2 -0
- package/dist/cjs/api/resources/lang2Fhir/{client/requests → types}/ProfileUploadRequest.d.ts +2 -10
- package/dist/cjs/api/resources/lang2Fhir/types/ProfileUploadRequest.js +3 -0
- package/dist/cjs/api/resources/lang2Fhir/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/lang2Fhir/types/index.js +1 -0
- package/dist/cjs/api/resources/profiles/client/Client.d.ts +12 -0
- package/dist/cjs/api/resources/profiles/client/Client.js +16 -0
- package/dist/cjs/api/resources/profiles/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/profiles/client/index.js +2 -0
- package/dist/cjs/api/resources/profiles/errors/BadRequestError.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/BadRequestError.js +54 -0
- package/dist/cjs/api/resources/profiles/errors/ForbiddenError.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/ForbiddenError.js +54 -0
- package/dist/cjs/api/resources/profiles/errors/InternalServerError.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/InternalServerError.js +54 -0
- package/dist/cjs/api/resources/profiles/errors/NotFoundError.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/NotFoundError.js +54 -0
- package/dist/cjs/api/resources/profiles/errors/UnauthorizedError.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/UnauthorizedError.js +54 -0
- package/dist/cjs/api/resources/profiles/errors/index.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/errors/index.js +21 -0
- package/dist/cjs/api/resources/profiles/exports.d.ts +3 -0
- package/dist/cjs/api/resources/profiles/exports.js +22 -0
- package/dist/cjs/api/resources/profiles/index.d.ts +4 -0
- package/dist/cjs/api/resources/profiles/index.js +20 -0
- package/dist/cjs/api/resources/profiles/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/profiles/resources/index.js +41 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/Client.d.ts +127 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/Client.js +397 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/index.js +17 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/requests/ListRequest.d.ts +10 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/requests/ListRequest.js +3 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/exports.d.ts +2 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/exports.js +21 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/index.d.ts +1 -0
- package/dist/cjs/api/resources/profiles/resources/profiles/index.js +17 -0
- package/dist/cjs/api/resources/profiles/types/FhirResource.d.ts +4 -0
- package/dist/cjs/api/resources/profiles/types/FhirResource.js +3 -0
- package/dist/cjs/api/resources/profiles/types/ProfileGetResponse.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/types/ProfileGetResponse.js +3 -0
- package/dist/cjs/api/resources/profiles/types/ProfileListResponse.d.ts +4 -0
- package/dist/cjs/api/resources/profiles/types/ProfileListResponse.js +3 -0
- package/dist/cjs/api/resources/profiles/types/ProfileSummary.d.ts +26 -0
- package/dist/cjs/api/resources/profiles/types/ProfileSummary.js +12 -0
- package/dist/cjs/api/resources/profiles/types/ProfileUploadRequest.d.ts +7 -0
- package/dist/cjs/api/resources/profiles/types/ProfileUploadRequest.js +3 -0
- package/dist/cjs/api/resources/profiles/types/index.d.ts +5 -0
- package/dist/cjs/api/resources/profiles/types/index.js +21 -0
- package/dist/cjs/api/resources/summary/client/Client.js +2 -1
- package/dist/cjs/api/resources/summary/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/summary/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/summary/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/summary/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/summary/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/summary/resources/templates/client/Client.js +3 -2
- package/dist/cjs/api/resources/tools/client/Client.js +5 -4
- package/dist/cjs/api/resources/tools/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/tools/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/tools/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/tools/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/tools/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/tools/resources/mcpServers/client/Client.js +2 -1
- package/dist/cjs/api/resources/voice/errors/BadGatewayError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/ContentTooLargeError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/GatewayTimeoutError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/PaymentRequiredError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/ServiceUnavailableError.js +1 -1
- package/dist/cjs/api/resources/voice/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/api/resources/workflows/client/Client.js +4 -3
- package/dist/cjs/api/resources/workflows/errors/BadRequestError.js +1 -1
- package/dist/cjs/api/resources/workflows/errors/ForbiddenError.js +1 -1
- package/dist/cjs/api/resources/workflows/errors/GatewayTimeoutError.js +1 -1
- package/dist/cjs/api/resources/workflows/errors/InternalServerError.js +1 -1
- package/dist/cjs/api/resources/workflows/errors/NotFoundError.js +1 -1
- package/dist/cjs/api/resources/workflows/errors/UnauthorizedError.js +1 -1
- package/dist/cjs/core/file/file.js +3 -0
- package/dist/cjs/core/requestBody.d.ts +12 -0
- package/dist/cjs/core/requestBody.js +26 -0
- package/dist/cjs/core/stream/Stream.d.ts +45 -1
- package/dist/cjs/core/stream/Stream.js +323 -84
- package/dist/cjs/core/stream/index.d.ts +1 -0
- package/dist/cjs/core/url/qs.js +2 -2
- package/dist/cjs/errors/phenomlError.d.ts +1 -0
- package/dist/cjs/errors/phenomlError.js +5 -1
- package/dist/cjs/errors/phenomlTimeoutError.d.ts +2 -2
- package/dist/cjs/errors/phenomlTimeoutError.js +40 -6
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +12 -0
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +6 -0
- package/dist/esm/Client.mjs +10 -0
- package/dist/esm/api/resources/agent/client/Client.mjs +4 -3
- package/dist/esm/api/resources/agent/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/ConflictError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/GatewayTimeoutError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/agent/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/agent/resources/chat/client/Client.mjs +3 -2
- package/dist/esm/api/resources/agent/resources/prompts/client/Client.mjs +4 -3
- package/dist/esm/api/resources/authtoken/client/Client.mjs +2 -1
- package/dist/esm/api/resources/authtoken/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/authtoken/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/authtoken/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/cohort/client/Client.mjs +2 -1
- package/dist/esm/api/resources/cohort/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/cohort/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/cohort/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/construe/client/Client.mjs +2 -1
- package/dist/esm/api/resources/construe/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/ConflictError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/FailedDependencyError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/GatewayTimeoutError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/NotImplementedError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/ServiceUnavailableError.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/construe/resources/codeSystems/client/Client.mjs +2 -1
- package/dist/esm/api/resources/construe/resources/codeSystems/client/requests/DeleteRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codeSystems/client/requests/ExportRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codeSystems/client/requests/FindRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codes/client/Client.d.mts +47 -0
- package/dist/esm/api/resources/construe/resources/codes/client/Client.mjs +97 -1
- package/dist/esm/api/resources/construe/resources/codes/client/requests/CodesListRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codes/client/requests/ExtractRequest.d.mts +12 -0
- package/dist/esm/api/resources/construe/resources/codes/client/requests/LookupRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codes/client/requests/PhenoCrRequest.d.mts +16 -0
- package/dist/esm/api/resources/construe/resources/codes/client/requests/SearchSemanticRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codes/client/requests/SearchTextRequest.d.mts +1 -1
- package/dist/esm/api/resources/construe/resources/codes/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/construe/types/ExtractRequestSystem.d.mts +11 -8
- package/dist/esm/api/resources/construe/types/PhenocrExtractRequestSystem.d.mts +6 -0
- package/dist/esm/api/resources/construe/types/PhenocrExtractRequestSystem.mjs +2 -0
- package/dist/esm/api/resources/construe/types/index.d.mts +1 -0
- package/dist/esm/api/resources/construe/types/index.mjs +1 -0
- package/dist/esm/api/resources/fhir/client/Client.mjs +5 -4
- package/dist/esm/api/resources/fhir2Omop/client/Client.mjs +2 -1
- package/dist/esm/api/resources/fhir2Omop/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/fhir2Omop/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/fhir2Omop/errors/ServiceUnavailableError.mjs +1 -1
- package/dist/esm/api/resources/fhir2Omop/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/fhir2Omop/types/CareSiteRow.d.mts +8 -0
- package/dist/esm/api/resources/fhir2Omop/types/CareSiteRow.mjs +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/ConditionOccurrenceRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/DeathRow.d.mts +9 -0
- package/dist/esm/api/resources/fhir2Omop/types/DeathRow.mjs +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/DrugExposureRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/LocationRow.d.mts +14 -0
- package/dist/esm/api/resources/fhir2Omop/types/LocationRow.mjs +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/MeasurementRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/ObservationPeriodRow.d.mts +7 -0
- package/dist/esm/api/resources/fhir2Omop/types/ObservationPeriodRow.mjs +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/ObservationRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/OmopTables.d.mts +5 -0
- package/dist/esm/api/resources/fhir2Omop/types/PersonRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/ProcedureOccurrenceRow.d.mts +1 -0
- package/dist/esm/api/resources/fhir2Omop/types/ProviderRow.d.mts +15 -0
- package/dist/esm/api/resources/fhir2Omop/types/ProviderRow.mjs +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/VisitOccurrenceRow.d.mts +2 -0
- package/dist/esm/api/resources/fhir2Omop/types/index.d.mts +5 -0
- package/dist/esm/api/resources/fhir2Omop/types/index.mjs +5 -0
- package/dist/esm/api/resources/fhirProvider/client/Client.mjs +2 -1
- package/dist/esm/api/resources/fhirProvider/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/fhirProvider/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/fhirProvider/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/fhirProvider/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/fhirProvider/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/fhirProvider/resources/authConfig/client/Client.mjs +4 -3
- package/dist/esm/api/resources/implementationGuides/client/Client.d.mts +12 -0
- package/dist/esm/api/resources/implementationGuides/client/Client.mjs +12 -0
- package/dist/esm/api/resources/implementationGuides/client/index.d.mts +1 -0
- package/dist/esm/api/resources/implementationGuides/client/index.mjs +1 -0
- package/dist/esm/api/resources/implementationGuides/errors/BadRequestError.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/BadRequestError.mjs +17 -0
- package/dist/esm/api/resources/implementationGuides/errors/ForbiddenError.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/ForbiddenError.mjs +17 -0
- package/dist/esm/api/resources/implementationGuides/errors/InternalServerError.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/InternalServerError.mjs +17 -0
- package/dist/esm/api/resources/implementationGuides/errors/NotFoundError.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/NotFoundError.mjs +17 -0
- package/dist/esm/api/resources/implementationGuides/errors/UnauthorizedError.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/UnauthorizedError.mjs +17 -0
- package/dist/esm/api/resources/implementationGuides/errors/index.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/errors/index.mjs +5 -0
- package/dist/esm/api/resources/implementationGuides/exports.d.mts +3 -0
- package/dist/esm/api/resources/implementationGuides/exports.mjs +4 -0
- package/dist/esm/api/resources/implementationGuides/index.d.mts +4 -0
- package/dist/esm/api/resources/implementationGuides/index.mjs +4 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/Client.d.mts +91 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/Client.mjs +279 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/index.d.mts +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/index.mjs +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/requests/UpdateImplementationGuideRequest.d.mts +8 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/requests/UpdateImplementationGuideRequest.mjs +2 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/exports.d.mts +2 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/exports.mjs +3 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/index.d.mts +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/implementationGuides/index.mjs +1 -0
- package/dist/esm/api/resources/implementationGuides/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/implementationGuides/resources/index.mjs +2 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideDetail.d.mts +5 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideDetail.mjs +2 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideListResponse.d.mts +4 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideListResponse.mjs +2 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideSummary.d.mts +15 -0
- package/dist/esm/api/resources/implementationGuides/types/ImplementationGuideSummary.mjs +2 -0
- package/dist/esm/api/resources/implementationGuides/types/index.d.mts +3 -0
- package/dist/esm/api/resources/implementationGuides/types/index.mjs +3 -0
- package/dist/esm/api/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/index.mjs +2 -0
- package/dist/esm/api/resources/lang2Fhir/client/Client.d.mts +8 -0
- package/dist/esm/api/resources/lang2Fhir/client/Client.mjs +15 -6
- package/dist/esm/api/resources/lang2Fhir/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/lang2Fhir/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/ClientClosedRequestError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/GatewayTimeoutError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/UnprocessableEntityError.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/types/CreateMultiResponse.d.mts +2 -0
- package/dist/esm/api/resources/lang2Fhir/{client/requests → types}/ProfileUploadRequest.d.mts +2 -10
- package/dist/esm/api/resources/lang2Fhir/types/ProfileUploadRequest.mjs +2 -0
- package/dist/esm/api/resources/lang2Fhir/types/index.d.mts +1 -0
- package/dist/esm/api/resources/lang2Fhir/types/index.mjs +1 -0
- package/dist/esm/api/resources/profiles/client/Client.d.mts +12 -0
- package/dist/esm/api/resources/profiles/client/Client.mjs +12 -0
- package/dist/esm/api/resources/profiles/client/index.d.mts +1 -0
- package/dist/esm/api/resources/profiles/client/index.mjs +1 -0
- package/dist/esm/api/resources/profiles/errors/BadRequestError.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/BadRequestError.mjs +17 -0
- package/dist/esm/api/resources/profiles/errors/ForbiddenError.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/ForbiddenError.mjs +17 -0
- package/dist/esm/api/resources/profiles/errors/InternalServerError.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/InternalServerError.mjs +17 -0
- package/dist/esm/api/resources/profiles/errors/NotFoundError.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/NotFoundError.mjs +17 -0
- package/dist/esm/api/resources/profiles/errors/UnauthorizedError.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/UnauthorizedError.mjs +17 -0
- package/dist/esm/api/resources/profiles/errors/index.d.mts +5 -0
- package/dist/esm/api/resources/profiles/errors/index.mjs +5 -0
- package/dist/esm/api/resources/profiles/exports.d.mts +3 -0
- package/dist/esm/api/resources/profiles/exports.mjs +4 -0
- package/dist/esm/api/resources/profiles/index.d.mts +4 -0
- package/dist/esm/api/resources/profiles/index.mjs +4 -0
- package/dist/esm/api/resources/profiles/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/profiles/resources/index.mjs +2 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/Client.d.mts +127 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/Client.mjs +360 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/index.d.mts +1 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/index.mjs +1 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/requests/ListRequest.d.mts +10 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/requests/ListRequest.mjs +2 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/profiles/resources/profiles/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/profiles/resources/profiles/exports.d.mts +2 -0
- package/dist/esm/api/resources/profiles/resources/profiles/exports.mjs +3 -0
- package/dist/esm/api/resources/profiles/resources/profiles/index.d.mts +1 -0
- package/dist/esm/api/resources/profiles/resources/profiles/index.mjs +1 -0
- package/dist/esm/api/resources/profiles/types/FhirResource.d.mts +4 -0
- package/dist/esm/api/resources/profiles/types/FhirResource.mjs +2 -0
- package/dist/esm/api/resources/profiles/types/ProfileGetResponse.d.mts +5 -0
- package/dist/esm/api/resources/profiles/types/ProfileGetResponse.mjs +2 -0
- package/dist/esm/api/resources/profiles/types/ProfileListResponse.d.mts +4 -0
- package/dist/esm/api/resources/profiles/types/ProfileListResponse.mjs +2 -0
- package/dist/esm/api/resources/profiles/types/ProfileSummary.d.mts +26 -0
- package/dist/esm/api/resources/profiles/types/ProfileSummary.mjs +9 -0
- package/dist/esm/api/resources/profiles/types/ProfileUploadRequest.d.mts +7 -0
- package/dist/esm/api/resources/profiles/types/ProfileUploadRequest.mjs +2 -0
- package/dist/esm/api/resources/profiles/types/index.d.mts +5 -0
- package/dist/esm/api/resources/profiles/types/index.mjs +5 -0
- package/dist/esm/api/resources/summary/client/Client.mjs +2 -1
- package/dist/esm/api/resources/summary/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/summary/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/summary/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/summary/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/summary/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/summary/resources/templates/client/Client.mjs +3 -2
- package/dist/esm/api/resources/tools/client/Client.mjs +5 -4
- package/dist/esm/api/resources/tools/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/tools/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/tools/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/tools/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/tools/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/tools/resources/mcpServers/client/Client.mjs +2 -1
- package/dist/esm/api/resources/voice/errors/BadGatewayError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/ContentTooLargeError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/GatewayTimeoutError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/PaymentRequiredError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/ServiceUnavailableError.mjs +1 -1
- package/dist/esm/api/resources/voice/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/api/resources/workflows/client/Client.mjs +4 -3
- package/dist/esm/api/resources/workflows/errors/BadRequestError.mjs +1 -1
- package/dist/esm/api/resources/workflows/errors/ForbiddenError.mjs +1 -1
- package/dist/esm/api/resources/workflows/errors/GatewayTimeoutError.mjs +1 -1
- package/dist/esm/api/resources/workflows/errors/InternalServerError.mjs +1 -1
- package/dist/esm/api/resources/workflows/errors/NotFoundError.mjs +1 -1
- package/dist/esm/api/resources/workflows/errors/UnauthorizedError.mjs +1 -1
- package/dist/esm/core/file/file.mjs +3 -0
- package/dist/esm/core/requestBody.d.mts +12 -0
- package/dist/esm/core/requestBody.mjs +23 -0
- package/dist/esm/core/stream/Stream.d.mts +45 -1
- package/dist/esm/core/stream/Stream.mjs +323 -84
- package/dist/esm/core/stream/index.d.mts +1 -0
- package/dist/esm/core/url/qs.mjs +2 -2
- package/dist/esm/errors/phenomlError.d.mts +1 -0
- package/dist/esm/errors/phenomlError.mjs +5 -1
- package/dist/esm/errors/phenomlTimeoutError.d.mts +2 -2
- package/dist/esm/errors/phenomlTimeoutError.mjs +7 -6
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/openapi/openapi.json +1224 -150
- package/package.json +23 -1
- package/reference.md +772 -71
- /package/dist/cjs/api/resources/{lang2Fhir/client/requests/ProfileUploadRequest.js → construe/resources/codes/client/requests/PhenoCrRequest.js} +0 -0
- /package/dist/esm/api/resources/{lang2Fhir/client/requests/ProfileUploadRequest.mjs → construe/resources/codes/client/requests/PhenoCrRequest.mjs} +0 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.ProfilesClient = void 0;
|
|
19
|
+
var Client_js_1 = require("./client/Client.js");
|
|
20
|
+
Object.defineProperty(exports, "ProfilesClient", { enumerable: true, get: function () { return Client_js_1.ProfilesClient; } });
|
|
21
|
+
__exportStar(require("./client/index.js"), exports);
|
|
22
|
+
__exportStar(require("./resources/index.js"), exports);
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|
|
18
|
+
__exportStar(require("./errors/index.js"), exports);
|
|
19
|
+
__exportStar(require("./resources/index.js"), exports);
|
|
20
|
+
__exportStar(require("./types/index.js"), exports);
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
19
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
20
|
+
};
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
38
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
+
exports.profiles = void 0;
|
|
40
|
+
__exportStar(require("./profiles/client/requests/index.js"), exports);
|
|
41
|
+
exports.profiles = __importStar(require("./profiles/index.js"));
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../../../core/index.js";
|
|
4
|
+
import * as phenoml from "../../../../../index.js";
|
|
5
|
+
export declare namespace ProfilesClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Manage custom FHIR profiles (StructureDefinitions) as instance-level FHIR artifacts.
|
|
12
|
+
*/
|
|
13
|
+
export declare class ProfilesClient {
|
|
14
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<ProfilesClient.Options>;
|
|
15
|
+
constructor(options?: ProfilesClient.Options);
|
|
16
|
+
/**
|
|
17
|
+
* Returns metadata for every custom (uploaded) FHIR profile on this
|
|
18
|
+
* instance, across all implementation guides. The full StructureDefinition
|
|
19
|
+
* JSON is omitted from each entry; fetch a single profile by id to retrieve it.
|
|
20
|
+
*
|
|
21
|
+
* The `url` query parameter filters by canonical URL. The canonical URL is the
|
|
22
|
+
* stable key other platform features use to reference a profile (FHIR's
|
|
23
|
+
* `meta.profile`, `baseDefinition`), since StructureDefinition ids are only
|
|
24
|
+
* unique within a package. A non-matching filter returns an empty list, not a 404.
|
|
25
|
+
*
|
|
26
|
+
* @param {phenoml.profiles.ListRequest} request
|
|
27
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
28
|
+
*
|
|
29
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
30
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
31
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* await client.profiles.profiles.list({
|
|
35
|
+
* url: "http://phenoml.com/fhir/StructureDefinition/custom-patient|1.0.0"
|
|
36
|
+
* })
|
|
37
|
+
*/
|
|
38
|
+
list(request?: phenoml.profiles.ListRequest, requestOptions?: ProfilesClient.RequestOptions): core.HttpResponsePromise<phenoml.profiles.ProfileListResponse>;
|
|
39
|
+
private __list;
|
|
40
|
+
/**
|
|
41
|
+
* Creates a custom profile from a FHIR StructureDefinition supplied as a JSON
|
|
42
|
+
* object. All metadata (version, resource type, id, url) is derived from the
|
|
43
|
+
* StructureDefinition; the lowercase StructureDefinition id becomes the
|
|
44
|
+
* profile's lookup key. Code system configuration is auto-extracted from the
|
|
45
|
+
* snapshot. Optionally group the profile under a named implementation guide.
|
|
46
|
+
*
|
|
47
|
+
* @param {phenoml.profiles.ProfileUploadRequest} request
|
|
48
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
49
|
+
*
|
|
50
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
51
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
52
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
53
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* await client.profiles.profiles.create({
|
|
57
|
+
* structure_definition: {
|
|
58
|
+
* "key": "value"
|
|
59
|
+
* }
|
|
60
|
+
* })
|
|
61
|
+
*/
|
|
62
|
+
create(request: phenoml.profiles.ProfileUploadRequest, requestOptions?: ProfilesClient.RequestOptions): core.HttpResponsePromise<phenoml.profiles.ProfileSummary>;
|
|
63
|
+
private __create;
|
|
64
|
+
/**
|
|
65
|
+
* Returns a single custom profile by id, including its full StructureDefinition JSON.
|
|
66
|
+
*
|
|
67
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
68
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
69
|
+
*
|
|
70
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
71
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
72
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
73
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
74
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
75
|
+
*
|
|
76
|
+
* @example
|
|
77
|
+
* await client.profiles.profiles.get("custom-patient")
|
|
78
|
+
*/
|
|
79
|
+
get(id: string, requestOptions?: ProfilesClient.RequestOptions): core.HttpResponsePromise<phenoml.profiles.ProfileGetResponse>;
|
|
80
|
+
private __get;
|
|
81
|
+
/**
|
|
82
|
+
* Replaces an existing custom profile with a new StructureDefinition. The
|
|
83
|
+
* `id` path parameter is authoritative: if the StructureDefinition includes
|
|
84
|
+
* an `id` it must match the path parameter, and if it omits one the path
|
|
85
|
+
* parameter is used. The FHIR resource type of the profile cannot change.
|
|
86
|
+
* Code system configuration is
|
|
87
|
+
* re-derived from the new StructureDefinition. When `implementation_guide` is
|
|
88
|
+
* omitted, the profile keeps its existing implementation guide. The instance
|
|
89
|
+
* stores a single version per canonical URL, so this replaces it in place.
|
|
90
|
+
*
|
|
91
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
92
|
+
* @param {phenoml.profiles.ProfileUploadRequest} request
|
|
93
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
94
|
+
*
|
|
95
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
96
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
97
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
98
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
99
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
100
|
+
*
|
|
101
|
+
* @example
|
|
102
|
+
* await client.profiles.profiles.update("custom-patient", {
|
|
103
|
+
* structure_definition: {
|
|
104
|
+
* "key": "value"
|
|
105
|
+
* }
|
|
106
|
+
* })
|
|
107
|
+
*/
|
|
108
|
+
update(id: string, request: phenoml.profiles.ProfileUploadRequest, requestOptions?: ProfilesClient.RequestOptions): core.HttpResponsePromise<phenoml.profiles.ProfileSummary>;
|
|
109
|
+
private __update;
|
|
110
|
+
/**
|
|
111
|
+
* Permanently deletes a custom profile by id.
|
|
112
|
+
*
|
|
113
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
114
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
115
|
+
*
|
|
116
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
117
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
118
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
119
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
120
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
121
|
+
*
|
|
122
|
+
* @example
|
|
123
|
+
* await client.profiles.profiles.delete("custom-patient")
|
|
124
|
+
*/
|
|
125
|
+
delete(id: string, requestOptions?: ProfilesClient.RequestOptions): core.HttpResponsePromise<void>;
|
|
126
|
+
private __delete;
|
|
127
|
+
}
|
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.ProfilesClient = void 0;
|
|
47
|
+
const BaseClient_js_1 = require("../../../../../../BaseClient.js");
|
|
48
|
+
const headers_js_1 = require("../../../../../../core/headers.js");
|
|
49
|
+
const core = __importStar(require("../../../../../../core/index.js"));
|
|
50
|
+
const requestBody_js_1 = require("../../../../../../core/requestBody.js");
|
|
51
|
+
const environments = __importStar(require("../../../../../../environments.js"));
|
|
52
|
+
const handleNonStatusCodeError_js_1 = require("../../../../../../errors/handleNonStatusCodeError.js");
|
|
53
|
+
const errors = __importStar(require("../../../../../../errors/index.js"));
|
|
54
|
+
const phenoml = __importStar(require("../../../../../index.js"));
|
|
55
|
+
/**
|
|
56
|
+
* Manage custom FHIR profiles (StructureDefinitions) as instance-level FHIR artifacts.
|
|
57
|
+
*/
|
|
58
|
+
class ProfilesClient {
|
|
59
|
+
constructor(options = {}) {
|
|
60
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Returns metadata for every custom (uploaded) FHIR profile on this
|
|
64
|
+
* instance, across all implementation guides. The full StructureDefinition
|
|
65
|
+
* JSON is omitted from each entry; fetch a single profile by id to retrieve it.
|
|
66
|
+
*
|
|
67
|
+
* The `url` query parameter filters by canonical URL. The canonical URL is the
|
|
68
|
+
* stable key other platform features use to reference a profile (FHIR's
|
|
69
|
+
* `meta.profile`, `baseDefinition`), since StructureDefinition ids are only
|
|
70
|
+
* unique within a package. A non-matching filter returns an empty list, not a 404.
|
|
71
|
+
*
|
|
72
|
+
* @param {phenoml.profiles.ListRequest} request
|
|
73
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
74
|
+
*
|
|
75
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
76
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
77
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
78
|
+
*
|
|
79
|
+
* @example
|
|
80
|
+
* await client.profiles.profiles.list({
|
|
81
|
+
* url: "http://phenoml.com/fhir/StructureDefinition/custom-patient|1.0.0"
|
|
82
|
+
* })
|
|
83
|
+
*/
|
|
84
|
+
list(request = {}, requestOptions) {
|
|
85
|
+
return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions));
|
|
86
|
+
}
|
|
87
|
+
__list() {
|
|
88
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
89
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
90
|
+
const { url } = request;
|
|
91
|
+
const _queryParams = {
|
|
92
|
+
url,
|
|
93
|
+
};
|
|
94
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
95
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
96
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
97
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "fhir/profiles"),
|
|
98
|
+
method: "GET",
|
|
99
|
+
headers: _headers,
|
|
100
|
+
queryString: core.url
|
|
101
|
+
.queryBuilder()
|
|
102
|
+
.addMany(_queryParams)
|
|
103
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
104
|
+
.build(),
|
|
105
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
106
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
107
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
108
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
109
|
+
logging: this._options.logging,
|
|
110
|
+
});
|
|
111
|
+
if (_response.ok) {
|
|
112
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
113
|
+
}
|
|
114
|
+
if (_response.error.reason === "status-code") {
|
|
115
|
+
switch (_response.error.statusCode) {
|
|
116
|
+
case 401:
|
|
117
|
+
throw new phenoml.profiles.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
118
|
+
case 403:
|
|
119
|
+
throw new phenoml.profiles.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
120
|
+
case 500:
|
|
121
|
+
throw new phenoml.profiles.InternalServerError(_response.error.body, _response.rawResponse);
|
|
122
|
+
default:
|
|
123
|
+
throw new errors.phenomlError({
|
|
124
|
+
statusCode: _response.error.statusCode,
|
|
125
|
+
body: _response.error.body,
|
|
126
|
+
rawResponse: _response.rawResponse,
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/fhir/profiles");
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Creates a custom profile from a FHIR StructureDefinition supplied as a JSON
|
|
135
|
+
* object. All metadata (version, resource type, id, url) is derived from the
|
|
136
|
+
* StructureDefinition; the lowercase StructureDefinition id becomes the
|
|
137
|
+
* profile's lookup key. Code system configuration is auto-extracted from the
|
|
138
|
+
* snapshot. Optionally group the profile under a named implementation guide.
|
|
139
|
+
*
|
|
140
|
+
* @param {phenoml.profiles.ProfileUploadRequest} request
|
|
141
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
142
|
+
*
|
|
143
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
144
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
145
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
146
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
147
|
+
*
|
|
148
|
+
* @example
|
|
149
|
+
* await client.profiles.profiles.create({
|
|
150
|
+
* structure_definition: {
|
|
151
|
+
* "key": "value"
|
|
152
|
+
* }
|
|
153
|
+
* })
|
|
154
|
+
*/
|
|
155
|
+
create(request, requestOptions) {
|
|
156
|
+
return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions));
|
|
157
|
+
}
|
|
158
|
+
__create(request, requestOptions) {
|
|
159
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
160
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
161
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
162
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
163
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
164
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "fhir/profiles"),
|
|
165
|
+
method: "POST",
|
|
166
|
+
headers: _headers,
|
|
167
|
+
contentType: "application/json",
|
|
168
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
169
|
+
requestType: "json",
|
|
170
|
+
body: (0, requestBody_js_1.mergeAdditionalBodyParameters)(request, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.additionalBodyParameters),
|
|
171
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
172
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
173
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
174
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
175
|
+
logging: this._options.logging,
|
|
176
|
+
});
|
|
177
|
+
if (_response.ok) {
|
|
178
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
179
|
+
}
|
|
180
|
+
if (_response.error.reason === "status-code") {
|
|
181
|
+
switch (_response.error.statusCode) {
|
|
182
|
+
case 400:
|
|
183
|
+
throw new phenoml.profiles.BadRequestError(_response.error.body, _response.rawResponse);
|
|
184
|
+
case 401:
|
|
185
|
+
throw new phenoml.profiles.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
186
|
+
case 403:
|
|
187
|
+
throw new phenoml.profiles.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
188
|
+
case 500:
|
|
189
|
+
throw new phenoml.profiles.InternalServerError(_response.error.body, _response.rawResponse);
|
|
190
|
+
default:
|
|
191
|
+
throw new errors.phenomlError({
|
|
192
|
+
statusCode: _response.error.statusCode,
|
|
193
|
+
body: _response.error.body,
|
|
194
|
+
rawResponse: _response.rawResponse,
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/fhir/profiles");
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
/**
|
|
202
|
+
* Returns a single custom profile by id, including its full StructureDefinition JSON.
|
|
203
|
+
*
|
|
204
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
205
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
206
|
+
*
|
|
207
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
208
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
209
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
210
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
211
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
212
|
+
*
|
|
213
|
+
* @example
|
|
214
|
+
* await client.profiles.profiles.get("custom-patient")
|
|
215
|
+
*/
|
|
216
|
+
get(id, requestOptions) {
|
|
217
|
+
return core.HttpResponsePromise.fromPromise(this.__get(id, requestOptions));
|
|
218
|
+
}
|
|
219
|
+
__get(id, requestOptions) {
|
|
220
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
221
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
222
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
223
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
224
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
225
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `fhir/profiles/${core.url.encodePathParam(id)}`),
|
|
226
|
+
method: "GET",
|
|
227
|
+
headers: _headers,
|
|
228
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
229
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
230
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
231
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
232
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
233
|
+
logging: this._options.logging,
|
|
234
|
+
});
|
|
235
|
+
if (_response.ok) {
|
|
236
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
237
|
+
}
|
|
238
|
+
if (_response.error.reason === "status-code") {
|
|
239
|
+
switch (_response.error.statusCode) {
|
|
240
|
+
case 400:
|
|
241
|
+
throw new phenoml.profiles.BadRequestError(_response.error.body, _response.rawResponse);
|
|
242
|
+
case 401:
|
|
243
|
+
throw new phenoml.profiles.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
244
|
+
case 403:
|
|
245
|
+
throw new phenoml.profiles.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
246
|
+
case 404:
|
|
247
|
+
throw new phenoml.profiles.NotFoundError(_response.error.body, _response.rawResponse);
|
|
248
|
+
case 500:
|
|
249
|
+
throw new phenoml.profiles.InternalServerError(_response.error.body, _response.rawResponse);
|
|
250
|
+
default:
|
|
251
|
+
throw new errors.phenomlError({
|
|
252
|
+
statusCode: _response.error.statusCode,
|
|
253
|
+
body: _response.error.body,
|
|
254
|
+
rawResponse: _response.rawResponse,
|
|
255
|
+
});
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/fhir/profiles/{id}");
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
/**
|
|
262
|
+
* Replaces an existing custom profile with a new StructureDefinition. The
|
|
263
|
+
* `id` path parameter is authoritative: if the StructureDefinition includes
|
|
264
|
+
* an `id` it must match the path parameter, and if it omits one the path
|
|
265
|
+
* parameter is used. The FHIR resource type of the profile cannot change.
|
|
266
|
+
* Code system configuration is
|
|
267
|
+
* re-derived from the new StructureDefinition. When `implementation_guide` is
|
|
268
|
+
* omitted, the profile keeps its existing implementation guide. The instance
|
|
269
|
+
* stores a single version per canonical URL, so this replaces it in place.
|
|
270
|
+
*
|
|
271
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
272
|
+
* @param {phenoml.profiles.ProfileUploadRequest} request
|
|
273
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
274
|
+
*
|
|
275
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
276
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
277
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
278
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
279
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
280
|
+
*
|
|
281
|
+
* @example
|
|
282
|
+
* await client.profiles.profiles.update("custom-patient", {
|
|
283
|
+
* structure_definition: {
|
|
284
|
+
* "key": "value"
|
|
285
|
+
* }
|
|
286
|
+
* })
|
|
287
|
+
*/
|
|
288
|
+
update(id, request, requestOptions) {
|
|
289
|
+
return core.HttpResponsePromise.fromPromise(this.__update(id, request, requestOptions));
|
|
290
|
+
}
|
|
291
|
+
__update(id, request, requestOptions) {
|
|
292
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
293
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
294
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
295
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
296
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
297
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `fhir/profiles/${core.url.encodePathParam(id)}`),
|
|
298
|
+
method: "PUT",
|
|
299
|
+
headers: _headers,
|
|
300
|
+
contentType: "application/json",
|
|
301
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
302
|
+
requestType: "json",
|
|
303
|
+
body: (0, requestBody_js_1.mergeAdditionalBodyParameters)(request, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.additionalBodyParameters),
|
|
304
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
305
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
306
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
307
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
308
|
+
logging: this._options.logging,
|
|
309
|
+
});
|
|
310
|
+
if (_response.ok) {
|
|
311
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
312
|
+
}
|
|
313
|
+
if (_response.error.reason === "status-code") {
|
|
314
|
+
switch (_response.error.statusCode) {
|
|
315
|
+
case 400:
|
|
316
|
+
throw new phenoml.profiles.BadRequestError(_response.error.body, _response.rawResponse);
|
|
317
|
+
case 401:
|
|
318
|
+
throw new phenoml.profiles.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
319
|
+
case 403:
|
|
320
|
+
throw new phenoml.profiles.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
321
|
+
case 404:
|
|
322
|
+
throw new phenoml.profiles.NotFoundError(_response.error.body, _response.rawResponse);
|
|
323
|
+
case 500:
|
|
324
|
+
throw new phenoml.profiles.InternalServerError(_response.error.body, _response.rawResponse);
|
|
325
|
+
default:
|
|
326
|
+
throw new errors.phenomlError({
|
|
327
|
+
statusCode: _response.error.statusCode,
|
|
328
|
+
body: _response.error.body,
|
|
329
|
+
rawResponse: _response.rawResponse,
|
|
330
|
+
});
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "PUT", "/fhir/profiles/{id}");
|
|
334
|
+
});
|
|
335
|
+
}
|
|
336
|
+
/**
|
|
337
|
+
* Permanently deletes a custom profile by id.
|
|
338
|
+
*
|
|
339
|
+
* @param {string} id - The lowercase StructureDefinition id of the custom profile.
|
|
340
|
+
* @param {ProfilesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
341
|
+
*
|
|
342
|
+
* @throws {@link phenoml.profiles.BadRequestError}
|
|
343
|
+
* @throws {@link phenoml.profiles.UnauthorizedError}
|
|
344
|
+
* @throws {@link phenoml.profiles.ForbiddenError}
|
|
345
|
+
* @throws {@link phenoml.profiles.NotFoundError}
|
|
346
|
+
* @throws {@link phenoml.profiles.InternalServerError}
|
|
347
|
+
*
|
|
348
|
+
* @example
|
|
349
|
+
* await client.profiles.profiles.delete("custom-patient")
|
|
350
|
+
*/
|
|
351
|
+
delete(id, requestOptions) {
|
|
352
|
+
return core.HttpResponsePromise.fromPromise(this.__delete(id, requestOptions));
|
|
353
|
+
}
|
|
354
|
+
__delete(id, requestOptions) {
|
|
355
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
356
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
357
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
358
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
359
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
360
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `fhir/profiles/${core.url.encodePathParam(id)}`),
|
|
361
|
+
method: "DELETE",
|
|
362
|
+
headers: _headers,
|
|
363
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
364
|
+
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
365
|
+
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
366
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
367
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
368
|
+
logging: this._options.logging,
|
|
369
|
+
});
|
|
370
|
+
if (_response.ok) {
|
|
371
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
372
|
+
}
|
|
373
|
+
if (_response.error.reason === "status-code") {
|
|
374
|
+
switch (_response.error.statusCode) {
|
|
375
|
+
case 400:
|
|
376
|
+
throw new phenoml.profiles.BadRequestError(_response.error.body, _response.rawResponse);
|
|
377
|
+
case 401:
|
|
378
|
+
throw new phenoml.profiles.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
379
|
+
case 403:
|
|
380
|
+
throw new phenoml.profiles.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
381
|
+
case 404:
|
|
382
|
+
throw new phenoml.profiles.NotFoundError(_response.error.body, _response.rawResponse);
|
|
383
|
+
case 500:
|
|
384
|
+
throw new phenoml.profiles.InternalServerError(_response.error.body, _response.rawResponse);
|
|
385
|
+
default:
|
|
386
|
+
throw new errors.phenomlError({
|
|
387
|
+
statusCode: _response.error.statusCode,
|
|
388
|
+
body: _response.error.body,
|
|
389
|
+
rawResponse: _response.rawResponse,
|
|
390
|
+
});
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/fhir/profiles/{id}");
|
|
394
|
+
});
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
exports.ProfilesClient = ProfilesClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./requests/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./requests/index.js"), exports);
|