@airweave/sdk 0.2.52 → 0.3.41
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/README.md +20 -6
- package/dist/cjs/Client.d.ts +48 -0
- package/dist/cjs/Client.js +76 -0
- package/dist/cjs/api/errors/UnprocessableEntityError.d.ts +9 -0
- package/dist/cjs/api/errors/UnprocessableEntityError.js +52 -0
- package/dist/cjs/api/errors/index.d.ts +1 -0
- package/dist/cjs/api/errors/index.js +17 -0
- package/dist/cjs/api/index.d.ts +3 -0
- package/dist/cjs/api/index.js +19 -0
- package/dist/cjs/api/resources/collections/client/Client.d.ts +158 -0
- package/dist/cjs/api/resources/collections/client/Client.js +537 -0
- package/dist/cjs/api/resources/collections/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/collections/client/index.js +17 -0
- package/dist/cjs/api/resources/collections/client/requests/CollectionCreate.d.ts +16 -0
- package/dist/cjs/api/resources/collections/client/requests/CollectionUpdate.d.ts +13 -0
- package/dist/cjs/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.d.ts +13 -0
- package/dist/cjs/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.d.ts +17 -0
- package/dist/cjs/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.d.ts +20 -0
- package/dist/cjs/api/resources/collections/client/requests/index.d.ts +5 -0
- package/dist/cjs/api/resources/collections/index.d.ts +1 -0
- package/dist/cjs/api/resources/collections/index.js +17 -0
- package/dist/cjs/api/resources/index.d.ts +7 -0
- package/dist/cjs/api/resources/index.js +46 -0
- package/dist/cjs/api/resources/sourceConnections/client/Client.d.ts +208 -0
- package/dist/cjs/api/resources/sourceConnections/client/Client.js +689 -0
- package/dist/cjs/api/resources/sourceConnections/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/sourceConnections/client/index.js +17 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.ts +11 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.d.ts +13 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.d.ts +13 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.d.ts +21 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/SourceConnectionCreate.d.ts +29 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.ts +30 -0
- package/dist/cjs/api/resources/sourceConnections/client/requests/index.d.ts +6 -0
- package/dist/cjs/api/resources/sourceConnections/index.d.ts +1 -0
- package/dist/cjs/api/resources/sourceConnections/index.js +17 -0
- package/dist/cjs/api/resources/sources/client/Client.d.ts +65 -0
- package/dist/cjs/api/resources/sources/client/Client.js +181 -0
- package/dist/cjs/api/resources/sources/index.d.ts +1 -0
- package/dist/cjs/api/resources/sources/index.js +17 -0
- package/dist/cjs/api/resources/whiteLabels/client/Client.d.ts +190 -0
- package/dist/cjs/api/resources/whiteLabels/client/Client.js +600 -0
- package/dist/cjs/api/resources/whiteLabels/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/whiteLabels/client/index.js +17 -0
- package/dist/cjs/api/resources/whiteLabels/client/requests/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.ts +16 -0
- package/dist/cjs/api/resources/whiteLabels/client/requests/WhiteLabelCreate.d.ts +28 -0
- package/dist/cjs/api/resources/whiteLabels/client/requests/WhiteLabelUpdate.d.ts +23 -0
- package/dist/cjs/api/resources/whiteLabels/client/requests/index.d.ts +3 -0
- package/dist/cjs/api/resources/whiteLabels/index.d.ts +1 -0
- package/dist/cjs/api/resources/whiteLabels/index.js +17 -0
- package/dist/cjs/api/types/ApiKey.d.ts +17 -0
- package/dist/cjs/api/types/ApiKeyCreate.d.ts +10 -0
- package/dist/cjs/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.ts +13 -0
- package/dist/cjs/api/types/Collection.d.ts +30 -0
- package/dist/cjs/api/types/Connection.d.ts +18 -0
- package/dist/cjs/api/types/DagEdge.d.ts +15 -0
- package/dist/cjs/api/types/DagEdgeCreate.d.ts +10 -0
- package/dist/cjs/api/types/DagNode.d.ts +20 -0
- package/dist/cjs/api/types/DagNodeCreate.d.ts +17 -0
- package/dist/cjs/api/types/Destination.d.ts +22 -0
- package/dist/cjs/api/types/DestinationWithAuthenticationFields.d.ts +23 -0
- package/dist/cjs/api/types/EmbeddingModel.d.ts +20 -0
- package/dist/cjs/api/types/EmbeddingModelWithAuthenticationFields.d.ts +21 -0
- package/dist/cjs/api/types/EntityDefinition.d.ts +21 -0
- package/dist/cjs/api/types/EntityDefinitionCreate.d.ts +19 -0
- package/dist/cjs/api/types/EntityDefinitionUpdate.d.ts +19 -0
- package/dist/cjs/api/types/Fields.d.ts +10 -0
- package/dist/cjs/api/types/HttpValidationError.d.ts +7 -0
- package/dist/cjs/api/types/IntegrationCredentialInDb.d.ts +18 -0
- package/dist/cjs/api/types/IntegrationCredentialRawCreate.d.ts +19 -0
- package/dist/cjs/api/types/InvitationCreate.d.ts +10 -0
- package/dist/cjs/api/types/InvitationResponse.d.ts +13 -0
- package/dist/cjs/api/types/MemberResponse.d.ts +15 -0
- package/dist/cjs/api/types/Organization.d.ts +14 -0
- package/dist/cjs/api/types/OrganizationCreate.d.ts +14 -0
- package/dist/cjs/api/types/OrganizationWithRole.d.ts +16 -0
- package/dist/cjs/api/types/ResponseType.d.ts +11 -0
- package/dist/cjs/api/types/SearchResponse.d.ts +17 -0
- package/dist/cjs/api/types/SearchStatus.d.ts +12 -0
- package/dist/cjs/api/types/Source.d.ts +39 -0
- package/dist/cjs/api/types/SourceConnection.d.ts +61 -0
- package/dist/cjs/api/types/SourceConnectionCreateWithCredential.d.ts +25 -0
- package/dist/cjs/api/types/SourceConnectionCreateWithWhiteLabel.d.ts +29 -0
- package/dist/cjs/api/types/SourceConnectionJob.d.ts +45 -0
- package/dist/cjs/api/types/SourceConnectionListItem.d.ts +29 -0
- package/dist/cjs/api/types/Sync.d.ts +24 -0
- package/dist/cjs/api/types/SyncCreate.d.ts +19 -0
- package/dist/cjs/api/types/SyncDag.d.ts +29 -0
- package/dist/cjs/api/types/SyncDagCreate.d.ts +14 -0
- package/dist/cjs/api/types/SyncDagUpdate.d.ts +14 -0
- package/dist/cjs/api/types/SyncJob.d.ts +30 -0
- package/dist/cjs/api/types/SyncJobStatus.d.ts +15 -0
- package/dist/cjs/api/types/SyncJobStatus.js +14 -0
- package/dist/cjs/api/types/SyncUpdate.d.ts +14 -0
- package/dist/cjs/api/types/SyncWithSourceConnection.d.ts +25 -0
- package/dist/cjs/api/types/Transformer.d.ts +19 -0
- package/dist/cjs/api/types/TransformerCreate.d.ts +15 -0
- package/dist/cjs/api/types/TransformerUpdate.d.ts +15 -0
- package/dist/cjs/api/types/User.d.ts +15 -0
- package/dist/cjs/api/types/UserCreate.d.ts +11 -0
- package/dist/cjs/api/types/UserOrganization.d.ts +14 -0
- package/dist/cjs/api/types/ValidationError.d.ts +14 -0
- package/dist/cjs/api/types/WhiteLabel.d.ts +32 -0
- package/dist/cjs/api/types/index.d.ts +65 -0
- package/dist/cjs/api/types/index.js +81 -0
- package/dist/cjs/core/fetcher/APIResponse.d.ts +20 -0
- package/dist/cjs/core/fetcher/BinaryResponse.d.ts +17 -0
- package/dist/cjs/core/fetcher/BinaryResponse.js +14 -0
- package/dist/cjs/core/fetcher/Fetcher.d.ts +40 -0
- package/dist/cjs/core/fetcher/Fetcher.js +120 -0
- package/dist/cjs/core/fetcher/Headers.d.ts +2 -0
- package/dist/cjs/core/fetcher/Headers.js +84 -0
- package/dist/cjs/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/dist/cjs/core/fetcher/HttpResponsePromise.js +103 -0
- package/dist/cjs/core/fetcher/RawResponse.d.ts +29 -0
- package/dist/cjs/core/fetcher/RawResponse.js +44 -0
- package/dist/cjs/core/fetcher/ResponseWithBody.d.ts +4 -0
- package/dist/cjs/core/fetcher/ResponseWithBody.js +6 -0
- package/dist/cjs/core/fetcher/createRequestUrl.d.ts +1 -0
- package/dist/cjs/core/fetcher/createRequestUrl.js +8 -0
- package/dist/cjs/core/fetcher/getFetchFn.js +68 -0
- package/dist/cjs/core/fetcher/getRequestBody.js +23 -0
- package/dist/cjs/core/fetcher/getResponseBody.js +55 -0
- package/dist/cjs/core/fetcher/index.d.ts +9 -0
- package/dist/cjs/core/fetcher/index.js +15 -0
- package/dist/cjs/core/fetcher/makeRequest.js +42 -0
- package/dist/cjs/core/fetcher/requestWithRetries.js +40 -0
- package/dist/cjs/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +30 -0
- package/dist/cjs/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +21 -0
- package/dist/cjs/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +31 -0
- package/dist/cjs/core/fetcher/stream-wrappers/chooseStreamWrapper.js +59 -0
- package/dist/cjs/core/headers.d.ts +3 -0
- package/dist/cjs/core/headers.js +29 -0
- package/dist/cjs/core/index.d.ts +3 -0
- package/dist/cjs/core/index.js +42 -0
- package/dist/cjs/core/json.d.ts +15 -0
- package/dist/cjs/core/json.js +24 -0
- package/dist/cjs/core/runtime/index.d.ts +1 -0
- package/dist/cjs/core/runtime/index.js +5 -0
- package/dist/cjs/core/runtime/runtime.d.ts +9 -0
- package/dist/cjs/core/runtime/runtime.js +102 -0
- package/dist/cjs/core/url/index.d.ts +2 -0
- package/dist/cjs/core/url/index.js +7 -0
- package/dist/cjs/core/url/join.d.ts +1 -0
- package/dist/cjs/core/url/join.js +49 -0
- package/dist/cjs/core/url/qs.d.ts +6 -0
- package/dist/cjs/core/url/qs.js +64 -0
- package/dist/cjs/errors/AirweaveSDKError.d.ts +15 -0
- package/dist/cjs/errors/AirweaveSDKError.js +30 -0
- package/dist/cjs/errors/index.d.ts +2 -0
- package/dist/cjs/errors/index.js +7 -0
- package/dist/cjs/index.d.ts +4 -0
- package/dist/cjs/index.js +44 -0
- package/dist/cjs/version.d.ts +1 -0
- package/dist/cjs/version.js +4 -0
- package/dist/esm/Client.d.mts +48 -0
- package/dist/esm/Client.mjs +39 -0
- package/dist/esm/api/errors/UnprocessableEntityError.d.mts +9 -0
- package/dist/esm/api/errors/UnprocessableEntityError.mjs +15 -0
- package/dist/esm/api/errors/index.d.mts +1 -0
- package/dist/esm/api/errors/index.mjs +1 -0
- package/dist/esm/api/index.d.mts +3 -0
- package/dist/esm/api/index.mjs +3 -0
- package/dist/esm/api/resources/collections/client/Client.d.mts +158 -0
- package/dist/esm/api/resources/collections/client/Client.mjs +500 -0
- package/dist/esm/api/resources/collections/client/index.d.mts +2 -0
- package/dist/esm/api/resources/collections/client/index.mjs +1 -0
- package/dist/esm/api/resources/collections/client/requests/CollectionCreate.d.mts +16 -0
- package/dist/esm/api/resources/collections/client/requests/CollectionCreate.mjs +4 -0
- package/dist/esm/api/resources/collections/client/requests/CollectionUpdate.d.mts +13 -0
- package/dist/esm/api/resources/collections/client/requests/CollectionUpdate.mjs +4 -0
- package/dist/esm/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.d.mts +13 -0
- package/dist/esm/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.mjs +4 -0
- package/dist/esm/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.d.mts +17 -0
- package/dist/esm/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.mjs +4 -0
- package/dist/esm/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.d.mts +20 -0
- package/dist/esm/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.mjs +4 -0
- package/dist/esm/api/resources/collections/client/requests/index.d.mts +5 -0
- package/dist/esm/api/resources/collections/index.d.mts +1 -0
- package/dist/esm/api/resources/collections/index.mjs +1 -0
- package/dist/esm/api/resources/index.d.mts +7 -0
- package/dist/esm/api/resources/index.mjs +7 -0
- package/dist/esm/api/resources/sourceConnections/client/Client.d.mts +208 -0
- package/dist/esm/api/resources/sourceConnections/client/Client.mjs +652 -0
- package/dist/esm/api/resources/sourceConnections/client/index.d.mts +2 -0
- package/dist/esm/api/resources/sourceConnections/client/index.mjs +1 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.mts +11 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.d.mts +13 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.d.mts +13 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.d.mts +21 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/SourceConnectionCreate.d.mts +29 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/SourceConnectionCreate.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.mts +30 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.mjs +4 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/index.d.mts +6 -0
- package/dist/esm/api/resources/sourceConnections/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/sourceConnections/index.d.mts +1 -0
- package/dist/esm/api/resources/sourceConnections/index.mjs +1 -0
- package/dist/esm/api/resources/sources/client/Client.d.mts +65 -0
- package/dist/esm/api/resources/sources/client/Client.mjs +144 -0
- package/dist/esm/api/resources/sources/client/index.d.mts +1 -0
- package/dist/esm/api/resources/sources/client/index.mjs +1 -0
- package/dist/esm/api/resources/sources/index.d.mts +1 -0
- package/dist/esm/api/resources/sources/index.mjs +1 -0
- package/dist/esm/api/resources/whiteLabels/client/Client.d.mts +190 -0
- package/dist/esm/api/resources/whiteLabels/client/Client.mjs +563 -0
- package/dist/esm/api/resources/whiteLabels/client/index.d.mts +2 -0
- package/dist/esm/api/resources/whiteLabels/client/index.mjs +1 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.mts +16 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.mjs +4 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/WhiteLabelCreate.d.mts +28 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/WhiteLabelCreate.mjs +4 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/WhiteLabelUpdate.d.mts +23 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/WhiteLabelUpdate.mjs +4 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/index.d.mts +3 -0
- package/dist/esm/api/resources/whiteLabels/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/whiteLabels/index.d.mts +1 -0
- package/dist/esm/api/resources/whiteLabels/index.mjs +1 -0
- package/dist/esm/api/types/ApiKey.d.mts +17 -0
- package/dist/esm/api/types/ApiKey.mjs +4 -0
- package/dist/esm/api/types/ApiKeyCreate.d.mts +10 -0
- package/dist/esm/api/types/ApiKeyCreate.mjs +4 -0
- package/dist/esm/api/types/AuthType.mjs +13 -0
- package/dist/esm/api/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.mjs +4 -0
- package/dist/esm/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.mts +13 -0
- package/dist/esm/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.mjs +4 -0
- package/dist/esm/api/types/Collection.d.mts +30 -0
- package/dist/esm/api/types/Collection.mjs +4 -0
- package/dist/esm/api/types/CollectionStatus.mjs +9 -0
- package/dist/esm/api/types/ConfigField.mjs +4 -0
- package/dist/esm/api/types/ConfigValues.mjs +4 -0
- package/dist/esm/api/types/Connection.d.mts +18 -0
- package/dist/esm/api/types/Connection.mjs +4 -0
- package/dist/esm/api/types/ConnectionStatus.mjs +8 -0
- package/dist/esm/api/types/DagEdge.d.mts +15 -0
- package/dist/esm/api/types/DagEdge.mjs +4 -0
- package/dist/esm/api/types/DagEdgeCreate.d.mts +10 -0
- package/dist/esm/api/types/DagEdgeCreate.mjs +4 -0
- package/dist/esm/api/types/DagNode.d.mts +20 -0
- package/dist/esm/api/types/DagNode.mjs +4 -0
- package/dist/esm/api/types/DagNodeCreate.d.mts +17 -0
- package/dist/esm/api/types/DagNodeCreate.mjs +4 -0
- package/dist/esm/api/types/Destination.d.mts +22 -0
- package/dist/esm/api/types/Destination.mjs +4 -0
- package/dist/esm/api/types/DestinationWithAuthenticationFields.d.mts +23 -0
- package/dist/esm/api/types/DestinationWithAuthenticationFields.mjs +4 -0
- package/dist/esm/api/types/EmbeddingModel.d.mts +20 -0
- package/dist/esm/api/types/EmbeddingModel.mjs +4 -0
- package/dist/esm/api/types/EmbeddingModelWithAuthenticationFields.d.mts +21 -0
- package/dist/esm/api/types/EmbeddingModelWithAuthenticationFields.mjs +4 -0
- package/dist/esm/api/types/EntityCount.mjs +4 -0
- package/dist/esm/api/types/EntityDefinition.d.mts +21 -0
- package/dist/esm/api/types/EntityDefinition.mjs +4 -0
- package/dist/esm/api/types/EntityDefinitionCreate.d.mts +19 -0
- package/dist/esm/api/types/EntityDefinitionCreate.mjs +4 -0
- package/dist/esm/api/types/EntityDefinitionUpdate.d.mts +19 -0
- package/dist/esm/api/types/EntityDefinitionUpdate.mjs +4 -0
- package/dist/esm/api/types/EntityType.mjs +7 -0
- package/dist/esm/api/types/Fields.d.mts +10 -0
- package/dist/esm/api/types/Fields.mjs +4 -0
- package/dist/esm/api/types/HttpValidationError.d.mts +7 -0
- package/dist/esm/api/types/HttpValidationError.mjs +4 -0
- package/dist/esm/api/types/IntegrationCredentialInDb.d.mts +18 -0
- package/dist/esm/api/types/IntegrationCredentialInDb.mjs +4 -0
- package/dist/esm/api/types/IntegrationCredentialRawCreate.d.mts +19 -0
- package/dist/esm/api/types/IntegrationCredentialRawCreate.mjs +4 -0
- package/dist/esm/api/types/IntegrationType.mjs +8 -0
- package/dist/esm/api/types/InvitationCreate.d.mts +10 -0
- package/dist/esm/api/types/InvitationCreate.mjs +4 -0
- package/dist/esm/api/types/InvitationResponse.d.mts +13 -0
- package/dist/esm/api/types/InvitationResponse.mjs +4 -0
- package/dist/esm/api/types/MemberResponse.d.mts +15 -0
- package/dist/esm/api/types/MemberResponse.mjs +4 -0
- package/dist/esm/api/types/NodeType.mjs +9 -0
- package/dist/esm/api/types/OAuth2AuthUrl.mjs +4 -0
- package/dist/esm/api/types/Organization.d.mts +14 -0
- package/dist/esm/api/types/Organization.mjs +4 -0
- package/dist/esm/api/types/OrganizationCreate.d.mts +14 -0
- package/dist/esm/api/types/OrganizationCreate.mjs +4 -0
- package/dist/esm/api/types/OrganizationWithRole.d.mts +16 -0
- package/dist/esm/api/types/OrganizationWithRole.mjs +4 -0
- package/dist/esm/api/types/ResponseType.d.mts +11 -0
- package/dist/esm/api/types/ResponseType.mjs +7 -0
- package/dist/esm/api/types/SearchResponse.d.mts +17 -0
- package/dist/esm/api/types/SearchResponse.mjs +4 -0
- package/dist/esm/api/types/SearchStatus.d.mts +12 -0
- package/dist/esm/api/types/SearchStatus.mjs +8 -0
- package/dist/esm/api/types/Source.d.mts +39 -0
- package/dist/esm/api/types/Source.mjs +4 -0
- package/dist/esm/api/types/SourceConnection.d.mts +61 -0
- package/dist/esm/api/types/SourceConnection.mjs +4 -0
- package/dist/esm/api/types/SourceConnectionCreateWithCredential.d.mts +25 -0
- package/dist/esm/api/types/SourceConnectionCreateWithCredential.mjs +4 -0
- package/dist/esm/api/types/SourceConnectionCreateWithWhiteLabel.d.mts +29 -0
- package/dist/esm/api/types/SourceConnectionCreateWithWhiteLabel.mjs +4 -0
- package/dist/esm/api/types/SourceConnectionJob.d.mts +45 -0
- package/dist/esm/api/types/SourceConnectionJob.mjs +4 -0
- package/dist/esm/api/types/SourceConnectionListItem.d.mts +29 -0
- package/dist/esm/api/types/SourceConnectionListItem.mjs +4 -0
- package/dist/esm/api/types/SourceConnectionStatus.mjs +8 -0
- package/dist/esm/api/types/Sync.d.mts +24 -0
- package/dist/esm/api/types/Sync.mjs +4 -0
- package/dist/esm/api/types/SyncCreate.d.mts +19 -0
- package/dist/esm/api/types/SyncCreate.mjs +4 -0
- package/dist/esm/api/types/SyncDag.d.mts +29 -0
- package/dist/esm/api/types/SyncDag.mjs +4 -0
- package/dist/esm/api/types/SyncDagCreate.d.mts +14 -0
- package/dist/esm/api/types/SyncDagCreate.mjs +4 -0
- package/dist/esm/api/types/SyncDagUpdate.d.mts +14 -0
- package/dist/esm/api/types/SyncDagUpdate.mjs +4 -0
- package/dist/esm/api/types/SyncJob.d.mts +30 -0
- package/dist/esm/api/types/SyncJob.mjs +4 -0
- package/dist/esm/api/types/SyncJobStatus.d.mts +15 -0
- package/dist/esm/api/types/SyncJobStatus.mjs +11 -0
- package/dist/esm/api/types/SyncStatus.mjs +8 -0
- package/dist/esm/api/types/SyncUpdate.d.mts +14 -0
- package/dist/esm/api/types/SyncUpdate.mjs +4 -0
- package/dist/esm/api/types/SyncWithSourceConnection.d.mts +25 -0
- package/dist/esm/api/types/SyncWithSourceConnection.mjs +4 -0
- package/dist/esm/api/types/Transformer.d.mts +19 -0
- package/dist/esm/api/types/Transformer.mjs +4 -0
- package/dist/esm/api/types/TransformerCreate.d.mts +15 -0
- package/dist/esm/api/types/TransformerCreate.mjs +4 -0
- package/dist/esm/api/types/TransformerUpdate.d.mts +15 -0
- package/dist/esm/api/types/TransformerUpdate.mjs +4 -0
- package/dist/esm/api/types/User.d.mts +15 -0
- package/dist/esm/api/types/User.mjs +4 -0
- package/dist/esm/api/types/UserCreate.d.mts +11 -0
- package/dist/esm/api/types/UserCreate.mjs +4 -0
- package/dist/esm/api/types/UserOrganization.d.mts +14 -0
- package/dist/esm/api/types/UserOrganization.mjs +4 -0
- package/dist/esm/api/types/ValidationError.d.mts +14 -0
- package/dist/esm/api/types/ValidationError.mjs +4 -0
- package/dist/esm/api/types/WhiteLabel.d.mts +32 -0
- package/dist/esm/api/types/WhiteLabel.mjs +4 -0
- package/dist/esm/api/types/index.d.mts +65 -0
- package/dist/esm/api/types/index.mjs +65 -0
- package/dist/esm/core/fetcher/APIResponse.d.mts +20 -0
- package/dist/esm/core/fetcher/APIResponse.mjs +1 -0
- package/dist/esm/core/fetcher/BinaryResponse.d.mts +17 -0
- package/dist/esm/core/fetcher/BinaryResponse.mjs +11 -0
- package/dist/esm/core/fetcher/Fetcher.d.mts +40 -0
- package/dist/esm/core/fetcher/Fetcher.mjs +116 -0
- package/dist/esm/core/fetcher/Headers.d.mts +2 -0
- package/dist/esm/core/fetcher/Headers.mjs +82 -0
- package/dist/esm/core/fetcher/HttpResponsePromise.d.mts +58 -0
- package/dist/esm/core/fetcher/HttpResponsePromise.mjs +99 -0
- package/dist/esm/core/fetcher/RawResponse.d.mts +29 -0
- package/dist/esm/core/fetcher/RawResponse.mjs +40 -0
- package/dist/esm/core/fetcher/ResponseWithBody.d.mts +4 -0
- package/dist/esm/core/fetcher/ResponseWithBody.mjs +3 -0
- package/dist/esm/core/fetcher/Supplier.mjs +19 -0
- package/dist/esm/core/fetcher/createRequestUrl.d.mts +1 -0
- package/dist/esm/core/fetcher/createRequestUrl.mjs +5 -0
- package/dist/esm/core/fetcher/getFetchFn.mjs +32 -0
- package/dist/esm/core/fetcher/getHeader.mjs +8 -0
- package/dist/esm/core/fetcher/getRequestBody.mjs +20 -0
- package/dist/esm/core/fetcher/getResponseBody.mjs +52 -0
- package/dist/esm/core/fetcher/index.d.mts +9 -0
- package/dist/esm/core/fetcher/index.mjs +5 -0
- package/dist/esm/core/fetcher/makeRequest.mjs +38 -0
- package/dist/esm/core/fetcher/requestWithRetries.mjs +37 -0
- package/dist/esm/core/fetcher/signals.mjs +32 -0
- package/dist/esm/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.mts +30 -0
- package/dist/esm/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.mjs +243 -0
- package/dist/esm/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.mts +21 -0
- package/dist/esm/core/fetcher/stream-wrappers/NodePre18StreamWrapper.mjs +122 -0
- package/dist/esm/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.mts +31 -0
- package/dist/esm/core/fetcher/stream-wrappers/UndiciStreamWrapper.mjs +225 -0
- package/dist/esm/core/fetcher/stream-wrappers/chooseStreamWrapper.mjs +23 -0
- package/dist/esm/core/headers.d.mts +3 -0
- package/dist/esm/core/headers.mjs +25 -0
- package/dist/esm/core/index.d.mts +3 -0
- package/dist/esm/core/index.mjs +3 -0
- package/dist/esm/core/json.d.mts +15 -0
- package/dist/esm/core/json.mjs +19 -0
- package/dist/esm/core/runtime/index.d.mts +1 -0
- package/dist/esm/core/runtime/index.mjs +1 -0
- package/dist/esm/core/runtime/runtime.d.mts +9 -0
- package/dist/esm/core/runtime/runtime.mjs +99 -0
- package/dist/esm/core/url/index.d.mts +2 -0
- package/dist/esm/core/url/index.mjs +2 -0
- package/dist/esm/core/url/join.d.mts +1 -0
- package/dist/esm/core/url/join.mjs +46 -0
- package/dist/esm/core/url/qs.d.mts +6 -0
- package/dist/esm/core/url/qs.mjs +61 -0
- package/dist/esm/environments.mjs +7 -0
- package/dist/esm/errors/AirweaveSDKError.d.mts +15 -0
- package/dist/esm/errors/AirweaveSDKError.mjs +26 -0
- package/dist/esm/errors/AirweaveSDKTimeoutError.mjs +9 -0
- package/dist/esm/errors/index.d.mts +2 -0
- package/dist/esm/errors/index.mjs +2 -0
- package/dist/esm/index.d.mts +4 -0
- package/dist/esm/index.mjs +4 -0
- package/dist/esm/version.d.mts +1 -0
- package/dist/esm/version.mjs +1 -0
- package/package.json +39 -14
- package/reference.md +860 -127
- package/Client.d.ts +0 -37
- package/Client.js +0 -27
- package/api/errors/UnprocessableEntityError.d.ts +0 -8
- package/api/errors/UnprocessableEntityError.js +0 -51
- package/api/errors/index.d.ts +0 -1
- package/api/errors/index.js +0 -17
- package/api/index.d.ts +0 -3
- package/api/index.js +0 -19
- package/api/resources/collections/client/Client.d.ts +0 -135
- package/api/resources/collections/client/Client.js +0 -510
- package/api/resources/collections/client/index.d.ts +0 -1
- package/api/resources/collections/client/index.js +0 -17
- package/api/resources/collections/client/requests/CollectionCreate.d.ts +0 -15
- package/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.d.ts +0 -10
- package/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.d.ts +0 -11
- package/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.d.ts +0 -20
- package/api/resources/collections/client/requests/index.d.ts +0 -4
- package/api/resources/collections/index.d.ts +0 -1
- package/api/resources/collections/index.js +0 -17
- package/api/resources/index.d.ts +0 -6
- package/api/resources/index.js +0 -45
- package/api/resources/sourceConnections/client/Client.d.ts +0 -191
- package/api/resources/sourceConnections/client/Client.js +0 -625
- package/api/resources/sourceConnections/client/index.d.ts +0 -1
- package/api/resources/sourceConnections/client/index.js +0 -17
- package/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.ts +0 -10
- package/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.d.ts +0 -10
- package/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.d.ts +0 -10
- package/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.d.ts +0 -15
- package/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.ts +0 -18
- package/api/resources/sourceConnections/client/requests/index.d.ts +0 -5
- package/api/resources/sourceConnections/index.d.ts +0 -2
- package/api/resources/sourceConnections/index.js +0 -18
- package/api/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.d.ts +0 -5
- package/api/resources/sourceConnections/types/index.d.ts +0 -1
- package/api/resources/sourceConnections/types/index.js +0 -17
- package/api/resources/sources/client/Client.d.ts +0 -68
- package/api/resources/sources/client/Client.js +0 -208
- package/api/resources/sources/index.d.ts +0 -1
- package/api/resources/sources/index.js +0 -17
- package/api/types/ApiKey.d.ts +0 -17
- package/api/types/ApiKeyCreate.d.ts +0 -10
- package/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.ts +0 -9
- package/api/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.ts +0 -8
- package/api/types/Chat.d.ts +0 -22
- package/api/types/ChatCreate.d.ts +0 -14
- package/api/types/ChatMessage.d.ts +0 -18
- package/api/types/ChatMessageCreate.d.ts +0 -10
- package/api/types/ChatUpdate.d.ts +0 -12
- package/api/types/Collection.d.ts +0 -19
- package/api/types/CollectionUpdate.d.ts +0 -10
- package/api/types/Connection.d.ts +0 -18
- package/api/types/DagEdge.d.ts +0 -15
- package/api/types/DagEdgeCreate.d.ts +0 -10
- package/api/types/DagNode.d.ts +0 -20
- package/api/types/DagNodeCreate.d.ts +0 -17
- package/api/types/Destination.d.ts +0 -22
- package/api/types/DestinationWithAuthenticationFields.d.ts +0 -23
- package/api/types/EmbeddingModel.d.ts +0 -20
- package/api/types/EmbeddingModelWithAuthenticationFields.d.ts +0 -21
- package/api/types/EntityDefinition.d.ts +0 -18
- package/api/types/EntityDefinitionCreate.d.ts +0 -16
- package/api/types/EntityDefinitionCreateEntitySchema.d.ts +0 -4
- package/api/types/EntityDefinitionEntitySchema.d.ts +0 -4
- package/api/types/EntityDefinitionUpdate.d.ts +0 -16
- package/api/types/EntityDefinitionUpdateEntitySchema.d.ts +0 -4
- package/api/types/EntityDefinitionUpdateEntitySchema.js +0 -5
- package/api/types/EntityRelation.d.ts +0 -16
- package/api/types/EntityRelation.js +0 -5
- package/api/types/EntityRelationCreate.d.ts +0 -12
- package/api/types/EntityRelationCreate.js +0 -5
- package/api/types/EntityRelationUpdate.d.ts +0 -12
- package/api/types/EntityRelationUpdate.js +0 -5
- package/api/types/Fields.d.ts +0 -10
- package/api/types/HttpValidationError.d.ts +0 -7
- package/api/types/IntegrationCredentialInDb.d.ts +0 -18
- package/api/types/IntegrationCredentialRawCreate.d.ts +0 -19
- package/api/types/Organization.d.ts +0 -13
- package/api/types/ResponseType.d.ts +0 -11
- package/api/types/SearchResponse.d.ts +0 -13
- package/api/types/SearchStatus.d.ts +0 -12
- package/api/types/Source.d.ts +0 -25
- package/api/types/SourceConnection.d.ts +0 -33
- package/api/types/SourceConnectionAuthFields.d.ts +0 -5
- package/api/types/SourceConnectionAuthFields.js +0 -5
- package/api/types/SourceConnectionCreate.d.ts +0 -23
- package/api/types/SourceConnectionJob.d.ts +0 -30
- package/api/types/SourceConnectionListItem.d.ts +0 -22
- package/api/types/Sync.d.ts +0 -24
- package/api/types/SyncCreate.d.ts +0 -19
- package/api/types/SyncDag.d.ts +0 -29
- package/api/types/SyncDagCreate.d.ts +0 -14
- package/api/types/SyncDagUpdate.d.ts +0 -14
- package/api/types/SyncJob.d.ts +0 -30
- package/api/types/SyncJobStatus.d.ts +0 -13
- package/api/types/SyncJobStatus.js +0 -12
- package/api/types/SyncUpdate.d.ts +0 -14
- package/api/types/SyncWithSourceConnection.d.ts +0 -25
- package/api/types/Transformer.d.ts +0 -19
- package/api/types/TransformerCreate.d.ts +0 -15
- package/api/types/TransformerUpdate.d.ts +0 -15
- package/api/types/User.d.ts +0 -13
- package/api/types/UserCreate.d.ts +0 -11
- package/api/types/ValidationError.d.ts +0 -9
- package/api/types/ValidationErrorLocItem.d.ts +0 -4
- package/api/types/ValidationErrorLocItem.js +0 -5
- package/api/types/WhiteLabel.d.ts +0 -20
- package/api/types/WhiteLabelCreate.d.ts +0 -14
- package/api/types/WhiteLabelUpdate.d.ts +0 -13
- package/api/types/index.d.ts +0 -75
- package/api/types/index.js +0 -91
- package/core/fetcher/APIResponse.d.ts +0 -10
- package/core/fetcher/Fetcher.d.ts +0 -39
- package/core/fetcher/Fetcher.js +0 -99
- package/core/fetcher/createRequestUrl.d.ts +0 -1
- package/core/fetcher/createRequestUrl.js +0 -12
- package/core/fetcher/getFetchFn.js +0 -68
- package/core/fetcher/getRequestBody.js +0 -22
- package/core/fetcher/getResponseBody.js +0 -54
- package/core/fetcher/index.d.ts +0 -5
- package/core/fetcher/index.js +0 -9
- package/core/fetcher/makeRequest.js +0 -42
- package/core/fetcher/requestWithRetries.js +0 -40
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/core/index.d.ts +0 -3
- package/core/index.js +0 -42
- package/core/runtime/index.d.ts +0 -1
- package/core/runtime/index.js +0 -5
- package/core/runtime/runtime.d.ts +0 -9
- package/core/runtime/runtime.js +0 -93
- package/core/schemas/Schema.d.ts +0 -85
- package/core/schemas/Schema.js +0 -22
- package/core/schemas/builders/bigint/bigint.d.ts +0 -2
- package/core/schemas/builders/bigint/bigint.js +0 -49
- package/core/schemas/builders/bigint/index.d.ts +0 -1
- package/core/schemas/builders/bigint/index.js +0 -5
- package/core/schemas/builders/date/date.d.ts +0 -2
- package/core/schemas/builders/date/date.js +0 -62
- package/core/schemas/builders/date/index.d.ts +0 -1
- package/core/schemas/builders/date/index.js +0 -5
- package/core/schemas/builders/enum/enum.d.ts +0 -2
- package/core/schemas/builders/enum/enum.js +0 -38
- package/core/schemas/builders/enum/index.d.ts +0 -1
- package/core/schemas/builders/enum/index.js +0 -5
- package/core/schemas/builders/index.d.ts +0 -14
- package/core/schemas/builders/index.js +0 -30
- package/core/schemas/builders/lazy/index.d.ts +0 -3
- package/core/schemas/builders/lazy/index.js +0 -7
- package/core/schemas/builders/lazy/lazy.d.ts +0 -5
- package/core/schemas/builders/lazy/lazy.js +0 -24
- package/core/schemas/builders/lazy/lazyObject.d.ts +0 -3
- package/core/schemas/builders/lazy/lazyObject.js +0 -11
- package/core/schemas/builders/list/index.d.ts +0 -1
- package/core/schemas/builders/list/index.js +0 -5
- package/core/schemas/builders/list/list.d.ts +0 -2
- package/core/schemas/builders/list/list.js +0 -54
- package/core/schemas/builders/literals/booleanLiteral.d.ts +0 -2
- package/core/schemas/builders/literals/booleanLiteral.js +0 -28
- package/core/schemas/builders/literals/index.d.ts +0 -2
- package/core/schemas/builders/literals/index.js +0 -7
- package/core/schemas/builders/literals/stringLiteral.d.ts +0 -2
- package/core/schemas/builders/literals/stringLiteral.js +0 -28
- package/core/schemas/builders/object/index.d.ts +0 -6
- package/core/schemas/builders/object/index.js +0 -11
- package/core/schemas/builders/object/object.d.ts +0 -3
- package/core/schemas/builders/object/object.js +0 -260
- package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +0 -6
- package/core/schemas/builders/object/objectWithoutOptionalProperties.js +0 -7
- package/core/schemas/builders/object/property.d.ts +0 -8
- package/core/schemas/builders/object/property.js +0 -15
- package/core/schemas/builders/object/types.d.ts +0 -31
- package/core/schemas/builders/object/types.js +0 -2
- package/core/schemas/builders/object-like/getObjectLikeUtils.d.ts +0 -9
- package/core/schemas/builders/object-like/getObjectLikeUtils.js +0 -53
- package/core/schemas/builders/object-like/index.d.ts +0 -2
- package/core/schemas/builders/object-like/index.js +0 -6
- package/core/schemas/builders/object-like/types.d.ts +0 -7
- package/core/schemas/builders/object-like/types.js +0 -2
- package/core/schemas/builders/primitives/any.d.ts +0 -1
- package/core/schemas/builders/primitives/any.js +0 -6
- package/core/schemas/builders/primitives/boolean.d.ts +0 -1
- package/core/schemas/builders/primitives/boolean.js +0 -25
- package/core/schemas/builders/primitives/index.d.ts +0 -5
- package/core/schemas/builders/primitives/index.js +0 -13
- package/core/schemas/builders/primitives/number.d.ts +0 -1
- package/core/schemas/builders/primitives/number.js +0 -25
- package/core/schemas/builders/primitives/string.d.ts +0 -1
- package/core/schemas/builders/primitives/string.js +0 -25
- package/core/schemas/builders/primitives/unknown.d.ts +0 -1
- package/core/schemas/builders/primitives/unknown.js +0 -6
- package/core/schemas/builders/record/index.d.ts +0 -2
- package/core/schemas/builders/record/index.js +0 -5
- package/core/schemas/builders/record/record.d.ts +0 -3
- package/core/schemas/builders/record/record.js +0 -94
- package/core/schemas/builders/record/types.d.ts +0 -4
- package/core/schemas/builders/record/types.js +0 -2
- package/core/schemas/builders/schema-utils/JsonError.d.ts +0 -5
- package/core/schemas/builders/schema-utils/JsonError.js +0 -12
- package/core/schemas/builders/schema-utils/ParseError.d.ts +0 -5
- package/core/schemas/builders/schema-utils/ParseError.js +0 -12
- package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +0 -17
- package/core/schemas/builders/schema-utils/getSchemaUtils.js +0 -81
- package/core/schemas/builders/schema-utils/index.d.ts +0 -4
- package/core/schemas/builders/schema-utils/index.js +0 -11
- package/core/schemas/builders/schema-utils/stringifyValidationErrors.d.ts +0 -2
- package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +0 -9
- package/core/schemas/builders/set/index.d.ts +0 -1
- package/core/schemas/builders/set/index.js +0 -5
- package/core/schemas/builders/set/set.d.ts +0 -2
- package/core/schemas/builders/set/set.js +0 -43
- package/core/schemas/builders/undiscriminated-union/index.d.ts +0 -2
- package/core/schemas/builders/undiscriminated-union/index.js +0 -5
- package/core/schemas/builders/undiscriminated-union/types.d.ts +0 -4
- package/core/schemas/builders/undiscriminated-union/types.js +0 -2
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.d.ts +0 -3
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +0 -39
- package/core/schemas/builders/union/discriminant.d.ts +0 -5
- package/core/schemas/builders/union/discriminant.js +0 -9
- package/core/schemas/builders/union/index.d.ts +0 -4
- package/core/schemas/builders/union/index.js +0 -7
- package/core/schemas/builders/union/types.d.ts +0 -13
- package/core/schemas/builders/union/types.js +0 -2
- package/core/schemas/builders/union/union.d.ts +0 -4
- package/core/schemas/builders/union/union.js +0 -129
- package/core/schemas/index.d.ts +0 -2
- package/core/schemas/index.js +0 -17
- package/core/schemas/utils/MaybePromise.d.ts +0 -1
- package/core/schemas/utils/MaybePromise.js +0 -2
- package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +0 -7
- package/core/schemas/utils/addQuestionMarksToNullableProperties.js +0 -2
- package/core/schemas/utils/createIdentitySchemaCreator.d.ts +0 -2
- package/core/schemas/utils/createIdentitySchemaCreator.js +0 -15
- package/core/schemas/utils/entries.d.ts +0 -1
- package/core/schemas/utils/entries.js +0 -6
- package/core/schemas/utils/filterObject.d.ts +0 -1
- package/core/schemas/utils/filterObject.js +0 -13
- package/core/schemas/utils/getErrorMessageForIncorrectType.d.ts +0 -1
- package/core/schemas/utils/getErrorMessageForIncorrectType.js +0 -27
- package/core/schemas/utils/isPlainObject.d.ts +0 -1
- package/core/schemas/utils/isPlainObject.js +0 -17
- package/core/schemas/utils/keys.d.ts +0 -1
- package/core/schemas/utils/keys.js +0 -6
- package/core/schemas/utils/maybeSkipValidation.d.ts +0 -2
- package/core/schemas/utils/maybeSkipValidation.js +0 -27
- package/core/schemas/utils/partition.d.ts +0 -1
- package/core/schemas/utils/partition.js +0 -15
- package/dist/Client.d.ts +0 -37
- package/dist/Client.js +0 -27
- package/dist/api/errors/UnprocessableEntityError.d.ts +0 -8
- package/dist/api/errors/UnprocessableEntityError.js +0 -51
- package/dist/api/errors/index.d.ts +0 -1
- package/dist/api/errors/index.js +0 -17
- package/dist/api/index.d.ts +0 -3
- package/dist/api/index.js +0 -19
- package/dist/api/resources/collections/client/Client.d.ts +0 -135
- package/dist/api/resources/collections/client/Client.js +0 -510
- package/dist/api/resources/collections/client/index.d.ts +0 -1
- package/dist/api/resources/collections/client/index.js +0 -17
- package/dist/api/resources/collections/client/requests/CollectionCreate.d.ts +0 -15
- package/dist/api/resources/collections/client/requests/CollectionCreate.js +0 -5
- package/dist/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.d.ts +0 -10
- package/dist/api/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.js +0 -5
- package/dist/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.d.ts +0 -11
- package/dist/api/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.js +0 -5
- package/dist/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.d.ts +0 -20
- package/dist/api/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.js +0 -5
- package/dist/api/resources/collections/client/requests/index.d.ts +0 -4
- package/dist/api/resources/collections/index.d.ts +0 -1
- package/dist/api/resources/collections/index.js +0 -17
- package/dist/api/resources/index.d.ts +0 -6
- package/dist/api/resources/index.js +0 -45
- package/dist/api/resources/sourceConnections/client/Client.d.ts +0 -191
- package/dist/api/resources/sourceConnections/client/Client.js +0 -625
- package/dist/api/resources/sourceConnections/client/index.d.ts +0 -1
- package/dist/api/resources/sourceConnections/client/index.js +0 -17
- package/dist/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.ts +0 -10
- package/dist/api/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.js +0 -5
- package/dist/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.d.ts +0 -10
- package/dist/api/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.js +0 -5
- package/dist/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.d.ts +0 -10
- package/dist/api/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.js +0 -5
- package/dist/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.d.ts +0 -15
- package/dist/api/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.js +0 -5
- package/dist/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.ts +0 -18
- package/dist/api/resources/sourceConnections/client/requests/SourceConnectionUpdate.js +0 -5
- package/dist/api/resources/sourceConnections/client/requests/index.d.ts +0 -5
- package/dist/api/resources/sourceConnections/client/requests/index.js +0 -2
- package/dist/api/resources/sourceConnections/index.d.ts +0 -2
- package/dist/api/resources/sourceConnections/index.js +0 -18
- package/dist/api/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.d.ts +0 -5
- package/dist/api/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.js +0 -5
- package/dist/api/resources/sourceConnections/types/index.d.ts +0 -1
- package/dist/api/resources/sourceConnections/types/index.js +0 -17
- package/dist/api/resources/sources/client/Client.d.ts +0 -68
- package/dist/api/resources/sources/client/Client.js +0 -208
- package/dist/api/resources/sources/client/index.js +0 -2
- package/dist/api/resources/sources/index.d.ts +0 -1
- package/dist/api/resources/sources/index.js +0 -17
- package/dist/api/types/ApiKey.d.ts +0 -17
- package/dist/api/types/ApiKey.js +0 -5
- package/dist/api/types/ApiKeyCreate.d.ts +0 -10
- package/dist/api/types/ApiKeyCreate.js +0 -5
- package/dist/api/types/AuthType.js +0 -16
- package/dist/api/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.js +0 -5
- package/dist/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.ts +0 -9
- package/dist/api/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.js +0 -5
- package/dist/api/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.ts +0 -8
- package/dist/api/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.js +0 -5
- package/dist/api/types/Chat.d.ts +0 -22
- package/dist/api/types/Chat.js +0 -5
- package/dist/api/types/ChatCreate.d.ts +0 -14
- package/dist/api/types/ChatCreate.js +0 -5
- package/dist/api/types/ChatMessage.d.ts +0 -18
- package/dist/api/types/ChatMessage.js +0 -5
- package/dist/api/types/ChatMessageCreate.d.ts +0 -10
- package/dist/api/types/ChatMessageCreate.js +0 -5
- package/dist/api/types/ChatUpdate.d.ts +0 -12
- package/dist/api/types/ChatUpdate.js +0 -5
- package/dist/api/types/Collection.d.ts +0 -19
- package/dist/api/types/Collection.js +0 -5
- package/dist/api/types/CollectionStatus.js +0 -12
- package/dist/api/types/CollectionUpdate.d.ts +0 -10
- package/dist/api/types/CollectionUpdate.js +0 -5
- package/dist/api/types/ConfigField.js +0 -5
- package/dist/api/types/ConfigValues.js +0 -5
- package/dist/api/types/Connection.d.ts +0 -18
- package/dist/api/types/Connection.js +0 -5
- package/dist/api/types/ConnectionStatus.js +0 -11
- package/dist/api/types/DagEdge.d.ts +0 -15
- package/dist/api/types/DagEdge.js +0 -5
- package/dist/api/types/DagEdgeCreate.d.ts +0 -10
- package/dist/api/types/DagEdgeCreate.js +0 -5
- package/dist/api/types/DagNode.d.ts +0 -20
- package/dist/api/types/DagNode.js +0 -5
- package/dist/api/types/DagNodeCreate.d.ts +0 -17
- package/dist/api/types/DagNodeCreate.js +0 -5
- package/dist/api/types/Destination.d.ts +0 -22
- package/dist/api/types/Destination.js +0 -5
- package/dist/api/types/DestinationWithAuthenticationFields.d.ts +0 -23
- package/dist/api/types/DestinationWithAuthenticationFields.js +0 -5
- package/dist/api/types/EmbeddingModel.d.ts +0 -20
- package/dist/api/types/EmbeddingModel.js +0 -5
- package/dist/api/types/EmbeddingModelWithAuthenticationFields.d.ts +0 -21
- package/dist/api/types/EmbeddingModelWithAuthenticationFields.js +0 -5
- package/dist/api/types/EntityCount.js +0 -5
- package/dist/api/types/EntityDefinition.d.ts +0 -18
- package/dist/api/types/EntityDefinition.js +0 -5
- package/dist/api/types/EntityDefinitionCreate.d.ts +0 -16
- package/dist/api/types/EntityDefinitionCreate.js +0 -5
- package/dist/api/types/EntityDefinitionCreateEntitySchema.d.ts +0 -4
- package/dist/api/types/EntityDefinitionCreateEntitySchema.js +0 -5
- package/dist/api/types/EntityDefinitionEntitySchema.d.ts +0 -4
- package/dist/api/types/EntityDefinitionEntitySchema.js +0 -5
- package/dist/api/types/EntityDefinitionUpdate.d.ts +0 -16
- package/dist/api/types/EntityDefinitionUpdate.js +0 -5
- package/dist/api/types/EntityDefinitionUpdateEntitySchema.d.ts +0 -4
- package/dist/api/types/EntityDefinitionUpdateEntitySchema.js +0 -5
- package/dist/api/types/EntityRelation.d.ts +0 -16
- package/dist/api/types/EntityRelation.js +0 -5
- package/dist/api/types/EntityRelationCreate.d.ts +0 -12
- package/dist/api/types/EntityRelationCreate.js +0 -5
- package/dist/api/types/EntityRelationUpdate.d.ts +0 -12
- package/dist/api/types/EntityRelationUpdate.js +0 -5
- package/dist/api/types/EntityType.js +0 -10
- package/dist/api/types/Fields.d.ts +0 -10
- package/dist/api/types/Fields.js +0 -5
- package/dist/api/types/HttpValidationError.d.ts +0 -7
- package/dist/api/types/HttpValidationError.js +0 -5
- package/dist/api/types/IntegrationCredentialInDb.d.ts +0 -18
- package/dist/api/types/IntegrationCredentialInDb.js +0 -5
- package/dist/api/types/IntegrationCredentialRawCreate.d.ts +0 -19
- package/dist/api/types/IntegrationCredentialRawCreate.js +0 -5
- package/dist/api/types/IntegrationType.js +0 -11
- package/dist/api/types/NodeType.js +0 -12
- package/dist/api/types/OAuth2AuthUrl.js +0 -5
- package/dist/api/types/Organization.d.ts +0 -13
- package/dist/api/types/Organization.js +0 -5
- package/dist/api/types/ResponseType.d.ts +0 -11
- package/dist/api/types/ResponseType.js +0 -10
- package/dist/api/types/SearchResponse.d.ts +0 -13
- package/dist/api/types/SearchResponse.js +0 -5
- package/dist/api/types/SearchStatus.d.ts +0 -12
- package/dist/api/types/SearchStatus.js +0 -11
- package/dist/api/types/Source.d.ts +0 -25
- package/dist/api/types/Source.js +0 -5
- package/dist/api/types/SourceConnection.d.ts +0 -33
- package/dist/api/types/SourceConnection.js +0 -5
- package/dist/api/types/SourceConnectionAuthFields.d.ts +0 -5
- package/dist/api/types/SourceConnectionAuthFields.js +0 -5
- package/dist/api/types/SourceConnectionCreate.d.ts +0 -23
- package/dist/api/types/SourceConnectionCreate.js +0 -5
- package/dist/api/types/SourceConnectionJob.d.ts +0 -30
- package/dist/api/types/SourceConnectionJob.js +0 -5
- package/dist/api/types/SourceConnectionListItem.d.ts +0 -22
- package/dist/api/types/SourceConnectionListItem.js +0 -5
- package/dist/api/types/SourceConnectionStatus.js +0 -11
- package/dist/api/types/Sync.d.ts +0 -24
- package/dist/api/types/Sync.js +0 -5
- package/dist/api/types/SyncCreate.d.ts +0 -19
- package/dist/api/types/SyncCreate.js +0 -5
- package/dist/api/types/SyncDag.d.ts +0 -29
- package/dist/api/types/SyncDag.js +0 -5
- package/dist/api/types/SyncDagCreate.d.ts +0 -14
- package/dist/api/types/SyncDagCreate.js +0 -5
- package/dist/api/types/SyncDagUpdate.d.ts +0 -14
- package/dist/api/types/SyncDagUpdate.js +0 -5
- package/dist/api/types/SyncJob.d.ts +0 -30
- package/dist/api/types/SyncJob.js +0 -5
- package/dist/api/types/SyncJobStatus.d.ts +0 -13
- package/dist/api/types/SyncJobStatus.js +0 -12
- package/dist/api/types/SyncStatus.js +0 -11
- package/dist/api/types/SyncUpdate.d.ts +0 -14
- package/dist/api/types/SyncUpdate.js +0 -5
- package/dist/api/types/SyncWithSourceConnection.d.ts +0 -25
- package/dist/api/types/SyncWithSourceConnection.js +0 -5
- package/dist/api/types/Transformer.d.ts +0 -19
- package/dist/api/types/Transformer.js +0 -5
- package/dist/api/types/TransformerCreate.d.ts +0 -15
- package/dist/api/types/TransformerCreate.js +0 -5
- package/dist/api/types/TransformerUpdate.d.ts +0 -15
- package/dist/api/types/TransformerUpdate.js +0 -5
- package/dist/api/types/User.d.ts +0 -13
- package/dist/api/types/User.js +0 -5
- package/dist/api/types/UserCreate.d.ts +0 -11
- package/dist/api/types/UserCreate.js +0 -5
- package/dist/api/types/ValidationError.d.ts +0 -9
- package/dist/api/types/ValidationError.js +0 -5
- package/dist/api/types/ValidationErrorLocItem.d.ts +0 -4
- package/dist/api/types/ValidationErrorLocItem.js +0 -5
- package/dist/api/types/WhiteLabel.d.ts +0 -20
- package/dist/api/types/WhiteLabel.js +0 -5
- package/dist/api/types/WhiteLabelCreate.d.ts +0 -14
- package/dist/api/types/WhiteLabelCreate.js +0 -5
- package/dist/api/types/WhiteLabelUpdate.d.ts +0 -13
- package/dist/api/types/WhiteLabelUpdate.js +0 -5
- package/dist/api/types/index.d.ts +0 -75
- package/dist/api/types/index.js +0 -91
- package/dist/core/fetcher/APIResponse.d.ts +0 -10
- package/dist/core/fetcher/APIResponse.js +0 -2
- package/dist/core/fetcher/Fetcher.d.ts +0 -39
- package/dist/core/fetcher/Fetcher.js +0 -99
- package/dist/core/fetcher/Supplier.js +0 -22
- package/dist/core/fetcher/createRequestUrl.d.ts +0 -1
- package/dist/core/fetcher/createRequestUrl.js +0 -12
- package/dist/core/fetcher/getFetchFn.js +0 -68
- package/dist/core/fetcher/getHeader.js +0 -11
- package/dist/core/fetcher/getRequestBody.js +0 -22
- package/dist/core/fetcher/getResponseBody.js +0 -54
- package/dist/core/fetcher/index.d.ts +0 -5
- package/dist/core/fetcher/index.js +0 -9
- package/dist/core/fetcher/makeRequest.js +0 -42
- package/dist/core/fetcher/requestWithRetries.js +0 -40
- package/dist/core/fetcher/signals.js +0 -36
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/dist/core/index.d.ts +0 -3
- package/dist/core/index.js +0 -42
- package/dist/core/runtime/index.d.ts +0 -1
- package/dist/core/runtime/index.js +0 -5
- package/dist/core/runtime/runtime.d.ts +0 -9
- package/dist/core/runtime/runtime.js +0 -93
- package/dist/core/schemas/Schema.d.ts +0 -85
- package/dist/core/schemas/Schema.js +0 -22
- package/dist/core/schemas/builders/bigint/bigint.d.ts +0 -2
- package/dist/core/schemas/builders/bigint/bigint.js +0 -49
- package/dist/core/schemas/builders/bigint/index.d.ts +0 -1
- package/dist/core/schemas/builders/bigint/index.js +0 -5
- package/dist/core/schemas/builders/date/date.d.ts +0 -2
- package/dist/core/schemas/builders/date/date.js +0 -62
- package/dist/core/schemas/builders/date/index.d.ts +0 -1
- package/dist/core/schemas/builders/date/index.js +0 -5
- package/dist/core/schemas/builders/enum/enum.d.ts +0 -2
- package/dist/core/schemas/builders/enum/enum.js +0 -38
- package/dist/core/schemas/builders/enum/index.d.ts +0 -1
- package/dist/core/schemas/builders/enum/index.js +0 -5
- package/dist/core/schemas/builders/index.d.ts +0 -14
- package/dist/core/schemas/builders/index.js +0 -30
- package/dist/core/schemas/builders/lazy/index.d.ts +0 -3
- package/dist/core/schemas/builders/lazy/index.js +0 -7
- package/dist/core/schemas/builders/lazy/lazy.d.ts +0 -5
- package/dist/core/schemas/builders/lazy/lazy.js +0 -24
- package/dist/core/schemas/builders/lazy/lazyObject.d.ts +0 -3
- package/dist/core/schemas/builders/lazy/lazyObject.js +0 -11
- package/dist/core/schemas/builders/list/index.d.ts +0 -1
- package/dist/core/schemas/builders/list/index.js +0 -5
- package/dist/core/schemas/builders/list/list.d.ts +0 -2
- package/dist/core/schemas/builders/list/list.js +0 -54
- package/dist/core/schemas/builders/literals/booleanLiteral.d.ts +0 -2
- package/dist/core/schemas/builders/literals/booleanLiteral.js +0 -28
- package/dist/core/schemas/builders/literals/index.d.ts +0 -2
- package/dist/core/schemas/builders/literals/index.js +0 -7
- package/dist/core/schemas/builders/literals/stringLiteral.d.ts +0 -2
- package/dist/core/schemas/builders/literals/stringLiteral.js +0 -28
- package/dist/core/schemas/builders/object/index.d.ts +0 -6
- package/dist/core/schemas/builders/object/index.js +0 -11
- package/dist/core/schemas/builders/object/object.d.ts +0 -3
- package/dist/core/schemas/builders/object/object.js +0 -260
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +0 -6
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +0 -7
- package/dist/core/schemas/builders/object/property.d.ts +0 -8
- package/dist/core/schemas/builders/object/property.js +0 -15
- package/dist/core/schemas/builders/object/types.d.ts +0 -31
- package/dist/core/schemas/builders/object/types.js +0 -2
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.d.ts +0 -9
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +0 -53
- package/dist/core/schemas/builders/object-like/index.d.ts +0 -2
- package/dist/core/schemas/builders/object-like/index.js +0 -6
- package/dist/core/schemas/builders/object-like/types.d.ts +0 -7
- package/dist/core/schemas/builders/object-like/types.js +0 -2
- package/dist/core/schemas/builders/primitives/any.d.ts +0 -1
- package/dist/core/schemas/builders/primitives/any.js +0 -6
- package/dist/core/schemas/builders/primitives/boolean.d.ts +0 -1
- package/dist/core/schemas/builders/primitives/boolean.js +0 -25
- package/dist/core/schemas/builders/primitives/index.d.ts +0 -5
- package/dist/core/schemas/builders/primitives/index.js +0 -13
- package/dist/core/schemas/builders/primitives/number.d.ts +0 -1
- package/dist/core/schemas/builders/primitives/number.js +0 -25
- package/dist/core/schemas/builders/primitives/string.d.ts +0 -1
- package/dist/core/schemas/builders/primitives/string.js +0 -25
- package/dist/core/schemas/builders/primitives/unknown.d.ts +0 -1
- package/dist/core/schemas/builders/primitives/unknown.js +0 -6
- package/dist/core/schemas/builders/record/index.d.ts +0 -2
- package/dist/core/schemas/builders/record/index.js +0 -5
- package/dist/core/schemas/builders/record/record.d.ts +0 -3
- package/dist/core/schemas/builders/record/record.js +0 -94
- package/dist/core/schemas/builders/record/types.d.ts +0 -4
- package/dist/core/schemas/builders/record/types.js +0 -2
- package/dist/core/schemas/builders/schema-utils/JsonError.d.ts +0 -5
- package/dist/core/schemas/builders/schema-utils/JsonError.js +0 -12
- package/dist/core/schemas/builders/schema-utils/ParseError.d.ts +0 -5
- package/dist/core/schemas/builders/schema-utils/ParseError.js +0 -12
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +0 -17
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +0 -81
- package/dist/core/schemas/builders/schema-utils/index.d.ts +0 -4
- package/dist/core/schemas/builders/schema-utils/index.js +0 -11
- package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.d.ts +0 -2
- package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +0 -9
- package/dist/core/schemas/builders/set/index.d.ts +0 -1
- package/dist/core/schemas/builders/set/index.js +0 -5
- package/dist/core/schemas/builders/set/set.d.ts +0 -2
- package/dist/core/schemas/builders/set/set.js +0 -43
- package/dist/core/schemas/builders/undiscriminated-union/index.d.ts +0 -2
- package/dist/core/schemas/builders/undiscriminated-union/index.js +0 -5
- package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +0 -4
- package/dist/core/schemas/builders/undiscriminated-union/types.js +0 -2
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.d.ts +0 -3
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +0 -39
- package/dist/core/schemas/builders/union/discriminant.d.ts +0 -5
- package/dist/core/schemas/builders/union/discriminant.js +0 -9
- package/dist/core/schemas/builders/union/index.d.ts +0 -4
- package/dist/core/schemas/builders/union/index.js +0 -7
- package/dist/core/schemas/builders/union/types.d.ts +0 -13
- package/dist/core/schemas/builders/union/types.js +0 -2
- package/dist/core/schemas/builders/union/union.d.ts +0 -4
- package/dist/core/schemas/builders/union/union.js +0 -129
- package/dist/core/schemas/index.d.ts +0 -2
- package/dist/core/schemas/index.js +0 -17
- package/dist/core/schemas/utils/MaybePromise.d.ts +0 -1
- package/dist/core/schemas/utils/MaybePromise.js +0 -2
- package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +0 -7
- package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.js +0 -2
- package/dist/core/schemas/utils/createIdentitySchemaCreator.d.ts +0 -2
- package/dist/core/schemas/utils/createIdentitySchemaCreator.js +0 -15
- package/dist/core/schemas/utils/entries.d.ts +0 -1
- package/dist/core/schemas/utils/entries.js +0 -6
- package/dist/core/schemas/utils/filterObject.d.ts +0 -1
- package/dist/core/schemas/utils/filterObject.js +0 -13
- package/dist/core/schemas/utils/getErrorMessageForIncorrectType.d.ts +0 -1
- package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +0 -27
- package/dist/core/schemas/utils/isPlainObject.d.ts +0 -1
- package/dist/core/schemas/utils/isPlainObject.js +0 -17
- package/dist/core/schemas/utils/keys.d.ts +0 -1
- package/dist/core/schemas/utils/keys.js +0 -6
- package/dist/core/schemas/utils/maybeSkipValidation.d.ts +0 -2
- package/dist/core/schemas/utils/maybeSkipValidation.js +0 -27
- package/dist/core/schemas/utils/partition.d.ts +0 -1
- package/dist/core/schemas/utils/partition.js +0 -15
- package/dist/errors/AirweaveSDKError.d.ts +0 -12
- package/dist/errors/AirweaveSDKError.js +0 -32
- package/dist/errors/index.d.ts +0 -2
- package/dist/errors/index.js +0 -7
- package/dist/index.d.ts +0 -4
- package/dist/index.js +0 -44
- package/dist/serialization/index.d.ts +0 -2
- package/dist/serialization/index.js +0 -18
- package/dist/serialization/resources/collections/client/index.d.ts +0 -3
- package/dist/serialization/resources/collections/client/index.js +0 -42
- package/dist/serialization/resources/collections/client/listCollections.d.ts +0 -11
- package/dist/serialization/resources/collections/client/listCollections.js +0 -42
- package/dist/serialization/resources/collections/client/refreshAllSourceConnections.d.ts +0 -11
- package/dist/serialization/resources/collections/client/refreshAllSourceConnections.js +0 -42
- package/dist/serialization/resources/collections/client/requests/CollectionCreate.d.ts +0 -13
- package/dist/serialization/resources/collections/client/requests/CollectionCreate.js +0 -44
- package/dist/serialization/resources/collections/client/requests/index.d.ts +0 -1
- package/dist/serialization/resources/collections/client/requests/index.js +0 -5
- package/dist/serialization/resources/collections/index.d.ts +0 -1
- package/dist/serialization/resources/collections/index.js +0 -17
- package/dist/serialization/resources/index.d.ts +0 -6
- package/dist/serialization/resources/index.js +0 -45
- package/dist/serialization/resources/sourceConnections/client/index.d.ts +0 -3
- package/dist/serialization/resources/sourceConnections/client/index.js +0 -42
- package/dist/serialization/resources/sourceConnections/client/listSourceConnectionJobs.d.ts +0 -11
- package/dist/serialization/resources/sourceConnections/client/listSourceConnectionJobs.js +0 -42
- package/dist/serialization/resources/sourceConnections/client/listSourceConnections.d.ts +0 -11
- package/dist/serialization/resources/sourceConnections/client/listSourceConnections.js +0 -42
- package/dist/serialization/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.ts +0 -12
- package/dist/serialization/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.js +0 -43
- package/dist/serialization/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.ts +0 -20
- package/dist/serialization/resources/sourceConnections/client/requests/SourceConnectionUpdate.js +0 -51
- package/dist/serialization/resources/sourceConnections/client/requests/index.d.ts +0 -2
- package/dist/serialization/resources/sourceConnections/client/requests/index.js +0 -7
- package/dist/serialization/resources/sourceConnections/index.d.ts +0 -2
- package/dist/serialization/resources/sourceConnections/index.js +0 -18
- package/dist/serialization/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.d.ts +0 -11
- package/dist/serialization/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.js +0 -42
- package/dist/serialization/resources/sourceConnections/types/index.d.ts +0 -1
- package/dist/serialization/resources/sourceConnections/types/index.js +0 -17
- package/dist/serialization/resources/sources/client/index.d.ts +0 -1
- package/dist/serialization/resources/sources/client/index.js +0 -37
- package/dist/serialization/resources/sources/client/readSources.d.ts +0 -11
- package/dist/serialization/resources/sources/client/readSources.js +0 -42
- package/dist/serialization/resources/sources/index.d.ts +0 -1
- package/dist/serialization/resources/sources/index.js +0 -17
- package/dist/serialization/types/ApiKey.d.ts +0 -20
- package/dist/serialization/types/ApiKey.js +0 -51
- package/dist/serialization/types/ApiKeyCreate.d.ts +0 -12
- package/dist/serialization/types/ApiKeyCreate.js +0 -43
- package/dist/serialization/types/AuthType.d.ts +0 -10
- package/dist/serialization/types/AuthType.js +0 -50
- package/dist/serialization/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.d.ts +0 -13
- package/dist/serialization/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.js +0 -44
- package/dist/serialization/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.ts +0 -15
- package/dist/serialization/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.js +0 -46
- package/dist/serialization/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.ts +0 -14
- package/dist/serialization/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.js +0 -45
- package/dist/serialization/types/Chat.d.ts +0 -25
- package/dist/serialization/types/Chat.js +0 -56
- package/dist/serialization/types/ChatCreate.d.ts +0 -17
- package/dist/serialization/types/ChatCreate.js +0 -48
- package/dist/serialization/types/ChatMessage.d.ts +0 -21
- package/dist/serialization/types/ChatMessage.js +0 -52
- package/dist/serialization/types/ChatMessageCreate.d.ts +0 -13
- package/dist/serialization/types/ChatMessageCreate.js +0 -44
- package/dist/serialization/types/ChatUpdate.d.ts +0 -15
- package/dist/serialization/types/ChatUpdate.js +0 -46
- package/dist/serialization/types/Collection.d.ts +0 -21
- package/dist/serialization/types/Collection.js +0 -52
- package/dist/serialization/types/CollectionStatus.d.ts +0 -10
- package/dist/serialization/types/CollectionStatus.js +0 -41
- package/dist/serialization/types/CollectionUpdate.d.ts +0 -12
- package/dist/serialization/types/CollectionUpdate.js +0 -43
- package/dist/serialization/types/ConfigField.d.ts +0 -15
- package/dist/serialization/types/ConfigField.js +0 -46
- package/dist/serialization/types/ConfigValues.d.ts +0 -10
- package/dist/serialization/types/ConfigValues.js +0 -41
- package/dist/serialization/types/Connection.d.ts +0 -22
- package/dist/serialization/types/Connection.js +0 -53
- package/dist/serialization/types/ConnectionStatus.d.ts +0 -10
- package/dist/serialization/types/ConnectionStatus.js +0 -41
- package/dist/serialization/types/DagEdge.d.ts +0 -18
- package/dist/serialization/types/DagEdge.js +0 -49
- package/dist/serialization/types/DagEdgeCreate.d.ts +0 -13
- package/dist/serialization/types/DagEdgeCreate.js +0 -44
- package/dist/serialization/types/DagNode.d.ts +0 -23
- package/dist/serialization/types/DagNode.js +0 -54
- package/dist/serialization/types/DagNodeCreate.d.ts +0 -19
- package/dist/serialization/types/DagNodeCreate.js +0 -50
- package/dist/serialization/types/Destination.d.ts +0 -25
- package/dist/serialization/types/Destination.js +0 -56
- package/dist/serialization/types/DestinationWithAuthenticationFields.d.ts +0 -27
- package/dist/serialization/types/DestinationWithAuthenticationFields.js +0 -58
- package/dist/serialization/types/EmbeddingModel.d.ts +0 -23
- package/dist/serialization/types/EmbeddingModel.js +0 -54
- package/dist/serialization/types/EmbeddingModelWithAuthenticationFields.d.ts +0 -25
- package/dist/serialization/types/EmbeddingModelWithAuthenticationFields.js +0 -56
- package/dist/serialization/types/EntityCount.d.ts +0 -12
- package/dist/serialization/types/EntityCount.js +0 -43
- package/dist/serialization/types/EntityDefinition.d.ts +0 -22
- package/dist/serialization/types/EntityDefinition.js +0 -53
- package/dist/serialization/types/EntityDefinitionCreate.d.ts +0 -20
- package/dist/serialization/types/EntityDefinitionCreate.js +0 -51
- package/dist/serialization/types/EntityDefinitionCreateEntitySchema.d.ts +0 -10
- package/dist/serialization/types/EntityDefinitionCreateEntitySchema.js +0 -44
- package/dist/serialization/types/EntityDefinitionEntitySchema.d.ts +0 -10
- package/dist/serialization/types/EntityDefinitionEntitySchema.js +0 -44
- package/dist/serialization/types/EntityDefinitionUpdate.d.ts +0 -20
- package/dist/serialization/types/EntityDefinitionUpdate.js +0 -51
- package/dist/serialization/types/EntityDefinitionUpdateEntitySchema.d.ts +0 -10
- package/dist/serialization/types/EntityDefinitionUpdateEntitySchema.js +0 -44
- package/dist/serialization/types/EntityRelation.d.ts +0 -19
- package/dist/serialization/types/EntityRelation.js +0 -50
- package/dist/serialization/types/EntityRelationCreate.d.ts +0 -15
- package/dist/serialization/types/EntityRelationCreate.js +0 -46
- package/dist/serialization/types/EntityRelationUpdate.d.ts +0 -15
- package/dist/serialization/types/EntityRelationUpdate.js +0 -46
- package/dist/serialization/types/EntityType.d.ts +0 -10
- package/dist/serialization/types/EntityType.js +0 -41
- package/dist/serialization/types/Fields.d.ts +0 -13
- package/dist/serialization/types/Fields.js +0 -44
- package/dist/serialization/types/HttpValidationError.d.ts +0 -13
- package/dist/serialization/types/HttpValidationError.js +0 -44
- package/dist/serialization/types/IntegrationCredentialInDb.d.ts +0 -22
- package/dist/serialization/types/IntegrationCredentialInDb.js +0 -53
- package/dist/serialization/types/IntegrationCredentialRawCreate.d.ts +0 -20
- package/dist/serialization/types/IntegrationCredentialRawCreate.js +0 -51
- package/dist/serialization/types/IntegrationType.d.ts +0 -10
- package/dist/serialization/types/IntegrationType.js +0 -41
- package/dist/serialization/types/NodeType.d.ts +0 -10
- package/dist/serialization/types/NodeType.js +0 -41
- package/dist/serialization/types/OAuth2AuthUrl.d.ts +0 -12
- package/dist/serialization/types/OAuth2AuthUrl.js +0 -43
- package/dist/serialization/types/Organization.d.ts +0 -16
- package/dist/serialization/types/Organization.js +0 -47
- package/dist/serialization/types/ResponseType.d.ts +0 -10
- package/dist/serialization/types/ResponseType.js +0 -41
- package/dist/serialization/types/SearchResponse.d.ts +0 -17
- package/dist/serialization/types/SearchResponse.js +0 -48
- package/dist/serialization/types/SearchStatus.d.ts +0 -10
- package/dist/serialization/types/SearchStatus.js +0 -41
- package/dist/serialization/types/Source.d.ts +0 -29
- package/dist/serialization/types/Source.js +0 -60
- package/dist/serialization/types/SourceConnection.d.ts +0 -38
- package/dist/serialization/types/SourceConnection.js +0 -69
- package/dist/serialization/types/SourceConnectionAuthFields.d.ts +0 -11
- package/dist/serialization/types/SourceConnectionAuthFields.js +0 -42
- package/dist/serialization/types/SourceConnectionCreate.d.ts +0 -22
- package/dist/serialization/types/SourceConnectionCreate.js +0 -53
- package/dist/serialization/types/SourceConnectionJob.d.ts +0 -30
- package/dist/serialization/types/SourceConnectionJob.js +0 -61
- package/dist/serialization/types/SourceConnectionListItem.d.ts +0 -22
- package/dist/serialization/types/SourceConnectionListItem.js +0 -53
- package/dist/serialization/types/SourceConnectionStatus.d.ts +0 -10
- package/dist/serialization/types/SourceConnectionStatus.js +0 -41
- package/dist/serialization/types/Sync.d.ts +0 -27
- package/dist/serialization/types/Sync.js +0 -58
- package/dist/serialization/types/SyncCreate.d.ts +0 -22
- package/dist/serialization/types/SyncCreate.js +0 -53
- package/dist/serialization/types/SyncDag.d.ts +0 -22
- package/dist/serialization/types/SyncDag.js +0 -53
- package/dist/serialization/types/SyncDagCreate.d.ts +0 -18
- package/dist/serialization/types/SyncDagCreate.js +0 -49
- package/dist/serialization/types/SyncDagUpdate.d.ts +0 -18
- package/dist/serialization/types/SyncDagUpdate.js +0 -49
- package/dist/serialization/types/SyncJob.d.ts +0 -32
- package/dist/serialization/types/SyncJob.js +0 -63
- package/dist/serialization/types/SyncJobStatus.d.ts +0 -10
- package/dist/serialization/types/SyncJobStatus.js +0 -41
- package/dist/serialization/types/SyncStatus.d.ts +0 -10
- package/dist/serialization/types/SyncStatus.js +0 -41
- package/dist/serialization/types/SyncUpdate.d.ts +0 -17
- package/dist/serialization/types/SyncUpdate.js +0 -48
- package/dist/serialization/types/SyncWithSourceConnection.d.ts +0 -29
- package/dist/serialization/types/SyncWithSourceConnection.js +0 -60
- package/dist/serialization/types/Transformer.d.ts +0 -22
- package/dist/serialization/types/Transformer.js +0 -53
- package/dist/serialization/types/TransformerCreate.d.ts +0 -18
- package/dist/serialization/types/TransformerCreate.js +0 -49
- package/dist/serialization/types/TransformerUpdate.d.ts +0 -18
- package/dist/serialization/types/TransformerUpdate.js +0 -49
- package/dist/serialization/types/User.d.ts +0 -16
- package/dist/serialization/types/User.js +0 -47
- package/dist/serialization/types/UserCreate.d.ts +0 -14
- package/dist/serialization/types/UserCreate.js +0 -45
- package/dist/serialization/types/ValidationError.d.ts +0 -15
- package/dist/serialization/types/ValidationError.js +0 -46
- package/dist/serialization/types/ValidationErrorLocItem.d.ts +0 -10
- package/dist/serialization/types/ValidationErrorLocItem.js +0 -41
- package/dist/serialization/types/WhiteLabel.d.ts +0 -23
- package/dist/serialization/types/WhiteLabel.js +0 -54
- package/dist/serialization/types/WhiteLabelCreate.d.ts +0 -17
- package/dist/serialization/types/WhiteLabelCreate.js +0 -48
- package/dist/serialization/types/WhiteLabelUpdate.d.ts +0 -16
- package/dist/serialization/types/WhiteLabelUpdate.js +0 -47
- package/dist/serialization/types/index.d.ts +0 -75
- package/dist/serialization/types/index.js +0 -91
- package/dist/version.d.ts +0 -1
- package/dist/version.js +0 -4
- package/environments.js +0 -10
- package/errors/AirweaveSDKError.d.ts +0 -12
- package/errors/AirweaveSDKError.js +0 -32
- package/errors/AirweaveSDKTimeoutError.js +0 -13
- package/errors/index.d.ts +0 -2
- package/errors/index.js +0 -7
- package/index.d.ts +0 -4
- package/index.js +0 -44
- package/jest.config.js +0 -5
- package/serialization/index.d.ts +0 -2
- package/serialization/index.js +0 -18
- package/serialization/resources/collections/client/index.d.ts +0 -3
- package/serialization/resources/collections/client/index.js +0 -42
- package/serialization/resources/collections/client/listCollections.d.ts +0 -11
- package/serialization/resources/collections/client/listCollections.js +0 -42
- package/serialization/resources/collections/client/refreshAllSourceConnections.d.ts +0 -11
- package/serialization/resources/collections/client/refreshAllSourceConnections.js +0 -42
- package/serialization/resources/collections/client/requests/CollectionCreate.d.ts +0 -13
- package/serialization/resources/collections/client/requests/CollectionCreate.js +0 -44
- package/serialization/resources/collections/client/requests/index.d.ts +0 -1
- package/serialization/resources/collections/client/requests/index.js +0 -5
- package/serialization/resources/collections/index.d.ts +0 -1
- package/serialization/resources/collections/index.js +0 -17
- package/serialization/resources/index.d.ts +0 -6
- package/serialization/resources/index.js +0 -45
- package/serialization/resources/sourceConnections/client/index.d.ts +0 -3
- package/serialization/resources/sourceConnections/client/index.js +0 -42
- package/serialization/resources/sourceConnections/client/listSourceConnectionJobs.d.ts +0 -11
- package/serialization/resources/sourceConnections/client/listSourceConnectionJobs.js +0 -42
- package/serialization/resources/sourceConnections/client/listSourceConnections.d.ts +0 -11
- package/serialization/resources/sourceConnections/client/listSourceConnections.js +0 -42
- package/serialization/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.d.ts +0 -12
- package/serialization/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.js +0 -43
- package/serialization/resources/sourceConnections/client/requests/SourceConnectionUpdate.d.ts +0 -20
- package/serialization/resources/sourceConnections/client/requests/SourceConnectionUpdate.js +0 -51
- package/serialization/resources/sourceConnections/client/requests/index.d.ts +0 -2
- package/serialization/resources/sourceConnections/client/requests/index.js +0 -7
- package/serialization/resources/sourceConnections/index.d.ts +0 -2
- package/serialization/resources/sourceConnections/index.js +0 -18
- package/serialization/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.d.ts +0 -11
- package/serialization/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.js +0 -42
- package/serialization/resources/sourceConnections/types/index.d.ts +0 -1
- package/serialization/resources/sourceConnections/types/index.js +0 -17
- package/serialization/resources/sources/client/index.d.ts +0 -1
- package/serialization/resources/sources/client/index.js +0 -37
- package/serialization/resources/sources/client/readSources.d.ts +0 -11
- package/serialization/resources/sources/client/readSources.js +0 -42
- package/serialization/resources/sources/index.d.ts +0 -1
- package/serialization/resources/sources/index.js +0 -17
- package/serialization/types/ApiKey.d.ts +0 -20
- package/serialization/types/ApiKey.js +0 -51
- package/serialization/types/ApiKeyCreate.d.ts +0 -12
- package/serialization/types/ApiKeyCreate.js +0 -43
- package/serialization/types/AuthType.d.ts +0 -10
- package/serialization/types/AuthType.js +0 -50
- package/serialization/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.d.ts +0 -13
- package/serialization/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.js +0 -44
- package/serialization/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.d.ts +0 -15
- package/serialization/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.js +0 -46
- package/serialization/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.d.ts +0 -14
- package/serialization/types/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.js +0 -45
- package/serialization/types/Chat.d.ts +0 -25
- package/serialization/types/Chat.js +0 -56
- package/serialization/types/ChatCreate.d.ts +0 -17
- package/serialization/types/ChatCreate.js +0 -48
- package/serialization/types/ChatMessage.d.ts +0 -21
- package/serialization/types/ChatMessage.js +0 -52
- package/serialization/types/ChatMessageCreate.d.ts +0 -13
- package/serialization/types/ChatMessageCreate.js +0 -44
- package/serialization/types/ChatUpdate.d.ts +0 -15
- package/serialization/types/ChatUpdate.js +0 -46
- package/serialization/types/Collection.d.ts +0 -21
- package/serialization/types/Collection.js +0 -52
- package/serialization/types/CollectionStatus.d.ts +0 -10
- package/serialization/types/CollectionStatus.js +0 -41
- package/serialization/types/CollectionUpdate.d.ts +0 -12
- package/serialization/types/CollectionUpdate.js +0 -43
- package/serialization/types/ConfigField.d.ts +0 -15
- package/serialization/types/ConfigField.js +0 -46
- package/serialization/types/ConfigValues.d.ts +0 -10
- package/serialization/types/ConfigValues.js +0 -41
- package/serialization/types/Connection.d.ts +0 -22
- package/serialization/types/Connection.js +0 -53
- package/serialization/types/ConnectionStatus.d.ts +0 -10
- package/serialization/types/ConnectionStatus.js +0 -41
- package/serialization/types/DagEdge.d.ts +0 -18
- package/serialization/types/DagEdge.js +0 -49
- package/serialization/types/DagEdgeCreate.d.ts +0 -13
- package/serialization/types/DagEdgeCreate.js +0 -44
- package/serialization/types/DagNode.d.ts +0 -23
- package/serialization/types/DagNode.js +0 -54
- package/serialization/types/DagNodeCreate.d.ts +0 -19
- package/serialization/types/DagNodeCreate.js +0 -50
- package/serialization/types/Destination.d.ts +0 -25
- package/serialization/types/Destination.js +0 -56
- package/serialization/types/DestinationWithAuthenticationFields.d.ts +0 -27
- package/serialization/types/DestinationWithAuthenticationFields.js +0 -58
- package/serialization/types/EmbeddingModel.d.ts +0 -23
- package/serialization/types/EmbeddingModel.js +0 -54
- package/serialization/types/EmbeddingModelWithAuthenticationFields.d.ts +0 -25
- package/serialization/types/EmbeddingModelWithAuthenticationFields.js +0 -56
- package/serialization/types/EntityCount.d.ts +0 -12
- package/serialization/types/EntityCount.js +0 -43
- package/serialization/types/EntityDefinition.d.ts +0 -22
- package/serialization/types/EntityDefinition.js +0 -53
- package/serialization/types/EntityDefinitionCreate.d.ts +0 -20
- package/serialization/types/EntityDefinitionCreate.js +0 -51
- package/serialization/types/EntityDefinitionCreateEntitySchema.d.ts +0 -10
- package/serialization/types/EntityDefinitionCreateEntitySchema.js +0 -44
- package/serialization/types/EntityDefinitionEntitySchema.d.ts +0 -10
- package/serialization/types/EntityDefinitionEntitySchema.js +0 -44
- package/serialization/types/EntityDefinitionUpdate.d.ts +0 -20
- package/serialization/types/EntityDefinitionUpdate.js +0 -51
- package/serialization/types/EntityDefinitionUpdateEntitySchema.d.ts +0 -10
- package/serialization/types/EntityDefinitionUpdateEntitySchema.js +0 -44
- package/serialization/types/EntityRelation.d.ts +0 -19
- package/serialization/types/EntityRelation.js +0 -50
- package/serialization/types/EntityRelationCreate.d.ts +0 -15
- package/serialization/types/EntityRelationCreate.js +0 -46
- package/serialization/types/EntityRelationUpdate.d.ts +0 -15
- package/serialization/types/EntityRelationUpdate.js +0 -46
- package/serialization/types/EntityType.d.ts +0 -10
- package/serialization/types/EntityType.js +0 -41
- package/serialization/types/Fields.d.ts +0 -13
- package/serialization/types/Fields.js +0 -44
- package/serialization/types/HttpValidationError.d.ts +0 -13
- package/serialization/types/HttpValidationError.js +0 -44
- package/serialization/types/IntegrationCredentialInDb.d.ts +0 -22
- package/serialization/types/IntegrationCredentialInDb.js +0 -53
- package/serialization/types/IntegrationCredentialRawCreate.d.ts +0 -20
- package/serialization/types/IntegrationCredentialRawCreate.js +0 -51
- package/serialization/types/IntegrationType.d.ts +0 -10
- package/serialization/types/IntegrationType.js +0 -41
- package/serialization/types/NodeType.d.ts +0 -10
- package/serialization/types/NodeType.js +0 -41
- package/serialization/types/OAuth2AuthUrl.d.ts +0 -12
- package/serialization/types/OAuth2AuthUrl.js +0 -43
- package/serialization/types/Organization.d.ts +0 -16
- package/serialization/types/Organization.js +0 -47
- package/serialization/types/ResponseType.d.ts +0 -10
- package/serialization/types/ResponseType.js +0 -41
- package/serialization/types/SearchResponse.d.ts +0 -17
- package/serialization/types/SearchResponse.js +0 -48
- package/serialization/types/SearchStatus.d.ts +0 -10
- package/serialization/types/SearchStatus.js +0 -41
- package/serialization/types/Source.d.ts +0 -29
- package/serialization/types/Source.js +0 -60
- package/serialization/types/SourceConnection.d.ts +0 -38
- package/serialization/types/SourceConnection.js +0 -69
- package/serialization/types/SourceConnectionAuthFields.d.ts +0 -11
- package/serialization/types/SourceConnectionAuthFields.js +0 -42
- package/serialization/types/SourceConnectionCreate.d.ts +0 -22
- package/serialization/types/SourceConnectionCreate.js +0 -53
- package/serialization/types/SourceConnectionJob.d.ts +0 -30
- package/serialization/types/SourceConnectionJob.js +0 -61
- package/serialization/types/SourceConnectionListItem.d.ts +0 -22
- package/serialization/types/SourceConnectionListItem.js +0 -53
- package/serialization/types/SourceConnectionStatus.d.ts +0 -10
- package/serialization/types/SourceConnectionStatus.js +0 -41
- package/serialization/types/Sync.d.ts +0 -27
- package/serialization/types/Sync.js +0 -58
- package/serialization/types/SyncCreate.d.ts +0 -22
- package/serialization/types/SyncCreate.js +0 -53
- package/serialization/types/SyncDag.d.ts +0 -22
- package/serialization/types/SyncDag.js +0 -53
- package/serialization/types/SyncDagCreate.d.ts +0 -18
- package/serialization/types/SyncDagCreate.js +0 -49
- package/serialization/types/SyncDagUpdate.d.ts +0 -18
- package/serialization/types/SyncDagUpdate.js +0 -49
- package/serialization/types/SyncJob.d.ts +0 -32
- package/serialization/types/SyncJob.js +0 -63
- package/serialization/types/SyncJobStatus.d.ts +0 -10
- package/serialization/types/SyncJobStatus.js +0 -41
- package/serialization/types/SyncStatus.d.ts +0 -10
- package/serialization/types/SyncStatus.js +0 -41
- package/serialization/types/SyncUpdate.d.ts +0 -17
- package/serialization/types/SyncUpdate.js +0 -48
- package/serialization/types/SyncWithSourceConnection.d.ts +0 -29
- package/serialization/types/SyncWithSourceConnection.js +0 -60
- package/serialization/types/Transformer.d.ts +0 -22
- package/serialization/types/Transformer.js +0 -53
- package/serialization/types/TransformerCreate.d.ts +0 -18
- package/serialization/types/TransformerCreate.js +0 -49
- package/serialization/types/TransformerUpdate.d.ts +0 -18
- package/serialization/types/TransformerUpdate.js +0 -49
- package/serialization/types/User.d.ts +0 -16
- package/serialization/types/User.js +0 -47
- package/serialization/types/UserCreate.d.ts +0 -14
- package/serialization/types/UserCreate.js +0 -45
- package/serialization/types/ValidationError.d.ts +0 -15
- package/serialization/types/ValidationError.js +0 -46
- package/serialization/types/ValidationErrorLocItem.d.ts +0 -10
- package/serialization/types/ValidationErrorLocItem.js +0 -41
- package/serialization/types/WhiteLabel.d.ts +0 -23
- package/serialization/types/WhiteLabel.js +0 -54
- package/serialization/types/WhiteLabelCreate.d.ts +0 -17
- package/serialization/types/WhiteLabelCreate.js +0 -48
- package/serialization/types/WhiteLabelUpdate.d.ts +0 -16
- package/serialization/types/WhiteLabelUpdate.js +0 -47
- package/serialization/types/index.d.ts +0 -75
- package/serialization/types/index.js +0 -91
- package/version.d.ts +0 -1
- package/version.js +0 -4
- /package/{api → dist/cjs/api}/resources/collections/client/requests/CollectionCreate.js +0 -0
- /package/{api/types → dist/cjs/api/resources/collections/client/requests}/CollectionUpdate.js +0 -0
- /package/{api → dist/cjs/api}/resources/collections/client/requests/DeleteCollectionCollectionsReadableIdDeleteRequest.js +0 -0
- /package/{api → dist/cjs/api}/resources/collections/client/requests/ListCollectionsCollectionsGetRequest.js +0 -0
- /package/{api → dist/cjs/api}/resources/collections/client/requests/SearchCollectionCollectionsReadableIdSearchGetRequest.js +0 -0
- /package/{api → dist/cjs/api}/resources/collections/client/requests/index.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/BodyRunSourceConnectionSourceConnectionsSourceConnectionIdRunPost.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/DeleteSourceConnectionSourceConnectionsSourceConnectionIdDeleteRequest.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/GetSourceConnectionSourceConnectionsSourceConnectionIdGetRequest.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/ListSourceConnectionsSourceConnectionsGetRequest.js +0 -0
- /package/{api/types → dist/cjs/api/resources/sourceConnections/client/requests}/SourceConnectionCreate.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/SourceConnectionUpdate.js +0 -0
- /package/{api → dist/cjs/api}/resources/sourceConnections/client/requests/index.js +0 -0
- /package/{api → dist/cjs/api}/resources/sources/client/index.d.ts +0 -0
- /package/{api → dist/cjs/api}/resources/sources/client/index.js +0 -0
- /package/{api/types → dist/cjs/api/resources/whiteLabels/client/requests}/BodyExchangeWhiteLabelOauth2CodeWhiteLabelsWhiteLabelIdOauth2CodeOptions.js +0 -0
- /package/{api/types → dist/cjs/api/resources/whiteLabels/client/requests}/WhiteLabelCreate.js +0 -0
- /package/{api/types → dist/cjs/api/resources/whiteLabels/client/requests}/WhiteLabelUpdate.js +0 -0
- /package/dist/{api/resources/collections → cjs/api/resources/whiteLabels}/client/requests/index.js +0 -0
- /package/{api → dist/cjs/api}/types/ApiKey.js +0 -0
- /package/{api → dist/cjs/api}/types/ApiKeyCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/AuthType.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/AuthType.js +0 -0
- /package/{api → dist/cjs/api}/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.js +0 -0
- /package/{api → dist/cjs/api}/types/BodyCreateCredentialsFromAuthorizationCodeSourceConnectionsSourceShortNameCodeToTokenCredentialsPost.js +0 -0
- /package/{api → dist/cjs/api}/types/Collection.js +0 -0
- /package/{api → dist/cjs/api}/types/CollectionStatus.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/CollectionStatus.js +0 -0
- /package/{api → dist/cjs/api}/types/ConfigField.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/ConfigField.js +0 -0
- /package/{api → dist/cjs/api}/types/ConfigValues.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/ConfigValues.js +0 -0
- /package/{api → dist/cjs/api}/types/Connection.js +0 -0
- /package/{api → dist/cjs/api}/types/ConnectionStatus.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/ConnectionStatus.js +0 -0
- /package/{api → dist/cjs/api}/types/DagEdge.js +0 -0
- /package/{api → dist/cjs/api}/types/DagEdgeCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/DagNode.js +0 -0
- /package/{api → dist/cjs/api}/types/DagNodeCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/Destination.js +0 -0
- /package/{api → dist/cjs/api}/types/DestinationWithAuthenticationFields.js +0 -0
- /package/{api → dist/cjs/api}/types/EmbeddingModel.js +0 -0
- /package/{api → dist/cjs/api}/types/EmbeddingModelWithAuthenticationFields.js +0 -0
- /package/{api → dist/cjs/api}/types/EntityCount.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/EntityCount.js +0 -0
- /package/{api → dist/cjs/api}/types/EntityDefinition.js +0 -0
- /package/{api → dist/cjs/api}/types/EntityDefinitionCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/EntityDefinitionUpdate.js +0 -0
- /package/{api → dist/cjs/api}/types/EntityType.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/EntityType.js +0 -0
- /package/{api → dist/cjs/api}/types/Fields.js +0 -0
- /package/{api → dist/cjs/api}/types/HttpValidationError.js +0 -0
- /package/{api → dist/cjs/api}/types/IntegrationCredentialInDb.js +0 -0
- /package/{api → dist/cjs/api}/types/IntegrationCredentialRawCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/IntegrationType.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/IntegrationType.js +0 -0
- /package/{api/resources/sourceConnections/types/SourceConnectionUpdateAuthFields.js → dist/cjs/api/types/InvitationCreate.js} +0 -0
- /package/{api/types/Chat.js → dist/cjs/api/types/InvitationResponse.js} +0 -0
- /package/{api/types/ChatCreate.js → dist/cjs/api/types/MemberResponse.js} +0 -0
- /package/{api → dist/cjs/api}/types/NodeType.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/NodeType.js +0 -0
- /package/{api → dist/cjs/api}/types/OAuth2AuthUrl.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/OAuth2AuthUrl.js +0 -0
- /package/{api → dist/cjs/api}/types/Organization.js +0 -0
- /package/{api/types/ChatMessage.js → dist/cjs/api/types/OrganizationCreate.js} +0 -0
- /package/{api/types/ChatMessageCreate.js → dist/cjs/api/types/OrganizationWithRole.js} +0 -0
- /package/{api → dist/cjs/api}/types/ResponseType.js +0 -0
- /package/{api → dist/cjs/api}/types/SearchResponse.js +0 -0
- /package/{api → dist/cjs/api}/types/SearchStatus.js +0 -0
- /package/{api → dist/cjs/api}/types/Source.js +0 -0
- /package/{api → dist/cjs/api}/types/SourceConnection.js +0 -0
- /package/{api/types/ChatUpdate.js → dist/cjs/api/types/SourceConnectionCreateWithCredential.js} +0 -0
- /package/{api/types/EntityDefinitionCreateEntitySchema.js → dist/cjs/api/types/SourceConnectionCreateWithWhiteLabel.js} +0 -0
- /package/{api → dist/cjs/api}/types/SourceConnectionJob.js +0 -0
- /package/{api → dist/cjs/api}/types/SourceConnectionListItem.js +0 -0
- /package/{api → dist/cjs/api}/types/SourceConnectionStatus.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/SourceConnectionStatus.js +0 -0
- /package/{api → dist/cjs/api}/types/Sync.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncDag.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncDagCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncDagUpdate.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncJob.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncStatus.d.ts +0 -0
- /package/{api → dist/cjs/api}/types/SyncStatus.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncUpdate.js +0 -0
- /package/{api → dist/cjs/api}/types/SyncWithSourceConnection.js +0 -0
- /package/{api → dist/cjs/api}/types/Transformer.js +0 -0
- /package/{api → dist/cjs/api}/types/TransformerCreate.js +0 -0
- /package/{api → dist/cjs/api}/types/TransformerUpdate.js +0 -0
- /package/{api → dist/cjs/api}/types/User.js +0 -0
- /package/{api → dist/cjs/api}/types/UserCreate.js +0 -0
- /package/{api/types/EntityDefinitionEntitySchema.js → dist/cjs/api/types/UserOrganization.js} +0 -0
- /package/{api → dist/cjs/api}/types/ValidationError.js +0 -0
- /package/{api → dist/cjs/api}/types/WhiteLabel.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/APIResponse.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/Supplier.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/Supplier.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/getFetchFn.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/getHeader.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/getHeader.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/getRequestBody.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/getResponseBody.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/makeRequest.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/requestWithRetries.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/signals.d.ts +0 -0
- /package/{core → dist/cjs/core}/fetcher/signals.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -0
- /package/{core → dist/cjs/core}/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -0
- /package/dist/{environments.d.ts → cjs/environments.d.ts} +0 -0
- /package/dist/{environments.js → cjs/environments.js} +0 -0
- /package/dist/{errors → cjs/errors}/AirweaveSDKTimeoutError.d.ts +0 -0
- /package/dist/{errors → cjs/errors}/AirweaveSDKTimeoutError.js +0 -0
- /package/dist/{api/resources/sources/client/index.d.ts → esm/api/resources/collections/client/requests/index.mjs} +0 -0
- /package/dist/{api/types/AuthType.d.ts → esm/api/types/AuthType.d.mts} +0 -0
- /package/dist/{api/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.d.ts → esm/api/types/BodyConnectSlackWithTokenConnectionsDirectTokenSlackPost.d.mts} +0 -0
- /package/dist/{api/types/CollectionStatus.d.ts → esm/api/types/CollectionStatus.d.mts} +0 -0
- /package/dist/{api/types/ConfigField.d.ts → esm/api/types/ConfigField.d.mts} +0 -0
- /package/dist/{api/types/ConfigValues.d.ts → esm/api/types/ConfigValues.d.mts} +0 -0
- /package/dist/{api/types/ConnectionStatus.d.ts → esm/api/types/ConnectionStatus.d.mts} +0 -0
- /package/dist/{api/types/EntityCount.d.ts → esm/api/types/EntityCount.d.mts} +0 -0
- /package/dist/{api/types/EntityType.d.ts → esm/api/types/EntityType.d.mts} +0 -0
- /package/dist/{api/types/IntegrationType.d.ts → esm/api/types/IntegrationType.d.mts} +0 -0
- /package/dist/{api/types/NodeType.d.ts → esm/api/types/NodeType.d.mts} +0 -0
- /package/dist/{api/types/OAuth2AuthUrl.d.ts → esm/api/types/OAuth2AuthUrl.d.mts} +0 -0
- /package/dist/{api/types/SourceConnectionStatus.d.ts → esm/api/types/SourceConnectionStatus.d.mts} +0 -0
- /package/dist/{api/types/SyncStatus.d.ts → esm/api/types/SyncStatus.d.mts} +0 -0
- /package/dist/{core/fetcher/Supplier.d.ts → esm/core/fetcher/Supplier.d.mts} +0 -0
- /package/dist/{core/fetcher/getFetchFn.d.ts → esm/core/fetcher/getFetchFn.d.mts} +0 -0
- /package/dist/{core/fetcher/getHeader.d.ts → esm/core/fetcher/getHeader.d.mts} +0 -0
- /package/dist/{core/fetcher/getRequestBody.d.ts → esm/core/fetcher/getRequestBody.d.mts} +0 -0
- /package/dist/{core/fetcher/getResponseBody.d.ts → esm/core/fetcher/getResponseBody.d.mts} +0 -0
- /package/dist/{core/fetcher/makeRequest.d.ts → esm/core/fetcher/makeRequest.d.mts} +0 -0
- /package/dist/{core/fetcher/requestWithRetries.d.ts → esm/core/fetcher/requestWithRetries.d.mts} +0 -0
- /package/dist/{core/fetcher/signals.d.ts → esm/core/fetcher/signals.d.mts} +0 -0
- /package/dist/{core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts → esm/core/fetcher/stream-wrappers/chooseStreamWrapper.d.mts} +0 -0
- /package/{environments.d.ts → dist/esm/environments.d.mts} +0 -0
- /package/{errors/AirweaveSDKTimeoutError.d.ts → dist/esm/errors/AirweaveSDKTimeoutError.d.mts} +0 -0
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
let Headers;
|
|
2
|
+
if (typeof globalThis.Headers !== "undefined") {
|
|
3
|
+
Headers = globalThis.Headers;
|
|
4
|
+
}
|
|
5
|
+
else {
|
|
6
|
+
Headers = class Headers {
|
|
7
|
+
constructor(init) {
|
|
8
|
+
this.headers = new Map();
|
|
9
|
+
if (init) {
|
|
10
|
+
if (init instanceof Headers) {
|
|
11
|
+
init.forEach((value, key) => this.append(key, value));
|
|
12
|
+
}
|
|
13
|
+
else if (Array.isArray(init)) {
|
|
14
|
+
for (const [key, value] of init) {
|
|
15
|
+
if (typeof key === "string" && typeof value === "string") {
|
|
16
|
+
this.append(key, value);
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
throw new TypeError("Each header entry must be a [string, string] tuple");
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
for (const [key, value] of Object.entries(init)) {
|
|
25
|
+
if (typeof value === "string") {
|
|
26
|
+
this.append(key, value);
|
|
27
|
+
}
|
|
28
|
+
else {
|
|
29
|
+
throw new TypeError("Header values must be strings");
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
append(name, value) {
|
|
36
|
+
const key = name.toLowerCase();
|
|
37
|
+
const existing = this.headers.get(key) || [];
|
|
38
|
+
this.headers.set(key, [...existing, value]);
|
|
39
|
+
}
|
|
40
|
+
delete(name) {
|
|
41
|
+
const key = name.toLowerCase();
|
|
42
|
+
this.headers.delete(key);
|
|
43
|
+
}
|
|
44
|
+
get(name) {
|
|
45
|
+
const key = name.toLowerCase();
|
|
46
|
+
const values = this.headers.get(key);
|
|
47
|
+
return values ? values.join(", ") : null;
|
|
48
|
+
}
|
|
49
|
+
has(name) {
|
|
50
|
+
const key = name.toLowerCase();
|
|
51
|
+
return this.headers.has(key);
|
|
52
|
+
}
|
|
53
|
+
set(name, value) {
|
|
54
|
+
const key = name.toLowerCase();
|
|
55
|
+
this.headers.set(key, [value]);
|
|
56
|
+
}
|
|
57
|
+
forEach(callbackfn, thisArg) {
|
|
58
|
+
const boundCallback = thisArg ? callbackfn.bind(thisArg) : callbackfn;
|
|
59
|
+
this.headers.forEach((values, key) => boundCallback(values.join(", "), key, this));
|
|
60
|
+
}
|
|
61
|
+
getSetCookie() {
|
|
62
|
+
return this.headers.get("set-cookie") || [];
|
|
63
|
+
}
|
|
64
|
+
*entries() {
|
|
65
|
+
for (const [key, values] of this.headers.entries()) {
|
|
66
|
+
yield [key, values.join(", ")];
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
*keys() {
|
|
70
|
+
yield* this.headers.keys();
|
|
71
|
+
}
|
|
72
|
+
*values() {
|
|
73
|
+
for (const values of this.headers.values()) {
|
|
74
|
+
yield values.join(", ");
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
[Symbol.iterator]() {
|
|
78
|
+
return this.entries();
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
export { Headers };
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { WithRawResponse } from "./RawResponse.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* A promise that returns the parsed response and lets you retrieve the raw response too.
|
|
4
|
+
*/
|
|
5
|
+
export declare class HttpResponsePromise<T> extends Promise<T> {
|
|
6
|
+
private innerPromise;
|
|
7
|
+
private unwrappedPromise;
|
|
8
|
+
private constructor();
|
|
9
|
+
/**
|
|
10
|
+
* Creates an `HttpResponsePromise` from a function that returns a promise.
|
|
11
|
+
*
|
|
12
|
+
* @param fn - A function that returns a promise resolving to a `WithRawResponse` object.
|
|
13
|
+
* @param args - Arguments to pass to the function.
|
|
14
|
+
* @returns An `HttpResponsePromise` instance.
|
|
15
|
+
*/
|
|
16
|
+
static fromFunction<F extends (...args: never[]) => Promise<WithRawResponse<T>>, T>(fn: F, ...args: Parameters<F>): HttpResponsePromise<T>;
|
|
17
|
+
/**
|
|
18
|
+
* Creates a function that returns an `HttpResponsePromise` from a function that returns a promise.
|
|
19
|
+
*
|
|
20
|
+
* @param fn - A function that returns a promise resolving to a `WithRawResponse` object.
|
|
21
|
+
* @returns A function that returns an `HttpResponsePromise` instance.
|
|
22
|
+
*/
|
|
23
|
+
static interceptFunction<F extends (...args: never[]) => Promise<WithRawResponse<T>>, T = Awaited<ReturnType<F>>["data"]>(fn: F): (...args: Parameters<F>) => HttpResponsePromise<T>;
|
|
24
|
+
/**
|
|
25
|
+
* Creates an `HttpResponsePromise` from an existing promise.
|
|
26
|
+
*
|
|
27
|
+
* @param promise - A promise resolving to a `WithRawResponse` object.
|
|
28
|
+
* @returns An `HttpResponsePromise` instance.
|
|
29
|
+
*/
|
|
30
|
+
static fromPromise<T>(promise: Promise<WithRawResponse<T>>): HttpResponsePromise<T>;
|
|
31
|
+
/**
|
|
32
|
+
* Creates an `HttpResponsePromise` from an executor function.
|
|
33
|
+
*
|
|
34
|
+
* @param executor - A function that takes resolve and reject callbacks to create a promise.
|
|
35
|
+
* @returns An `HttpResponsePromise` instance.
|
|
36
|
+
*/
|
|
37
|
+
static fromExecutor<T>(executor: (resolve: (value: WithRawResponse<T>) => void, reject: (reason?: unknown) => void) => void): HttpResponsePromise<T>;
|
|
38
|
+
/**
|
|
39
|
+
* Creates an `HttpResponsePromise` from a resolved result.
|
|
40
|
+
*
|
|
41
|
+
* @param result - A `WithRawResponse` object to resolve immediately.
|
|
42
|
+
* @returns An `HttpResponsePromise` instance.
|
|
43
|
+
*/
|
|
44
|
+
static fromResult<T>(result: WithRawResponse<T>): HttpResponsePromise<T>;
|
|
45
|
+
private unwrap;
|
|
46
|
+
/** @inheritdoc */
|
|
47
|
+
then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | null, onrejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | null): Promise<TResult1 | TResult2>;
|
|
48
|
+
/** @inheritdoc */
|
|
49
|
+
catch<TResult = never>(onrejected?: ((reason: unknown) => TResult | PromiseLike<TResult>) | null): Promise<T | TResult>;
|
|
50
|
+
/** @inheritdoc */
|
|
51
|
+
finally(onfinally?: (() => void) | null): Promise<T>;
|
|
52
|
+
/**
|
|
53
|
+
* Retrieves the data and raw response.
|
|
54
|
+
*
|
|
55
|
+
* @returns A promise resolving to a `WithRawResponse` object.
|
|
56
|
+
*/
|
|
57
|
+
withRawResponse(): Promise<WithRawResponse<T>>;
|
|
58
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* A promise that returns the parsed response and lets you retrieve the raw response too.
|
|
12
|
+
*/
|
|
13
|
+
export class HttpResponsePromise extends Promise {
|
|
14
|
+
constructor(promise) {
|
|
15
|
+
// Initialize with a no-op to avoid premature parsing
|
|
16
|
+
super((resolve) => {
|
|
17
|
+
resolve(undefined);
|
|
18
|
+
});
|
|
19
|
+
this.innerPromise = promise;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Creates an `HttpResponsePromise` from a function that returns a promise.
|
|
23
|
+
*
|
|
24
|
+
* @param fn - A function that returns a promise resolving to a `WithRawResponse` object.
|
|
25
|
+
* @param args - Arguments to pass to the function.
|
|
26
|
+
* @returns An `HttpResponsePromise` instance.
|
|
27
|
+
*/
|
|
28
|
+
static fromFunction(fn, ...args) {
|
|
29
|
+
return new HttpResponsePromise(fn(...args));
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Creates a function that returns an `HttpResponsePromise` from a function that returns a promise.
|
|
33
|
+
*
|
|
34
|
+
* @param fn - A function that returns a promise resolving to a `WithRawResponse` object.
|
|
35
|
+
* @returns A function that returns an `HttpResponsePromise` instance.
|
|
36
|
+
*/
|
|
37
|
+
static interceptFunction(fn) {
|
|
38
|
+
return (...args) => {
|
|
39
|
+
return HttpResponsePromise.fromPromise(fn(...args));
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Creates an `HttpResponsePromise` from an existing promise.
|
|
44
|
+
*
|
|
45
|
+
* @param promise - A promise resolving to a `WithRawResponse` object.
|
|
46
|
+
* @returns An `HttpResponsePromise` instance.
|
|
47
|
+
*/
|
|
48
|
+
static fromPromise(promise) {
|
|
49
|
+
return new HttpResponsePromise(promise);
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Creates an `HttpResponsePromise` from an executor function.
|
|
53
|
+
*
|
|
54
|
+
* @param executor - A function that takes resolve and reject callbacks to create a promise.
|
|
55
|
+
* @returns An `HttpResponsePromise` instance.
|
|
56
|
+
*/
|
|
57
|
+
static fromExecutor(executor) {
|
|
58
|
+
const promise = new Promise(executor);
|
|
59
|
+
return new HttpResponsePromise(promise);
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Creates an `HttpResponsePromise` from a resolved result.
|
|
63
|
+
*
|
|
64
|
+
* @param result - A `WithRawResponse` object to resolve immediately.
|
|
65
|
+
* @returns An `HttpResponsePromise` instance.
|
|
66
|
+
*/
|
|
67
|
+
static fromResult(result) {
|
|
68
|
+
const promise = Promise.resolve(result);
|
|
69
|
+
return new HttpResponsePromise(promise);
|
|
70
|
+
}
|
|
71
|
+
unwrap() {
|
|
72
|
+
if (!this.unwrappedPromise) {
|
|
73
|
+
this.unwrappedPromise = this.innerPromise.then(({ data }) => data);
|
|
74
|
+
}
|
|
75
|
+
return this.unwrappedPromise;
|
|
76
|
+
}
|
|
77
|
+
/** @inheritdoc */
|
|
78
|
+
then(onfulfilled, onrejected) {
|
|
79
|
+
return this.unwrap().then(onfulfilled, onrejected);
|
|
80
|
+
}
|
|
81
|
+
/** @inheritdoc */
|
|
82
|
+
catch(onrejected) {
|
|
83
|
+
return this.unwrap().catch(onrejected);
|
|
84
|
+
}
|
|
85
|
+
/** @inheritdoc */
|
|
86
|
+
finally(onfinally) {
|
|
87
|
+
return this.unwrap().finally(onfinally);
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Retrieves the data and raw response.
|
|
91
|
+
*
|
|
92
|
+
* @returns A promise resolving to a `WithRawResponse` object.
|
|
93
|
+
*/
|
|
94
|
+
withRawResponse() {
|
|
95
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
96
|
+
return yield this.innerPromise;
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The raw response from the fetch call excluding the body.
|
|
3
|
+
*/
|
|
4
|
+
export type RawResponse = Omit<{
|
|
5
|
+
[K in keyof Response as Response[K] extends Function ? never : K]: Response[K];
|
|
6
|
+
}, "ok" | "body" | "bodyUsed">;
|
|
7
|
+
/**
|
|
8
|
+
* A raw response indicating that the request was aborted.
|
|
9
|
+
*/
|
|
10
|
+
export declare const abortRawResponse: RawResponse;
|
|
11
|
+
/**
|
|
12
|
+
* A raw response indicating an unknown error.
|
|
13
|
+
*/
|
|
14
|
+
export declare const unknownRawResponse: RawResponse;
|
|
15
|
+
/**
|
|
16
|
+
* Converts a `RawResponse` object into a `RawResponse` by extracting its properties,
|
|
17
|
+
* excluding the `body` and `bodyUsed` fields.
|
|
18
|
+
*
|
|
19
|
+
* @param response - The `RawResponse` object to convert.
|
|
20
|
+
* @returns A `RawResponse` object containing the extracted properties of the input response.
|
|
21
|
+
*/
|
|
22
|
+
export declare function toRawResponse(response: Response): RawResponse;
|
|
23
|
+
/**
|
|
24
|
+
* Creates a `RawResponse` from a standard `Response` object.
|
|
25
|
+
*/
|
|
26
|
+
export interface WithRawResponse<T> {
|
|
27
|
+
readonly data: T;
|
|
28
|
+
readonly rawResponse: RawResponse;
|
|
29
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Headers } from "./Headers.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* A raw response indicating that the request was aborted.
|
|
4
|
+
*/
|
|
5
|
+
export const abortRawResponse = {
|
|
6
|
+
headers: new Headers(),
|
|
7
|
+
redirected: false,
|
|
8
|
+
status: 499,
|
|
9
|
+
statusText: "Client Closed Request",
|
|
10
|
+
type: "error",
|
|
11
|
+
url: "",
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* A raw response indicating an unknown error.
|
|
15
|
+
*/
|
|
16
|
+
export const unknownRawResponse = {
|
|
17
|
+
headers: new Headers(),
|
|
18
|
+
redirected: false,
|
|
19
|
+
status: 0,
|
|
20
|
+
statusText: "Unknown Error",
|
|
21
|
+
type: "error",
|
|
22
|
+
url: "",
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Converts a `RawResponse` object into a `RawResponse` by extracting its properties,
|
|
26
|
+
* excluding the `body` and `bodyUsed` fields.
|
|
27
|
+
*
|
|
28
|
+
* @param response - The `RawResponse` object to convert.
|
|
29
|
+
* @returns A `RawResponse` object containing the extracted properties of the input response.
|
|
30
|
+
*/
|
|
31
|
+
export function toRawResponse(response) {
|
|
32
|
+
return {
|
|
33
|
+
headers: response.headers,
|
|
34
|
+
redirected: response.redirected,
|
|
35
|
+
status: response.status,
|
|
36
|
+
statusText: response.statusText,
|
|
37
|
+
type: response.type,
|
|
38
|
+
url: response.url,
|
|
39
|
+
};
|
|
40
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
export const Supplier = {
|
|
11
|
+
get: (supplier) => __awaiter(void 0, void 0, void 0, function* () {
|
|
12
|
+
if (typeof supplier === "function") {
|
|
13
|
+
return supplier();
|
|
14
|
+
}
|
|
15
|
+
else {
|
|
16
|
+
return supplier;
|
|
17
|
+
}
|
|
18
|
+
}),
|
|
19
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function createRequestUrl(baseUrl: string, queryParameters?: Record<string, unknown>): string;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { RUNTIME } from "../runtime/index.mjs";
|
|
11
|
+
/**
|
|
12
|
+
* Returns a fetch function based on the runtime
|
|
13
|
+
*/
|
|
14
|
+
export function getFetchFn() {
|
|
15
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
16
|
+
// In Node.js 18+ environments, use native fetch
|
|
17
|
+
if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) {
|
|
18
|
+
return fetch;
|
|
19
|
+
}
|
|
20
|
+
// In Node.js 18 or lower environments, the SDK always uses`node-fetch`.
|
|
21
|
+
if (RUNTIME.type === "node") {
|
|
22
|
+
return (yield import("node-fetch")).default;
|
|
23
|
+
}
|
|
24
|
+
// Otherwise the SDK uses global fetch if available,
|
|
25
|
+
// and falls back to node-fetch.
|
|
26
|
+
if (typeof fetch == "function") {
|
|
27
|
+
return fetch;
|
|
28
|
+
}
|
|
29
|
+
// Defaults to node `node-fetch` if global fetch isn't available
|
|
30
|
+
return (yield import("node-fetch")).default;
|
|
31
|
+
});
|
|
32
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { toJson } from "../json.mjs";
|
|
11
|
+
export function getRequestBody(_a) {
|
|
12
|
+
return __awaiter(this, arguments, void 0, function* ({ body, type }) {
|
|
13
|
+
if (type.includes("json")) {
|
|
14
|
+
return toJson(body);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
return body;
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { getBinaryResponse } from "./BinaryResponse.mjs";
|
|
11
|
+
import { isResponseWithBody } from "./ResponseWithBody.mjs";
|
|
12
|
+
import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper.mjs";
|
|
13
|
+
export function getResponseBody(response, responseType) {
|
|
14
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15
|
+
if (!isResponseWithBody(response)) {
|
|
16
|
+
return undefined;
|
|
17
|
+
}
|
|
18
|
+
switch (responseType) {
|
|
19
|
+
case "binary-response":
|
|
20
|
+
return getBinaryResponse(response);
|
|
21
|
+
case "blob":
|
|
22
|
+
return yield response.blob();
|
|
23
|
+
case "arrayBuffer":
|
|
24
|
+
return yield response.arrayBuffer();
|
|
25
|
+
case "sse":
|
|
26
|
+
return response.body;
|
|
27
|
+
case "streaming":
|
|
28
|
+
return chooseStreamWrapper(response.body);
|
|
29
|
+
case "text":
|
|
30
|
+
return yield response.text();
|
|
31
|
+
}
|
|
32
|
+
// if responseType is "json" or not specified, try to parse as JSON
|
|
33
|
+
const text = yield response.text();
|
|
34
|
+
if (text.length > 0) {
|
|
35
|
+
try {
|
|
36
|
+
let responseBody = JSON.parse(text);
|
|
37
|
+
return responseBody;
|
|
38
|
+
}
|
|
39
|
+
catch (err) {
|
|
40
|
+
return {
|
|
41
|
+
ok: false,
|
|
42
|
+
error: {
|
|
43
|
+
reason: "non-json",
|
|
44
|
+
statusCode: response.status,
|
|
45
|
+
rawBody: text,
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
return undefined;
|
|
51
|
+
});
|
|
52
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export type { APIResponse } from "./APIResponse.mjs";
|
|
2
|
+
export { fetcher } from "./Fetcher.mjs";
|
|
3
|
+
export type { Fetcher, FetchFunction } from "./Fetcher.mjs";
|
|
4
|
+
export { getHeader } from "./getHeader.mjs";
|
|
5
|
+
export { Supplier } from "./Supplier.mjs";
|
|
6
|
+
export { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse.mjs";
|
|
7
|
+
export type { RawResponse, WithRawResponse } from "./RawResponse.mjs";
|
|
8
|
+
export { HttpResponsePromise } from "./HttpResponsePromise.mjs";
|
|
9
|
+
export { BinaryResponse } from "./BinaryResponse.mjs";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { fetcher } from "./Fetcher.mjs";
|
|
2
|
+
export { getHeader } from "./getHeader.mjs";
|
|
3
|
+
export { Supplier } from "./Supplier.mjs";
|
|
4
|
+
export { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse.mjs";
|
|
5
|
+
export { HttpResponsePromise } from "./HttpResponsePromise.mjs";
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { anySignal, getTimeoutSignal } from "./signals.mjs";
|
|
11
|
+
export const makeRequest = (fetchFn, url, method, headers, requestBody, timeoutMs, abortSignal, withCredentials, duplex) => __awaiter(void 0, void 0, void 0, function* () {
|
|
12
|
+
const signals = [];
|
|
13
|
+
// Add timeout signal
|
|
14
|
+
let timeoutAbortId = undefined;
|
|
15
|
+
if (timeoutMs != null) {
|
|
16
|
+
const { signal, abortId } = getTimeoutSignal(timeoutMs);
|
|
17
|
+
timeoutAbortId = abortId;
|
|
18
|
+
signals.push(signal);
|
|
19
|
+
}
|
|
20
|
+
// Add arbitrary signal
|
|
21
|
+
if (abortSignal != null) {
|
|
22
|
+
signals.push(abortSignal);
|
|
23
|
+
}
|
|
24
|
+
let newSignals = anySignal(signals);
|
|
25
|
+
const response = yield fetchFn(url, {
|
|
26
|
+
method: method,
|
|
27
|
+
headers,
|
|
28
|
+
body: requestBody,
|
|
29
|
+
signal: newSignals,
|
|
30
|
+
credentials: withCredentials ? "include" : undefined,
|
|
31
|
+
// @ts-ignore
|
|
32
|
+
duplex,
|
|
33
|
+
});
|
|
34
|
+
if (timeoutAbortId != null) {
|
|
35
|
+
clearTimeout(timeoutAbortId);
|
|
36
|
+
}
|
|
37
|
+
return response;
|
|
38
|
+
});
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
const INITIAL_RETRY_DELAY = 1000; // in milliseconds
|
|
11
|
+
const MAX_RETRY_DELAY = 60000; // in milliseconds
|
|
12
|
+
const DEFAULT_MAX_RETRIES = 2;
|
|
13
|
+
const JITTER_FACTOR = 0.2; // 20% random jitter
|
|
14
|
+
function addJitter(delay) {
|
|
15
|
+
// Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR
|
|
16
|
+
const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR;
|
|
17
|
+
return delay * jitterMultiplier;
|
|
18
|
+
}
|
|
19
|
+
export function requestWithRetries(requestFn_1) {
|
|
20
|
+
return __awaiter(this, arguments, void 0, function* (requestFn, maxRetries = DEFAULT_MAX_RETRIES) {
|
|
21
|
+
let response = yield requestFn();
|
|
22
|
+
for (let i = 0; i < maxRetries; ++i) {
|
|
23
|
+
if ([408, 429].includes(response.status) || response.status >= 500) {
|
|
24
|
+
// Calculate base delay using exponential backoff (in milliseconds)
|
|
25
|
+
const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY);
|
|
26
|
+
// Add jitter to the delay
|
|
27
|
+
const delayWithJitter = addJitter(baseDelay);
|
|
28
|
+
yield new Promise((resolve) => setTimeout(resolve, delayWithJitter));
|
|
29
|
+
response = yield requestFn();
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
break;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return response;
|
|
36
|
+
});
|
|
37
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
const TIMEOUT = "timeout";
|
|
2
|
+
export function getTimeoutSignal(timeoutMs) {
|
|
3
|
+
const controller = new AbortController();
|
|
4
|
+
const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs);
|
|
5
|
+
return { signal: controller.signal, abortId };
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Returns an abort signal that is getting aborted when
|
|
9
|
+
* at least one of the specified abort signals is aborted.
|
|
10
|
+
*
|
|
11
|
+
* Requires at least node.js 18.
|
|
12
|
+
*/
|
|
13
|
+
export function anySignal(...args) {
|
|
14
|
+
// Allowing signals to be passed either as array
|
|
15
|
+
// of signals or as multiple arguments.
|
|
16
|
+
const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args);
|
|
17
|
+
const controller = new AbortController();
|
|
18
|
+
for (const signal of signals) {
|
|
19
|
+
if (signal.aborted) {
|
|
20
|
+
// Exiting early if one of the signals
|
|
21
|
+
// is already aborted.
|
|
22
|
+
controller.abort(signal === null || signal === void 0 ? void 0 : signal.reason);
|
|
23
|
+
break;
|
|
24
|
+
}
|
|
25
|
+
// Listening for signals and removing the listeners
|
|
26
|
+
// when at least one symbol is aborted.
|
|
27
|
+
signal.addEventListener("abort", () => controller.abort(signal === null || signal === void 0 ? void 0 : signal.reason), {
|
|
28
|
+
signal: controller.signal,
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
return controller.signal;
|
|
32
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { Writable } from "readable-stream";
|
|
2
|
+
import { EventCallback, StreamWrapper } from "./chooseStreamWrapper.mjs";
|
|
3
|
+
export declare class Node18UniversalStreamWrapper<ReadFormat extends Uint8Array | Uint16Array | Uint32Array> implements StreamWrapper<Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>, ReadFormat> {
|
|
4
|
+
private readableStream;
|
|
5
|
+
private reader;
|
|
6
|
+
private events;
|
|
7
|
+
private paused;
|
|
8
|
+
private resumeCallback;
|
|
9
|
+
private encoding;
|
|
10
|
+
constructor(readableStream: ReadableStream<ReadFormat>);
|
|
11
|
+
on(event: string, callback: EventCallback): void;
|
|
12
|
+
off(event: string, callback: EventCallback): void;
|
|
13
|
+
pipe(dest: Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>): Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>;
|
|
14
|
+
pipeTo(dest: Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>): Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>;
|
|
15
|
+
unpipe(dest: Node18UniversalStreamWrapper<ReadFormat> | Writable | WritableStream<ReadFormat>): void;
|
|
16
|
+
destroy(error?: Error): void;
|
|
17
|
+
pause(): void;
|
|
18
|
+
resume(): void;
|
|
19
|
+
get isPaused(): boolean;
|
|
20
|
+
read(): Promise<ReadFormat | undefined>;
|
|
21
|
+
setEncoding(encoding: string): void;
|
|
22
|
+
text(): Promise<string>;
|
|
23
|
+
json<T>(): Promise<T>;
|
|
24
|
+
private _write;
|
|
25
|
+
private _end;
|
|
26
|
+
private _error;
|
|
27
|
+
private _emit;
|
|
28
|
+
private _startReading;
|
|
29
|
+
[Symbol.asyncIterator](): AsyncIterableIterator<ReadFormat>;
|
|
30
|
+
}
|