@hydradb/sdk 2.1.2 → 2.1.4
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/Client.d.ts +5 -2
- package/dist/Client.js +9 -11
- package/dist/api/client/requests/SearchQueryRequest.d.ts +32 -0
- package/dist/api/errors/ConflictError.d.ts +1 -2
- package/dist/api/errors/InternalServerError.d.ts +1 -2
- package/dist/api/resources/connectors/client/Client.d.ts +68 -14
- package/dist/api/resources/connectors/client/Client.js +239 -94
- package/dist/api/resources/connectors/client/requests/HandlerConfigureReq.d.ts +8 -0
- package/dist/api/resources/connectors/client/requests/HandlerConnectorCreateReq.d.ts +7 -7
- package/dist/api/resources/connectors/client/requests/HandlerConnectorUpdateReq.d.ts +20 -0
- package/dist/api/resources/connectors/client/requests/HandlerResourceCreateReq.d.ts +14 -2
- package/dist/api/resources/connectors/client/requests/StatusConnectorsRequest.d.ts +10 -0
- package/dist/api/resources/connectors/client/requests/UpdateResourceAclConnectorsRequest.d.ts +17 -0
- package/dist/api/resources/connectors/client/requests/index.d.ts +3 -0
- package/dist/api/resources/context/client/Client.d.ts +38 -2
- package/dist/api/resources/context/client/Client.js +125 -13
- package/dist/api/resources/context/client/requests/HandlerContextMetadataUpdateRequest.d.ts +18 -4
- package/dist/api/resources/context/client/requests/IngestContextRequest.d.ts +3 -0
- package/dist/api/resources/context/client/requests/InspectContextRequest.d.ts +2 -0
- package/dist/api/resources/context/client/requests/ListV2ListContentRequest.d.ts +10 -0
- package/dist/api/resources/context/client/requests/RelationsContextRequest.d.ts +2 -0
- package/dist/api/resources/context/client/requests/SourcesV2SourceDeleteRequest.d.ts +2 -0
- package/dist/api/resources/context/client/requests/SubgraphContextRequest.d.ts +31 -0
- package/dist/api/resources/context/client/requests/index.d.ts +1 -0
- package/dist/api/resources/context/types/DeleteContextRequestXHydraDbDeleteStatus.d.ts +5 -0
- package/dist/api/resources/context/types/DeleteContextRequestXHydraDbDeleteStatus.js +8 -0
- package/dist/api/resources/context/types/SubgraphContextRequestType.d.ts +5 -0
- package/dist/api/resources/context/types/SubgraphContextRequestType.js +8 -0
- package/dist/api/resources/context/types/index.d.ts +2 -0
- package/dist/api/resources/context/types/index.js +2 -0
- package/dist/api/resources/databases/client/Client.d.ts +17 -0
- package/dist/api/resources/databases/client/Client.js +75 -58
- package/dist/api/resources/databases/client/requests/GetMetadataSchemaDatabasesRequest.d.ts +10 -0
- package/dist/api/resources/databases/client/requests/index.d.ts +1 -0
- package/dist/api/resources/feedback/client/Client.d.ts +32 -0
- package/dist/api/resources/feedback/client/Client.js +129 -0
- package/dist/api/resources/feedback/client/index.d.ts +1 -0
- package/dist/api/resources/feedback/client/index.js +2 -0
- package/dist/api/resources/feedback/exports.d.ts +2 -0
- package/dist/api/resources/feedback/exports.js +21 -0
- package/dist/api/resources/feedback/index.d.ts +1 -0
- package/dist/api/resources/feedback/index.js +17 -0
- package/dist/api/resources/index.d.ts +1 -0
- package/dist/api/resources/index.js +2 -1
- package/dist/api/resources/webhooks/client/Client.d.ts +46 -1
- package/dist/api/resources/webhooks/client/Client.js +207 -1
- package/dist/api/resources/webhooks/client/requests/PostWebhooksSupabaseRequest.d.ts +14 -0
- package/dist/api/resources/webhooks/client/requests/WebhooksSigningSecretRequest.d.ts +8 -0
- package/dist/api/resources/webhooks/client/requests/WebhooksWebhookRegisterRequest.d.ts +3 -1
- package/dist/api/resources/webhooks/client/requests/index.d.ts +2 -0
- package/dist/api/types/ConnectorsResource.d.ts +43 -0
- package/dist/api/types/FeedbackGroundTruth.d.ts +12 -0
- package/dist/api/types/FeedbackGroundTruth.js +3 -0
- package/dist/api/types/FeedbackRating.d.ts +6 -0
- package/dist/api/types/FeedbackRating.js +9 -0
- package/dist/api/types/FeedbackSource.d.ts +5 -0
- package/dist/api/types/FeedbackSource.js +8 -0
- package/dist/api/types/FeedbackSubmitRequest.d.ts +2 -0
- package/dist/api/types/FeedbackSubmitRequest.js +3 -0
- package/dist/api/types/FeedbackSubmitRequestFeedback.d.ts +3 -0
- package/dist/api/types/FeedbackSubmitRequestFeedback.js +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruth.d.ts +4 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruth.js +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruth.d.ts +2 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruth.js +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruthAnswer.d.ts +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruthAnswer.js +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruthSourceIds.d.ts +3 -0
- package/dist/api/types/FeedbackSubmitRequestGroundTruthGroundTruthSourceIds.js +3 -0
- package/dist/api/types/FeedbackSubmitResponse.d.ts +12 -0
- package/dist/api/types/FeedbackSubmitResponse.js +3 -0
- package/dist/api/types/FetchV2SourceFetchResponse.d.ts +7 -1
- package/dist/api/types/GithubComHydradbHydradbApplicationInternalServiceMetadataEditResult.d.ts +36 -2
- package/dist/api/types/GraphEntity.d.ts +12 -0
- package/dist/api/types/GraphGraphRelationsResponse.d.ts +30 -1
- package/dist/api/types/GraphRelationEvidence.d.ts +8 -0
- package/dist/api/types/GraphSourceSubgraphResponse.d.ts +40 -0
- package/dist/api/types/GraphSourceSubgraphResponse.js +3 -0
- package/dist/api/types/GraphSubgraphSource.d.ts +28 -0
- package/dist/api/types/GraphSubgraphSource.js +3 -0
- package/dist/api/types/GraphTripletWithEvidence.d.ts +7 -0
- package/dist/api/types/HandlerCatalogConnector.d.ts +26 -0
- package/dist/api/types/HandlerCatalogConnector.js +3 -0
- package/dist/api/types/HandlerConfigureResponse.d.ts +24 -0
- package/dist/api/types/HandlerConfigureResponse.js +3 -0
- package/dist/api/types/HandlerConfigureResponseMeta.d.ts +4 -0
- package/dist/api/types/HandlerConfigureResponseMeta.js +3 -0
- package/dist/api/types/HandlerConnectorApiView.d.ts +139 -0
- package/dist/api/types/HandlerConnectorApiView.js +3 -0
- package/dist/api/types/HandlerConnectorCatalogResponse.d.ts +4 -0
- package/dist/api/types/HandlerConnectorCatalogResponse.js +3 -0
- package/dist/api/types/HandlerConnectorCreateResponse.d.ts +143 -0
- package/dist/api/types/HandlerConnectorCreateResponse.js +3 -0
- package/dist/api/types/HandlerConnectorDeleteResponse.d.ts +6 -0
- package/dist/api/types/HandlerConnectorDeleteResponse.js +3 -0
- package/dist/api/types/HandlerConnectorListResponse.d.ts +11 -0
- package/dist/api/types/HandlerConnectorListResponse.js +3 -0
- package/dist/api/types/HandlerConnectorResourceStatus.d.ts +37 -0
- package/dist/api/types/HandlerConnectorResourceStatus.js +3 -0
- package/dist/api/types/HandlerConnectorResourcesResponse.d.ts +4 -0
- package/dist/api/types/HandlerConnectorResourcesResponse.js +3 -0
- package/dist/api/types/HandlerConnectorStatusError.d.ts +19 -0
- package/dist/api/types/HandlerConnectorStatusError.js +3 -0
- package/dist/api/types/HandlerConnectorStatusResponse.d.ts +37 -0
- package/dist/api/types/HandlerConnectorStatusResponse.js +3 -0
- package/dist/api/types/HandlerConnectorSyncResponse.d.ts +4 -0
- package/dist/api/types/HandlerConnectorSyncResponse.js +3 -0
- package/dist/api/types/HandlerConnectorUpdateResponse.d.ts +22 -0
- package/dist/api/types/HandlerConnectorUpdateResponse.js +3 -0
- package/dist/api/types/HandlerCredentialsUpdateResponse.d.ts +6 -0
- package/dist/api/types/HandlerCredentialsUpdateResponse.js +3 -0
- package/dist/api/types/HandlerDiscoverResponseBody.d.ts +9 -0
- package/dist/api/types/HandlerDiscoverResponseBody.js +3 -0
- package/dist/api/types/HandlerDiscoveredResourceDto.d.ts +9 -0
- package/dist/api/types/HandlerDiscoveredResourceDto.js +3 -0
- package/dist/api/types/{HandlerEnvelopeListV2SourceListResponse.d.ts → HandlerEnvelopeFeedbackSubmitResponse.d.ts} +2 -2
- package/dist/api/types/HandlerEnvelopeFeedbackSubmitResponse.js +3 -0
- package/dist/api/types/{HandlerEnvelopeIngestionV2SourceUploadResponse.d.ts → HandlerEnvelopeGraphSourceSubgraphResponse.d.ts} +2 -2
- package/dist/api/types/HandlerEnvelopeGraphSourceSubgraphResponse.js +3 -0
- package/dist/api/types/HandlerEnvelopeHandlerSupabaseWebhookAck.d.ts +9 -0
- package/dist/api/types/HandlerEnvelopeHandlerSupabaseWebhookAck.js +3 -0
- package/dist/api/types/HandlerEnvelopeIngestionV2IngestResponse.d.ts +9 -0
- package/dist/api/types/HandlerEnvelopeIngestionV2IngestResponse.js +3 -0
- package/dist/api/types/HandlerEnvelopeListV2ListResponse.d.ts +9 -0
- package/dist/api/types/HandlerEnvelopeListV2ListResponse.js +3 -0
- package/dist/api/types/HandlerEnvelopeTenantsTenantMetadataSchemaResponse.d.ts +9 -0
- package/dist/api/types/HandlerEnvelopeTenantsTenantMetadataSchemaResponse.js +3 -0
- package/dist/api/types/HandlerEnvelopeWebhooksSigningSecretResponse.d.ts +9 -0
- package/dist/api/types/HandlerEnvelopeWebhooksSigningSecretResponse.js +3 -0
- package/dist/api/types/HandlerErrorDetail.d.ts +8 -1
- package/dist/api/types/HandlerErrorEnvelopeSourcesMemoryDeleteResponse.d.ts +10 -0
- package/dist/api/types/HandlerErrorEnvelopeSourcesMemoryDeleteResponse.js +3 -0
- package/dist/api/types/HandlerProviderListResponse.d.ts +4 -0
- package/dist/api/types/HandlerProviderListResponse.js +3 -0
- package/dist/api/types/HandlerResourceDeleteResponse.d.ts +8 -0
- package/dist/api/types/HandlerResourceDeleteResponse.js +3 -0
- package/dist/api/types/HandlerResourceMapping.d.ts +25 -0
- package/dist/api/types/HandlerResourceMappingSyncMode.d.ts +14 -0
- package/dist/api/types/HandlerResourceMappingSyncMode.js +17 -0
- package/dist/api/types/HandlerSupabaseWebhookAck.d.ts +7 -0
- package/dist/api/types/HandlerSupabaseWebhookAck.js +3 -0
- package/dist/api/types/HandlerTableConfigEntry.d.ts +5 -0
- package/dist/api/types/HandlerTableConfigEntry.js +3 -0
- package/dist/api/types/IngestionSourceStatus.d.ts +4 -0
- package/dist/api/types/IngestionSourceStatus.js +4 -0
- package/dist/api/types/IngestionV2IngestResponse.d.ts +21 -0
- package/dist/api/types/IngestionV2IngestResponse.js +3 -0
- package/dist/api/types/IngestionV2IngestResultItem.d.ts +30 -0
- package/dist/api/types/IngestionV2IngestResultItem.js +3 -0
- package/dist/api/types/IngestionV2ProcessingStatus.d.ts +9 -1
- package/dist/api/types/ListContentFilter.d.ts +8 -2
- package/dist/api/types/ListV2ListResponse.d.ts +23 -0
- package/dist/api/types/ListV2ListResponse.js +3 -0
- package/dist/api/types/ListV2MemoryItem.d.ts +66 -0
- package/dist/api/types/ListV2MemoryItem.js +3 -0
- package/dist/api/types/ListV2SourceItem.d.ts +70 -0
- package/dist/api/types/ListV2SourceItem.js +3 -0
- package/dist/api/types/SearchMetadataFilters.d.ts +1 -1
- package/dist/api/types/SearchSourceFact.d.ts +18 -0
- package/dist/api/types/SearchSourceFact.js +3 -0
- package/dist/api/types/SearchSourceFilterInfo.d.ts +15 -0
- package/dist/api/types/SearchSourceFilterInfo.js +3 -0
- package/dist/api/types/SearchSourceInfo.d.ts +3 -1
- package/dist/api/types/SearchTemporalDuration.d.ts +24 -0
- package/dist/api/types/SearchTemporalDuration.js +3 -0
- package/dist/api/types/SearchTemporalFact.d.ts +25 -0
- package/dist/api/types/SearchTemporalFact.js +3 -0
- package/dist/api/types/SearchTemporalFilterInfo.d.ts +27 -0
- package/dist/api/types/SearchTemporalFilterInfo.js +3 -0
- package/dist/api/types/SearchTemporalIntentOverride.d.ts +14 -0
- package/dist/api/types/SearchTemporalIntentOverride.js +3 -0
- package/dist/api/types/SearchV2Chunk.d.ts +3 -1
- package/dist/api/types/SearchV2RetrievalResult.d.ts +13 -0
- package/dist/api/types/SourcesMemoryDeleteResponse.d.ts +9 -1
- package/dist/api/types/TenantsCustomPropertyDefinition.d.ts +0 -2
- package/dist/api/types/TenantsInfraV2.d.ts +2 -2
- package/dist/api/types/TenantsTenantMetadataSchemaResponse.d.ts +7 -0
- package/dist/api/types/TenantsTenantMetadataSchemaResponse.js +3 -0
- package/dist/api/types/WebhooksDeliveryItem.d.ts +6 -0
- package/dist/api/types/WebhooksSigningSecretResponse.d.ts +8 -0
- package/dist/api/types/WebhooksSigningSecretResponse.js +3 -0
- package/dist/api/types/WebhooksWebhookRegisterResponse.d.ts +2 -0
- package/dist/api/types/index.d.ts +55 -7
- package/dist/api/types/index.js +55 -7
- package/dist/helpers/buildString.js +140 -16
- package/dist/helpers/index.d.ts +1 -0
- package/dist/helpers/index.js +6 -1
- package/dist/helpers/verifyWebhook.d.ts +31 -0
- package/dist/helpers/verifyWebhook.js +56 -0
- package/dist/serialization/client/index.d.ts +0 -2
- package/dist/serialization/client/index.js +0 -25
- package/dist/serialization/client/requests/SearchQueryRequest.d.ts +5 -0
- package/dist/serialization/client/requests/SearchQueryRequest.js +5 -0
- package/dist/serialization/resources/connectors/client/index.d.ts +2 -9
- package/dist/serialization/resources/connectors/client/index.js +6 -13
- package/dist/serialization/resources/connectors/client/requests/HandlerConfigureReq.d.ts +2 -0
- package/dist/serialization/resources/connectors/client/requests/HandlerConfigureReq.js +2 -0
- package/dist/serialization/resources/connectors/client/requests/HandlerConnectorCreateReq.d.ts +1 -3
- package/dist/serialization/resources/connectors/client/requests/HandlerConnectorCreateReq.js +1 -3
- package/dist/serialization/resources/connectors/client/requests/HandlerConnectorUpdateReq.d.ts +11 -0
- package/dist/serialization/resources/connectors/client/requests/HandlerConnectorUpdateReq.js +43 -0
- package/dist/serialization/resources/connectors/client/requests/HandlerResourceCreateReq.d.ts +2 -0
- package/dist/serialization/resources/connectors/client/requests/HandlerResourceCreateReq.js +2 -0
- package/dist/serialization/resources/connectors/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/connectors/client/requests/index.js +3 -1
- package/dist/serialization/resources/connectors/client/rotateAConnectorsStoredOAuthRefreshTokenInternalUseOnly.d.ts +6 -0
- package/dist/serialization/resources/connectors/client/{deleteResource.js → rotateAConnectorsStoredOAuthRefreshTokenInternalUseOnly.js} +2 -2
- package/dist/serialization/resources/connectors/client/{rotateAConnectorsStoredOAuthRefreshToken.d.ts → updateResourceAcl.d.ts} +2 -2
- package/dist/serialization/resources/context/client/requests/HandlerContextMetadataUpdateRequest.d.ts +1 -0
- package/dist/serialization/resources/context/client/requests/HandlerContextMetadataUpdateRequest.js +1 -0
- package/dist/serialization/resources/context/client/requests/ListV2ListContentRequest.d.ts +2 -0
- package/dist/serialization/resources/context/client/requests/ListV2ListContentRequest.js +2 -0
- package/dist/serialization/resources/context/client/requests/SourcesV2SourceDeleteRequest.d.ts +1 -1
- package/dist/serialization/resources/context/types/DeleteContextRequestXHydraDbDeleteStatus.d.ts +7 -0
- package/dist/serialization/resources/{connectors/client/delete.js → context/types/DeleteContextRequestXHydraDbDeleteStatus.js} +2 -2
- package/dist/serialization/resources/context/types/SubgraphContextRequestType.d.ts +7 -0
- package/dist/serialization/resources/{connectors/client/configure.js → context/types/SubgraphContextRequestType.js} +2 -2
- package/dist/serialization/resources/context/types/index.d.ts +2 -0
- package/dist/serialization/resources/context/types/index.js +2 -0
- package/dist/serialization/resources/webhooks/client/index.d.ts +1 -0
- package/dist/serialization/resources/webhooks/client/index.js +24 -0
- package/dist/serialization/resources/webhooks/client/requests/WebhooksSigningSecretRequest.d.ts +9 -0
- package/dist/serialization/resources/webhooks/client/requests/WebhooksSigningSecretRequest.js +41 -0
- package/dist/serialization/resources/webhooks/client/requests/WebhooksWebhookRegisterRequest.d.ts +1 -0
- package/dist/serialization/resources/webhooks/client/requests/WebhooksWebhookRegisterRequest.js +1 -0
- package/dist/serialization/resources/webhooks/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/webhooks/client/requests/index.js +3 -1
- package/dist/serialization/resources/webhooks/client/supabaseRowChangeWebhook.d.ts +6 -0
- package/dist/serialization/resources/{connectors/client/discover.js → webhooks/client/supabaseRowChangeWebhook.js} +2 -2
- package/dist/serialization/types/ConnectorsResource.d.ts +6 -0
- package/dist/serialization/types/ConnectorsResource.js +6 -0
- package/dist/serialization/types/FeedbackGroundTruth.d.ts +10 -0
- package/dist/serialization/types/FeedbackGroundTruth.js +42 -0
- package/dist/serialization/types/FeedbackRating.d.ts +7 -0
- package/dist/serialization/{client/catalog.js → types/FeedbackRating.js} +2 -2
- package/dist/serialization/types/FeedbackSource.d.ts +7 -0
- package/dist/serialization/{client/listProviders.js → types/FeedbackSource.js} +2 -2
- package/dist/serialization/types/FeedbackSubmitRequest.d.ts +9 -0
- package/dist/serialization/types/FeedbackSubmitRequest.js +41 -0
- package/dist/serialization/types/FeedbackSubmitRequestFeedback.d.ts +9 -0
- package/dist/serialization/types/FeedbackSubmitRequestFeedback.js +41 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruth.d.ts +10 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruth.js +42 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruthGroundTruth.d.ts +9 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruthGroundTruth.js +44 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruthGroundTruthAnswer.d.ts +9 -0
- package/dist/serialization/types/{ListV2SourceListResponse.js → FeedbackSubmitRequestGroundTruthGroundTruthAnswer.js} +3 -4
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruthGroundTruthSourceIds.d.ts +9 -0
- package/dist/serialization/types/FeedbackSubmitRequestGroundTruthGroundTruthSourceIds.js +41 -0
- package/dist/serialization/types/FeedbackSubmitResponse.d.ts +13 -0
- package/dist/serialization/types/FeedbackSubmitResponse.js +45 -0
- package/dist/serialization/types/GithubComHydradbHydradbApplicationInternalServiceMetadataEditResult.d.ts +7 -0
- package/dist/serialization/types/GithubComHydradbHydradbApplicationInternalServiceMetadataEditResult.js +7 -0
- package/dist/serialization/types/GraphEntity.d.ts +1 -0
- package/dist/serialization/types/GraphEntity.js +1 -0
- package/dist/serialization/types/GraphGraphRelationsResponse.d.ts +2 -0
- package/dist/serialization/types/GraphGraphRelationsResponse.js +2 -0
- package/dist/serialization/types/GraphRelationEvidence.d.ts +1 -0
- package/dist/serialization/types/GraphRelationEvidence.js +1 -0
- package/dist/serialization/types/GraphSourceSubgraphResponse.d.ts +19 -0
- package/dist/serialization/types/GraphSourceSubgraphResponse.js +51 -0
- package/dist/serialization/types/GraphSubgraphSource.d.ts +18 -0
- package/dist/serialization/types/GraphSubgraphSource.js +50 -0
- package/dist/serialization/types/GraphTripletWithEvidence.d.ts +1 -0
- package/dist/serialization/types/GraphTripletWithEvidence.js +1 -0
- package/dist/serialization/types/HandlerCatalogConnector.d.ts +18 -0
- package/dist/serialization/types/HandlerCatalogConnector.js +50 -0
- package/dist/serialization/types/HandlerConfigureResponse.d.ts +16 -0
- package/dist/serialization/types/HandlerConfigureResponse.js +48 -0
- package/dist/serialization/types/HandlerConfigureResponseMeta.d.ts +10 -0
- package/dist/serialization/types/HandlerConfigureResponseMeta.js +42 -0
- package/dist/serialization/types/{ConnectorsConnector.d.ts → HandlerConnectorApiView.d.ts} +16 -7
- package/dist/serialization/types/{ConnectorsConnector.js → HandlerConnectorApiView.js} +16 -7
- package/dist/serialization/types/HandlerConnectorCatalogResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerConnectorCatalogResponse.js +42 -0
- package/dist/serialization/types/HandlerConnectorCreateResponse.d.ts +41 -0
- package/dist/serialization/types/HandlerConnectorCreateResponse.js +73 -0
- package/dist/serialization/types/HandlerConnectorDeleteResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerConnectorDeleteResponse.js +42 -0
- package/dist/serialization/types/HandlerConnectorListResponse.d.ts +11 -0
- package/dist/serialization/types/HandlerConnectorListResponse.js +43 -0
- package/dist/serialization/types/HandlerConnectorResourceStatus.d.ts +20 -0
- package/dist/serialization/types/HandlerConnectorResourceStatus.js +52 -0
- package/dist/serialization/types/HandlerConnectorResourcesResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerConnectorResourcesResponse.js +42 -0
- package/dist/serialization/types/HandlerConnectorStatusError.d.ts +12 -0
- package/dist/serialization/types/HandlerConnectorStatusError.js +44 -0
- package/dist/serialization/types/HandlerConnectorStatusResponse.d.ts +20 -0
- package/dist/serialization/types/HandlerConnectorStatusResponse.js +52 -0
- package/dist/serialization/types/HandlerConnectorSyncResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerConnectorSyncResponse.js +42 -0
- package/dist/serialization/types/HandlerConnectorUpdateResponse.d.ts +15 -0
- package/dist/serialization/types/HandlerConnectorUpdateResponse.js +47 -0
- package/dist/serialization/types/HandlerCredentialsUpdateResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerCredentialsUpdateResponse.js +42 -0
- package/dist/serialization/types/HandlerDiscoverResponseBody.d.ts +13 -0
- package/dist/serialization/types/HandlerDiscoverResponseBody.js +45 -0
- package/dist/serialization/types/HandlerDiscoveredResourceDto.d.ts +12 -0
- package/dist/serialization/types/HandlerDiscoveredResourceDto.js +44 -0
- package/dist/serialization/types/{HandlerEnvelopeListV2SourceListResponse.d.ts → HandlerEnvelopeFeedbackSubmitResponse.d.ts} +4 -4
- package/dist/serialization/types/{HandlerEnvelopeListV2SourceListResponse.js → HandlerEnvelopeFeedbackSubmitResponse.js} +4 -4
- package/dist/serialization/types/HandlerEnvelopeGraphSourceSubgraphResponse.d.ts +15 -0
- package/dist/serialization/types/HandlerEnvelopeGraphSourceSubgraphResponse.js +47 -0
- package/dist/serialization/types/HandlerEnvelopeHandlerSupabaseWebhookAck.d.ts +15 -0
- package/dist/serialization/types/HandlerEnvelopeHandlerSupabaseWebhookAck.js +47 -0
- package/dist/serialization/types/HandlerEnvelopeIngestionV2IngestResponse.d.ts +15 -0
- package/dist/serialization/types/HandlerEnvelopeIngestionV2IngestResponse.js +47 -0
- package/dist/serialization/types/HandlerEnvelopeListV2ListResponse.d.ts +15 -0
- package/dist/serialization/types/{HandlerEnvelopeIngestionV2SourceUploadResponse.js → HandlerEnvelopeListV2ListResponse.js} +4 -4
- package/dist/serialization/types/HandlerEnvelopeTenantsTenantMetadataSchemaResponse.d.ts +15 -0
- package/dist/serialization/types/HandlerEnvelopeTenantsTenantMetadataSchemaResponse.js +47 -0
- package/dist/serialization/types/HandlerEnvelopeWebhooksSigningSecretResponse.d.ts +15 -0
- package/dist/serialization/types/HandlerEnvelopeWebhooksSigningSecretResponse.js +47 -0
- package/dist/serialization/types/HandlerErrorEnvelopeSourcesMemoryDeleteResponse.d.ts +17 -0
- package/dist/serialization/types/HandlerErrorEnvelopeSourcesMemoryDeleteResponse.js +49 -0
- package/dist/serialization/types/HandlerProviderListResponse.d.ts +10 -0
- package/dist/serialization/types/HandlerProviderListResponse.js +42 -0
- package/dist/serialization/types/HandlerResourceDeleteResponse.d.ts +11 -0
- package/dist/serialization/types/HandlerResourceDeleteResponse.js +43 -0
- package/dist/serialization/types/HandlerResourceMapping.d.ts +4 -0
- package/dist/serialization/types/HandlerResourceMapping.js +4 -0
- package/dist/serialization/types/HandlerResourceMappingSyncMode.d.ts +7 -0
- package/dist/serialization/types/HandlerResourceMappingSyncMode.js +39 -0
- package/dist/serialization/types/HandlerSupabaseWebhookAck.d.ts +11 -0
- package/dist/serialization/types/HandlerSupabaseWebhookAck.js +43 -0
- package/dist/serialization/types/HandlerTableConfigEntry.d.ts +11 -0
- package/dist/serialization/types/HandlerTableConfigEntry.js +43 -0
- package/dist/serialization/types/IngestionV2IngestResponse.d.ts +14 -0
- package/dist/serialization/types/{IngestionV2SourceUploadResponse.js → IngestionV2IngestResponse.js} +4 -4
- package/dist/serialization/types/{IngestionV2SourceUploadResultItem.d.ts → IngestionV2IngestResultItem.d.ts} +4 -2
- package/dist/serialization/types/{IngestionV2SourceUploadResultItem.js → IngestionV2IngestResultItem.js} +4 -2
- package/dist/serialization/types/ListV2ListResponse.d.ts +17 -0
- package/dist/serialization/types/{ListSourceListResponse.js → ListV2ListResponse.js} +6 -5
- package/dist/serialization/types/ListV2MemoryItem.d.ts +29 -0
- package/dist/serialization/types/ListV2MemoryItem.js +63 -0
- package/dist/serialization/types/ListV2SourceItem.d.ts +29 -0
- package/dist/serialization/types/ListV2SourceItem.js +63 -0
- package/dist/serialization/types/SearchSourceFact.d.ts +20 -0
- package/dist/serialization/types/SearchSourceFact.js +52 -0
- package/dist/serialization/types/SearchSourceFilterInfo.d.ts +17 -0
- package/dist/serialization/types/SearchSourceFilterInfo.js +49 -0
- package/dist/serialization/types/SearchSourceInfo.d.ts +1 -0
- package/dist/serialization/types/SearchSourceInfo.js +1 -0
- package/dist/serialization/types/SearchTemporalDuration.d.ts +16 -0
- package/dist/serialization/types/SearchTemporalDuration.js +48 -0
- package/dist/serialization/types/SearchTemporalFact.d.ts +20 -0
- package/dist/serialization/types/SearchTemporalFact.js +52 -0
- package/dist/serialization/types/SearchTemporalFilterInfo.d.ts +16 -0
- package/dist/serialization/types/SearchTemporalFilterInfo.js +48 -0
- package/dist/serialization/types/SearchTemporalIntentOverride.d.ts +14 -0
- package/dist/serialization/types/SearchTemporalIntentOverride.js +46 -0
- package/dist/serialization/types/SearchV2Chunk.d.ts +1 -0
- package/dist/serialization/types/SearchV2Chunk.js +1 -0
- package/dist/serialization/types/SearchV2RetrievalResult.d.ts +10 -0
- package/dist/serialization/types/SearchV2RetrievalResult.js +10 -0
- package/dist/serialization/types/TenantsCustomPropertyDefinition.d.ts +0 -1
- package/dist/serialization/types/TenantsCustomPropertyDefinition.js +0 -1
- package/dist/serialization/types/TenantsTenantMetadataSchemaResponse.d.ts +12 -0
- package/dist/serialization/types/TenantsTenantMetadataSchemaResponse.js +44 -0
- package/dist/serialization/types/WebhooksDeliveryItem.d.ts +1 -0
- package/dist/serialization/types/WebhooksDeliveryItem.js +1 -0
- package/dist/serialization/types/WebhooksSigningSecretResponse.d.ts +11 -0
- package/dist/serialization/types/WebhooksSigningSecretResponse.js +43 -0
- package/dist/serialization/types/WebhooksWebhookRegisterResponse.d.ts +1 -0
- package/dist/serialization/types/WebhooksWebhookRegisterResponse.js +1 -0
- package/dist/serialization/types/index.d.ts +55 -7
- package/dist/serialization/types/index.js +55 -7
- package/package.json +1 -1
- package/dist/api/types/ConnectorsConnector.d.ts +0 -58
- package/dist/api/types/IngestionV2SourceUploadResponse.d.ts +0 -13
- package/dist/api/types/IngestionV2SourceUploadResultItem.d.ts +0 -17
- package/dist/api/types/ListSourceListResponse.d.ts +0 -12
- package/dist/api/types/ListV2SourceListResponse.d.ts +0 -4
- package/dist/serialization/client/catalog.d.ts +0 -6
- package/dist/serialization/client/listProviders.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/configure.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/delete.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/deleteResource.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/discover.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/discoverPreview.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/discoverPreview.js +0 -39
- package/dist/serialization/resources/connectors/client/list.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/list.js +0 -39
- package/dist/serialization/resources/connectors/client/listResources.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/listResources.js +0 -39
- package/dist/serialization/resources/connectors/client/sync.d.ts +0 -6
- package/dist/serialization/resources/connectors/client/sync.js +0 -39
- package/dist/serialization/types/HandlerEnvelopeIngestionV2SourceUploadResponse.d.ts +0 -15
- package/dist/serialization/types/IngestionV2SourceUploadResponse.d.ts +0 -14
- package/dist/serialization/types/ListSourceListResponse.d.ts +0 -14
- package/dist/serialization/types/ListV2SourceListResponse.d.ts +0 -10
- /package/dist/api/{types/ConnectorsConnector.js → resources/connectors/client/requests/HandlerConnectorUpdateReq.js} +0 -0
- /package/dist/api/{types/HandlerEnvelopeIngestionV2SourceUploadResponse.js → resources/connectors/client/requests/StatusConnectorsRequest.js} +0 -0
- /package/dist/api/{types/HandlerEnvelopeListV2SourceListResponse.js → resources/connectors/client/requests/UpdateResourceAclConnectorsRequest.js} +0 -0
- /package/dist/api/{types/IngestionV2SourceUploadResponse.js → resources/context/client/requests/SubgraphContextRequest.js} +0 -0
- /package/dist/api/{types/IngestionV2SourceUploadResultItem.js → resources/databases/client/requests/GetMetadataSchemaDatabasesRequest.js} +0 -0
- /package/dist/api/{types/ListSourceListResponse.js → resources/webhooks/client/requests/PostWebhooksSupabaseRequest.js} +0 -0
- /package/dist/api/{types/ListV2SourceListResponse.js → resources/webhooks/client/requests/WebhooksSigningSecretRequest.js} +0 -0
- /package/dist/serialization/resources/connectors/client/{rotateAConnectorsStoredOAuthRefreshToken.js → updateResourceAcl.js} +0 -0
|
@@ -91,13 +91,7 @@ class DatabasesClient {
|
|
|
91
91
|
if (_response.error.reason === "status-code") {
|
|
92
92
|
switch (_response.error.statusCode) {
|
|
93
93
|
case 500:
|
|
94
|
-
throw new HydraDB.InternalServerError(
|
|
95
|
-
unrecognizedObjectKeys: "passthrough",
|
|
96
|
-
allowUnrecognizedUnionMembers: true,
|
|
97
|
-
allowUnrecognizedEnumValues: true,
|
|
98
|
-
skipValidation: true,
|
|
99
|
-
breadcrumbsPrefix: ["response"],
|
|
100
|
-
}), _response.rawResponse);
|
|
94
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
101
95
|
default:
|
|
102
96
|
throw new errors.HydraDBError({
|
|
103
97
|
statusCode: _response.error.statusCode,
|
|
@@ -178,21 +172,9 @@ class DatabasesClient {
|
|
|
178
172
|
breadcrumbsPrefix: ["response"],
|
|
179
173
|
}), _response.rawResponse);
|
|
180
174
|
case 409:
|
|
181
|
-
throw new HydraDB.ConflictError(
|
|
182
|
-
unrecognizedObjectKeys: "passthrough",
|
|
183
|
-
allowUnrecognizedUnionMembers: true,
|
|
184
|
-
allowUnrecognizedEnumValues: true,
|
|
185
|
-
skipValidation: true,
|
|
186
|
-
breadcrumbsPrefix: ["response"],
|
|
187
|
-
}), _response.rawResponse);
|
|
175
|
+
throw new HydraDB.ConflictError(_response.error.body, _response.rawResponse);
|
|
188
176
|
case 500:
|
|
189
|
-
throw new HydraDB.InternalServerError(
|
|
190
|
-
unrecognizedObjectKeys: "passthrough",
|
|
191
|
-
allowUnrecognizedUnionMembers: true,
|
|
192
|
-
allowUnrecognizedEnumValues: true,
|
|
193
|
-
skipValidation: true,
|
|
194
|
-
breadcrumbsPrefix: ["response"],
|
|
195
|
-
}), _response.rawResponse);
|
|
177
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
196
178
|
default:
|
|
197
179
|
throw new errors.HydraDBError({
|
|
198
180
|
statusCode: _response.error.statusCode,
|
|
@@ -270,13 +252,7 @@ class DatabasesClient {
|
|
|
270
252
|
case 404:
|
|
271
253
|
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
272
254
|
case 500:
|
|
273
|
-
throw new HydraDB.InternalServerError(
|
|
274
|
-
unrecognizedObjectKeys: "passthrough",
|
|
275
|
-
allowUnrecognizedUnionMembers: true,
|
|
276
|
-
allowUnrecognizedEnumValues: true,
|
|
277
|
-
skipValidation: true,
|
|
278
|
-
breadcrumbsPrefix: ["response"],
|
|
279
|
-
}), _response.rawResponse);
|
|
255
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
280
256
|
default:
|
|
281
257
|
throw new errors.HydraDBError({
|
|
282
258
|
statusCode: _response.error.statusCode,
|
|
@@ -354,13 +330,7 @@ class DatabasesClient {
|
|
|
354
330
|
case 404:
|
|
355
331
|
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
356
332
|
case 500:
|
|
357
|
-
throw new HydraDB.InternalServerError(
|
|
358
|
-
unrecognizedObjectKeys: "passthrough",
|
|
359
|
-
allowUnrecognizedUnionMembers: true,
|
|
360
|
-
allowUnrecognizedEnumValues: true,
|
|
361
|
-
skipValidation: true,
|
|
362
|
-
breadcrumbsPrefix: ["response"],
|
|
363
|
-
}), _response.rawResponse);
|
|
333
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
364
334
|
default:
|
|
365
335
|
throw new errors.HydraDBError({
|
|
366
336
|
statusCode: _response.error.statusCode,
|
|
@@ -438,13 +408,7 @@ class DatabasesClient {
|
|
|
438
408
|
case 404:
|
|
439
409
|
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
440
410
|
case 500:
|
|
441
|
-
throw new HydraDB.InternalServerError(
|
|
442
|
-
unrecognizedObjectKeys: "passthrough",
|
|
443
|
-
allowUnrecognizedUnionMembers: true,
|
|
444
|
-
allowUnrecognizedEnumValues: true,
|
|
445
|
-
skipValidation: true,
|
|
446
|
-
breadcrumbsPrefix: ["response"],
|
|
447
|
-
}), _response.rawResponse);
|
|
411
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
448
412
|
default:
|
|
449
413
|
throw new errors.HydraDBError({
|
|
450
414
|
statusCode: _response.error.statusCode,
|
|
@@ -522,13 +486,78 @@ class DatabasesClient {
|
|
|
522
486
|
case 404:
|
|
523
487
|
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
524
488
|
case 500:
|
|
525
|
-
throw new HydraDB.InternalServerError(
|
|
489
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
490
|
+
default:
|
|
491
|
+
throw new errors.HydraDBError({
|
|
492
|
+
statusCode: _response.error.statusCode,
|
|
493
|
+
body: _response.error.body,
|
|
494
|
+
rawResponse: _response.rawResponse,
|
|
495
|
+
});
|
|
496
|
+
}
|
|
497
|
+
}
|
|
498
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/databases/status");
|
|
499
|
+
}
|
|
500
|
+
/**
|
|
501
|
+
* Read the database's declared metadata schema fields. Returns the same field shape accepted by database creation and by Update Metadata Schema, so the response round-trips into add_fields.
|
|
502
|
+
*
|
|
503
|
+
* @param {HydraDB.GetMetadataSchemaDatabasesRequest} request
|
|
504
|
+
* @param {DatabasesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
505
|
+
*
|
|
506
|
+
* @throws {@link HydraDB.BadRequestError}
|
|
507
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
508
|
+
* @throws {@link HydraDB.InternalServerError}
|
|
509
|
+
*
|
|
510
|
+
* @example
|
|
511
|
+
* await client.databases.getMetadataSchema({
|
|
512
|
+
* database: "acme_corp"
|
|
513
|
+
* })
|
|
514
|
+
*/
|
|
515
|
+
getMetadataSchema(request, requestOptions) {
|
|
516
|
+
return core.HttpResponsePromise.fromPromise(this.__getMetadataSchema(request, requestOptions));
|
|
517
|
+
}
|
|
518
|
+
async __getMetadataSchema(request, requestOptions) {
|
|
519
|
+
const { database } = request;
|
|
520
|
+
const _authRequest = await this._options.authProvider.getAuthRequest();
|
|
521
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, this._options?.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ "API-Version": requestOptions?.apiVersion ?? this._options?.apiVersion ?? "2" }), requestOptions?.headers);
|
|
522
|
+
const _response = await core.fetcher({
|
|
523
|
+
url: core.url.join((await core.Supplier.get(this._options.baseUrl)) ??
|
|
524
|
+
(await core.Supplier.get(this._options.environment)) ??
|
|
525
|
+
environments.HydraDBEnvironment.Default, `databases/${core.url.encodePathParam(database)}/metadata-schema`),
|
|
526
|
+
method: "GET",
|
|
527
|
+
headers: _headers,
|
|
528
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions?.queryParams).build(),
|
|
529
|
+
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
|
|
530
|
+
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
|
|
531
|
+
abortSignal: requestOptions?.abortSignal,
|
|
532
|
+
fetchFn: this._options?.fetch,
|
|
533
|
+
logging: this._options.logging,
|
|
534
|
+
});
|
|
535
|
+
if (_response.ok) {
|
|
536
|
+
return {
|
|
537
|
+
data: serializers.HandlerEnvelopeTenantsTenantMetadataSchemaResponse.parseOrThrow(_response.body, {
|
|
538
|
+
unrecognizedObjectKeys: "passthrough",
|
|
539
|
+
allowUnrecognizedUnionMembers: true,
|
|
540
|
+
allowUnrecognizedEnumValues: true,
|
|
541
|
+
skipValidation: true,
|
|
542
|
+
breadcrumbsPrefix: ["response"],
|
|
543
|
+
}),
|
|
544
|
+
rawResponse: _response.rawResponse,
|
|
545
|
+
};
|
|
546
|
+
}
|
|
547
|
+
if (_response.error.reason === "status-code") {
|
|
548
|
+
switch (_response.error.statusCode) {
|
|
549
|
+
case 400:
|
|
550
|
+
throw new HydraDB.BadRequestError(serializers.HandlerErrorResponse.parseOrThrow(_response.error.body, {
|
|
526
551
|
unrecognizedObjectKeys: "passthrough",
|
|
527
552
|
allowUnrecognizedUnionMembers: true,
|
|
528
553
|
allowUnrecognizedEnumValues: true,
|
|
529
554
|
skipValidation: true,
|
|
530
555
|
breadcrumbsPrefix: ["response"],
|
|
531
556
|
}), _response.rawResponse);
|
|
557
|
+
case 404:
|
|
558
|
+
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
559
|
+
case 500:
|
|
560
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
532
561
|
default:
|
|
533
562
|
throw new errors.HydraDBError({
|
|
534
563
|
statusCode: _response.error.statusCode,
|
|
@@ -537,7 +566,7 @@ class DatabasesClient {
|
|
|
537
566
|
});
|
|
538
567
|
}
|
|
539
568
|
}
|
|
540
|
-
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/databases/
|
|
569
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/databases/{database}/metadata-schema");
|
|
541
570
|
}
|
|
542
571
|
/**
|
|
543
572
|
* Add new metadata schema fields to an existing database. Additive only — existing fields cannot be deleted or retyped.
|
|
@@ -606,21 +635,9 @@ class DatabasesClient {
|
|
|
606
635
|
case 404:
|
|
607
636
|
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
608
637
|
case 409:
|
|
609
|
-
throw new HydraDB.ConflictError(
|
|
610
|
-
unrecognizedObjectKeys: "passthrough",
|
|
611
|
-
allowUnrecognizedUnionMembers: true,
|
|
612
|
-
allowUnrecognizedEnumValues: true,
|
|
613
|
-
skipValidation: true,
|
|
614
|
-
breadcrumbsPrefix: ["response"],
|
|
615
|
-
}), _response.rawResponse);
|
|
638
|
+
throw new HydraDB.ConflictError(_response.error.body, _response.rawResponse);
|
|
616
639
|
case 500:
|
|
617
|
-
throw new HydraDB.InternalServerError(
|
|
618
|
-
unrecognizedObjectKeys: "passthrough",
|
|
619
|
-
allowUnrecognizedUnionMembers: true,
|
|
620
|
-
allowUnrecognizedEnumValues: true,
|
|
621
|
-
skipValidation: true,
|
|
622
|
-
breadcrumbsPrefix: ["response"],
|
|
623
|
-
}), _response.rawResponse);
|
|
640
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
624
641
|
default:
|
|
625
642
|
throw new errors.HydraDBError({
|
|
626
643
|
statusCode: _response.error.statusCode,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export type { CollectionsDatabasesRequest } from "./CollectionsDatabasesRequest.js";
|
|
2
2
|
export type { DeleteDatabasesRequest } from "./DeleteDatabasesRequest.js";
|
|
3
|
+
export type { GetMetadataSchemaDatabasesRequest } from "./GetMetadataSchemaDatabasesRequest.js";
|
|
3
4
|
export type { StatsDatabasesRequest } from "./StatsDatabasesRequest.js";
|
|
4
5
|
export type { StatusDatabasesRequest } from "./StatusDatabasesRequest.js";
|
|
5
6
|
export type { TenantsTenantCreateRequest } from "./TenantsTenantCreateRequest.js";
|
|
@@ -0,0 +1,32 @@
|
|
|
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 HydraDB from "../../../index.js";
|
|
5
|
+
export declare namespace FeedbackClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export declare class FeedbackClient {
|
|
11
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<FeedbackClient.Options>;
|
|
12
|
+
constructor(options?: FeedbackClient.Options);
|
|
13
|
+
/**
|
|
14
|
+
* Record feedback about a query that already ran, correlated by the `request_id` returned in that query's `response.meta.request_id`. Accepts a free-text comment plus an optional positive/negative/neutral rating, and is intended for both end users and agents (`source`). Feeds internal retrieval-quality validation; it does not change the result of the original query.
|
|
15
|
+
*
|
|
16
|
+
* @param {HydraDB.FeedbackSubmitRequest} request
|
|
17
|
+
* @param {FeedbackClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
|
+
*
|
|
19
|
+
* @throws {@link HydraDB.BadRequestError}
|
|
20
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
21
|
+
* @throws {@link HydraDB.InternalServerError}
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* await client.feedback.submit({
|
|
25
|
+
* feedback: {
|
|
26
|
+
* "key": "value"
|
|
27
|
+
* }
|
|
28
|
+
* })
|
|
29
|
+
*/
|
|
30
|
+
submit(request: HydraDB.FeedbackSubmitRequest, requestOptions?: FeedbackClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeFeedbackSubmitResponse>;
|
|
31
|
+
private __submit;
|
|
32
|
+
}
|
|
@@ -0,0 +1,129 @@
|
|
|
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
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.FeedbackClient = void 0;
|
|
38
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
39
|
+
const headers_js_1 = require("../../../../core/headers.js");
|
|
40
|
+
const core = __importStar(require("../../../../core/index.js"));
|
|
41
|
+
const environments = __importStar(require("../../../../environments.js"));
|
|
42
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
43
|
+
const errors = __importStar(require("../../../../errors/index.js"));
|
|
44
|
+
const serializers = __importStar(require("../../../../serialization/index.js"));
|
|
45
|
+
const HydraDB = __importStar(require("../../../index.js"));
|
|
46
|
+
class FeedbackClient {
|
|
47
|
+
constructor(options = {}) {
|
|
48
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Record feedback about a query that already ran, correlated by the `request_id` returned in that query's `response.meta.request_id`. Accepts a free-text comment plus an optional positive/negative/neutral rating, and is intended for both end users and agents (`source`). Feeds internal retrieval-quality validation; it does not change the result of the original query.
|
|
52
|
+
*
|
|
53
|
+
* @param {HydraDB.FeedbackSubmitRequest} request
|
|
54
|
+
* @param {FeedbackClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
55
|
+
*
|
|
56
|
+
* @throws {@link HydraDB.BadRequestError}
|
|
57
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
58
|
+
* @throws {@link HydraDB.InternalServerError}
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* await client.feedback.submit({
|
|
62
|
+
* feedback: {
|
|
63
|
+
* "key": "value"
|
|
64
|
+
* }
|
|
65
|
+
* })
|
|
66
|
+
*/
|
|
67
|
+
submit(request, requestOptions) {
|
|
68
|
+
return core.HttpResponsePromise.fromPromise(this.__submit(request, requestOptions));
|
|
69
|
+
}
|
|
70
|
+
async __submit(request, requestOptions) {
|
|
71
|
+
const _authRequest = await this._options.authProvider.getAuthRequest();
|
|
72
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, this._options?.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ "API-Version": requestOptions?.apiVersion ?? this._options?.apiVersion ?? "2" }), requestOptions?.headers);
|
|
73
|
+
const _response = await core.fetcher({
|
|
74
|
+
url: core.url.join((await core.Supplier.get(this._options.baseUrl)) ??
|
|
75
|
+
(await core.Supplier.get(this._options.environment)) ??
|
|
76
|
+
environments.HydraDBEnvironment.Default, "feedback"),
|
|
77
|
+
method: "POST",
|
|
78
|
+
headers: _headers,
|
|
79
|
+
contentType: "application/json",
|
|
80
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions?.queryParams).build(),
|
|
81
|
+
requestType: "json",
|
|
82
|
+
body: serializers.FeedbackSubmitRequest.jsonOrThrow(request, {
|
|
83
|
+
unrecognizedObjectKeys: "strip",
|
|
84
|
+
omitUndefined: true,
|
|
85
|
+
}),
|
|
86
|
+
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
|
|
87
|
+
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
|
|
88
|
+
abortSignal: requestOptions?.abortSignal,
|
|
89
|
+
fetchFn: this._options?.fetch,
|
|
90
|
+
logging: this._options.logging,
|
|
91
|
+
});
|
|
92
|
+
if (_response.ok) {
|
|
93
|
+
return {
|
|
94
|
+
data: serializers.HandlerEnvelopeFeedbackSubmitResponse.parseOrThrow(_response.body, {
|
|
95
|
+
unrecognizedObjectKeys: "passthrough",
|
|
96
|
+
allowUnrecognizedUnionMembers: true,
|
|
97
|
+
allowUnrecognizedEnumValues: true,
|
|
98
|
+
skipValidation: true,
|
|
99
|
+
breadcrumbsPrefix: ["response"],
|
|
100
|
+
}),
|
|
101
|
+
rawResponse: _response.rawResponse,
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
if (_response.error.reason === "status-code") {
|
|
105
|
+
switch (_response.error.statusCode) {
|
|
106
|
+
case 400:
|
|
107
|
+
throw new HydraDB.BadRequestError(serializers.HandlerErrorResponse.parseOrThrow(_response.error.body, {
|
|
108
|
+
unrecognizedObjectKeys: "passthrough",
|
|
109
|
+
allowUnrecognizedUnionMembers: true,
|
|
110
|
+
allowUnrecognizedEnumValues: true,
|
|
111
|
+
skipValidation: true,
|
|
112
|
+
breadcrumbsPrefix: ["response"],
|
|
113
|
+
}), _response.rawResponse);
|
|
114
|
+
case 404:
|
|
115
|
+
throw new HydraDB.NotFoundError(_response.error.body, _response.rawResponse);
|
|
116
|
+
case 500:
|
|
117
|
+
throw new HydraDB.InternalServerError(_response.error.body, _response.rawResponse);
|
|
118
|
+
default:
|
|
119
|
+
throw new errors.HydraDBError({
|
|
120
|
+
statusCode: _response.error.statusCode,
|
|
121
|
+
body: _response.error.body,
|
|
122
|
+
rawResponse: _response.rawResponse,
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/feedback");
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
exports.FeedbackClient = FeedbackClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
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.FeedbackClient = void 0;
|
|
19
|
+
var Client_js_1 = require("./client/Client.js");
|
|
20
|
+
Object.defineProperty(exports, "FeedbackClient", { enumerable: true, get: function () { return Client_js_1.FeedbackClient; } });
|
|
21
|
+
__exportStar(require("./client/index.js"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/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("./client/index.js"), exports);
|
|
@@ -5,5 +5,6 @@ export * as context from "./context/index.js";
|
|
|
5
5
|
export * from "./context/types/index.js";
|
|
6
6
|
export * from "./databases/client/requests/index.js";
|
|
7
7
|
export * as databases from "./databases/index.js";
|
|
8
|
+
export * as feedback from "./feedback/index.js";
|
|
8
9
|
export * from "./webhooks/client/requests/index.js";
|
|
9
10
|
export * as webhooks from "./webhooks/index.js";
|
|
@@ -36,7 +36,7 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
36
36
|
};
|
|
37
37
|
})();
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.webhooks = exports.databases = exports.context = exports.connectors = void 0;
|
|
39
|
+
exports.webhooks = exports.feedback = exports.databases = exports.context = exports.connectors = void 0;
|
|
40
40
|
__exportStar(require("./connectors/client/requests/index.js"), exports);
|
|
41
41
|
exports.connectors = __importStar(require("./connectors/index.js"));
|
|
42
42
|
__exportStar(require("./context/client/requests/index.js"), exports);
|
|
@@ -44,5 +44,6 @@ exports.context = __importStar(require("./context/index.js"));
|
|
|
44
44
|
__exportStar(require("./context/types/index.js"), exports);
|
|
45
45
|
__exportStar(require("./databases/client/requests/index.js"), exports);
|
|
46
46
|
exports.databases = __importStar(require("./databases/index.js"));
|
|
47
|
+
exports.feedback = __importStar(require("./feedback/index.js"));
|
|
47
48
|
__exportStar(require("./webhooks/client/requests/index.js"), exports);
|
|
48
49
|
exports.webhooks = __importStar(require("./webhooks/index.js"));
|
|
@@ -21,7 +21,7 @@ export declare class WebhooksClient {
|
|
|
21
21
|
get(requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeWebhooksWebhookGetResponse>;
|
|
22
22
|
private __get;
|
|
23
23
|
/**
|
|
24
|
-
* Register the indexing webhook for this API key's org.
|
|
24
|
+
* Register the indexing webhook for this API key's org. Set `generate_signing_secret` to register and enable signing in one request; the secret is returned once on the response. Omitting `signing_secret` preserves any secret already configured - to disable signing, call DELETE /webhooks/indexing/signing-secret.
|
|
25
25
|
*
|
|
26
26
|
* @param {HydraDB.WebhooksWebhookRegisterRequest} request
|
|
27
27
|
* @param {WebhooksClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -86,6 +86,32 @@ export declare class WebhooksClient {
|
|
|
86
86
|
*/
|
|
87
87
|
retryDelivery(request: HydraDB.RetryDeliveryWebhooksRequest, requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeWebhooksRetryResponse>;
|
|
88
88
|
private __retryDelivery;
|
|
89
|
+
/**
|
|
90
|
+
* Generates a signing secret, or stores one you supply. The plaintext is returned exactly once and cannot be retrieved afterwards. Takes effect immediately, so rotate only once your receiver accepts the new secret.
|
|
91
|
+
*
|
|
92
|
+
* @param {HydraDB.WebhooksSigningSecretRequest} request
|
|
93
|
+
* @param {WebhooksClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
94
|
+
*
|
|
95
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
96
|
+
* @throws {@link HydraDB.UnprocessableEntityError}
|
|
97
|
+
*
|
|
98
|
+
* @example
|
|
99
|
+
* await client.webhooks.setSigningSecret()
|
|
100
|
+
*/
|
|
101
|
+
setSigningSecret(request?: HydraDB.WebhooksSigningSecretRequest, requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeWebhooksSigningSecretResponse>;
|
|
102
|
+
private __setSigningSecret;
|
|
103
|
+
/**
|
|
104
|
+
* Removes the stored signing secret. Deliveries stop carrying the X-HydraDB-Signature header. This is the only way to disable signing - editing a registration never clears the secret.
|
|
105
|
+
*
|
|
106
|
+
* @param {WebhooksClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
107
|
+
*
|
|
108
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
109
|
+
*
|
|
110
|
+
* @example
|
|
111
|
+
* await client.webhooks.clearSigningSecret()
|
|
112
|
+
*/
|
|
113
|
+
clearSigningSecret(requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeWebhooksWebhookRegisterResponse>;
|
|
114
|
+
private __clearSigningSecret;
|
|
89
115
|
/**
|
|
90
116
|
* Send a test webhook event to the registered endpoint to verify connectivity.
|
|
91
117
|
*
|
|
@@ -98,4 +124,23 @@ export declare class WebhooksClient {
|
|
|
98
124
|
*/
|
|
99
125
|
test(requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeWebhooksWebhookTestResponse>;
|
|
100
126
|
private __test;
|
|
127
|
+
/**
|
|
128
|
+
* Ingest a Supabase INSERT/UPDATE/DELETE row change into the graph.
|
|
129
|
+
*
|
|
130
|
+
* @param {HydraDB.PostWebhooksSupabaseRequest} request
|
|
131
|
+
* @param {WebhooksClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
132
|
+
*
|
|
133
|
+
* @throws {@link HydraDB.BadRequestError}
|
|
134
|
+
* @throws {@link HydraDB.NotFoundError}
|
|
135
|
+
*
|
|
136
|
+
* @example
|
|
137
|
+
* await client.webhooks.supabaseRowChangeWebhook({
|
|
138
|
+
* hydraDbConnector: "X-HydraDB-Connector",
|
|
139
|
+
* body: {
|
|
140
|
+
* "key": "value"
|
|
141
|
+
* }
|
|
142
|
+
* })
|
|
143
|
+
*/
|
|
144
|
+
supabaseRowChangeWebhook(request: HydraDB.PostWebhooksSupabaseRequest, requestOptions?: WebhooksClient.RequestOptions): core.HttpResponsePromise<HydraDB.HandlerEnvelopeHandlerSupabaseWebhookAck>;
|
|
145
|
+
private __supabaseRowChangeWebhook;
|
|
101
146
|
}
|