phenoml 9.2.0 → 10.0.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 +13 -4
- package/dist/cjs/BaseClient.js +59 -0
- package/dist/cjs/Client.d.ts +34 -34
- package/dist/cjs/Client.js +13 -54
- package/dist/cjs/api/resources/agent/client/Client.d.ts +26 -27
- package/dist/cjs/api/resources/agent/client/Client.js +56 -185
- package/dist/cjs/api/resources/agent/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/agent/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/agent/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/agent/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/agent/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/agent/exports.d.ts +3 -0
- package/dist/cjs/api/resources/agent/exports.js +22 -0
- package/dist/cjs/api/resources/agent/resources/prompts/client/Client.d.ts +20 -21
- package/dist/cjs/api/resources/agent/resources/prompts/client/Client.js +35 -129
- package/dist/cjs/api/resources/agent/resources/prompts/exports.d.ts +2 -0
- package/dist/cjs/api/resources/agent/resources/prompts/exports.js +21 -0
- package/dist/cjs/api/resources/agent/resources/prompts/types/PromptsDeleteResponse.d.ts +2 -2
- package/dist/cjs/api/resources/agent/resources/prompts/types/PromptsListResponse.d.ts +3 -3
- package/dist/cjs/api/resources/agent/types/AgentChatResponse.d.ts +4 -4
- package/dist/cjs/api/resources/agent/types/AgentChatStreamEvent.d.ts +8 -8
- package/dist/cjs/api/resources/agent/types/AgentCreateRequest.d.ts +4 -4
- package/dist/cjs/api/resources/agent/types/AgentDeleteResponse.d.ts +2 -2
- package/dist/cjs/api/resources/agent/types/AgentGetChatMessagesResponse.d.ts +3 -3
- package/dist/cjs/api/resources/agent/types/AgentListResponse.d.ts +3 -3
- package/dist/cjs/api/resources/agent/types/AgentPromptsResponse.d.ts +3 -3
- package/dist/cjs/api/resources/agent/types/AgentResponse.d.ts +3 -3
- package/dist/cjs/api/resources/agent/types/AgentTemplate.d.ts +8 -8
- package/dist/cjs/api/resources/agent/types/ChatMessageTemplate.d.ts +10 -10
- package/dist/cjs/api/resources/agent/types/ChatSessionTemplate.d.ts +9 -9
- package/dist/cjs/api/resources/agent/types/JsonPatchOperation.d.ts +2 -2
- package/dist/cjs/api/resources/agent/types/PromptTemplate.d.ts +6 -6
- package/dist/cjs/api/resources/agent/types/SuccessResponse.d.ts +2 -2
- package/dist/cjs/api/resources/authtoken/client/Client.d.ts +9 -9
- package/dist/cjs/api/resources/authtoken/client/Client.js +7 -6
- package/dist/cjs/api/resources/authtoken/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/authtoken/errors/InternalServerError.d.ts +5 -0
- package/dist/cjs/api/resources/authtoken/errors/InternalServerError.js +54 -0
- package/dist/cjs/api/resources/authtoken/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/authtoken/errors/index.d.ts +1 -0
- package/dist/cjs/api/resources/authtoken/errors/index.js +1 -0
- package/dist/cjs/api/resources/authtoken/exports.d.ts +3 -0
- package/dist/cjs/api/resources/authtoken/exports.js +22 -0
- package/dist/cjs/api/resources/authtoken/resources/auth/client/Client.d.ts +28 -30
- package/dist/cjs/api/resources/authtoken/resources/auth/client/Client.js +76 -43
- package/dist/cjs/api/resources/authtoken/resources/auth/client/requests/ClientCredentialsRequest.d.ts +12 -0
- package/dist/cjs/api/resources/authtoken/resources/auth/client/requests/ClientCredentialsRequest.js +3 -0
- package/dist/cjs/api/resources/authtoken/resources/auth/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/authtoken/resources/auth/exports.d.ts +2 -0
- package/dist/cjs/api/resources/authtoken/resources/auth/exports.js +21 -0
- package/dist/cjs/api/resources/authtoken/types/BadRequestErrorBody.d.ts +3 -3
- package/dist/cjs/api/resources/authtoken/types/OAuthError.d.ts +19 -0
- package/dist/cjs/api/resources/authtoken/types/OAuthError.js +14 -0
- package/dist/cjs/api/resources/authtoken/types/TokenResponse.d.ts +8 -0
- package/dist/cjs/api/resources/authtoken/types/TokenResponse.js +3 -0
- package/dist/cjs/api/resources/authtoken/types/UnauthorizedErrorBody.d.ts +3 -3
- package/dist/cjs/api/resources/authtoken/types/index.d.ts +2 -0
- package/dist/cjs/api/resources/authtoken/types/index.js +2 -0
- package/dist/cjs/api/resources/cohort/client/Client.d.ts +8 -9
- package/dist/cjs/api/resources/cohort/client/Client.js +11 -27
- package/dist/cjs/api/resources/cohort/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/cohort/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/cohort/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/cohort/exports.d.ts +2 -0
- package/dist/cjs/api/resources/cohort/exports.js +21 -0
- package/dist/cjs/api/resources/cohort/types/CohortResponse.d.ts +3 -3
- package/dist/cjs/api/resources/cohort/types/SearchConcept.d.ts +4 -4
- package/dist/cjs/api/resources/construe/client/Client.d.ts +28 -29
- package/dist/cjs/api/resources/construe/client/Client.js +78 -239
- package/dist/cjs/api/resources/construe/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/construe/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/construe/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/ConflictError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/FailedDependencyError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/GatewayTimeoutError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/NotImplementedError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/ServiceUnavailableError.js +5 -1
- package/dist/cjs/api/resources/construe/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/construe/exports.d.ts +2 -0
- package/dist/cjs/api/resources/construe/exports.js +21 -0
- package/dist/cjs/api/resources/construe/types/CodeResponse.d.ts +1 -1
- package/dist/cjs/api/resources/construe/types/ConstrueUploadCodeSystemResponse.d.ts +3 -3
- package/dist/cjs/api/resources/construe/types/ExtractRequestConfig.d.ts +8 -8
- package/dist/cjs/api/resources/construe/types/ExtractRequestSystem.d.ts +2 -2
- package/dist/cjs/api/resources/construe/types/ExtractedCodeResult.d.ts +3 -3
- package/dist/cjs/api/resources/construe/types/GetCodeResponse.d.ts +1 -1
- package/dist/cjs/api/resources/construe/types/ListCodesResponse.d.ts +1 -1
- package/dist/cjs/api/resources/fhir/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/fhir/client/Client.js +46 -134
- package/dist/cjs/api/resources/fhir/client/requests/FhirSearchRequest.d.ts +0 -6
- package/dist/cjs/api/resources/fhir/errors/BadGatewayError.js +5 -1
- package/dist/cjs/api/resources/fhir/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/fhir/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/fhir/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/fhir/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/fhir/exports.d.ts +2 -0
- package/dist/cjs/api/resources/fhir/exports.js +21 -0
- package/dist/cjs/api/resources/fhir/types/ErrorResponse.d.ts +2 -2
- package/dist/cjs/api/resources/fhir/types/FhirBundle.d.ts +8 -8
- package/dist/cjs/api/resources/fhir/types/FhirPatchRequestBodyItem.d.ts +2 -2
- package/dist/cjs/api/resources/fhir/types/FhirResource.d.ts +5 -5
- package/dist/cjs/api/resources/fhirProvider/client/Client.d.ts +20 -21
- package/dist/cjs/api/resources/fhirProvider/client/Client.js +35 -129
- package/dist/cjs/api/resources/fhirProvider/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/fhirProvider/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/fhirProvider/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/fhirProvider/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/fhirProvider/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/fhirProvider/exports.d.ts +2 -0
- package/dist/cjs/api/resources/fhirProvider/exports.js +21 -0
- package/dist/cjs/api/resources/fhirProvider/types/ClientSecretAuth.d.ts +2 -2
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderAuthConfig.d.ts +12 -12
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderDeleteResponse.d.ts +2 -2
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderListResponse.d.ts +3 -3
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderRemoveAuthConfigResponse.d.ts +3 -3
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderResponse.d.ts +3 -3
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderSandboxInfo.d.ts +4 -4
- package/dist/cjs/api/resources/fhirProvider/types/FhirProviderTemplate.d.ts +8 -8
- package/dist/cjs/api/resources/fhirProvider/types/FhirQueryResponse.d.ts +4 -4
- package/dist/cjs/api/resources/fhirProvider/types/JsonWebKey.d.ts +6 -6
- package/dist/cjs/api/resources/fhirProvider/types/JwtAuth.d.ts +3 -3
- package/dist/cjs/api/resources/fhirProvider/types/OnBehalfOfAuth.d.ts +2 -2
- package/dist/cjs/api/resources/fhirProvider/types/ServiceAccountMetadata.d.ts +4 -4
- package/dist/cjs/api/resources/fhirProvider/types/SmartConfiguration.d.ts +5 -5
- package/dist/cjs/api/resources/lang2Fhir/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/lang2Fhir/client/Client.js +31 -112
- package/dist/cjs/api/resources/lang2Fhir/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/lang2Fhir/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/lang2Fhir/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/FailedDependencyError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/errors/UnprocessableEntityError.js +5 -1
- package/dist/cjs/api/resources/lang2Fhir/exports.d.ts +2 -0
- package/dist/cjs/api/resources/lang2Fhir/exports.js +21 -0
- package/dist/cjs/api/resources/lang2Fhir/types/CreateMultiResponse.d.ts +15 -15
- package/dist/cjs/api/resources/lang2Fhir/types/Lang2FhirUploadProfileResponse.d.ts +4 -4
- package/dist/cjs/api/resources/lang2Fhir/types/SearchResponse.d.ts +2 -2
- package/dist/cjs/api/resources/summary/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/summary/client/Client.js +31 -112
- package/dist/cjs/api/resources/summary/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/summary/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/summary/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/summary/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/summary/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/summary/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/summary/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/summary/exports.d.ts +2 -0
- package/dist/cjs/api/resources/summary/exports.js +21 -0
- package/dist/cjs/api/resources/summary/types/CreateSummaryResponse.d.ts +4 -4
- package/dist/cjs/api/resources/summary/types/CreateSummaryTemplateResponse.d.ts +4 -4
- package/dist/cjs/api/resources/summary/types/ErrorResponse.d.ts +2 -2
- package/dist/cjs/api/resources/summary/types/FhirBundle.d.ts +1 -1
- package/dist/cjs/api/resources/summary/types/SummaryDeleteTemplateResponse.d.ts +2 -2
- package/dist/cjs/api/resources/summary/types/SummaryGetTemplateResponse.d.ts +2 -2
- package/dist/cjs/api/resources/summary/types/SummaryListTemplatesResponse.d.ts +2 -2
- package/dist/cjs/api/resources/summary/types/SummaryTemplate.d.ts +9 -9
- package/dist/cjs/api/resources/summary/types/SummaryUpdateTemplateResponse.d.ts +3 -3
- package/dist/cjs/api/resources/tools/client/Client.d.ts +17 -18
- package/dist/cjs/api/resources/tools/client/Client.js +32 -91
- package/dist/cjs/api/resources/tools/client/requests/index.d.ts +1 -1
- package/dist/cjs/api/resources/tools/client/requests/index.js +3 -0
- package/dist/cjs/api/resources/tools/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/tools/errors/FailedDependencyError.js +5 -1
- package/dist/cjs/api/resources/tools/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/tools/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/tools/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/tools/exports.d.ts +3 -0
- package/dist/cjs/api/resources/tools/exports.js +22 -0
- package/dist/cjs/api/resources/tools/resources/mcpServer/client/Client.d.ts +17 -18
- package/dist/cjs/api/resources/tools/resources/mcpServer/client/Client.js +24 -79
- package/dist/cjs/api/resources/tools/resources/mcpServer/exports.d.ts +3 -0
- package/dist/cjs/api/resources/tools/resources/mcpServer/exports.js +22 -0
- package/dist/cjs/api/resources/tools/resources/mcpServer/resources/tools/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/tools/resources/mcpServer/resources/tools/client/Client.js +23 -78
- package/dist/cjs/api/resources/tools/resources/mcpServer/resources/tools/exports.d.ts +2 -0
- package/dist/cjs/api/resources/tools/resources/mcpServer/resources/tools/exports.js +21 -0
- package/dist/cjs/api/resources/tools/types/CohortResponse.d.ts +5 -5
- package/dist/cjs/api/resources/tools/types/Lang2FhirAndCreateMultiResponse.d.ts +10 -10
- package/dist/cjs/api/resources/tools/types/Lang2FhirAndCreateResponse.d.ts +4 -4
- package/dist/cjs/api/resources/tools/types/Lang2FhirAndSearchResponse.d.ts +5 -5
- package/dist/cjs/api/resources/tools/types/McpServerResponse.d.ts +7 -7
- package/dist/cjs/api/resources/tools/types/McpServerToolCallResponse.d.ts +4 -4
- package/dist/cjs/api/resources/tools/types/McpServerToolResponse.d.ts +9 -9
- package/dist/cjs/api/resources/tools/types/SearchConcept.d.ts +4 -4
- package/dist/cjs/api/resources/workflows/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/workflows/client/Client.js +43 -128
- package/dist/cjs/api/resources/workflows/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/resources/workflows/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/resources/workflows/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/resources/workflows/errors/NotFoundError.js +5 -1
- package/dist/cjs/api/resources/workflows/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/workflows/exports.d.ts +2 -0
- package/dist/cjs/api/resources/workflows/exports.js +21 -0
- package/dist/cjs/api/resources/workflows/types/CreateWorkflowResponse.d.ts +5 -5
- package/dist/cjs/api/resources/workflows/types/DecisionNodeDefinition.d.ts +3 -3
- package/dist/cjs/api/resources/workflows/types/ExecuteWorkflowResponse.d.ts +4 -4
- package/dist/cjs/api/resources/workflows/types/Lang2FhirCreateDefinition.d.ts +4 -4
- package/dist/cjs/api/resources/workflows/types/Lang2FhirSearchDefinition.d.ts +5 -5
- package/dist/cjs/api/resources/workflows/types/ListWorkflowsResponse.d.ts +4 -4
- package/dist/cjs/api/resources/workflows/types/StepOperation.d.ts +4 -4
- package/dist/cjs/api/resources/workflows/types/SubWorkflowDefinition.d.ts +3 -3
- package/dist/cjs/api/resources/workflows/types/WorkflowConfig.d.ts +2 -2
- package/dist/cjs/api/resources/workflows/types/WorkflowDefinition.d.ts +8 -8
- package/dist/cjs/api/resources/workflows/types/WorkflowGraph.d.ts +1 -1
- package/dist/cjs/api/resources/workflows/types/WorkflowResponse.d.ts +9 -9
- package/dist/cjs/api/resources/workflows/types/WorkflowStep.d.ts +8 -8
- package/dist/cjs/api/resources/workflows/types/WorkflowStepSummary.d.ts +5 -5
- package/dist/cjs/api/resources/workflows/types/WorkflowsDeleteResponse.d.ts +2 -2
- package/dist/cjs/api/resources/workflows/types/WorkflowsGetResponse.d.ts +3 -3
- package/dist/cjs/api/resources/workflows/types/WorkflowsUpdateResponse.d.ts +4 -4
- package/dist/cjs/auth/OAuthAuthProvider.d.ts +45 -0
- package/dist/cjs/auth/OAuthAuthProvider.js +190 -0
- package/dist/cjs/auth/index.d.ts +1 -0
- package/dist/cjs/auth/index.js +5 -0
- package/dist/cjs/core/auth/AuthProvider.d.ts +4 -1
- package/dist/cjs/core/auth/BearerToken.d.ts +3 -1
- package/dist/cjs/core/auth/BearerToken.js +7 -6
- package/dist/cjs/core/auth/NoOpAuthProvider.d.ts +5 -0
- package/dist/cjs/core/auth/NoOpAuthProvider.js +9 -0
- package/dist/cjs/core/auth/index.d.ts +1 -0
- package/dist/cjs/core/auth/index.js +3 -1
- package/dist/cjs/core/fetcher/BinaryResponse.d.ts +6 -7
- package/dist/cjs/core/fetcher/EndpointSupplier.d.ts +2 -2
- package/dist/cjs/core/fetcher/Fetcher.d.ts +6 -3
- package/dist/cjs/core/fetcher/Fetcher.js +10 -3
- package/dist/cjs/core/fetcher/getResponseBody.js +18 -4
- package/dist/cjs/core/fetcher/makeRequest.d.ts +6 -1
- package/dist/cjs/core/fetcher/makeRequest.js +30 -9
- package/dist/cjs/core/fetcher/signals.d.ts +1 -1
- package/dist/cjs/core/headers.d.ts +2 -2
- package/dist/cjs/core/runtime/runtime.js +17 -15
- package/dist/cjs/core/stream/Stream.d.ts +9 -0
- package/dist/cjs/core/stream/Stream.js +100 -5
- package/dist/cjs/errors/handleNonStatusCodeError.d.ts +2 -0
- package/dist/cjs/errors/handleNonStatusCodeError.js +65 -0
- package/dist/cjs/errors/phenomlError.js +5 -1
- package/dist/cjs/errors/phenomlTimeoutError.js +5 -1
- package/dist/cjs/index.d.ts +4 -2
- package/dist/cjs/index.js +9 -5
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +13 -4
- package/dist/esm/BaseClient.mjs +24 -1
- package/dist/esm/Client.d.mts +34 -34
- package/dist/esm/Client.mjs +23 -31
- package/dist/esm/api/resources/agent/client/Client.d.mts +26 -27
- package/dist/esm/api/resources/agent/client/Client.mjs +55 -184
- package/dist/esm/api/resources/agent/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/agent/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/agent/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/agent/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/agent/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/agent/exports.d.mts +3 -0
- package/dist/esm/api/resources/agent/exports.mjs +4 -0
- package/dist/esm/api/resources/agent/resources/prompts/client/Client.d.mts +20 -21
- package/dist/esm/api/resources/agent/resources/prompts/client/Client.mjs +34 -128
- package/dist/esm/api/resources/agent/resources/prompts/exports.d.mts +2 -0
- package/dist/esm/api/resources/agent/resources/prompts/exports.mjs +3 -0
- package/dist/esm/api/resources/agent/resources/prompts/types/PromptsDeleteResponse.d.mts +2 -2
- package/dist/esm/api/resources/agent/resources/prompts/types/PromptsListResponse.d.mts +3 -3
- package/dist/esm/api/resources/agent/types/AgentChatResponse.d.mts +4 -4
- package/dist/esm/api/resources/agent/types/AgentChatStreamEvent.d.mts +8 -8
- package/dist/esm/api/resources/agent/types/AgentCreateRequest.d.mts +4 -4
- package/dist/esm/api/resources/agent/types/AgentDeleteResponse.d.mts +2 -2
- package/dist/esm/api/resources/agent/types/AgentGetChatMessagesResponse.d.mts +3 -3
- package/dist/esm/api/resources/agent/types/AgentListResponse.d.mts +3 -3
- package/dist/esm/api/resources/agent/types/AgentPromptsResponse.d.mts +3 -3
- package/dist/esm/api/resources/agent/types/AgentResponse.d.mts +3 -3
- package/dist/esm/api/resources/agent/types/AgentTemplate.d.mts +8 -8
- package/dist/esm/api/resources/agent/types/ChatMessageTemplate.d.mts +10 -10
- package/dist/esm/api/resources/agent/types/ChatSessionTemplate.d.mts +9 -9
- package/dist/esm/api/resources/agent/types/JsonPatchOperation.d.mts +2 -2
- package/dist/esm/api/resources/agent/types/PromptTemplate.d.mts +6 -6
- package/dist/esm/api/resources/agent/types/SuccessResponse.d.mts +2 -2
- package/dist/esm/api/resources/authtoken/client/Client.d.mts +9 -9
- package/dist/esm/api/resources/authtoken/client/Client.mjs +6 -5
- package/dist/esm/api/resources/authtoken/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/authtoken/errors/InternalServerError.d.mts +5 -0
- package/dist/esm/api/resources/authtoken/errors/InternalServerError.mjs +17 -0
- package/dist/esm/api/resources/authtoken/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/authtoken/errors/index.d.mts +1 -0
- package/dist/esm/api/resources/authtoken/errors/index.mjs +1 -0
- package/dist/esm/api/resources/authtoken/exports.d.mts +3 -0
- package/dist/esm/api/resources/authtoken/exports.mjs +4 -0
- package/dist/esm/api/resources/authtoken/resources/auth/client/Client.d.mts +28 -30
- package/dist/esm/api/resources/authtoken/resources/auth/client/Client.mjs +74 -41
- package/dist/esm/api/resources/authtoken/resources/auth/client/requests/ClientCredentialsRequest.d.mts +12 -0
- package/dist/esm/api/resources/authtoken/resources/auth/client/requests/ClientCredentialsRequest.mjs +2 -0
- package/dist/esm/api/resources/authtoken/resources/auth/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/authtoken/resources/auth/exports.d.mts +2 -0
- package/dist/esm/api/resources/authtoken/resources/auth/exports.mjs +3 -0
- package/dist/esm/api/resources/authtoken/types/BadRequestErrorBody.d.mts +3 -3
- package/dist/esm/api/resources/authtoken/types/OAuthError.d.mts +19 -0
- package/dist/esm/api/resources/authtoken/types/OAuthError.mjs +11 -0
- package/dist/esm/api/resources/authtoken/types/TokenResponse.d.mts +8 -0
- package/dist/esm/api/resources/authtoken/types/TokenResponse.mjs +2 -0
- package/dist/esm/api/resources/authtoken/types/UnauthorizedErrorBody.d.mts +3 -3
- package/dist/esm/api/resources/authtoken/types/index.d.mts +2 -0
- package/dist/esm/api/resources/authtoken/types/index.mjs +2 -0
- package/dist/esm/api/resources/cohort/client/Client.d.mts +8 -9
- package/dist/esm/api/resources/cohort/client/Client.mjs +10 -26
- package/dist/esm/api/resources/cohort/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/cohort/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/cohort/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/cohort/exports.d.mts +2 -0
- package/dist/esm/api/resources/cohort/exports.mjs +3 -0
- package/dist/esm/api/resources/cohort/types/CohortResponse.d.mts +3 -3
- package/dist/esm/api/resources/cohort/types/SearchConcept.d.mts +4 -4
- package/dist/esm/api/resources/construe/client/Client.d.mts +28 -29
- package/dist/esm/api/resources/construe/client/Client.mjs +77 -238
- package/dist/esm/api/resources/construe/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/construe/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/construe/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/ConflictError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/FailedDependencyError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/GatewayTimeoutError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/NotImplementedError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/ServiceUnavailableError.mjs +5 -1
- package/dist/esm/api/resources/construe/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/construe/exports.d.mts +2 -0
- package/dist/esm/api/resources/construe/exports.mjs +3 -0
- package/dist/esm/api/resources/construe/types/CodeResponse.d.mts +1 -1
- package/dist/esm/api/resources/construe/types/ConstrueUploadCodeSystemResponse.d.mts +3 -3
- package/dist/esm/api/resources/construe/types/ExtractRequestConfig.d.mts +8 -8
- package/dist/esm/api/resources/construe/types/ExtractRequestSystem.d.mts +2 -2
- package/dist/esm/api/resources/construe/types/ExtractedCodeResult.d.mts +3 -3
- package/dist/esm/api/resources/construe/types/GetCodeResponse.d.mts +1 -1
- package/dist/esm/api/resources/construe/types/ListCodesResponse.d.mts +1 -1
- package/dist/esm/api/resources/fhir/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/fhir/client/Client.mjs +44 -132
- package/dist/esm/api/resources/fhir/client/requests/FhirSearchRequest.d.mts +0 -6
- package/dist/esm/api/resources/fhir/errors/BadGatewayError.mjs +5 -1
- package/dist/esm/api/resources/fhir/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/fhir/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/fhir/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/fhir/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/fhir/exports.d.mts +2 -0
- package/dist/esm/api/resources/fhir/exports.mjs +3 -0
- package/dist/esm/api/resources/fhir/types/ErrorResponse.d.mts +2 -2
- package/dist/esm/api/resources/fhir/types/FhirBundle.d.mts +8 -8
- package/dist/esm/api/resources/fhir/types/FhirPatchRequestBodyItem.d.mts +2 -2
- package/dist/esm/api/resources/fhir/types/FhirResource.d.mts +5 -5
- package/dist/esm/api/resources/fhirProvider/client/Client.d.mts +20 -21
- package/dist/esm/api/resources/fhirProvider/client/Client.mjs +34 -128
- package/dist/esm/api/resources/fhirProvider/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/fhirProvider/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/fhirProvider/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/fhirProvider/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/fhirProvider/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/fhirProvider/exports.d.mts +2 -0
- package/dist/esm/api/resources/fhirProvider/exports.mjs +3 -0
- package/dist/esm/api/resources/fhirProvider/types/ClientSecretAuth.d.mts +2 -2
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderAuthConfig.d.mts +12 -12
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderDeleteResponse.d.mts +2 -2
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderListResponse.d.mts +3 -3
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderRemoveAuthConfigResponse.d.mts +3 -3
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderResponse.d.mts +3 -3
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderSandboxInfo.d.mts +4 -4
- package/dist/esm/api/resources/fhirProvider/types/FhirProviderTemplate.d.mts +8 -8
- package/dist/esm/api/resources/fhirProvider/types/FhirQueryResponse.d.mts +4 -4
- package/dist/esm/api/resources/fhirProvider/types/JsonWebKey.d.mts +6 -6
- package/dist/esm/api/resources/fhirProvider/types/JwtAuth.d.mts +3 -3
- package/dist/esm/api/resources/fhirProvider/types/OnBehalfOfAuth.d.mts +2 -2
- package/dist/esm/api/resources/fhirProvider/types/ServiceAccountMetadata.d.mts +4 -4
- package/dist/esm/api/resources/fhirProvider/types/SmartConfiguration.d.mts +5 -5
- package/dist/esm/api/resources/lang2Fhir/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/lang2Fhir/client/Client.mjs +30 -111
- package/dist/esm/api/resources/lang2Fhir/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/lang2Fhir/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/lang2Fhir/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/errors/FailedDependencyError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/errors/UnprocessableEntityError.mjs +5 -1
- package/dist/esm/api/resources/lang2Fhir/exports.d.mts +2 -0
- package/dist/esm/api/resources/lang2Fhir/exports.mjs +3 -0
- package/dist/esm/api/resources/lang2Fhir/types/CreateMultiResponse.d.mts +15 -15
- package/dist/esm/api/resources/lang2Fhir/types/Lang2FhirUploadProfileResponse.d.mts +4 -4
- package/dist/esm/api/resources/lang2Fhir/types/SearchResponse.d.mts +2 -2
- package/dist/esm/api/resources/summary/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/summary/client/Client.mjs +30 -111
- package/dist/esm/api/resources/summary/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/summary/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/summary/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/summary/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/summary/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/summary/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/summary/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/summary/exports.d.mts +2 -0
- package/dist/esm/api/resources/summary/exports.mjs +3 -0
- package/dist/esm/api/resources/summary/types/CreateSummaryResponse.d.mts +4 -4
- package/dist/esm/api/resources/summary/types/CreateSummaryTemplateResponse.d.mts +4 -4
- package/dist/esm/api/resources/summary/types/ErrorResponse.d.mts +2 -2
- package/dist/esm/api/resources/summary/types/FhirBundle.d.mts +1 -1
- package/dist/esm/api/resources/summary/types/SummaryDeleteTemplateResponse.d.mts +2 -2
- package/dist/esm/api/resources/summary/types/SummaryGetTemplateResponse.d.mts +2 -2
- package/dist/esm/api/resources/summary/types/SummaryListTemplatesResponse.d.mts +2 -2
- package/dist/esm/api/resources/summary/types/SummaryTemplate.d.mts +9 -9
- package/dist/esm/api/resources/summary/types/SummaryUpdateTemplateResponse.d.mts +3 -3
- package/dist/esm/api/resources/tools/client/Client.d.mts +17 -18
- package/dist/esm/api/resources/tools/client/Client.mjs +31 -90
- package/dist/esm/api/resources/tools/client/requests/index.d.mts +1 -1
- package/dist/esm/api/resources/tools/client/requests/index.mjs +1 -1
- package/dist/esm/api/resources/tools/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/tools/errors/FailedDependencyError.mjs +5 -1
- package/dist/esm/api/resources/tools/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/tools/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/tools/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/tools/exports.d.mts +3 -0
- package/dist/esm/api/resources/tools/exports.mjs +4 -0
- package/dist/esm/api/resources/tools/resources/mcpServer/client/Client.d.mts +17 -18
- package/dist/esm/api/resources/tools/resources/mcpServer/client/Client.mjs +24 -79
- package/dist/esm/api/resources/tools/resources/mcpServer/exports.d.mts +3 -0
- package/dist/esm/api/resources/tools/resources/mcpServer/exports.mjs +4 -0
- package/dist/esm/api/resources/tools/resources/mcpServer/resources/tools/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/tools/resources/mcpServer/resources/tools/client/Client.mjs +22 -77
- package/dist/esm/api/resources/tools/resources/mcpServer/resources/tools/exports.d.mts +2 -0
- package/dist/esm/api/resources/tools/resources/mcpServer/resources/tools/exports.mjs +3 -0
- package/dist/esm/api/resources/tools/types/CohortResponse.d.mts +5 -5
- package/dist/esm/api/resources/tools/types/Lang2FhirAndCreateMultiResponse.d.mts +10 -10
- package/dist/esm/api/resources/tools/types/Lang2FhirAndCreateResponse.d.mts +4 -4
- package/dist/esm/api/resources/tools/types/Lang2FhirAndSearchResponse.d.mts +5 -5
- package/dist/esm/api/resources/tools/types/McpServerResponse.d.mts +7 -7
- package/dist/esm/api/resources/tools/types/McpServerToolCallResponse.d.mts +4 -4
- package/dist/esm/api/resources/tools/types/McpServerToolResponse.d.mts +9 -9
- package/dist/esm/api/resources/tools/types/SearchConcept.d.mts +4 -4
- package/dist/esm/api/resources/workflows/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/workflows/client/Client.mjs +42 -127
- package/dist/esm/api/resources/workflows/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/resources/workflows/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/resources/workflows/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/resources/workflows/errors/NotFoundError.mjs +5 -1
- package/dist/esm/api/resources/workflows/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/workflows/exports.d.mts +2 -0
- package/dist/esm/api/resources/workflows/exports.mjs +3 -0
- package/dist/esm/api/resources/workflows/types/CreateWorkflowResponse.d.mts +5 -5
- package/dist/esm/api/resources/workflows/types/DecisionNodeDefinition.d.mts +3 -3
- package/dist/esm/api/resources/workflows/types/ExecuteWorkflowResponse.d.mts +4 -4
- package/dist/esm/api/resources/workflows/types/Lang2FhirCreateDefinition.d.mts +4 -4
- package/dist/esm/api/resources/workflows/types/Lang2FhirSearchDefinition.d.mts +5 -5
- package/dist/esm/api/resources/workflows/types/ListWorkflowsResponse.d.mts +4 -4
- package/dist/esm/api/resources/workflows/types/StepOperation.d.mts +4 -4
- package/dist/esm/api/resources/workflows/types/SubWorkflowDefinition.d.mts +3 -3
- package/dist/esm/api/resources/workflows/types/WorkflowConfig.d.mts +2 -2
- package/dist/esm/api/resources/workflows/types/WorkflowDefinition.d.mts +8 -8
- package/dist/esm/api/resources/workflows/types/WorkflowGraph.d.mts +1 -1
- package/dist/esm/api/resources/workflows/types/WorkflowResponse.d.mts +9 -9
- package/dist/esm/api/resources/workflows/types/WorkflowStep.d.mts +8 -8
- package/dist/esm/api/resources/workflows/types/WorkflowStepSummary.d.mts +5 -5
- package/dist/esm/api/resources/workflows/types/WorkflowsDeleteResponse.d.mts +2 -2
- package/dist/esm/api/resources/workflows/types/WorkflowsGetResponse.d.mts +3 -3
- package/dist/esm/api/resources/workflows/types/WorkflowsUpdateResponse.d.mts +4 -4
- package/dist/esm/auth/OAuthAuthProvider.d.mts +45 -0
- package/dist/esm/auth/OAuthAuthProvider.mjs +152 -0
- package/dist/esm/auth/index.d.mts +1 -0
- package/dist/esm/auth/index.mjs +1 -0
- package/dist/esm/core/auth/AuthProvider.d.mts +4 -1
- package/dist/esm/core/auth/BearerToken.d.mts +3 -1
- package/dist/esm/core/auth/BearerToken.mjs +7 -6
- package/dist/esm/core/auth/NoOpAuthProvider.d.mts +5 -0
- package/dist/esm/core/auth/NoOpAuthProvider.mjs +5 -0
- package/dist/esm/core/auth/index.d.mts +1 -0
- package/dist/esm/core/auth/index.mjs +1 -0
- package/dist/esm/core/fetcher/BinaryResponse.d.mts +6 -7
- package/dist/esm/core/fetcher/EndpointSupplier.d.mts +2 -2
- package/dist/esm/core/fetcher/Fetcher.d.mts +6 -3
- package/dist/esm/core/fetcher/Fetcher.mjs +10 -3
- package/dist/esm/core/fetcher/getResponseBody.mjs +18 -4
- package/dist/esm/core/fetcher/makeRequest.d.mts +6 -1
- package/dist/esm/core/fetcher/makeRequest.mjs +28 -9
- package/dist/esm/core/fetcher/signals.d.mts +1 -1
- package/dist/esm/core/headers.d.mts +2 -2
- package/dist/esm/core/runtime/runtime.mjs +17 -15
- package/dist/esm/core/stream/Stream.d.mts +9 -0
- package/dist/esm/core/stream/Stream.mjs +100 -5
- package/dist/esm/errors/handleNonStatusCodeError.d.mts +2 -0
- package/dist/esm/errors/handleNonStatusCodeError.mjs +29 -0
- package/dist/esm/errors/phenomlError.mjs +5 -1
- package/dist/esm/errors/phenomlTimeoutError.mjs +5 -1
- package/dist/esm/index.d.mts +4 -2
- package/dist/esm/index.mjs +3 -2
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +162 -5
- package/reference.md +141 -74
- package/dist/cjs/WrapperClient.d.ts +0 -21
- package/dist/cjs/WrapperClient.js +0 -111
- package/dist/cjs/core/fetcher/ResponseWithBody.d.ts +0 -4
- package/dist/cjs/core/fetcher/ResponseWithBody.js +0 -6
- package/dist/esm/WrapperClient.d.mts +0 -21
- package/dist/esm/WrapperClient.mjs +0 -75
- package/dist/esm/core/fetcher/ResponseWithBody.d.mts +0 -4
- package/dist/esm/core/fetcher/ResponseWithBody.mjs +0 -3
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
export interface Lang2FhirAndCreateMultiResponse {
|
|
2
2
|
/** Whether the resources were created successfully */
|
|
3
|
-
success?: boolean;
|
|
3
|
+
success?: boolean | undefined;
|
|
4
4
|
/** Status message */
|
|
5
|
-
message?: string;
|
|
5
|
+
message?: string | undefined;
|
|
6
6
|
/** FHIR transaction-response Bundle from the server with resolved resource IDs */
|
|
7
|
-
response_bundle?: Lang2FhirAndCreateMultiResponse.ResponseBundle;
|
|
7
|
+
response_bundle?: Lang2FhirAndCreateMultiResponse.ResponseBundle | undefined;
|
|
8
8
|
/** Metadata about created resources (temp IDs, types, descriptions) */
|
|
9
|
-
resource_info?: Lang2FhirAndCreateMultiResponse.ResourceInfo.Item[];
|
|
9
|
+
resource_info?: Lang2FhirAndCreateMultiResponse.ResourceInfo.Item[] | undefined;
|
|
10
10
|
}
|
|
11
11
|
export declare namespace Lang2FhirAndCreateMultiResponse {
|
|
12
12
|
/**
|
|
13
13
|
* FHIR transaction-response Bundle from the server with resolved resource IDs
|
|
14
14
|
*/
|
|
15
15
|
interface ResponseBundle {
|
|
16
|
-
resourceType?: string;
|
|
17
|
-
type?: string;
|
|
18
|
-
entry?: Record<string, unknown>[];
|
|
16
|
+
resourceType?: string | undefined;
|
|
17
|
+
type?: string | undefined;
|
|
18
|
+
entry?: Record<string, unknown>[] | undefined;
|
|
19
19
|
}
|
|
20
20
|
type ResourceInfo = ResourceInfo.Item[];
|
|
21
21
|
namespace ResourceInfo {
|
|
22
22
|
interface Item {
|
|
23
23
|
/** Original temporary UUID */
|
|
24
|
-
tempId?: string;
|
|
24
|
+
tempId?: string | undefined;
|
|
25
25
|
/** FHIR resource type */
|
|
26
|
-
resourceType?: string;
|
|
26
|
+
resourceType?: string | undefined;
|
|
27
27
|
/** Text excerpt this resource was extracted from */
|
|
28
|
-
description?: string;
|
|
28
|
+
description?: string | undefined;
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export interface Lang2FhirAndCreateResponse {
|
|
2
2
|
/** The created FHIR resource */
|
|
3
|
-
fhir_resource?: Record<string, unknown
|
|
3
|
+
fhir_resource?: Record<string, unknown> | undefined;
|
|
4
4
|
/** ID of the resource in the FHIR server (if successfully stored) */
|
|
5
|
-
fhir_id?: string;
|
|
6
|
-
success?: boolean;
|
|
5
|
+
fhir_id?: string | undefined;
|
|
6
|
+
success?: boolean | undefined;
|
|
7
7
|
/** Status message */
|
|
8
|
-
message?: string;
|
|
8
|
+
message?: string | undefined;
|
|
9
9
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
export interface Lang2FhirAndSearchResponse {
|
|
2
2
|
/** The FHIR resource type identified for the search */
|
|
3
|
-
resource_type?: string;
|
|
3
|
+
resource_type?: string | undefined;
|
|
4
4
|
/** FHIR search parameters in standard format */
|
|
5
|
-
search_params?: string;
|
|
5
|
+
search_params?: string | undefined;
|
|
6
6
|
/** Array of FHIR resources returned from the search */
|
|
7
|
-
fhir_results?: Record<string, unknown>[];
|
|
8
|
-
success?: boolean;
|
|
7
|
+
fhir_results?: Record<string, unknown>[] | undefined;
|
|
8
|
+
success?: boolean | undefined;
|
|
9
9
|
/** Status message */
|
|
10
|
-
message?: string;
|
|
10
|
+
message?: string | undefined;
|
|
11
11
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export interface McpServerResponse {
|
|
2
2
|
/** Whether the MCP server was created successfully */
|
|
3
|
-
success?: boolean;
|
|
3
|
+
success?: boolean | undefined;
|
|
4
4
|
/** Status message */
|
|
5
|
-
message?: string;
|
|
5
|
+
message?: string | undefined;
|
|
6
6
|
/** MCP server data */
|
|
7
|
-
data?: McpServerResponse.Data;
|
|
7
|
+
data?: McpServerResponse.Data | undefined;
|
|
8
8
|
}
|
|
9
9
|
export declare namespace McpServerResponse {
|
|
10
10
|
/**
|
|
@@ -12,12 +12,12 @@ export declare namespace McpServerResponse {
|
|
|
12
12
|
*/
|
|
13
13
|
interface Data {
|
|
14
14
|
/** ID of the MCP server */
|
|
15
|
-
id?: string;
|
|
15
|
+
id?: string | undefined;
|
|
16
16
|
/** Name of the MCP server */
|
|
17
|
-
name?: string;
|
|
17
|
+
name?: string | undefined;
|
|
18
18
|
/** Description of the MCP server */
|
|
19
|
-
description?: string;
|
|
19
|
+
description?: string | undefined;
|
|
20
20
|
/** URL of the MCP server */
|
|
21
|
-
mcp_server_url?: string;
|
|
21
|
+
mcp_server_url?: string | undefined;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export interface McpServerToolCallResponse {
|
|
2
2
|
/** Whether the MCP server tool was called successfully */
|
|
3
|
-
success?: boolean;
|
|
3
|
+
success?: boolean | undefined;
|
|
4
4
|
/** Status message */
|
|
5
|
-
message?: string;
|
|
5
|
+
message?: string | undefined;
|
|
6
6
|
/** Result of the MCP server tool call */
|
|
7
|
-
result?: Record<string, unknown
|
|
7
|
+
result?: Record<string, unknown> | undefined;
|
|
8
8
|
/** Error message if the call failed */
|
|
9
|
-
error?: string;
|
|
9
|
+
error?: string | undefined;
|
|
10
10
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export interface McpServerToolResponse {
|
|
2
2
|
/** Whether the MCP server tool was created successfully */
|
|
3
|
-
success?: boolean;
|
|
3
|
+
success?: boolean | undefined;
|
|
4
4
|
/** Status message */
|
|
5
|
-
message?: string;
|
|
5
|
+
message?: string | undefined;
|
|
6
6
|
/** MCP server tool data */
|
|
7
|
-
data?: McpServerToolResponse.Data;
|
|
7
|
+
data?: McpServerToolResponse.Data | undefined;
|
|
8
8
|
}
|
|
9
9
|
export declare namespace McpServerToolResponse {
|
|
10
10
|
/**
|
|
@@ -12,16 +12,16 @@ export declare namespace McpServerToolResponse {
|
|
|
12
12
|
*/
|
|
13
13
|
interface Data {
|
|
14
14
|
/** ID of the MCP server tool */
|
|
15
|
-
id?: string;
|
|
15
|
+
id?: string | undefined;
|
|
16
16
|
/** Name of the MCP server tool */
|
|
17
|
-
name?: string;
|
|
17
|
+
name?: string | undefined;
|
|
18
18
|
/** Description of the MCP server tool */
|
|
19
|
-
description?: string;
|
|
19
|
+
description?: string | undefined;
|
|
20
20
|
/** Input schema of the MCP server tool */
|
|
21
|
-
input_schema?: Record<string, unknown
|
|
21
|
+
input_schema?: Record<string, unknown> | undefined;
|
|
22
22
|
/** ID of the MCP server that the tool belongs to */
|
|
23
|
-
mcp_server_id?: string;
|
|
23
|
+
mcp_server_id?: string | undefined;
|
|
24
24
|
/** URL of the MCP server */
|
|
25
|
-
mcp_server_url?: string;
|
|
25
|
+
mcp_server_url?: string | undefined;
|
|
26
26
|
}
|
|
27
27
|
}
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export interface SearchConcept {
|
|
5
5
|
/** The FHIR resource type identified for this concept */
|
|
6
|
-
resource_type?: string;
|
|
6
|
+
resource_type?: string | undefined;
|
|
7
7
|
/** FHIR search parameters for this concept */
|
|
8
|
-
search_params?: string;
|
|
8
|
+
search_params?: string | undefined;
|
|
9
9
|
/** Description of what this search represents */
|
|
10
|
-
concept?: string;
|
|
10
|
+
concept?: string | undefined;
|
|
11
11
|
/** Whether this is an exclusion criteria */
|
|
12
|
-
exclude?: boolean;
|
|
12
|
+
exclude?: boolean | undefined;
|
|
13
13
|
}
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
2
3
|
import * as core from "../../../../core/index.js";
|
|
3
4
|
import * as phenoml from "../../../index.js";
|
|
4
|
-
export declare namespace
|
|
5
|
-
|
|
6
|
-
}
|
|
5
|
+
export declare namespace WorkflowsClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
7
|
interface RequestOptions extends BaseRequestOptions {
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
|
-
export declare class
|
|
11
|
-
protected readonly _options:
|
|
12
|
-
constructor(
|
|
10
|
+
export declare class WorkflowsClient {
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<WorkflowsClient.Options>;
|
|
12
|
+
constructor(options?: WorkflowsClient.Options);
|
|
13
13
|
/**
|
|
14
14
|
* Retrieves all workflow definitions for the authenticated user
|
|
15
15
|
*
|
|
16
16
|
* @param {phenoml.workflows.WorkflowsListRequest} request
|
|
17
|
-
* @param {
|
|
17
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
18
|
*
|
|
19
19
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
20
20
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -25,13 +25,13 @@ export declare class Workflows {
|
|
|
25
25
|
* verbose: true
|
|
26
26
|
* })
|
|
27
27
|
*/
|
|
28
|
-
list(request?: phenoml.workflows.WorkflowsListRequest, requestOptions?:
|
|
28
|
+
list(request?: phenoml.workflows.WorkflowsListRequest, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.ListWorkflowsResponse>;
|
|
29
29
|
private __list;
|
|
30
30
|
/**
|
|
31
31
|
* Creates a new workflow definition with graph generation from workflow instructions
|
|
32
32
|
*
|
|
33
33
|
* @param {phenoml.workflows.CreateWorkflowRequest} request
|
|
34
|
-
* @param {
|
|
34
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
35
35
|
*
|
|
36
36
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
37
37
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -51,14 +51,14 @@ export declare class Workflows {
|
|
|
51
51
|
* fhir_provider_id: "550e8400-e29b-41d4-a716-446655440000"
|
|
52
52
|
* })
|
|
53
53
|
*/
|
|
54
|
-
create(request: phenoml.workflows.CreateWorkflowRequest, requestOptions?:
|
|
54
|
+
create(request: phenoml.workflows.CreateWorkflowRequest, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.CreateWorkflowResponse>;
|
|
55
55
|
private __create;
|
|
56
56
|
/**
|
|
57
57
|
* Retrieves a workflow definition by its ID
|
|
58
58
|
*
|
|
59
59
|
* @param {string} id - ID of the workflow to retrieve
|
|
60
60
|
* @param {phenoml.workflows.WorkflowsGetRequest} request
|
|
61
|
-
* @param {
|
|
61
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
62
62
|
*
|
|
63
63
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
64
64
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -70,14 +70,14 @@ export declare class Workflows {
|
|
|
70
70
|
* verbose: true
|
|
71
71
|
* })
|
|
72
72
|
*/
|
|
73
|
-
get(id: string, request?: phenoml.workflows.WorkflowsGetRequest, requestOptions?:
|
|
73
|
+
get(id: string, request?: phenoml.workflows.WorkflowsGetRequest, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.WorkflowsGetResponse>;
|
|
74
74
|
private __get;
|
|
75
75
|
/**
|
|
76
76
|
* Updates an existing workflow definition
|
|
77
77
|
*
|
|
78
78
|
* @param {string} id - ID of the workflow to update
|
|
79
79
|
* @param {phenoml.workflows.UpdateWorkflowRequest} request
|
|
80
|
-
* @param {
|
|
80
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
81
81
|
*
|
|
82
82
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
83
83
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -98,13 +98,13 @@ export declare class Workflows {
|
|
|
98
98
|
* fhir_provider_id: "550e8400-e29b-41d4-a716-446655440000"
|
|
99
99
|
* })
|
|
100
100
|
*/
|
|
101
|
-
update(id: string, request: phenoml.workflows.UpdateWorkflowRequest, requestOptions?:
|
|
101
|
+
update(id: string, request: phenoml.workflows.UpdateWorkflowRequest, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.WorkflowsUpdateResponse>;
|
|
102
102
|
private __update;
|
|
103
103
|
/**
|
|
104
104
|
* Deletes a workflow definition by its ID
|
|
105
105
|
*
|
|
106
106
|
* @param {string} id - ID of the workflow to delete
|
|
107
|
-
* @param {
|
|
107
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
108
108
|
*
|
|
109
109
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
110
110
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -114,14 +114,14 @@ export declare class Workflows {
|
|
|
114
114
|
* @example
|
|
115
115
|
* await client.workflows.delete("id")
|
|
116
116
|
*/
|
|
117
|
-
delete(id: string, requestOptions?:
|
|
117
|
+
delete(id: string, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.WorkflowsDeleteResponse>;
|
|
118
118
|
private __delete;
|
|
119
119
|
/**
|
|
120
120
|
* Executes a workflow with provided input data and returns results
|
|
121
121
|
*
|
|
122
122
|
* @param {string} id - ID of the workflow to execute
|
|
123
123
|
* @param {phenoml.workflows.ExecuteWorkflowRequest} request
|
|
124
|
-
* @param {
|
|
124
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
125
125
|
*
|
|
126
126
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
127
127
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -139,7 +139,6 @@ export declare class Workflows {
|
|
|
139
139
|
* }
|
|
140
140
|
* })
|
|
141
141
|
*/
|
|
142
|
-
execute(id: string, request: phenoml.workflows.ExecuteWorkflowRequest, requestOptions?:
|
|
142
|
+
execute(id: string, request: phenoml.workflows.ExecuteWorkflowRequest, requestOptions?: WorkflowsClient.RequestOptions): core.HttpResponsePromise<phenoml.workflows.ExecuteWorkflowResponse>;
|
|
143
143
|
private __execute;
|
|
144
|
-
protected _getAuthorizationHeader(): Promise<string>;
|
|
145
144
|
}
|
|
@@ -54,21 +54,23 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
54
54
|
return t;
|
|
55
55
|
};
|
|
56
56
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
57
|
-
exports.
|
|
57
|
+
exports.WorkflowsClient = void 0;
|
|
58
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
58
59
|
const headers_js_1 = require("../../../../core/headers.js");
|
|
59
60
|
const core = __importStar(require("../../../../core/index.js"));
|
|
60
61
|
const environments = __importStar(require("../../../../environments.js"));
|
|
62
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
61
63
|
const errors = __importStar(require("../../../../errors/index.js"));
|
|
62
64
|
const phenoml = __importStar(require("../../../index.js"));
|
|
63
|
-
class
|
|
64
|
-
constructor(
|
|
65
|
-
this._options =
|
|
65
|
+
class WorkflowsClient {
|
|
66
|
+
constructor(options = {}) {
|
|
67
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
66
68
|
}
|
|
67
69
|
/**
|
|
68
70
|
* Retrieves all workflow definitions for the authenticated user
|
|
69
71
|
*
|
|
70
72
|
* @param {phenoml.workflows.WorkflowsListRequest} request
|
|
71
|
-
* @param {
|
|
73
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
72
74
|
*
|
|
73
75
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
74
76
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -86,11 +88,11 @@ class Workflows {
|
|
|
86
88
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
87
89
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
88
90
|
const { verbose } = request;
|
|
89
|
-
const _queryParams = {
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
91
|
+
const _queryParams = {
|
|
92
|
+
verbose,
|
|
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);
|
|
94
96
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
95
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, "workflows"),
|
|
96
98
|
method: "GET",
|
|
@@ -124,28 +126,14 @@ class Workflows {
|
|
|
124
126
|
});
|
|
125
127
|
}
|
|
126
128
|
}
|
|
127
|
-
|
|
128
|
-
case "non-json":
|
|
129
|
-
throw new errors.phenomlError({
|
|
130
|
-
statusCode: _response.error.statusCode,
|
|
131
|
-
body: _response.error.rawBody,
|
|
132
|
-
rawResponse: _response.rawResponse,
|
|
133
|
-
});
|
|
134
|
-
case "timeout":
|
|
135
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling GET /workflows.");
|
|
136
|
-
case "unknown":
|
|
137
|
-
throw new errors.phenomlError({
|
|
138
|
-
message: _response.error.errorMessage,
|
|
139
|
-
rawResponse: _response.rawResponse,
|
|
140
|
-
});
|
|
141
|
-
}
|
|
129
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/workflows");
|
|
142
130
|
});
|
|
143
131
|
}
|
|
144
132
|
/**
|
|
145
133
|
* Creates a new workflow definition with graph generation from workflow instructions
|
|
146
134
|
*
|
|
147
135
|
* @param {phenoml.workflows.CreateWorkflowRequest} request
|
|
148
|
-
* @param {
|
|
136
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
149
137
|
*
|
|
150
138
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
151
139
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -172,11 +160,11 @@ class Workflows {
|
|
|
172
160
|
return __awaiter(this, void 0, void 0, function* () {
|
|
173
161
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
174
162
|
const { verbose } = request, _body = __rest(request, ["verbose"]);
|
|
175
|
-
const _queryParams = {
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
163
|
+
const _queryParams = {
|
|
164
|
+
verbose,
|
|
165
|
+
};
|
|
166
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
167
|
+
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);
|
|
180
168
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
181
169
|
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, "workflows"),
|
|
182
170
|
method: "POST",
|
|
@@ -215,21 +203,7 @@ class Workflows {
|
|
|
215
203
|
});
|
|
216
204
|
}
|
|
217
205
|
}
|
|
218
|
-
|
|
219
|
-
case "non-json":
|
|
220
|
-
throw new errors.phenomlError({
|
|
221
|
-
statusCode: _response.error.statusCode,
|
|
222
|
-
body: _response.error.rawBody,
|
|
223
|
-
rawResponse: _response.rawResponse,
|
|
224
|
-
});
|
|
225
|
-
case "timeout":
|
|
226
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling POST /workflows.");
|
|
227
|
-
case "unknown":
|
|
228
|
-
throw new errors.phenomlError({
|
|
229
|
-
message: _response.error.errorMessage,
|
|
230
|
-
rawResponse: _response.rawResponse,
|
|
231
|
-
});
|
|
232
|
-
}
|
|
206
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/workflows");
|
|
233
207
|
});
|
|
234
208
|
}
|
|
235
209
|
/**
|
|
@@ -237,7 +211,7 @@ class Workflows {
|
|
|
237
211
|
*
|
|
238
212
|
* @param {string} id - ID of the workflow to retrieve
|
|
239
213
|
* @param {phenoml.workflows.WorkflowsGetRequest} request
|
|
240
|
-
* @param {
|
|
214
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
241
215
|
*
|
|
242
216
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
243
217
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -256,11 +230,11 @@ class Workflows {
|
|
|
256
230
|
return __awaiter(this, arguments, void 0, function* (id, request = {}, requestOptions) {
|
|
257
231
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
258
232
|
const { verbose } = request;
|
|
259
|
-
const _queryParams = {
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
233
|
+
const _queryParams = {
|
|
234
|
+
verbose,
|
|
235
|
+
};
|
|
236
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
237
|
+
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);
|
|
264
238
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
265
239
|
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, `workflows/${core.url.encodePathParam(id)}`),
|
|
266
240
|
method: "GET",
|
|
@@ -296,21 +270,7 @@ class Workflows {
|
|
|
296
270
|
});
|
|
297
271
|
}
|
|
298
272
|
}
|
|
299
|
-
|
|
300
|
-
case "non-json":
|
|
301
|
-
throw new errors.phenomlError({
|
|
302
|
-
statusCode: _response.error.statusCode,
|
|
303
|
-
body: _response.error.rawBody,
|
|
304
|
-
rawResponse: _response.rawResponse,
|
|
305
|
-
});
|
|
306
|
-
case "timeout":
|
|
307
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling GET /workflows/{id}.");
|
|
308
|
-
case "unknown":
|
|
309
|
-
throw new errors.phenomlError({
|
|
310
|
-
message: _response.error.errorMessage,
|
|
311
|
-
rawResponse: _response.rawResponse,
|
|
312
|
-
});
|
|
313
|
-
}
|
|
273
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/workflows/{id}");
|
|
314
274
|
});
|
|
315
275
|
}
|
|
316
276
|
/**
|
|
@@ -318,7 +278,7 @@ class Workflows {
|
|
|
318
278
|
*
|
|
319
279
|
* @param {string} id - ID of the workflow to update
|
|
320
280
|
* @param {phenoml.workflows.UpdateWorkflowRequest} request
|
|
321
|
-
* @param {
|
|
281
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
322
282
|
*
|
|
323
283
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
324
284
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -346,11 +306,11 @@ class Workflows {
|
|
|
346
306
|
return __awaiter(this, void 0, void 0, function* () {
|
|
347
307
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
348
308
|
const { verbose } = request, _body = __rest(request, ["verbose"]);
|
|
349
|
-
const _queryParams = {
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers,
|
|
309
|
+
const _queryParams = {
|
|
310
|
+
verbose,
|
|
311
|
+
};
|
|
312
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
313
|
+
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);
|
|
354
314
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
355
315
|
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, `workflows/${core.url.encodePathParam(id)}`),
|
|
356
316
|
method: "PUT",
|
|
@@ -391,28 +351,14 @@ class Workflows {
|
|
|
391
351
|
});
|
|
392
352
|
}
|
|
393
353
|
}
|
|
394
|
-
|
|
395
|
-
case "non-json":
|
|
396
|
-
throw new errors.phenomlError({
|
|
397
|
-
statusCode: _response.error.statusCode,
|
|
398
|
-
body: _response.error.rawBody,
|
|
399
|
-
rawResponse: _response.rawResponse,
|
|
400
|
-
});
|
|
401
|
-
case "timeout":
|
|
402
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling PUT /workflows/{id}.");
|
|
403
|
-
case "unknown":
|
|
404
|
-
throw new errors.phenomlError({
|
|
405
|
-
message: _response.error.errorMessage,
|
|
406
|
-
rawResponse: _response.rawResponse,
|
|
407
|
-
});
|
|
408
|
-
}
|
|
354
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "PUT", "/workflows/{id}");
|
|
409
355
|
});
|
|
410
356
|
}
|
|
411
357
|
/**
|
|
412
358
|
* Deletes a workflow definition by its ID
|
|
413
359
|
*
|
|
414
360
|
* @param {string} id - ID of the workflow to delete
|
|
415
|
-
* @param {
|
|
361
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
416
362
|
*
|
|
417
363
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
418
364
|
* @throws {@link phenoml.workflows.ForbiddenError}
|
|
@@ -428,7 +374,8 @@ class Workflows {
|
|
|
428
374
|
__delete(id, requestOptions) {
|
|
429
375
|
return __awaiter(this, void 0, void 0, function* () {
|
|
430
376
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
431
|
-
const
|
|
377
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
378
|
+
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);
|
|
432
379
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
433
380
|
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, `workflows/${core.url.encodePathParam(id)}`),
|
|
434
381
|
method: "DELETE",
|
|
@@ -464,21 +411,7 @@ class Workflows {
|
|
|
464
411
|
});
|
|
465
412
|
}
|
|
466
413
|
}
|
|
467
|
-
|
|
468
|
-
case "non-json":
|
|
469
|
-
throw new errors.phenomlError({
|
|
470
|
-
statusCode: _response.error.statusCode,
|
|
471
|
-
body: _response.error.rawBody,
|
|
472
|
-
rawResponse: _response.rawResponse,
|
|
473
|
-
});
|
|
474
|
-
case "timeout":
|
|
475
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling DELETE /workflows/{id}.");
|
|
476
|
-
case "unknown":
|
|
477
|
-
throw new errors.phenomlError({
|
|
478
|
-
message: _response.error.errorMessage,
|
|
479
|
-
rawResponse: _response.rawResponse,
|
|
480
|
-
});
|
|
481
|
-
}
|
|
414
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/workflows/{id}");
|
|
482
415
|
});
|
|
483
416
|
}
|
|
484
417
|
/**
|
|
@@ -486,7 +419,7 @@ class Workflows {
|
|
|
486
419
|
*
|
|
487
420
|
* @param {string} id - ID of the workflow to execute
|
|
488
421
|
* @param {phenoml.workflows.ExecuteWorkflowRequest} request
|
|
489
|
-
* @param {
|
|
422
|
+
* @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
490
423
|
*
|
|
491
424
|
* @throws {@link phenoml.workflows.BadRequestError}
|
|
492
425
|
* @throws {@link phenoml.workflows.UnauthorizedError}
|
|
@@ -510,7 +443,8 @@ class Workflows {
|
|
|
510
443
|
__execute(id, request, requestOptions) {
|
|
511
444
|
return __awaiter(this, void 0, void 0, function* () {
|
|
512
445
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
513
|
-
const
|
|
446
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
447
|
+
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);
|
|
514
448
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
515
449
|
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, `workflows/${core.url.encodePathParam(id)}/execute`),
|
|
516
450
|
method: "POST",
|
|
@@ -551,27 +485,8 @@ class Workflows {
|
|
|
551
485
|
});
|
|
552
486
|
}
|
|
553
487
|
}
|
|
554
|
-
|
|
555
|
-
case "non-json":
|
|
556
|
-
throw new errors.phenomlError({
|
|
557
|
-
statusCode: _response.error.statusCode,
|
|
558
|
-
body: _response.error.rawBody,
|
|
559
|
-
rawResponse: _response.rawResponse,
|
|
560
|
-
});
|
|
561
|
-
case "timeout":
|
|
562
|
-
throw new errors.phenomlTimeoutError("Timeout exceeded when calling POST /workflows/{id}/execute.");
|
|
563
|
-
case "unknown":
|
|
564
|
-
throw new errors.phenomlError({
|
|
565
|
-
message: _response.error.errorMessage,
|
|
566
|
-
rawResponse: _response.rawResponse,
|
|
567
|
-
});
|
|
568
|
-
}
|
|
569
|
-
});
|
|
570
|
-
}
|
|
571
|
-
_getAuthorizationHeader() {
|
|
572
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
573
|
-
return `Bearer ${yield core.Supplier.get(this._options.token)}`;
|
|
488
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/workflows/{id}/execute");
|
|
574
489
|
});
|
|
575
490
|
}
|
|
576
491
|
}
|
|
577
|
-
exports.
|
|
492
|
+
exports.WorkflowsClient = WorkflowsClient;
|
|
@@ -44,7 +44,11 @@ class BadRequestError extends errors.phenomlError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.BadRequestError = BadRequestError;
|
|
@@ -44,7 +44,11 @@ class ForbiddenError extends errors.phenomlError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.ForbiddenError = ForbiddenError;
|
|
@@ -44,7 +44,11 @@ class InternalServerError extends errors.phenomlError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.InternalServerError = InternalServerError;
|