@airtop/sdk 0.1.34 → 0.1.35-beta0
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/Client.d.ts +14 -4
- package/Client.js +16 -6
- package/README.md +35 -17
- package/api/errors/ForbiddenError.d.ts +8 -0
- package/api/errors/ForbiddenError.js +51 -0
- package/api/errors/InternalServerError.js +17 -7
- package/api/errors/NotFoundError.js +17 -7
- package/api/errors/UnauthorizedError.d.ts +8 -0
- package/api/errors/UnauthorizedError.js +51 -0
- package/api/errors/UnprocessableEntityError.js +17 -7
- package/api/errors/index.d.ts +2 -0
- package/api/errors/index.js +2 -0
- package/api/resources/automations/client/Client.d.ts +91 -0
- package/api/resources/automations/client/Client.js +429 -0
- package/api/resources/automations/client/index.d.ts +1 -0
- package/api/resources/automations/client/index.js +17 -0
- package/api/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.d.ts +19 -0
- package/api/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.js +5 -0
- package/api/resources/automations/client/requests/index.d.ts +1 -0
- package/api/resources/automations/client/requests/index.js +2 -0
- package/api/resources/automations/index.d.ts +1 -0
- package/api/resources/automations/index.js +17 -0
- package/api/resources/files/client/Client.d.ts +69 -0
- package/api/resources/files/client/Client.js +286 -0
- package/api/resources/files/client/index.d.ts +1 -0
- package/api/resources/files/client/index.js +17 -0
- package/api/resources/files/client/requests/CreateFileRestInputV1.d.ts +20 -0
- package/api/resources/files/client/requests/CreateFileRestInputV1.js +5 -0
- package/api/resources/files/client/requests/FilesListRequest.d.ts +24 -0
- package/api/resources/files/client/requests/FilesListRequest.js +5 -0
- package/api/resources/files/client/requests/index.d.ts +2 -0
- package/api/resources/files/client/requests/index.js +2 -0
- package/api/resources/files/index.d.ts +2 -0
- package/api/resources/files/index.js +18 -0
- package/api/resources/files/types/CreateFileRestInputV1FileType.d.ts +13 -0
- package/api/resources/files/types/CreateFileRestInputV1FileType.js +12 -0
- package/api/resources/files/types/index.d.ts +1 -0
- package/api/resources/files/types/index.js +17 -0
- package/api/resources/index.d.ts +5 -0
- package/api/resources/index.js +23 -8
- package/api/resources/profiles/client/Client.d.ts +4 -0
- package/api/resources/profiles/client/Client.js +23 -21
- package/api/resources/requests/client/Client.d.ts +4 -0
- package/api/resources/requests/client/Client.js +21 -19
- package/api/resources/sessions/client/Client.d.ts +15 -1
- package/api/resources/sessions/client/Client.js +98 -88
- package/api/resources/sessions/client/requests/SessionsEventsRequest.d.ts +7 -0
- package/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -4
- package/api/resources/sessions/types/SessionsListRequestStatus.d.ts +1 -1
- package/api/resources/sessions/types/index.d.ts +1 -1
- package/api/resources/sessions/types/index.js +1 -1
- package/api/resources/windows/client/Client.d.ts +142 -0
- package/api/resources/windows/client/Client.js +700 -199
- package/api/resources/windows/client/requests/AsyncClickRequest.d.ts +29 -0
- package/api/resources/windows/client/requests/AsyncClickRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncCreateAutomationRequest.d.ts +23 -0
- package/api/resources/windows/client/requests/AsyncCreateAutomationRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncExecuteAutomationRequest.d.ts +27 -0
- package/api/resources/windows/client/requests/AsyncExecuteAutomationRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncHoverRequest.d.ts +27 -0
- package/api/resources/windows/client/requests/AsyncHoverRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncMonitorRequest.d.ts +27 -0
- package/api/resources/windows/client/requests/AsyncMonitorRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncPageQueryRequest.d.ts +29 -0
- package/api/resources/windows/client/requests/AsyncPageQueryRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncPaginatedExtractionRequest.d.ts +27 -0
- package/api/resources/windows/client/requests/AsyncPaginatedExtractionRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncPromptContentRequest.d.ts +29 -0
- package/api/resources/windows/client/requests/AsyncPromptContentRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncScreenshotRequest.d.ts +23 -0
- package/api/resources/windows/client/requests/AsyncScreenshotRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncSummarizeContentRequest.d.ts +25 -0
- package/api/resources/windows/client/requests/AsyncSummarizeContentRequest.js +5 -0
- package/api/resources/windows/client/requests/AsyncTypeRequest.d.ts +37 -0
- package/api/resources/windows/client/requests/AsyncTypeRequest.js +5 -0
- package/api/resources/windows/client/requests/index.d.ts +11 -0
- package/api/resources/windows/types/CreateWindowInputV1BodyWaitUntil.d.ts +1 -1
- package/api/resources/windows/types/WindowLoadUrlV1BodyWaitUntil.d.ts +1 -1
- package/api/types/AsyncConfig.d.ts +7 -0
- package/api/types/AsyncConfig.js +5 -0
- package/api/types/AsyncSessionAiResponseEnvelope.d.ts +9 -0
- package/api/types/AsyncSessionAiResponseEnvelope.js +5 -0
- package/api/types/AutomationOutput.d.ts +10 -0
- package/api/types/AutomationOutput.js +5 -0
- package/api/types/BrowserWaitNavigationConfigWaitUntil.d.ts +1 -1
- package/api/types/ClickConfigClickType.d.ts +1 -1
- package/api/types/CreateAutomationRequestBodyConfiguration.d.ts +4 -0
- package/api/types/CreateAutomationRequestBodyConfiguration.js +5 -0
- package/api/types/CreateFileV1.d.ts +24 -0
- package/api/types/CreateFileV1.js +5 -0
- package/api/types/CreateFileV1FileType.d.ts +13 -0
- package/api/types/CreateFileV1FileType.js +12 -0
- package/api/types/DeleteAutomationOutputWrapperBody.d.ts +4 -0
- package/api/types/DeleteAutomationOutputWrapperBody.js +5 -0
- package/api/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.d.ts +10 -0
- package/api/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.js +5 -0
- package/api/types/EnvelopeGetFileV1EnvelopeDefaultMeta.d.ts +10 -0
- package/api/types/EnvelopeGetFileV1EnvelopeDefaultMeta.js +5 -0
- package/api/types/ExtensionConfigurationOutput.d.ts +13 -0
- package/api/types/ExtensionConfigurationOutput.js +5 -0
- package/api/types/ExternalFile.d.ts +33 -0
- package/api/types/ExternalFile.js +5 -0
- package/api/types/ExternalSessionAiResponseMetadataStatus.d.ts +1 -1
- package/api/types/FilesResponse.d.ts +10 -0
- package/api/types/FilesResponse.js +5 -0
- package/api/types/FilesWithPagination.d.ts +10 -0
- package/api/types/FilesWithPagination.js +5 -0
- package/api/types/GetFileV1.d.ts +24 -0
- package/api/types/GetFileV1.js +5 -0
- package/api/types/GetFileV1FileType.d.ts +13 -0
- package/api/types/GetFileV1FileType.js +12 -0
- package/api/types/ListAutomationsOutput.d.ts +7 -0
- package/api/types/ListAutomationsOutput.js +5 -0
- package/api/types/MonitorConfigIncludeVisualAnalysis.d.ts +1 -1
- package/api/types/Proxy.d.ts +1 -1
- package/api/types/SessionConfigV1Proxy.d.ts +1 -1
- package/api/types/StatusMessageStatus.d.ts +1 -1
- package/api/types/VisualAnalysisConfigPartitionDirection.d.ts +1 -1
- package/api/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +1 -1
- package/api/types/VisualAnalysisConfigScope.d.ts +1 -1
- package/api/types/index.d.ts +26 -0
- package/api/types/index.js +26 -0
- package/biome.json +3 -0
- package/core/auth/BearerToken.d.ts +1 -1
- package/core/fetcher/APIResponse.d.ts +1 -1
- package/core/fetcher/Fetcher.d.ts +3 -3
- package/core/fetcher/Fetcher.js +6 -5
- package/core/fetcher/Supplier.d.ts +1 -1
- package/core/fetcher/createRequestUrl.d.ts +1 -1
- package/core/fetcher/createRequestUrl.js +1 -2
- package/core/fetcher/getFetchFn.js +18 -9
- package/core/fetcher/getHeader.js +1 -2
- package/core/fetcher/getRequestBody.js +5 -5
- package/core/fetcher/getResponseBody.js +4 -2
- package/core/fetcher/makeRequest.d.ts +1 -1
- package/core/fetcher/requestWithRetries.js +17 -9
- package/core/fetcher/signals.d.ts +0 -1
- package/core/fetcher/signals.js +2 -3
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +1 -2
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +4 -2
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +1 -2
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +2 -2
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +4 -2
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +19 -10
- package/core/index.js +17 -7
- package/core/json.d.ts +15 -0
- package/core/json.js +24 -0
- package/core/runtime/runtime.d.ts +1 -1
- package/core/runtime/runtime.js +51 -41
- package/core/schemas/Schema.d.ts +8 -5
- package/core/schemas/Schema.js +3 -0
- package/core/schemas/builders/bigint/bigint.d.ts +2 -0
- package/core/schemas/builders/bigint/bigint.js +53 -0
- package/core/schemas/builders/bigint/index.d.ts +1 -0
- package/core/schemas/builders/bigint/index.js +5 -0
- package/core/schemas/builders/date/date.js +1 -2
- package/core/schemas/builders/enum/enum.js +1 -2
- package/core/schemas/builders/index.d.ts +1 -0
- package/core/schemas/builders/index.js +1 -0
- package/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/core/schemas/builders/lazy/lazy.js +3 -4
- package/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/core/schemas/builders/list/list.js +1 -2
- package/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/core/schemas/builders/object/object.d.ts +1 -1
- package/core/schemas/builders/object/object.js +31 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/core/schemas/builders/object/property.js +2 -3
- package/core/schemas/builders/object/types.d.ts +16 -11
- package/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/core/schemas/builders/object-like/types.d.ts +1 -1
- package/core/schemas/builders/record/record.js +2 -4
- package/core/schemas/builders/record/types.d.ts +2 -2
- package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/core/schemas/builders/set/set.js +1 -2
- package/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/core/schemas/builders/union/discriminant.js +1 -2
- package/core/schemas/builders/union/types.d.ts +6 -6
- package/core/schemas/builders/union/union.d.ts +1 -1
- package/core/schemas/builders/union/union.js +1 -2
- package/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/core/schemas/utils/entries.d.ts +1 -1
- package/core/schemas/utils/entries.js +1 -2
- package/core/schemas/utils/filterObject.d.ts +1 -1
- package/core/schemas/utils/filterObject.js +1 -2
- package/core/schemas/utils/getErrorMessageForIncorrectType.js +5 -2
- package/core/schemas/utils/isPlainObject.js +1 -2
- package/core/schemas/utils/keys.d.ts +1 -1
- package/core/schemas/utils/keys.js +1 -2
- package/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/core/schemas/utils/partition.js +1 -2
- package/core/streaming-fetcher/Stream.d.ts +0 -1
- package/core/streaming-fetcher/Stream.js +20 -21
- package/dist/Client.d.ts +14 -4
- package/dist/Client.js +16 -6
- package/dist/api/errors/ForbiddenError.d.ts +8 -0
- package/dist/api/errors/ForbiddenError.js +51 -0
- package/dist/api/errors/InternalServerError.js +17 -7
- package/dist/api/errors/NotFoundError.js +17 -7
- package/dist/api/errors/UnauthorizedError.d.ts +8 -0
- package/dist/api/errors/UnauthorizedError.js +51 -0
- package/dist/api/errors/UnprocessableEntityError.js +17 -7
- package/dist/api/errors/index.d.ts +2 -0
- package/dist/api/errors/index.js +2 -0
- package/dist/api/resources/automations/client/Client.d.ts +91 -0
- package/dist/api/resources/automations/client/Client.js +429 -0
- package/dist/api/resources/automations/client/index.d.ts +1 -0
- package/dist/api/resources/automations/client/index.js +17 -0
- package/dist/api/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.d.ts +19 -0
- package/dist/api/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.js +5 -0
- package/dist/api/resources/automations/client/requests/index.d.ts +1 -0
- package/dist/api/resources/automations/client/requests/index.js +2 -0
- package/dist/api/resources/automations/index.d.ts +1 -0
- package/dist/api/resources/automations/index.js +17 -0
- package/dist/api/resources/files/client/Client.d.ts +69 -0
- package/dist/api/resources/files/client/Client.js +286 -0
- package/dist/api/resources/files/client/index.d.ts +1 -0
- package/dist/api/resources/files/client/index.js +17 -0
- package/dist/api/resources/files/client/requests/CreateFileRestInputV1.d.ts +20 -0
- package/dist/api/resources/files/client/requests/CreateFileRestInputV1.js +5 -0
- package/dist/api/resources/files/client/requests/FilesListRequest.d.ts +24 -0
- package/dist/api/resources/files/client/requests/FilesListRequest.js +5 -0
- package/dist/api/resources/files/client/requests/index.d.ts +2 -0
- package/dist/api/resources/files/client/requests/index.js +2 -0
- package/dist/api/resources/files/index.d.ts +2 -0
- package/dist/api/resources/files/index.js +18 -0
- package/dist/api/resources/files/types/CreateFileRestInputV1FileType.d.ts +13 -0
- package/dist/api/resources/files/types/CreateFileRestInputV1FileType.js +12 -0
- package/dist/api/resources/files/types/index.d.ts +1 -0
- package/dist/api/resources/files/types/index.js +17 -0
- package/dist/api/resources/index.d.ts +5 -0
- package/dist/api/resources/index.js +23 -8
- package/dist/api/resources/profiles/client/Client.d.ts +4 -0
- package/dist/api/resources/profiles/client/Client.js +23 -21
- package/dist/api/resources/requests/client/Client.d.ts +4 -0
- package/dist/api/resources/requests/client/Client.js +21 -19
- package/dist/api/resources/sessions/client/Client.d.ts +15 -1
- package/dist/api/resources/sessions/client/Client.js +98 -88
- package/dist/api/resources/sessions/client/requests/SessionsEventsRequest.d.ts +7 -0
- package/dist/api/resources/sessions/types/SessionsEventsResponse.d.ts +4 -4
- package/dist/api/resources/sessions/types/SessionsListRequestStatus.d.ts +1 -1
- package/dist/api/resources/sessions/types/index.d.ts +1 -1
- package/dist/api/resources/sessions/types/index.js +1 -1
- package/dist/api/resources/windows/client/Client.d.ts +142 -0
- package/dist/api/resources/windows/client/Client.js +700 -199
- package/dist/api/resources/windows/client/requests/AsyncClickRequest.d.ts +29 -0
- package/dist/api/resources/windows/client/requests/AsyncClickRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncCreateAutomationRequest.d.ts +23 -0
- package/dist/api/resources/windows/client/requests/AsyncCreateAutomationRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncExecuteAutomationRequest.d.ts +27 -0
- package/dist/api/resources/windows/client/requests/AsyncExecuteAutomationRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncHoverRequest.d.ts +27 -0
- package/dist/api/resources/windows/client/requests/AsyncHoverRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncMonitorRequest.d.ts +27 -0
- package/dist/api/resources/windows/client/requests/AsyncMonitorRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncPageQueryRequest.d.ts +29 -0
- package/dist/api/resources/windows/client/requests/AsyncPageQueryRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncPaginatedExtractionRequest.d.ts +27 -0
- package/dist/api/resources/windows/client/requests/AsyncPaginatedExtractionRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncPromptContentRequest.d.ts +29 -0
- package/dist/api/resources/windows/client/requests/AsyncPromptContentRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncScreenshotRequest.d.ts +23 -0
- package/dist/api/resources/windows/client/requests/AsyncScreenshotRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncSummarizeContentRequest.d.ts +25 -0
- package/dist/api/resources/windows/client/requests/AsyncSummarizeContentRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/AsyncTypeRequest.d.ts +37 -0
- package/dist/api/resources/windows/client/requests/AsyncTypeRequest.js +5 -0
- package/dist/api/resources/windows/client/requests/index.d.ts +11 -0
- package/dist/api/resources/windows/types/CreateWindowInputV1BodyWaitUntil.d.ts +1 -1
- package/dist/api/resources/windows/types/WindowLoadUrlV1BodyWaitUntil.d.ts +1 -1
- package/dist/api/types/AsyncConfig.d.ts +7 -0
- package/dist/api/types/AsyncConfig.js +5 -0
- package/dist/api/types/AsyncSessionAiResponseEnvelope.d.ts +9 -0
- package/dist/api/types/AsyncSessionAiResponseEnvelope.js +5 -0
- package/dist/api/types/AutomationOutput.d.ts +10 -0
- package/dist/api/types/AutomationOutput.js +5 -0
- package/dist/api/types/BrowserWaitNavigationConfigWaitUntil.d.ts +1 -1
- package/dist/api/types/ClickConfigClickType.d.ts +1 -1
- package/dist/api/types/CreateAutomationRequestBodyConfiguration.d.ts +4 -0
- package/dist/api/types/CreateAutomationRequestBodyConfiguration.js +5 -0
- package/dist/api/types/CreateFileV1.d.ts +24 -0
- package/dist/api/types/CreateFileV1.js +5 -0
- package/dist/api/types/CreateFileV1FileType.d.ts +13 -0
- package/dist/api/types/CreateFileV1FileType.js +12 -0
- package/dist/api/types/DeleteAutomationOutputWrapperBody.d.ts +4 -0
- package/dist/api/types/DeleteAutomationOutputWrapperBody.js +5 -0
- package/dist/api/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.d.ts +10 -0
- package/dist/api/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.js +5 -0
- package/dist/api/types/EnvelopeGetFileV1EnvelopeDefaultMeta.d.ts +10 -0
- package/dist/api/types/EnvelopeGetFileV1EnvelopeDefaultMeta.js +5 -0
- package/dist/api/types/ExtensionConfigurationOutput.d.ts +13 -0
- package/dist/api/types/ExtensionConfigurationOutput.js +5 -0
- package/dist/api/types/ExternalFile.d.ts +33 -0
- package/dist/api/types/ExternalFile.js +5 -0
- package/dist/api/types/ExternalSessionAiResponseMetadataStatus.d.ts +1 -1
- package/dist/api/types/FilesResponse.d.ts +10 -0
- package/dist/api/types/FilesResponse.js +5 -0
- package/dist/api/types/FilesWithPagination.d.ts +10 -0
- package/dist/api/types/FilesWithPagination.js +5 -0
- package/dist/api/types/GetFileV1.d.ts +24 -0
- package/dist/api/types/GetFileV1.js +5 -0
- package/dist/api/types/GetFileV1FileType.d.ts +13 -0
- package/dist/api/types/GetFileV1FileType.js +12 -0
- package/dist/api/types/ListAutomationsOutput.d.ts +7 -0
- package/dist/api/types/ListAutomationsOutput.js +5 -0
- package/dist/api/types/MonitorConfigIncludeVisualAnalysis.d.ts +1 -1
- package/dist/api/types/Proxy.d.ts +1 -1
- package/dist/api/types/SessionConfigV1Proxy.d.ts +1 -1
- package/dist/api/types/StatusMessageStatus.d.ts +1 -1
- package/dist/api/types/VisualAnalysisConfigPartitionDirection.d.ts +1 -1
- package/dist/api/types/VisualAnalysisConfigResultSelectionStrategy.d.ts +1 -1
- package/dist/api/types/VisualAnalysisConfigScope.d.ts +1 -1
- package/dist/api/types/index.d.ts +26 -0
- package/dist/api/types/index.js +26 -0
- package/dist/core/auth/BearerToken.d.ts +1 -1
- package/dist/core/fetcher/APIResponse.d.ts +1 -1
- package/dist/core/fetcher/Fetcher.d.ts +3 -3
- package/dist/core/fetcher/Fetcher.js +6 -5
- package/dist/core/fetcher/Supplier.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.js +1 -2
- package/dist/core/fetcher/getFetchFn.js +18 -9
- package/dist/core/fetcher/getHeader.js +1 -2
- package/dist/core/fetcher/getRequestBody.js +5 -5
- package/dist/core/fetcher/getResponseBody.js +4 -2
- package/dist/core/fetcher/makeRequest.d.ts +1 -1
- package/dist/core/fetcher/requestWithRetries.js +17 -9
- package/dist/core/fetcher/signals.d.ts +0 -1
- package/dist/core/fetcher/signals.js +2 -3
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +1 -2
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +4 -2
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +1 -2
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +2 -2
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +4 -2
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +19 -10
- package/dist/core/index.js +17 -7
- package/dist/core/json.d.ts +15 -0
- package/dist/core/json.js +24 -0
- package/dist/core/runtime/runtime.d.ts +1 -1
- package/dist/core/runtime/runtime.js +51 -41
- package/dist/core/schemas/Schema.d.ts +8 -5
- package/dist/core/schemas/Schema.js +3 -0
- package/dist/core/schemas/builders/bigint/bigint.d.ts +2 -0
- package/dist/core/schemas/builders/bigint/bigint.js +53 -0
- package/dist/core/schemas/builders/bigint/index.d.ts +1 -0
- package/dist/core/schemas/builders/bigint/index.js +5 -0
- package/dist/core/schemas/builders/date/date.js +1 -2
- package/dist/core/schemas/builders/enum/enum.js +1 -2
- package/dist/core/schemas/builders/index.d.ts +1 -0
- package/dist/core/schemas/builders/index.js +1 -0
- package/dist/core/schemas/builders/lazy/lazy.d.ts +1 -1
- package/dist/core/schemas/builders/lazy/lazy.js +3 -4
- package/dist/core/schemas/builders/lazy/lazyObject.js +1 -2
- package/dist/core/schemas/builders/list/list.js +1 -2
- package/dist/core/schemas/builders/literals/booleanLiteral.js +1 -2
- package/dist/core/schemas/builders/literals/stringLiteral.js +1 -2
- package/dist/core/schemas/builders/object/object.d.ts +1 -1
- package/dist/core/schemas/builders/object/object.js +31 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
- package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
- package/dist/core/schemas/builders/object/property.js +2 -3
- package/dist/core/schemas/builders/object/types.d.ts +16 -11
- package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
- package/dist/core/schemas/builders/object-like/types.d.ts +1 -1
- package/dist/core/schemas/builders/record/record.js +2 -4
- package/dist/core/schemas/builders/record/types.d.ts +2 -2
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
- package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
- package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
- package/dist/core/schemas/builders/set/set.js +1 -2
- package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
- package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
- package/dist/core/schemas/builders/union/discriminant.js +1 -2
- package/dist/core/schemas/builders/union/types.d.ts +6 -6
- package/dist/core/schemas/builders/union/union.d.ts +1 -1
- package/dist/core/schemas/builders/union/union.js +1 -2
- package/dist/core/schemas/utils/MaybePromise.d.ts +1 -1
- package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
- package/dist/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
- package/dist/core/schemas/utils/entries.d.ts +1 -1
- package/dist/core/schemas/utils/entries.js +1 -2
- package/dist/core/schemas/utils/filterObject.d.ts +1 -1
- package/dist/core/schemas/utils/filterObject.js +1 -2
- package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +5 -2
- package/dist/core/schemas/utils/isPlainObject.js +1 -2
- package/dist/core/schemas/utils/keys.d.ts +1 -1
- package/dist/core/schemas/utils/keys.js +1 -2
- package/dist/core/schemas/utils/maybeSkipValidation.js +1 -2
- package/dist/core/schemas/utils/partition.js +1 -2
- package/dist/core/streaming-fetcher/Stream.d.ts +0 -1
- package/dist/core/streaming-fetcher/Stream.js +20 -21
- package/dist/environments.d.ts +1 -1
- package/dist/errors/AirtopError.js +2 -1
- package/dist/errors/AirtopTimeoutError.d.ts +1 -1
- package/dist/errors/AirtopTimeoutError.js +2 -2
- package/dist/index.js +17 -7
- package/dist/live-view/types.d.ts +1 -1
- package/dist/live-view/types.js +1 -1
- package/dist/serialization/resources/automations/client/index.d.ts +1 -0
- package/dist/serialization/resources/automations/client/index.js +17 -0
- package/dist/serialization/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.d.ts +14 -0
- package/dist/serialization/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.js +45 -0
- package/dist/serialization/resources/automations/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/automations/client/requests/index.js +5 -0
- package/dist/serialization/resources/automations/index.d.ts +1 -0
- package/dist/serialization/resources/automations/index.js +17 -0
- package/dist/serialization/resources/files/client/index.d.ts +1 -0
- package/dist/serialization/resources/files/client/index.js +17 -0
- package/dist/serialization/resources/files/client/requests/CreateFileRestInputV1.d.ts +16 -0
- package/dist/serialization/resources/files/client/requests/CreateFileRestInputV1.js +47 -0
- package/dist/serialization/resources/files/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/files/client/requests/index.js +5 -0
- package/dist/serialization/resources/files/index.d.ts +2 -0
- package/dist/serialization/resources/files/index.js +18 -0
- package/dist/serialization/resources/files/types/CreateFileRestInputV1FileType.d.ts +10 -0
- package/dist/serialization/resources/files/types/CreateFileRestInputV1FileType.js +41 -0
- package/dist/serialization/resources/files/types/index.d.ts +1 -0
- package/dist/serialization/resources/files/types/index.js +17 -0
- package/dist/serialization/resources/index.d.ts +5 -0
- package/dist/serialization/resources/index.js +23 -8
- package/dist/serialization/resources/sessions/client/requests/SessionRestInputV1.js +17 -7
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -5
- package/dist/serialization/resources/sessions/types/SessionsEventsResponse.js +19 -9
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseError.js +17 -7
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseSessionEvent.js +17 -7
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseStatus.js +17 -7
- package/dist/serialization/resources/sessions/types/SessionsEventsResponseWindowEvent.js +17 -7
- package/dist/serialization/resources/sessions/types/SessionsListRequestStatus.js +17 -7
- package/dist/serialization/resources/sessions/types/index.d.ts +1 -1
- package/dist/serialization/resources/sessions/types/index.js +1 -1
- package/dist/serialization/resources/windows/client/requests/AsyncClickRequest.d.ts +20 -0
- package/dist/serialization/resources/windows/client/requests/AsyncClickRequest.js +51 -0
- package/dist/serialization/resources/windows/client/requests/AsyncCreateAutomationRequest.d.ts +18 -0
- package/dist/serialization/resources/windows/client/requests/AsyncCreateAutomationRequest.js +49 -0
- package/dist/serialization/resources/windows/client/requests/AsyncExecuteAutomationRequest.d.ts +18 -0
- package/dist/serialization/resources/windows/client/requests/AsyncExecuteAutomationRequest.js +49 -0
- package/dist/serialization/resources/windows/client/requests/AsyncHoverRequest.d.ts +19 -0
- package/dist/serialization/resources/windows/client/requests/AsyncHoverRequest.js +50 -0
- package/dist/serialization/resources/windows/client/requests/AsyncMonitorRequest.d.ts +19 -0
- package/dist/serialization/resources/windows/client/requests/AsyncMonitorRequest.js +50 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPageQueryRequest.d.ts +20 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPageQueryRequest.js +51 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPaginatedExtractionRequest.d.ts +19 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPaginatedExtractionRequest.js +50 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPromptContentRequest.d.ts +20 -0
- package/dist/serialization/resources/windows/client/requests/AsyncPromptContentRequest.js +51 -0
- package/dist/serialization/resources/windows/client/requests/AsyncScreenshotRequest.d.ts +18 -0
- package/dist/serialization/resources/windows/client/requests/AsyncScreenshotRequest.js +49 -0
- package/dist/serialization/resources/windows/client/requests/AsyncSummarizeContentRequest.d.ts +19 -0
- package/dist/serialization/resources/windows/client/requests/AsyncSummarizeContentRequest.js +50 -0
- package/dist/serialization/resources/windows/client/requests/AsyncTypeRequest.d.ts +24 -0
- package/dist/serialization/resources/windows/client/requests/AsyncTypeRequest.js +55 -0
- package/dist/serialization/resources/windows/client/requests/CreateWindowInputV1Body.js +17 -7
- package/dist/serialization/resources/windows/client/requests/ScrapeContentRequest.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionClickHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionHoverHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionMonitorHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionPaginatedExtractionHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionScreenshotHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionScrollHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionSummaryHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/SessionTypeHandlerRequestBody.js +17 -7
- package/dist/serialization/resources/windows/client/requests/WindowLoadUrlV1Body.js +17 -7
- package/dist/serialization/resources/windows/client/requests/index.d.ts +11 -0
- package/dist/serialization/resources/windows/client/requests/index.js +23 -1
- package/dist/serialization/resources/windows/types/CreateWindowInputV1BodyWaitUntil.js +17 -7
- package/dist/serialization/resources/windows/types/WindowLoadUrlV1BodyWaitUntil.js +17 -7
- package/dist/serialization/types/AiPromptResponse.js +17 -7
- package/dist/serialization/types/AiResponseEnvelope.js +17 -7
- package/dist/serialization/types/AirtopProxyConfiguration.js +17 -7
- package/dist/serialization/types/AsyncConfig.d.ts +12 -0
- package/dist/serialization/types/AsyncConfig.js +43 -0
- package/dist/serialization/types/AsyncSessionAiResponseEnvelope.d.ts +15 -0
- package/dist/serialization/types/AsyncSessionAiResponseEnvelope.js +46 -0
- package/dist/serialization/types/AutomationOutput.d.ts +16 -0
- package/dist/serialization/types/AutomationOutput.js +47 -0
- package/dist/serialization/types/BrowserWaitNavigationConfig.js +17 -7
- package/dist/serialization/types/BrowserWaitNavigationConfigWaitUntil.js +17 -7
- package/dist/serialization/types/ClickConfig.js +17 -7
- package/dist/serialization/types/ClickConfigClickType.js +17 -7
- package/dist/serialization/types/ClientProvidedResponseMetadata.js +17 -7
- package/dist/serialization/types/CreateAutomationRequestBodyConfiguration.d.ts +10 -0
- package/dist/serialization/types/CreateAutomationRequestBodyConfiguration.js +41 -0
- package/dist/serialization/types/CreateFileV1.d.ts +21 -0
- package/dist/serialization/types/CreateFileV1.js +52 -0
- package/dist/serialization/types/CreateFileV1FileType.d.ts +10 -0
- package/dist/serialization/types/CreateFileV1FileType.js +41 -0
- package/dist/serialization/types/DeleteAutomationOutputWrapperBody.d.ts +10 -0
- package/dist/serialization/types/DeleteAutomationOutputWrapperBody.js +41 -0
- package/dist/serialization/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.d.ts +18 -0
- package/dist/serialization/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.js +49 -0
- package/dist/serialization/types/EnvelopeDefaultMeta.js +17 -7
- package/dist/serialization/types/EnvelopeGetFileV1EnvelopeDefaultMeta.d.ts +18 -0
- package/dist/serialization/types/EnvelopeGetFileV1EnvelopeDefaultMeta.js +49 -0
- package/dist/serialization/types/ErrorBody.js +17 -7
- package/dist/serialization/types/ErrorDetail.js +17 -7
- package/dist/serialization/types/ErrorMessage.js +17 -7
- package/dist/serialization/types/ErrorModel.js +17 -7
- package/dist/serialization/types/ExternalFile.d.ts +25 -0
- package/dist/serialization/types/ExternalFile.js +56 -0
- package/dist/serialization/types/ExternalSessionAiResponseMetadata.js +17 -7
- package/dist/serialization/types/ExternalSessionAiResponseMetadataStatus.js +17 -7
- package/dist/serialization/types/ExternalSessionAiResponseMetadataUsage.js +17 -7
- package/dist/serialization/types/ExternalSessionConfig.js +17 -7
- package/dist/serialization/types/ExternalSessionWithConnectionInfo.js +17 -7
- package/dist/serialization/types/FilesResponse.d.ts +18 -0
- package/dist/serialization/types/FilesResponse.js +49 -0
- package/dist/serialization/types/FilesWithPagination.d.ts +15 -0
- package/dist/serialization/types/FilesWithPagination.js +46 -0
- package/dist/serialization/types/GetFileV1.d.ts +21 -0
- package/dist/serialization/types/GetFileV1.js +52 -0
- package/dist/serialization/types/GetFileV1FileType.d.ts +10 -0
- package/dist/serialization/types/GetFileV1FileType.js +41 -0
- package/dist/serialization/types/IntervalMonitorConfig.js +17 -7
- package/dist/serialization/types/Issue.js +17 -7
- package/dist/serialization/types/ListAutomationsOutput.d.ts +13 -0
- package/dist/serialization/types/ListAutomationsOutput.js +44 -0
- package/dist/serialization/types/MicroInteractionConfig.js +17 -7
- package/dist/serialization/types/MicroInteractionConfigWithExperimental.js +17 -7
- package/dist/serialization/types/MicroInteractionExperimentalConfig.js +17 -7
- package/dist/serialization/types/MonitorConfig.js +17 -7
- package/dist/serialization/types/MonitorConfigIncludeVisualAnalysis.js +17 -7
- package/dist/serialization/types/OperationOutcome.js +17 -7
- package/dist/serialization/types/OperationOutcomeResponse.js +17 -7
- package/dist/serialization/types/PageQueryConfig.js +17 -7
- package/dist/serialization/types/PageQueryExperimentalConfig.js +17 -7
- package/dist/serialization/types/PaginatedExtractionConfig.js +17 -7
- package/dist/serialization/types/PaginatedExtractionExperimentalConfig.js +17 -7
- package/dist/serialization/types/Pagination.js +17 -7
- package/dist/serialization/types/Proxy.js +17 -7
- package/dist/serialization/types/ProxyConfigurationKind.js +17 -7
- package/dist/serialization/types/ProxyCredentials.js +17 -7
- package/dist/serialization/types/RequestStatusResponse.js +17 -7
- package/dist/serialization/types/ScrapeConfig.js +17 -7
- package/dist/serialization/types/ScrapeResponse.js +17 -7
- package/dist/serialization/types/ScrapeResponseContent.js +17 -7
- package/dist/serialization/types/ScrapeResponseEnvelope.js +17 -7
- package/dist/serialization/types/ScrapeResponseOutput.js +17 -7
- package/dist/serialization/types/ScreenshotConfig.js +17 -7
- package/dist/serialization/types/ScreenshotMetadata.js +17 -7
- package/dist/serialization/types/ScreenshotRequestConfig.js +17 -7
- package/dist/serialization/types/ScrollByConfig.js +17 -7
- package/dist/serialization/types/ScrollToEdgeConfig.js +17 -7
- package/dist/serialization/types/SessionConfigV1.js +17 -7
- package/dist/serialization/types/SessionConfigV1Proxy.js +17 -7
- package/dist/serialization/types/SessionEventMessage.js +17 -7
- package/dist/serialization/types/SessionPageQueryHandlerRequestBody.js +17 -7
- package/dist/serialization/types/SessionResponse.js +17 -7
- package/dist/serialization/types/SessionsResponse.js +17 -7
- package/dist/serialization/types/SessionsWithPagination.js +17 -7
- package/dist/serialization/types/StatusMessage.js +17 -7
- package/dist/serialization/types/StatusMessageStatus.js +17 -7
- package/dist/serialization/types/SummaryConfig.js +17 -7
- package/dist/serialization/types/SummaryExperimentalConfig.js +17 -7
- package/dist/serialization/types/VisualAnalysisConfig.js +17 -7
- package/dist/serialization/types/VisualAnalysisConfigPartitionDirection.js +17 -7
- package/dist/serialization/types/VisualAnalysisConfigResultSelectionStrategy.js +17 -7
- package/dist/serialization/types/VisualAnalysisConfigScope.js +17 -7
- package/dist/serialization/types/Window.js +17 -7
- package/dist/serialization/types/WindowEventMessage.js +17 -7
- package/dist/serialization/types/WindowId.js +17 -7
- package/dist/serialization/types/WindowIdResponse.js +17 -7
- package/dist/serialization/types/WindowResponse.js +17 -7
- package/dist/serialization/types/index.d.ts +26 -0
- package/dist/serialization/types/index.js +26 -0
- package/dist/utils/batch-operate/SessionQueue.js +2 -2
- package/dist/utils/batch-operate/WindowQueue.js +2 -2
- package/dist/utils/batch-operate/batch-util.d.ts +1 -1
- package/dist/utils/batch-operate/types.d.ts +5 -5
- package/dist/utils/process-screenshots.d.ts +1 -2
- package/dist/utils/process-screenshots.js +1 -2
- package/dist/version.d.ts +1 -0
- package/dist/version.js +4 -0
- package/dist/wrapper/AirtopClient.d.ts +5 -2
- package/dist/wrapper/AirtopClient.js +24 -8
- package/dist/wrapper/AirtopFiles.d.ts +38 -0
- package/dist/wrapper/AirtopFiles.js +151 -0
- package/dist/wrapper/AirtopRequests.js +2 -2
- package/dist/wrapper/AirtopSessions.js +7 -5
- package/dist/wrapper/AirtopWindows.d.ts +1 -1
- package/dist/wrapper/AirtopWindows.js +22 -12
- package/environments.d.ts +1 -1
- package/errors/AirtopError.js +2 -1
- package/errors/AirtopTimeoutError.d.ts +1 -1
- package/errors/AirtopTimeoutError.js +2 -2
- package/index.js +17 -7
- package/{jest.config.js → jest.config.mjs} +4 -1
- package/live-view/types.d.ts +1 -1
- package/live-view/types.js +1 -1
- package/package.json +18 -14
- package/reference.md +2009 -175
- package/scripts/rename-to-esm-files.js +115 -0
- package/serialization/resources/automations/client/index.d.ts +1 -0
- package/serialization/resources/automations/client/index.js +17 -0
- package/serialization/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.d.ts +14 -0
- package/serialization/resources/automations/client/requests/UpdateAutomationDescriptionInputBody.js +45 -0
- package/serialization/resources/automations/client/requests/index.d.ts +1 -0
- package/serialization/resources/automations/client/requests/index.js +5 -0
- package/serialization/resources/automations/index.d.ts +1 -0
- package/serialization/resources/automations/index.js +17 -0
- package/serialization/resources/files/client/index.d.ts +1 -0
- package/serialization/resources/files/client/index.js +17 -0
- package/serialization/resources/files/client/requests/CreateFileRestInputV1.d.ts +16 -0
- package/serialization/resources/files/client/requests/CreateFileRestInputV1.js +47 -0
- package/serialization/resources/files/client/requests/index.d.ts +1 -0
- package/serialization/resources/files/client/requests/index.js +5 -0
- package/serialization/resources/files/index.d.ts +2 -0
- package/serialization/resources/files/index.js +18 -0
- package/serialization/resources/files/types/CreateFileRestInputV1FileType.d.ts +10 -0
- package/serialization/resources/files/types/CreateFileRestInputV1FileType.js +41 -0
- package/serialization/resources/files/types/index.d.ts +1 -0
- package/serialization/resources/files/types/index.js +17 -0
- package/serialization/resources/index.d.ts +5 -0
- package/serialization/resources/index.js +23 -8
- package/serialization/resources/sessions/client/requests/SessionRestInputV1.js +17 -7
- package/serialization/resources/sessions/types/SessionsEventsResponse.d.ts +5 -5
- package/serialization/resources/sessions/types/SessionsEventsResponse.js +19 -9
- package/serialization/resources/sessions/types/SessionsEventsResponseError.js +17 -7
- package/serialization/resources/sessions/types/SessionsEventsResponseSessionEvent.js +17 -7
- package/serialization/resources/sessions/types/SessionsEventsResponseStatus.js +17 -7
- package/serialization/resources/sessions/types/SessionsEventsResponseWindowEvent.js +17 -7
- package/serialization/resources/sessions/types/SessionsListRequestStatus.js +17 -7
- package/serialization/resources/sessions/types/index.d.ts +1 -1
- package/serialization/resources/sessions/types/index.js +1 -1
- package/serialization/resources/windows/client/requests/AsyncClickRequest.d.ts +20 -0
- package/serialization/resources/windows/client/requests/AsyncClickRequest.js +51 -0
- package/serialization/resources/windows/client/requests/AsyncCreateAutomationRequest.d.ts +18 -0
- package/serialization/resources/windows/client/requests/AsyncCreateAutomationRequest.js +49 -0
- package/serialization/resources/windows/client/requests/AsyncExecuteAutomationRequest.d.ts +18 -0
- package/serialization/resources/windows/client/requests/AsyncExecuteAutomationRequest.js +49 -0
- package/serialization/resources/windows/client/requests/AsyncHoverRequest.d.ts +19 -0
- package/serialization/resources/windows/client/requests/AsyncHoverRequest.js +50 -0
- package/serialization/resources/windows/client/requests/AsyncMonitorRequest.d.ts +19 -0
- package/serialization/resources/windows/client/requests/AsyncMonitorRequest.js +50 -0
- package/serialization/resources/windows/client/requests/AsyncPageQueryRequest.d.ts +20 -0
- package/serialization/resources/windows/client/requests/AsyncPageQueryRequest.js +51 -0
- package/serialization/resources/windows/client/requests/AsyncPaginatedExtractionRequest.d.ts +19 -0
- package/serialization/resources/windows/client/requests/AsyncPaginatedExtractionRequest.js +50 -0
- package/serialization/resources/windows/client/requests/AsyncPromptContentRequest.d.ts +20 -0
- package/serialization/resources/windows/client/requests/AsyncPromptContentRequest.js +51 -0
- package/serialization/resources/windows/client/requests/AsyncScreenshotRequest.d.ts +18 -0
- package/serialization/resources/windows/client/requests/AsyncScreenshotRequest.js +49 -0
- package/serialization/resources/windows/client/requests/AsyncSummarizeContentRequest.d.ts +19 -0
- package/serialization/resources/windows/client/requests/AsyncSummarizeContentRequest.js +50 -0
- package/serialization/resources/windows/client/requests/AsyncTypeRequest.d.ts +24 -0
- package/serialization/resources/windows/client/requests/AsyncTypeRequest.js +55 -0
- package/serialization/resources/windows/client/requests/CreateWindowInputV1Body.js +17 -7
- package/serialization/resources/windows/client/requests/ScrapeContentRequest.js +17 -7
- package/serialization/resources/windows/client/requests/SessionClickHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionHoverHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionMonitorHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionPaginatedExtractionHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionScreenshotHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionScrollHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionSummaryHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/SessionTypeHandlerRequestBody.js +17 -7
- package/serialization/resources/windows/client/requests/WindowLoadUrlV1Body.js +17 -7
- package/serialization/resources/windows/client/requests/index.d.ts +11 -0
- package/serialization/resources/windows/client/requests/index.js +23 -1
- package/serialization/resources/windows/types/CreateWindowInputV1BodyWaitUntil.js +17 -7
- package/serialization/resources/windows/types/WindowLoadUrlV1BodyWaitUntil.js +17 -7
- package/serialization/types/AiPromptResponse.js +17 -7
- package/serialization/types/AiResponseEnvelope.js +17 -7
- package/serialization/types/AirtopProxyConfiguration.js +17 -7
- package/serialization/types/AsyncConfig.d.ts +12 -0
- package/serialization/types/AsyncConfig.js +43 -0
- package/serialization/types/AsyncSessionAiResponseEnvelope.d.ts +15 -0
- package/serialization/types/AsyncSessionAiResponseEnvelope.js +46 -0
- package/serialization/types/AutomationOutput.d.ts +16 -0
- package/serialization/types/AutomationOutput.js +47 -0
- package/serialization/types/BrowserWaitNavigationConfig.js +17 -7
- package/serialization/types/BrowserWaitNavigationConfigWaitUntil.js +17 -7
- package/serialization/types/ClickConfig.js +17 -7
- package/serialization/types/ClickConfigClickType.js +17 -7
- package/serialization/types/ClientProvidedResponseMetadata.js +17 -7
- package/serialization/types/CreateAutomationRequestBodyConfiguration.d.ts +10 -0
- package/serialization/types/CreateAutomationRequestBodyConfiguration.js +41 -0
- package/serialization/types/CreateFileV1.d.ts +21 -0
- package/serialization/types/CreateFileV1.js +52 -0
- package/serialization/types/CreateFileV1FileType.d.ts +10 -0
- package/serialization/types/CreateFileV1FileType.js +41 -0
- package/serialization/types/DeleteAutomationOutputWrapperBody.d.ts +10 -0
- package/serialization/types/DeleteAutomationOutputWrapperBody.js +41 -0
- package/serialization/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.d.ts +18 -0
- package/serialization/types/EnvelopeCreateFileV1EnvelopeDefaultMeta.js +49 -0
- package/serialization/types/EnvelopeDefaultMeta.js +17 -7
- package/serialization/types/EnvelopeGetFileV1EnvelopeDefaultMeta.d.ts +18 -0
- package/serialization/types/EnvelopeGetFileV1EnvelopeDefaultMeta.js +49 -0
- package/serialization/types/ErrorBody.js +17 -7
- package/serialization/types/ErrorDetail.js +17 -7
- package/serialization/types/ErrorMessage.js +17 -7
- package/serialization/types/ErrorModel.js +17 -7
- package/serialization/types/ExternalFile.d.ts +25 -0
- package/serialization/types/ExternalFile.js +56 -0
- package/serialization/types/ExternalSessionAiResponseMetadata.js +17 -7
- package/serialization/types/ExternalSessionAiResponseMetadataStatus.js +17 -7
- package/serialization/types/ExternalSessionAiResponseMetadataUsage.js +17 -7
- package/serialization/types/ExternalSessionConfig.js +17 -7
- package/serialization/types/ExternalSessionWithConnectionInfo.js +17 -7
- package/serialization/types/FilesResponse.d.ts +18 -0
- package/serialization/types/FilesResponse.js +49 -0
- package/serialization/types/FilesWithPagination.d.ts +15 -0
- package/serialization/types/FilesWithPagination.js +46 -0
- package/serialization/types/GetFileV1.d.ts +21 -0
- package/serialization/types/GetFileV1.js +52 -0
- package/serialization/types/GetFileV1FileType.d.ts +10 -0
- package/serialization/types/GetFileV1FileType.js +41 -0
- package/serialization/types/IntervalMonitorConfig.js +17 -7
- package/serialization/types/Issue.js +17 -7
- package/serialization/types/ListAutomationsOutput.d.ts +13 -0
- package/serialization/types/ListAutomationsOutput.js +44 -0
- package/serialization/types/MicroInteractionConfig.js +17 -7
- package/serialization/types/MicroInteractionConfigWithExperimental.js +17 -7
- package/serialization/types/MicroInteractionExperimentalConfig.js +17 -7
- package/serialization/types/MonitorConfig.js +17 -7
- package/serialization/types/MonitorConfigIncludeVisualAnalysis.js +17 -7
- package/serialization/types/OperationOutcome.js +17 -7
- package/serialization/types/OperationOutcomeResponse.js +17 -7
- package/serialization/types/PageQueryConfig.js +17 -7
- package/serialization/types/PageQueryExperimentalConfig.js +17 -7
- package/serialization/types/PaginatedExtractionConfig.js +17 -7
- package/serialization/types/PaginatedExtractionExperimentalConfig.js +17 -7
- package/serialization/types/Pagination.js +17 -7
- package/serialization/types/Proxy.js +17 -7
- package/serialization/types/ProxyConfigurationKind.js +17 -7
- package/serialization/types/ProxyCredentials.js +17 -7
- package/serialization/types/RequestStatusResponse.js +17 -7
- package/serialization/types/ScrapeConfig.js +17 -7
- package/serialization/types/ScrapeResponse.js +17 -7
- package/serialization/types/ScrapeResponseContent.js +17 -7
- package/serialization/types/ScrapeResponseEnvelope.js +17 -7
- package/serialization/types/ScrapeResponseOutput.js +17 -7
- package/serialization/types/ScreenshotConfig.js +17 -7
- package/serialization/types/ScreenshotMetadata.js +17 -7
- package/serialization/types/ScreenshotRequestConfig.js +17 -7
- package/serialization/types/ScrollByConfig.js +17 -7
- package/serialization/types/ScrollToEdgeConfig.js +17 -7
- package/serialization/types/SessionConfigV1.js +17 -7
- package/serialization/types/SessionConfigV1Proxy.js +17 -7
- package/serialization/types/SessionEventMessage.js +17 -7
- package/serialization/types/SessionPageQueryHandlerRequestBody.js +17 -7
- package/serialization/types/SessionResponse.js +17 -7
- package/serialization/types/SessionsResponse.js +17 -7
- package/serialization/types/SessionsWithPagination.js +17 -7
- package/serialization/types/StatusMessage.js +17 -7
- package/serialization/types/StatusMessageStatus.js +17 -7
- package/serialization/types/SummaryConfig.js +17 -7
- package/serialization/types/SummaryExperimentalConfig.js +17 -7
- package/serialization/types/VisualAnalysisConfig.js +17 -7
- package/serialization/types/VisualAnalysisConfigPartitionDirection.js +17 -7
- package/serialization/types/VisualAnalysisConfigResultSelectionStrategy.js +17 -7
- package/serialization/types/VisualAnalysisConfigScope.js +17 -7
- package/serialization/types/Window.js +17 -7
- package/serialization/types/WindowEventMessage.js +17 -7
- package/serialization/types/WindowId.js +17 -7
- package/serialization/types/WindowIdResponse.js +17 -7
- package/serialization/types/WindowResponse.js +17 -7
- package/serialization/types/index.d.ts +26 -0
- package/serialization/types/index.js +26 -0
- package/utils/batch-operate/SessionQueue.js +2 -2
- package/utils/batch-operate/WindowQueue.js +2 -2
- package/utils/batch-operate/batch-util.d.ts +1 -1
- package/utils/batch-operate/types.d.ts +5 -5
- package/utils/process-screenshots.d.ts +1 -2
- package/utils/process-screenshots.js +1 -2
- package/version.d.ts +1 -0
- package/version.js +4 -0
- package/wrapper/AirtopClient.d.ts +5 -2
- package/wrapper/AirtopClient.js +24 -8
- package/wrapper/AirtopFiles.d.ts +38 -0
- package/wrapper/AirtopFiles.js +151 -0
- package/wrapper/AirtopRequests.js +2 -2
- package/wrapper/AirtopSessions.js +7 -5
- package/wrapper/AirtopWindows.d.ts +1 -1
- package/wrapper/AirtopWindows.js +22 -12
@@ -0,0 +1,13 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
export interface ExtensionConfigurationOutput {
|
5
|
+
/** The date and time the configuration was created. Might be null for old configurations */
|
6
|
+
createdAt?: Date;
|
7
|
+
/** The ids of the extensions in configuration. */
|
8
|
+
extensionIds?: string[];
|
9
|
+
/** Name of the extension configuration. */
|
10
|
+
name: string;
|
11
|
+
/** The date and time the configuration was last updated. Might be null for configurations not updated recently */
|
12
|
+
updatedAt?: Date;
|
13
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
export interface ExternalFile {
|
5
|
+
/** Whether the file has been deleted */
|
6
|
+
deleted: boolean;
|
7
|
+
/** Time when the file was deleted */
|
8
|
+
deletionTime?: Date;
|
9
|
+
/** Size of the file in bytes */
|
10
|
+
fileBytes: number;
|
11
|
+
/** Name of the file */
|
12
|
+
fileName: string;
|
13
|
+
/** Type of the file */
|
14
|
+
fileType: string;
|
15
|
+
/** ID of the file */
|
16
|
+
id: string;
|
17
|
+
/** Time when the file was last heartbeated */
|
18
|
+
lastHeartbeatTime?: Date;
|
19
|
+
/** ID of the organization */
|
20
|
+
orgId: string;
|
21
|
+
/** IDs of the associated sessions */
|
22
|
+
sessionIds?: string[];
|
23
|
+
/** Status of the file */
|
24
|
+
status: string;
|
25
|
+
/** Time when the file was uploaded */
|
26
|
+
uploadCompleteTime?: Date;
|
27
|
+
/** Time when the file was uploaded */
|
28
|
+
uploadStartTime: Date;
|
29
|
+
/** Whether the file is visible in the API */
|
30
|
+
visibleInApi: boolean;
|
31
|
+
/** Whether the file is visible in the portal */
|
32
|
+
visibleInPortal: boolean;
|
33
|
+
}
|
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* Outcome of the operation.
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type ExternalSessionAiResponseMetadataStatus = "success" | "partial" | "failure";
|
8
8
|
export declare const ExternalSessionAiResponseMetadataStatus: {
|
9
9
|
readonly Success: "success";
|
10
10
|
readonly Partial: "partial";
|
@@ -0,0 +1,10 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Airtop from "../index";
|
5
|
+
export interface FilesResponse {
|
6
|
+
data: Airtop.FilesWithPagination;
|
7
|
+
errors?: Airtop.Issue[];
|
8
|
+
meta: Airtop.EnvelopeDefaultMeta;
|
9
|
+
warnings?: Airtop.Issue[];
|
10
|
+
}
|
@@ -0,0 +1,10 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Airtop from "../index";
|
5
|
+
export interface FilesWithPagination {
|
6
|
+
/** List of files. */
|
7
|
+
files?: Airtop.ExternalFile[];
|
8
|
+
/** Pagination details. */
|
9
|
+
pagination: Airtop.Pagination;
|
10
|
+
}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Airtop from "../index";
|
5
|
+
export interface GetFileV1 {
|
6
|
+
/** URL to download the file */
|
7
|
+
downloadUrl: string;
|
8
|
+
/** Size of the file in bytes */
|
9
|
+
fileBytes: number;
|
10
|
+
/** Name of the file */
|
11
|
+
fileName: string;
|
12
|
+
/** Type of the file */
|
13
|
+
fileType: Airtop.GetFileV1FileType;
|
14
|
+
/** ID of the file */
|
15
|
+
id: string;
|
16
|
+
/** ID of the organization */
|
17
|
+
orgId: string;
|
18
|
+
/** DEPRECATED: Use sessionIds instead */
|
19
|
+
sessionId?: string;
|
20
|
+
/** IDs of the associated sessions */
|
21
|
+
sessionIds?: string[];
|
22
|
+
/** Time when the file upload was started */
|
23
|
+
uploadStartTime: Date;
|
24
|
+
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
/**
|
5
|
+
* Type of the file
|
6
|
+
*/
|
7
|
+
export type GetFileV1FileType = "browser_download" | "screenshot" | "video" | "customer_upload";
|
8
|
+
export declare const GetFileV1FileType: {
|
9
|
+
readonly BrowserDownload: "browser_download";
|
10
|
+
readonly Screenshot: "screenshot";
|
11
|
+
readonly Video: "video";
|
12
|
+
readonly CustomerUpload: "customer_upload";
|
13
|
+
};
|
@@ -0,0 +1,12 @@
|
|
1
|
+
"use strict";
|
2
|
+
/**
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
4
|
+
*/
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
exports.GetFileV1FileType = void 0;
|
7
|
+
exports.GetFileV1FileType = {
|
8
|
+
BrowserDownload: "browser_download",
|
9
|
+
Screenshot: "screenshot",
|
10
|
+
Video: "video",
|
11
|
+
CustomerUpload: "customer_upload",
|
12
|
+
};
|
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* If set to 'enabled', Airtop AI will also analyze the web page visually when executing the condition check. If set to 'disabled', no visual analysis will be conducted.
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type MonitorConfigIncludeVisualAnalysis = "auto" | "disabled" | "enabled";
|
8
8
|
export declare const MonitorConfigIncludeVisualAnalysis: {
|
9
9
|
readonly Auto: "auto";
|
10
10
|
readonly Disabled: "disabled";
|
package/api/types/Proxy.d.ts
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* Status of the session
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type StatusMessageStatus = "awaitingCapacity" | "initializing" | "running" | "ended" | "error" | "disconnected";
|
8
8
|
export declare const StatusMessageStatus: {
|
9
9
|
readonly AwaitingCapacity: "awaitingCapacity";
|
10
10
|
readonly Initializing: "initializing";
|
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* The direction to partition the screenshot into chunks: 'vertical', 'horizontal', or 'bidirectional'. Defaults to 'vertical', which is recommended for most web pages. For optimal results when partitioning in a single direction, ensure the perpendicular dimension does not exceed 1920 pixels.
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type VisualAnalysisConfigPartitionDirection = "vertical" | "horizontal" | "bidirectional";
|
8
8
|
export declare const VisualAnalysisConfigPartitionDirection: {
|
9
9
|
readonly Vertical: "vertical";
|
10
10
|
readonly Horizontal: "horizontal";
|
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* [Experimental] The strategy to use for selecting the match using visual analysis. Can be 'auto', 'first' or 'bestMatch'. Defaults to 'auto'. Use 'auto' to let the system decide the best strategy. Use 'first' to select the first visual element that matches the element description. This will favor results that appear higher on the page in the event of multiple matches. Use 'bestMatch' to analyze the complete page and apply judgement to select the best candidate from all potential matches.
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type VisualAnalysisConfigResultSelectionStrategy = "first" | "bestMatch" | "auto";
|
8
8
|
export declare const VisualAnalysisConfigResultSelectionStrategy: {
|
9
9
|
readonly First: "first";
|
10
10
|
readonly BestMatch: "bestMatch";
|
@@ -4,7 +4,7 @@
|
|
4
4
|
/**
|
5
5
|
* Whether to analyze the current viewport or the whole page. Can be 'viewport', 'page', 'scan' or 'auto'. Defaults to 'auto', which provides the simplest out-of-the-box experience for most web pages. Use 'viewport' for analysis of the current browser view only. Use 'page' for a full page analysis. Use 'scan' for a full page analysis on sites that have compatibility or accuracy issues with 'page' mode.
|
6
6
|
*/
|
7
|
-
export
|
7
|
+
export type VisualAnalysisConfigScope = "viewport" | "page" | "scan" | "auto";
|
8
8
|
export declare const VisualAnalysisConfigScope: {
|
9
9
|
readonly Viewport: "viewport";
|
10
10
|
readonly Page: "page";
|
package/api/types/index.d.ts
CHANGED
@@ -1,22 +1,48 @@
|
|
1
1
|
export * from "./AiPromptResponse";
|
2
2
|
export * from "./AiResponseEnvelope";
|
3
|
+
export * from "./AsyncConfig";
|
4
|
+
export * from "./AsyncSessionAiResponseEnvelope";
|
5
|
+
export * from "./AutomationOutput";
|
3
6
|
export * from "./BrowserWaitNavigationConfigWaitUntil";
|
4
7
|
export * from "./BrowserWaitNavigationConfig";
|
5
8
|
export * from "./ClickConfigClickType";
|
6
9
|
export * from "./ClickConfig";
|
7
10
|
export * from "./ClientProvidedResponseMetadata";
|
11
|
+
export * from "./CreateAutomationRequestBodyConfiguration";
|
12
|
+
export * from "./CreateFileV1FileType";
|
13
|
+
export * from "./CreateFileV1";
|
14
|
+
export * from "./DeleteAutomationOutputWrapperBody";
|
15
|
+
export * from "./EnvelopeCreateFileV1EnvelopeDefaultMeta";
|
16
|
+
export * from "./CreateAutomationRequestBodyConfiguration";
|
17
|
+
export * from "./CreateFileV1FileType";
|
18
|
+
export * from "./CreateFileV1";
|
19
|
+
export * from "./DeleteAutomationOutputWrapperBody";
|
20
|
+
export * from "./EnvelopeCreateFileV1EnvelopeDefaultMeta";
|
8
21
|
export * from "./EnvelopeDefaultMeta";
|
22
|
+
export * from "./EnvelopeGetFileV1EnvelopeDefaultMeta";
|
23
|
+
export * from "./EnvelopeGetFileV1EnvelopeDefaultMeta";
|
9
24
|
export * from "./ErrorBody";
|
10
25
|
export * from "./ErrorDetail";
|
11
26
|
export * from "./ErrorMessage";
|
12
27
|
export * from "./ErrorModel";
|
28
|
+
export * from "./ExternalFile";
|
29
|
+
export * from "./ExternalFile";
|
13
30
|
export * from "./ExternalSessionAiResponseMetadataStatus";
|
14
31
|
export * from "./ExternalSessionAiResponseMetadata";
|
15
32
|
export * from "./ExternalSessionAiResponseMetadataUsage";
|
16
33
|
export * from "./ExternalSessionConfig";
|
17
34
|
export * from "./ExternalSessionWithConnectionInfo";
|
35
|
+
export * from "./FilesResponse";
|
36
|
+
export * from "./FilesWithPagination";
|
37
|
+
export * from "./GetFileV1FileType";
|
38
|
+
export * from "./GetFileV1";
|
39
|
+
export * from "./FilesResponse";
|
40
|
+
export * from "./FilesWithPagination";
|
41
|
+
export * from "./GetFileV1FileType";
|
42
|
+
export * from "./GetFileV1";
|
18
43
|
export * from "./IntervalMonitorConfig";
|
19
44
|
export * from "./Issue";
|
45
|
+
export * from "./ListAutomationsOutput";
|
20
46
|
export * from "./MicroInteractionConfig";
|
21
47
|
export * from "./MicroInteractionConfigWithExperimental";
|
22
48
|
export * from "./MicroInteractionExperimentalConfig";
|
package/api/types/index.js
CHANGED
@@ -16,23 +16,49 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
17
17
|
__exportStar(require("./AiPromptResponse"), exports);
|
18
18
|
__exportStar(require("./AiResponseEnvelope"), exports);
|
19
|
+
__exportStar(require("./AsyncConfig"), exports);
|
20
|
+
__exportStar(require("./AsyncSessionAiResponseEnvelope"), exports);
|
21
|
+
__exportStar(require("./AutomationOutput"), exports);
|
19
22
|
__exportStar(require("./BrowserWaitNavigationConfigWaitUntil"), exports);
|
20
23
|
__exportStar(require("./BrowserWaitNavigationConfig"), exports);
|
21
24
|
__exportStar(require("./ClickConfigClickType"), exports);
|
22
25
|
__exportStar(require("./ClickConfig"), exports);
|
23
26
|
__exportStar(require("./ClientProvidedResponseMetadata"), exports);
|
27
|
+
__exportStar(require("./CreateAutomationRequestBodyConfiguration"), exports);
|
28
|
+
__exportStar(require("./CreateFileV1FileType"), exports);
|
29
|
+
__exportStar(require("./CreateFileV1"), exports);
|
30
|
+
__exportStar(require("./DeleteAutomationOutputWrapperBody"), exports);
|
31
|
+
__exportStar(require("./EnvelopeCreateFileV1EnvelopeDefaultMeta"), exports);
|
32
|
+
__exportStar(require("./CreateAutomationRequestBodyConfiguration"), exports);
|
33
|
+
__exportStar(require("./CreateFileV1FileType"), exports);
|
34
|
+
__exportStar(require("./CreateFileV1"), exports);
|
35
|
+
__exportStar(require("./DeleteAutomationOutputWrapperBody"), exports);
|
36
|
+
__exportStar(require("./EnvelopeCreateFileV1EnvelopeDefaultMeta"), exports);
|
24
37
|
__exportStar(require("./EnvelopeDefaultMeta"), exports);
|
38
|
+
__exportStar(require("./EnvelopeGetFileV1EnvelopeDefaultMeta"), exports);
|
39
|
+
__exportStar(require("./EnvelopeGetFileV1EnvelopeDefaultMeta"), exports);
|
25
40
|
__exportStar(require("./ErrorBody"), exports);
|
26
41
|
__exportStar(require("./ErrorDetail"), exports);
|
27
42
|
__exportStar(require("./ErrorMessage"), exports);
|
28
43
|
__exportStar(require("./ErrorModel"), exports);
|
44
|
+
__exportStar(require("./ExternalFile"), exports);
|
45
|
+
__exportStar(require("./ExternalFile"), exports);
|
29
46
|
__exportStar(require("./ExternalSessionAiResponseMetadataStatus"), exports);
|
30
47
|
__exportStar(require("./ExternalSessionAiResponseMetadata"), exports);
|
31
48
|
__exportStar(require("./ExternalSessionAiResponseMetadataUsage"), exports);
|
32
49
|
__exportStar(require("./ExternalSessionConfig"), exports);
|
33
50
|
__exportStar(require("./ExternalSessionWithConnectionInfo"), exports);
|
51
|
+
__exportStar(require("./FilesResponse"), exports);
|
52
|
+
__exportStar(require("./FilesWithPagination"), exports);
|
53
|
+
__exportStar(require("./GetFileV1FileType"), exports);
|
54
|
+
__exportStar(require("./GetFileV1"), exports);
|
55
|
+
__exportStar(require("./FilesResponse"), exports);
|
56
|
+
__exportStar(require("./FilesWithPagination"), exports);
|
57
|
+
__exportStar(require("./GetFileV1FileType"), exports);
|
58
|
+
__exportStar(require("./GetFileV1"), exports);
|
34
59
|
__exportStar(require("./IntervalMonitorConfig"), exports);
|
35
60
|
__exportStar(require("./Issue"), exports);
|
61
|
+
__exportStar(require("./ListAutomationsOutput"), exports);
|
36
62
|
__exportStar(require("./MicroInteractionConfig"), exports);
|
37
63
|
__exportStar(require("./MicroInteractionConfigWithExperimental"), exports);
|
38
64
|
__exportStar(require("./MicroInteractionExperimentalConfig"), exports);
|
package/biome.json
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
export
|
1
|
+
export type APIResponse<Success, Failure> = SuccessfulResponse<Success> | FailedResponse<Failure>;
|
2
2
|
export interface SuccessfulResponse<T> {
|
3
3
|
ok: true;
|
4
4
|
body: T;
|
@@ -1,19 +1,19 @@
|
|
1
1
|
import { APIResponse } from "./APIResponse";
|
2
|
-
export
|
2
|
+
export type FetchFunction = <R = unknown>(args: Fetcher.Args) => Promise<APIResponse<R, Fetcher.Error>>;
|
3
3
|
export declare namespace Fetcher {
|
4
4
|
interface Args {
|
5
5
|
url: string;
|
6
6
|
method: string;
|
7
7
|
contentType?: string;
|
8
8
|
headers?: Record<string, string | undefined>;
|
9
|
-
queryParameters?: Record<string, string | string[] | object | object[]>;
|
9
|
+
queryParameters?: Record<string, string | string[] | object | object[] | null>;
|
10
10
|
body?: unknown;
|
11
11
|
timeoutMs?: number;
|
12
12
|
maxRetries?: number;
|
13
13
|
withCredentials?: boolean;
|
14
14
|
abortSignal?: AbortSignal;
|
15
15
|
requestType?: "json" | "file" | "bytes";
|
16
|
-
responseType?: "json" | "blob" | "sse" | "streaming" | "text";
|
16
|
+
responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer";
|
17
17
|
duplex?: "half";
|
18
18
|
}
|
19
19
|
type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError;
|
package/core/fetcher/Fetcher.js
CHANGED
@@ -9,7 +9,9 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
9
9
|
});
|
10
10
|
};
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.fetcher =
|
12
|
+
exports.fetcher = void 0;
|
13
|
+
exports.fetcherImpl = fetcherImpl;
|
14
|
+
const json_1 = require("../json");
|
13
15
|
const createRequestUrl_1 = require("./createRequestUrl");
|
14
16
|
const getFetchFn_1 = require("./getFetchFn");
|
15
17
|
const getRequestBody_1 = require("./getRequestBody");
|
@@ -30,7 +32,7 @@ function fetcherImpl(args) {
|
|
30
32
|
}
|
31
33
|
}
|
32
34
|
const url = (0, createRequestUrl_1.createRequestUrl)(args.url, args.queryParameters);
|
33
|
-
|
35
|
+
const requestBody = yield (0, getRequestBody_1.getRequestBody)({
|
34
36
|
body: args.body,
|
35
37
|
type: args.requestType === "json" ? "json" : "other",
|
36
38
|
});
|
@@ -39,7 +41,7 @@ function fetcherImpl(args) {
|
|
39
41
|
const response = yield (0, requestWithRetries_1.requestWithRetries)(() => __awaiter(this, void 0, void 0, function* () {
|
40
42
|
return (0, makeRequest_1.makeRequest)(fetchFn, url, args.method, headers, requestBody, args.timeoutMs, args.abortSignal, args.withCredentials, args.duplex);
|
41
43
|
}), args.maxRetries);
|
42
|
-
|
44
|
+
const responseBody = yield (0, getResponseBody_1.getResponseBody)(response, args.responseType);
|
43
45
|
if (response.status >= 200 && response.status < 400) {
|
44
46
|
return {
|
45
47
|
ok: true,
|
@@ -89,11 +91,10 @@ function fetcherImpl(args) {
|
|
89
91
|
ok: false,
|
90
92
|
error: {
|
91
93
|
reason: "unknown",
|
92
|
-
errorMessage:
|
94
|
+
errorMessage: (0, json_1.toJson)(error),
|
93
95
|
},
|
94
96
|
};
|
95
97
|
}
|
96
98
|
});
|
97
99
|
}
|
98
|
-
exports.fetcherImpl = fetcherImpl;
|
99
100
|
exports.fetcher = fetcherImpl;
|
@@ -1 +1 @@
|
|
1
|
-
export declare function createRequestUrl(baseUrl: string, queryParameters?: Record<string, string | string[] | object | object[]>): string;
|
1
|
+
export declare function createRequestUrl(baseUrl: string, queryParameters?: Record<string, string | string[] | object | object[] | null>): string;
|
@@ -3,11 +3,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.createRequestUrl =
|
6
|
+
exports.createRequestUrl = createRequestUrl;
|
7
7
|
const qs_1 = __importDefault(require("qs"));
|
8
8
|
function createRequestUrl(baseUrl, queryParameters) {
|
9
9
|
return Object.keys(queryParameters !== null && queryParameters !== void 0 ? queryParameters : {}).length > 0
|
10
10
|
? `${baseUrl}?${qs_1.default.stringify(queryParameters, { arrayFormat: "repeat" })}`
|
11
11
|
: baseUrl;
|
12
12
|
}
|
13
|
-
exports.createRequestUrl = createRequestUrl;
|
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
|
|
15
15
|
}) : function(o, v) {
|
16
16
|
o["default"] = v;
|
17
17
|
});
|
18
|
-
var __importStar = (this && this.__importStar) || function (
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
};
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
19
|
+
var ownKeys = function(o) {
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
21
|
+
var ar = [];
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
23
|
+
return ar;
|
24
|
+
};
|
25
|
+
return ownKeys(o);
|
26
|
+
};
|
27
|
+
return function (mod) {
|
28
|
+
if (mod && mod.__esModule) return mod;
|
29
|
+
var result = {};
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
31
|
+
__setModuleDefault(result, mod);
|
32
|
+
return result;
|
33
|
+
};
|
34
|
+
})();
|
25
35
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
26
36
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
27
37
|
return new (P || (P = Promise))(function (resolve, reject) {
|
@@ -32,7 +42,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
32
42
|
});
|
33
43
|
};
|
34
44
|
Object.defineProperty(exports, "__esModule", { value: true });
|
35
|
-
exports.getFetchFn =
|
45
|
+
exports.getFetchFn = getFetchFn;
|
36
46
|
const runtime_1 = require("../runtime");
|
37
47
|
/**
|
38
48
|
* Returns a fetch function based on the runtime
|
@@ -56,4 +66,3 @@ function getFetchFn() {
|
|
56
66
|
return (yield Promise.resolve().then(() => __importStar(require("node-fetch")))).default;
|
57
67
|
});
|
58
68
|
}
|
59
|
-
exports.getFetchFn = getFetchFn;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.getHeader =
|
3
|
+
exports.getHeader = getHeader;
|
4
4
|
function getHeader(headers, header) {
|
5
5
|
for (const [headerKey, headerValue] of Object.entries(headers)) {
|
6
6
|
if (headerKey.toLowerCase() === header.toLowerCase()) {
|
@@ -9,4 +9,3 @@ function getHeader(headers, header) {
|
|
9
9
|
}
|
10
10
|
return undefined;
|
11
11
|
}
|
12
|
-
exports.getHeader = getHeader;
|
@@ -9,15 +9,15 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
9
9
|
});
|
10
10
|
};
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.getRequestBody =
|
13
|
-
|
14
|
-
|
12
|
+
exports.getRequestBody = getRequestBody;
|
13
|
+
const json_1 = require("../json");
|
14
|
+
function getRequestBody(_a) {
|
15
|
+
return __awaiter(this, arguments, void 0, function* ({ body, type }) {
|
15
16
|
if (type.includes("json")) {
|
16
|
-
return
|
17
|
+
return (0, json_1.toJson)(body);
|
17
18
|
}
|
18
19
|
else {
|
19
20
|
return body;
|
20
21
|
}
|
21
22
|
});
|
22
23
|
}
|
23
|
-
exports.getRequestBody = getRequestBody;
|
@@ -9,13 +9,16 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
9
9
|
});
|
10
10
|
};
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.getResponseBody =
|
12
|
+
exports.getResponseBody = getResponseBody;
|
13
13
|
const chooseStreamWrapper_1 = require("./stream-wrappers/chooseStreamWrapper");
|
14
14
|
function getResponseBody(response, responseType) {
|
15
15
|
return __awaiter(this, void 0, void 0, function* () {
|
16
16
|
if (response.body != null && responseType === "blob") {
|
17
17
|
return yield response.blob();
|
18
18
|
}
|
19
|
+
else if (response.body != null && responseType === "arrayBuffer") {
|
20
|
+
return yield response.arrayBuffer();
|
21
|
+
}
|
19
22
|
else if (response.body != null && responseType === "sse") {
|
20
23
|
return response.body;
|
21
24
|
}
|
@@ -49,4 +52,3 @@ function getResponseBody(response, responseType) {
|
|
49
52
|
}
|
50
53
|
});
|
51
54
|
}
|
52
|
-
exports.getResponseBody = getResponseBody;
|
@@ -1 +1 @@
|
|
1
|
-
export declare const makeRequest: (fetchFn: (url: string, init: RequestInit) => Promise<Response>, url: string, method: string, headers: Record<string, string>, requestBody: BodyInit | undefined, timeoutMs?: number
|
1
|
+
export declare const makeRequest: (fetchFn: (url: string, init: RequestInit) => Promise<Response>, url: string, method: string, headers: Record<string, string>, requestBody: BodyInit | undefined, timeoutMs?: number, abortSignal?: AbortSignal, withCredentials?: boolean, duplex?: "half") => Promise<Response>;
|
@@ -9,17 +9,26 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
9
9
|
});
|
10
10
|
};
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
exports.requestWithRetries =
|
13
|
-
const INITIAL_RETRY_DELAY =
|
14
|
-
const MAX_RETRY_DELAY =
|
12
|
+
exports.requestWithRetries = requestWithRetries;
|
13
|
+
const INITIAL_RETRY_DELAY = 1000; // in milliseconds
|
14
|
+
const MAX_RETRY_DELAY = 60000; // in milliseconds
|
15
15
|
const DEFAULT_MAX_RETRIES = 2;
|
16
|
-
|
17
|
-
|
16
|
+
const JITTER_FACTOR = 0.2; // 20% random jitter
|
17
|
+
function addJitter(delay) {
|
18
|
+
// Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR
|
19
|
+
const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR;
|
20
|
+
return delay * jitterMultiplier;
|
21
|
+
}
|
22
|
+
function requestWithRetries(requestFn_1) {
|
23
|
+
return __awaiter(this, arguments, void 0, function* (requestFn, maxRetries = DEFAULT_MAX_RETRIES) {
|
18
24
|
let response = yield requestFn();
|
19
25
|
for (let i = 0; i < maxRetries; ++i) {
|
20
|
-
if ([408,
|
21
|
-
|
22
|
-
|
26
|
+
if ([408, 429].includes(response.status) || response.status >= 500) {
|
27
|
+
// Calculate base delay using exponential backoff (in milliseconds)
|
28
|
+
const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY);
|
29
|
+
// Add jitter to the delay
|
30
|
+
const delayWithJitter = addJitter(baseDelay);
|
31
|
+
yield new Promise((resolve) => setTimeout(resolve, delayWithJitter));
|
23
32
|
response = yield requestFn();
|
24
33
|
}
|
25
34
|
else {
|
@@ -29,4 +38,3 @@ function requestWithRetries(requestFn, maxRetries = DEFAULT_MAX_RETRIES) {
|
|
29
38
|
return response;
|
30
39
|
});
|
31
40
|
}
|
32
|
-
exports.requestWithRetries = requestWithRetries;
|