polytomic 1.16.0 → 1.18.1
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 -19
- package/api/errors/BadRequestError.js +7 -17
- package/api/errors/ConflictError.js +7 -17
- package/api/errors/ForbiddenError.js +7 -17
- package/api/errors/InternalServerError.js +7 -17
- package/api/errors/NotFoundError.js +7 -17
- package/api/errors/UnauthorizedError.js +7 -17
- package/api/errors/UnprocessableEntityError.js +7 -17
- package/api/resources/bulkSync/client/Client.d.ts +173 -24
- package/api/resources/bulkSync/client/Client.js +339 -118
- package/api/resources/bulkSync/client/requests/BulkSyncGetSourceRequest.d.ts +3 -0
- package/api/resources/bulkSync/client/requests/BulkSyncListRequest.d.ts +3 -0
- package/api/resources/bulkSync/client/requests/CreateBulkSyncRequest.d.ts +1 -1
- package/api/resources/bulkSync/client/requests/StartBulkSyncRequest.d.ts +4 -0
- package/api/resources/bulkSync/client/requests/UpdateBulkSyncRequest.d.ts +1 -1
- package/api/resources/bulkSync/resources/executions/client/Client.d.ts +77 -12
- package/api/resources/bulkSync/resources/executions/client/Client.js +168 -66
- package/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListRequest.d.ts +12 -0
- package/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListStatusRequest.d.ts +3 -3
- package/api/resources/bulkSync/resources/index.js +7 -17
- package/api/resources/bulkSync/resources/schedules/client/Client.d.ts +44 -15
- package/api/resources/bulkSync/resources/schedules/client/Client.js +116 -57
- package/api/resources/bulkSync/resources/schedules/client/requests/CreateScheduleRequest.d.ts +1 -1
- package/api/resources/bulkSync/resources/schedules/client/requests/UpdateScheduleRequest.d.ts +1 -1
- package/api/resources/bulkSync/resources/schemas/client/Client.d.ts +71 -11
- package/api/resources/bulkSync/resources/schemas/client/Client.js +150 -61
- package/api/resources/bulkSync/resources/schemas/client/requests/BulkSyncSchemasRequest.d.ts +1 -0
- package/api/resources/bulkSync/resources/schemas/client/requests/SchemasListRequest.d.ts +3 -0
- package/api/resources/bulkSync/resources/schemas/client/requests/UpdateBulkSchema.d.ts +7 -0
- package/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/api/resources/connections/client/Client.d.ts +160 -12
- package/api/resources/connections/client/Client.js +473 -86
- package/api/resources/connections/client/requests/ApiRequest.d.ts +13 -0
- package/api/resources/connections/client/requests/GetConnectionTypeParameterValuesRequestSchema.d.ts +15 -0
- package/api/resources/connections/client/requests/index.d.ts +2 -0
- package/api/resources/events/client/Client.d.ts +20 -7
- package/api/resources/events/client/Client.js +55 -33
- package/api/resources/events/client/requests/EventsListRequest.d.ts +17 -2
- package/api/resources/identity/client/Client.d.ts +11 -6
- package/api/resources/identity/client/Client.js +31 -24
- package/api/resources/index.js +7 -17
- package/api/resources/jobs/client/Client.d.ts +15 -8
- package/api/resources/jobs/client/Client.js +35 -26
- package/api/resources/modelSync/client/Client.d.ts +110 -19
- package/api/resources/modelSync/client/Client.js +287 -118
- package/api/resources/modelSync/client/requests/CreateModelSyncRequest.d.ts +1 -1
- package/api/resources/modelSync/client/requests/ModelSyncGetSourceFieldsRequest.d.ts +3 -0
- package/api/resources/modelSync/client/requests/ModelSyncGetSourceRequest.d.ts +3 -0
- package/api/resources/modelSync/client/requests/UpdateModelSyncRequest.d.ts +1 -1
- package/api/resources/modelSync/resources/executions/client/Client.d.ts +41 -12
- package/api/resources/modelSync/resources/executions/client/Client.js +115 -56
- package/api/resources/modelSync/resources/executions/client/requests/UpdateExecutionRequest.d.ts +1 -1
- package/api/resources/modelSync/resources/index.js +7 -17
- package/api/resources/modelSync/resources/targets/client/Client.d.ts +28 -11
- package/api/resources/modelSync/resources/targets/client/Client.js +89 -49
- package/api/resources/modelSync/resources/targets/client/requests/TargetsGetTargetFieldsRequest.d.ts +6 -0
- package/api/resources/modelSync/resources/targets/client/requests/TargetsGetTargetRequest.d.ts +6 -0
- package/api/resources/models/client/Client.d.ts +79 -8
- package/api/resources/models/client/Client.js +214 -86
- package/api/resources/models/client/requests/ModelsGetEnrichmentSourceRequest.d.ts +3 -0
- package/api/resources/notifications/client/Client.d.ts +13 -5
- package/api/resources/notifications/client/Client.js +48 -31
- package/api/resources/notifications/client/requests/V4GlobalErrorSubscribersRequest.d.ts +1 -0
- package/api/resources/organization/client/Client.d.ts +31 -13
- package/api/resources/organization/client/Client.js +109 -55
- package/api/resources/organization/client/requests/CreateOrganizationRequestSchema.d.ts +6 -0
- package/api/resources/organization/client/requests/UpdateOrganizationRequestSchema.d.ts +6 -0
- package/api/resources/permissions/client/Client.d.ts +2 -7
- package/api/resources/permissions/resources/index.js +7 -17
- package/api/resources/permissions/resources/policies/client/Client.d.ts +33 -5
- package/api/resources/permissions/resources/policies/client/Client.js +105 -47
- package/api/resources/permissions/resources/roles/client/Client.d.ts +38 -5
- package/api/resources/permissions/resources/roles/client/Client.js +110 -47
- package/api/resources/queryRunner/client/Client.d.ts +26 -7
- package/api/resources/queryRunner/client/Client.js +63 -35
- package/api/resources/queryRunner/client/requests/QueryRunnerGetQueryRequest.d.ts +3 -0
- package/api/resources/schemas/client/Client.d.ts +118 -23
- package/api/resources/schemas/client/Client.js +232 -86
- package/api/resources/schemas/client/requests/SetPrimaryKeysRequest.d.ts +1 -0
- package/api/resources/schemas/client/requests/UpsertSchemaFieldRequest.d.ts +1 -0
- package/api/resources/users/client/Client.d.ts +44 -16
- package/api/resources/users/client/Client.js +133 -66
- package/api/resources/users/client/requests/CreateUserRequestSchema.d.ts +4 -0
- package/api/resources/users/client/requests/UpdateUserRequestSchema.d.ts +4 -0
- package/api/resources/users/client/requests/UsersCreateApiKeyRequest.d.ts +3 -0
- package/api/resources/webhooks/client/Client.d.ts +67 -21
- package/api/resources/webhooks/client/Client.js +165 -75
- package/api/types/ApiKeyResponse.d.ts +1 -0
- package/api/types/BulkBulkSyncSchedule.d.ts +1 -0
- package/api/types/BulkDiscover.d.ts +1 -1
- package/api/types/BulkExecutionStatus.d.ts +1 -1
- package/api/types/BulkFetchMode.d.ts +1 -1
- package/api/types/BulkNormalizeNames.d.ts +1 -1
- package/api/types/BulkOutputDisposition.d.ts +9 -0
- package/api/types/BulkOutputDisposition.js +11 -0
- package/api/types/BulkResyncMode.d.ts +9 -0
- package/api/types/BulkResyncMode.js +11 -0
- package/api/types/BulkScheduleSyncMode.d.ts +1 -1
- package/api/types/BulkSchema.d.ts +2 -0
- package/api/types/BulkSchemaExecutionStatus.d.ts +2 -1
- package/api/types/BulkSchemaExecutionStatus.js +1 -0
- package/api/types/BulkSelectiveMode.d.ts +1 -1
- package/api/types/BulkSyncDest.d.ts +2 -0
- package/api/types/BulkSyncExecution.d.ts +1 -0
- package/api/types/BulkSyncExecutionStatus.d.ts +3 -0
- package/api/types/BulkSyncIngestionStatus.d.ts +14 -0
- package/{dist/version.js → api/types/BulkSyncIngestionStatus.js} +3 -2
- package/api/types/BulkSyncMode.d.ts +1 -1
- package/api/types/BulkSyncResponse.d.ts +2 -2
- package/api/types/BulkSyncSchemaExecutionStatus.d.ts +7 -0
- package/api/types/BulkSyncSource.d.ts +1 -0
- package/api/types/BulkSyncStatusResponse.d.ts +1 -0
- package/api/types/ConnectCardResponse.d.ts +1 -0
- package/api/types/ConnectionResponseSchema.d.ts +4 -2
- package/api/types/CreateSharedConnectionResponseSchema.d.ts +6 -0
- package/{version.js → api/types/CreateSharedConnectionResponseSchema.js} +3 -2
- package/api/types/Event.d.ts +4 -0
- package/api/types/EventBody.d.ts +1 -1
- package/api/types/ExecutionStatus.d.ts +1 -1
- package/api/types/FilterFieldReferenceType.d.ts +1 -1
- package/api/types/FilterFunction.d.ts +1 -1
- package/api/types/GetIdentityResponseSchema.d.ts +2 -0
- package/api/types/IngestionStatusLevel.d.ts +12 -0
- package/api/types/IngestionStatusLevel.js +11 -0
- package/api/types/JobResponse.d.ts +3 -0
- package/api/types/JsonschemaDefinitions.d.ts +1 -1
- package/api/types/JsonschemaForm.d.ts +1 -1
- package/api/types/LabelLabel.d.ts +1 -1
- package/api/types/ModelField.d.ts +1 -1
- package/api/types/ModelResponse.d.ts +2 -2
- package/api/types/ModelSyncMode.d.ts +2 -1
- package/api/types/ModelSyncMode.js +1 -0
- package/api/types/ModelSyncResponse.d.ts +2 -2
- package/api/types/ModelSyncSourceMetaResponse.d.ts +3 -0
- package/api/types/Organization.d.ts +5 -0
- package/api/types/{CommonOutputActor.d.ts → OutputActor.d.ts} +1 -1
- package/api/types/OutputActor.js +5 -0
- package/api/types/ScheduleFrequency.d.ts +1 -1
- package/api/types/SchemaIdentityFunction.d.ts +1 -1
- package/api/types/SourceMeta.d.ts +3 -0
- package/api/types/TypesType.d.ts +1 -1
- package/api/types/User.d.ts +6 -0
- package/api/types/UtilFieldType.d.ts +1 -1
- package/api/types/V2CreateSharedConnectionResponseEnvelope.d.ts +7 -0
- package/api/types/V2CreateSharedConnectionResponseEnvelope.js +5 -0
- package/api/types/V2EnricherConfiguration.d.ts +1 -1
- package/api/types/V2EnricherMapping.d.ts +1 -1
- package/api/types/V2ExecutionLogType.d.ts +1 -1
- package/api/types/V2OrderedMapStringGithubComInvopopJsonschemaSchema.d.ts +1 -1
- package/api/types/V2SampleRecord.d.ts +1 -1
- package/api/types/V2SchemaConfigurationFieldsItem.d.ts +1 -1
- package/api/types/V3BulkSyncSourceCapabilities.d.ts +6 -0
- package/api/types/V3BulkSyncSourceCapabilities.js +5 -0
- package/api/types/V4BulkSyncExecutionLogs.d.ts +6 -1
- package/api/types/V4BulkSyncScheduleApi.d.ts +5 -0
- package/api/types/V4ExportSyncLogsResponse.d.ts +1 -0
- package/api/types/V4GlobalErrorSubscribersResponse.d.ts +1 -0
- package/api/types/V4RunQueryResult.d.ts +2 -1
- package/api/types/V4UserFieldRequest.d.ts +4 -0
- package/api/types/WorkTaskStatus.d.ts +1 -1
- package/api/types/index.d.ts +13 -6
- package/api/types/index.js +13 -6
- package/core/auth/BearerToken.d.ts +1 -1
- package/core/fetcher/APIResponse.d.ts +1 -1
- package/core/fetcher/Fetcher.d.ts +3 -6
- package/core/fetcher/Fetcher.js +189 -20
- package/core/fetcher/Supplier.d.ts +1 -1
- package/core/fetcher/getHeader.js +2 -1
- package/core/runtime/runtime.d.ts +1 -2
- package/core/runtime/runtime.js +41 -52
- package/dist/Client.d.ts +14 -19
- package/dist/api/errors/BadRequestError.js +7 -17
- package/dist/api/errors/ConflictError.js +7 -17
- package/dist/api/errors/ForbiddenError.js +7 -17
- package/dist/api/errors/InternalServerError.js +7 -17
- package/dist/api/errors/NotFoundError.js +7 -17
- package/dist/api/errors/UnauthorizedError.js +7 -17
- package/dist/api/errors/UnprocessableEntityError.js +7 -17
- package/dist/api/resources/bulkSync/client/Client.d.ts +173 -24
- package/dist/api/resources/bulkSync/client/Client.js +339 -118
- package/dist/api/resources/bulkSync/client/requests/BulkSyncGetSourceRequest.d.ts +3 -0
- package/dist/api/resources/bulkSync/client/requests/BulkSyncListRequest.d.ts +3 -0
- package/dist/api/resources/bulkSync/client/requests/CreateBulkSyncRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/client/requests/StartBulkSyncRequest.d.ts +4 -0
- package/dist/api/resources/bulkSync/client/requests/UpdateBulkSyncRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/executions/client/Client.d.ts +77 -12
- package/dist/api/resources/bulkSync/resources/executions/client/Client.js +168 -66
- package/dist/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListRequest.d.ts +12 -0
- package/dist/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListStatusRequest.d.ts +3 -3
- package/dist/api/resources/bulkSync/resources/index.js +7 -17
- package/dist/api/resources/bulkSync/resources/schedules/client/Client.d.ts +44 -15
- package/dist/api/resources/bulkSync/resources/schedules/client/Client.js +116 -57
- package/dist/api/resources/bulkSync/resources/schedules/client/requests/CreateScheduleRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/schedules/client/requests/UpdateScheduleRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/schemas/client/Client.d.ts +71 -11
- package/dist/api/resources/bulkSync/resources/schemas/client/Client.js +150 -61
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/BulkSyncSchemasRequest.d.ts +1 -0
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/SchemasListRequest.d.ts +3 -0
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/UpdateBulkSchema.d.ts +7 -0
- package/dist/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/dist/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/dist/api/resources/connections/client/Client.d.ts +160 -12
- package/dist/api/resources/connections/client/Client.js +473 -86
- package/dist/api/resources/connections/client/requests/ApiRequest.d.ts +13 -0
- package/dist/api/resources/connections/client/requests/ApiRequest.js +5 -0
- package/dist/api/resources/connections/client/requests/GetConnectionTypeParameterValuesRequestSchema.d.ts +15 -0
- package/dist/api/resources/connections/client/requests/GetConnectionTypeParameterValuesRequestSchema.js +5 -0
- package/dist/api/resources/connections/client/requests/index.d.ts +2 -0
- package/dist/api/resources/events/client/Client.d.ts +20 -7
- package/dist/api/resources/events/client/Client.js +55 -33
- package/dist/api/resources/events/client/requests/EventsListRequest.d.ts +17 -2
- package/dist/api/resources/identity/client/Client.d.ts +11 -6
- package/dist/api/resources/identity/client/Client.js +31 -24
- package/dist/api/resources/index.js +7 -17
- package/dist/api/resources/jobs/client/Client.d.ts +15 -8
- package/dist/api/resources/jobs/client/Client.js +35 -26
- package/dist/api/resources/modelSync/client/Client.d.ts +110 -19
- package/dist/api/resources/modelSync/client/Client.js +287 -118
- package/dist/api/resources/modelSync/client/requests/CreateModelSyncRequest.d.ts +1 -1
- package/dist/api/resources/modelSync/client/requests/ModelSyncGetSourceFieldsRequest.d.ts +3 -0
- package/dist/api/resources/modelSync/client/requests/ModelSyncGetSourceRequest.d.ts +3 -0
- package/dist/api/resources/modelSync/client/requests/UpdateModelSyncRequest.d.ts +1 -1
- package/dist/api/resources/modelSync/resources/executions/client/Client.d.ts +41 -12
- package/dist/api/resources/modelSync/resources/executions/client/Client.js +115 -56
- package/dist/api/resources/modelSync/resources/executions/client/requests/UpdateExecutionRequest.d.ts +1 -1
- package/dist/api/resources/modelSync/resources/index.js +7 -17
- package/dist/api/resources/modelSync/resources/targets/client/Client.d.ts +28 -11
- package/dist/api/resources/modelSync/resources/targets/client/Client.js +89 -49
- package/dist/api/resources/modelSync/resources/targets/client/requests/TargetsGetTargetFieldsRequest.d.ts +6 -0
- package/dist/api/resources/modelSync/resources/targets/client/requests/TargetsGetTargetRequest.d.ts +6 -0
- package/dist/api/resources/models/client/Client.d.ts +79 -8
- package/dist/api/resources/models/client/Client.js +214 -86
- package/dist/api/resources/models/client/requests/ModelsGetEnrichmentSourceRequest.d.ts +3 -0
- package/dist/api/resources/notifications/client/Client.d.ts +13 -5
- package/dist/api/resources/notifications/client/Client.js +48 -31
- package/dist/api/resources/notifications/client/requests/V4GlobalErrorSubscribersRequest.d.ts +1 -0
- package/dist/api/resources/organization/client/Client.d.ts +31 -13
- package/dist/api/resources/organization/client/Client.js +109 -55
- package/dist/api/resources/organization/client/requests/CreateOrganizationRequestSchema.d.ts +6 -0
- package/dist/api/resources/organization/client/requests/UpdateOrganizationRequestSchema.d.ts +6 -0
- package/dist/api/resources/permissions/client/Client.d.ts +2 -7
- package/dist/api/resources/permissions/resources/index.js +7 -17
- package/dist/api/resources/permissions/resources/policies/client/Client.d.ts +33 -5
- package/dist/api/resources/permissions/resources/policies/client/Client.js +105 -47
- package/dist/api/resources/permissions/resources/roles/client/Client.d.ts +38 -5
- package/dist/api/resources/permissions/resources/roles/client/Client.js +110 -47
- package/dist/api/resources/queryRunner/client/Client.d.ts +26 -7
- package/dist/api/resources/queryRunner/client/Client.js +63 -35
- package/dist/api/resources/queryRunner/client/requests/QueryRunnerGetQueryRequest.d.ts +3 -0
- package/dist/api/resources/schemas/client/Client.d.ts +118 -23
- package/dist/api/resources/schemas/client/Client.js +232 -86
- package/dist/api/resources/schemas/client/requests/SetPrimaryKeysRequest.d.ts +1 -0
- package/dist/api/resources/schemas/client/requests/UpsertSchemaFieldRequest.d.ts +1 -0
- package/dist/api/resources/users/client/Client.d.ts +44 -16
- package/dist/api/resources/users/client/Client.js +133 -66
- package/dist/api/resources/users/client/requests/CreateUserRequestSchema.d.ts +4 -0
- package/dist/api/resources/users/client/requests/UpdateUserRequestSchema.d.ts +4 -0
- package/dist/api/resources/users/client/requests/UsersCreateApiKeyRequest.d.ts +3 -0
- package/dist/api/resources/webhooks/client/Client.d.ts +67 -21
- package/dist/api/resources/webhooks/client/Client.js +165 -75
- package/dist/api/types/ApiKeyResponse.d.ts +1 -0
- package/dist/api/types/BulkBulkSyncSchedule.d.ts +1 -0
- package/dist/api/types/BulkDiscover.d.ts +1 -1
- package/dist/api/types/BulkExecutionStatus.d.ts +1 -1
- package/dist/api/types/BulkFetchMode.d.ts +1 -1
- package/dist/api/types/BulkNormalizeNames.d.ts +1 -1
- package/dist/api/types/BulkOutputDisposition.d.ts +9 -0
- package/dist/api/types/BulkOutputDisposition.js +11 -0
- package/dist/api/types/BulkResyncMode.d.ts +9 -0
- package/dist/api/types/BulkResyncMode.js +11 -0
- package/dist/api/types/BulkScheduleSyncMode.d.ts +1 -1
- package/dist/api/types/BulkSchema.d.ts +2 -0
- package/dist/api/types/BulkSchemaExecutionStatus.d.ts +2 -1
- package/dist/api/types/BulkSchemaExecutionStatus.js +1 -0
- package/dist/api/types/BulkSelectiveMode.d.ts +1 -1
- package/dist/api/types/BulkSyncDest.d.ts +2 -0
- package/dist/api/types/BulkSyncExecution.d.ts +1 -0
- package/dist/api/types/BulkSyncExecutionStatus.d.ts +3 -0
- package/dist/api/types/BulkSyncIngestionStatus.d.ts +14 -0
- package/dist/api/types/BulkSyncIngestionStatus.js +5 -0
- package/dist/api/types/BulkSyncMode.d.ts +1 -1
- package/dist/api/types/BulkSyncResponse.d.ts +2 -2
- package/dist/api/types/BulkSyncSchemaExecutionStatus.d.ts +7 -0
- package/dist/api/types/BulkSyncSource.d.ts +1 -0
- package/dist/api/types/BulkSyncStatusResponse.d.ts +1 -0
- package/dist/api/types/ConnectCardResponse.d.ts +1 -0
- package/dist/api/types/ConnectionResponseSchema.d.ts +4 -2
- package/dist/api/types/CreateSharedConnectionResponseSchema.d.ts +6 -0
- package/dist/api/types/CreateSharedConnectionResponseSchema.js +5 -0
- package/dist/api/types/Event.d.ts +4 -0
- package/dist/api/types/EventBody.d.ts +1 -1
- package/dist/api/types/ExecutionStatus.d.ts +1 -1
- package/dist/api/types/FilterFieldReferenceType.d.ts +1 -1
- package/dist/api/types/FilterFunction.d.ts +1 -1
- package/dist/api/types/GetIdentityResponseSchema.d.ts +2 -0
- package/dist/api/types/IngestionStatusLevel.d.ts +12 -0
- package/dist/api/types/IngestionStatusLevel.js +11 -0
- package/dist/api/types/JobResponse.d.ts +3 -0
- package/dist/api/types/JsonschemaDefinitions.d.ts +1 -1
- package/dist/api/types/JsonschemaForm.d.ts +1 -1
- package/dist/api/types/LabelLabel.d.ts +1 -1
- package/dist/api/types/ModelField.d.ts +1 -1
- package/dist/api/types/ModelResponse.d.ts +2 -2
- package/dist/api/types/ModelSyncMode.d.ts +2 -1
- package/dist/api/types/ModelSyncMode.js +1 -0
- package/dist/api/types/ModelSyncResponse.d.ts +2 -2
- package/dist/api/types/ModelSyncSourceMetaResponse.d.ts +3 -0
- package/dist/api/types/Organization.d.ts +5 -0
- package/dist/api/types/{CommonOutputActor.d.ts → OutputActor.d.ts} +1 -1
- package/dist/api/types/OutputActor.js +5 -0
- package/dist/api/types/ScheduleFrequency.d.ts +1 -1
- package/dist/api/types/SchemaIdentityFunction.d.ts +1 -1
- package/dist/api/types/SourceMeta.d.ts +3 -0
- package/dist/api/types/TypesType.d.ts +1 -1
- package/dist/api/types/User.d.ts +6 -0
- package/dist/api/types/UtilFieldType.d.ts +1 -1
- package/dist/api/types/V2CreateSharedConnectionResponseEnvelope.d.ts +7 -0
- package/dist/api/types/V2CreateSharedConnectionResponseEnvelope.js +5 -0
- package/dist/api/types/V2EnricherConfiguration.d.ts +1 -1
- package/dist/api/types/V2EnricherMapping.d.ts +1 -1
- package/dist/api/types/V2ExecutionLogType.d.ts +1 -1
- package/dist/api/types/V2OrderedMapStringGithubComInvopopJsonschemaSchema.d.ts +1 -1
- package/dist/api/types/V2SampleRecord.d.ts +1 -1
- package/dist/api/types/V2SchemaConfigurationFieldsItem.d.ts +1 -1
- package/dist/api/types/V3BulkSyncSourceCapabilities.d.ts +6 -0
- package/dist/api/types/V3BulkSyncSourceCapabilities.js +5 -0
- package/dist/api/types/V4BulkSyncExecutionLogs.d.ts +6 -1
- package/dist/api/types/V4BulkSyncScheduleApi.d.ts +5 -0
- package/dist/api/types/V4ExportSyncLogsResponse.d.ts +1 -0
- package/dist/api/types/V4GlobalErrorSubscribersResponse.d.ts +1 -0
- package/dist/api/types/V4RunQueryResult.d.ts +2 -1
- package/dist/api/types/V4UserFieldRequest.d.ts +4 -0
- package/dist/api/types/WorkTaskStatus.d.ts +1 -1
- package/dist/api/types/index.d.ts +13 -6
- package/dist/api/types/index.js +13 -6
- 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 -6
- package/dist/core/fetcher/Fetcher.js +189 -20
- package/dist/core/fetcher/Supplier.d.ts +1 -1
- package/dist/core/fetcher/getHeader.js +2 -1
- package/dist/core/runtime/runtime.d.ts +1 -2
- package/dist/core/runtime/runtime.js +41 -52
- package/dist/environments.d.ts +1 -1
- package/dist/errors/PolytomicError.js +1 -2
- package/dist/errors/PolytomicTimeoutError.d.ts +1 -1
- package/dist/errors/PolytomicTimeoutError.js +2 -2
- package/dist/index.js +7 -17
- package/environments.d.ts +1 -1
- package/errors/PolytomicError.js +1 -2
- package/errors/PolytomicTimeoutError.d.ts +1 -1
- package/errors/PolytomicTimeoutError.js +2 -2
- package/index.js +7 -17
- package/{jest.config.mjs → jest.config.js} +1 -4
- package/package.json +17 -18
- package/core/fetcher/createRequestUrl.d.ts +0 -1
- package/core/fetcher/createRequestUrl.js +0 -12
- package/core/fetcher/getFetchFn.d.ts +0 -4
- package/core/fetcher/getFetchFn.js +0 -68
- package/core/fetcher/getRequestBody.d.ts +0 -7
- package/core/fetcher/getRequestBody.js +0 -23
- package/core/fetcher/getResponseBody.d.ts +0 -1
- package/core/fetcher/getResponseBody.js +0 -54
- package/core/fetcher/makeRequest.d.ts +0 -1
- package/core/fetcher/makeRequest.js +0 -42
- package/core/fetcher/requestWithRetries.d.ts +0 -1
- package/core/fetcher/requestWithRetries.js +0 -40
- package/core/fetcher/signals.d.ts +0 -11
- package/core/fetcher/signals.js +0 -36
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -18
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/core/json.d.ts +0 -15
- package/core/json.js +0 -24
- package/dist/core/fetcher/createRequestUrl.d.ts +0 -1
- package/dist/core/fetcher/createRequestUrl.js +0 -12
- package/dist/core/fetcher/getFetchFn.d.ts +0 -4
- package/dist/core/fetcher/getFetchFn.js +0 -68
- package/dist/core/fetcher/getRequestBody.d.ts +0 -7
- package/dist/core/fetcher/getRequestBody.js +0 -23
- package/dist/core/fetcher/getResponseBody.d.ts +0 -1
- package/dist/core/fetcher/getResponseBody.js +0 -54
- package/dist/core/fetcher/makeRequest.d.ts +0 -1
- package/dist/core/fetcher/makeRequest.js +0 -42
- package/dist/core/fetcher/requestWithRetries.d.ts +0 -1
- package/dist/core/fetcher/requestWithRetries.js +0 -40
- package/dist/core/fetcher/signals.d.ts +0 -11
- 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.d.ts +0 -18
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/dist/core/json.d.ts +0 -15
- package/dist/core/json.js +0 -24
- package/dist/version.d.ts +0 -1
- package/reference.md +0 -6547
- package/scripts/rename-to-esm-files.js +0 -115
- package/version.d.ts +0 -1
- /package/api/{types/CommonOutputActor.js → resources/connections/client/requests/ApiRequest.js} +0 -0
- /package/{dist/api/types/CommonOutputActor.js → api/resources/connections/client/requests/GetConnectionTypeParameterValuesRequestSchema.js} +0 -0
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
/**
|
|
5
5
|
* A map of `fieldSource` -> `fieldName: fieldValue`. Because there may be field name conflicts between the base model and enrichments, the base model fields are placed in a map under the model ID. Fields from enrichments are placed under the enricher ID.
|
|
6
6
|
*/
|
|
7
|
-
export type V2SampleRecord = Record<string, Record<string, unknown>>;
|
|
7
|
+
export declare type V2SampleRecord = Record<string, Record<string, unknown>>;
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
4
|
import * as Polytomic from "../index";
|
|
5
|
-
export type V2SchemaConfigurationFieldsItem = string | Polytomic.FieldConfiguration;
|
|
5
|
+
export declare type V2SchemaConfigurationFieldsItem = string | Polytomic.FieldConfiguration;
|
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
-
export
|
|
4
|
+
export interface V4BulkSyncExecutionLogs {
|
|
5
|
+
/** Timestamp at which the signed URLs in URLs stop working. */
|
|
6
|
+
Expires?: string;
|
|
7
|
+
/** Signed URLs that download the execution's log files. These URLs expire at the Expires timestamp. */
|
|
8
|
+
URLs?: string[];
|
|
9
|
+
}
|
|
@@ -3,11 +3,16 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as Polytomic from "../index";
|
|
5
5
|
export interface V4BulkSyncScheduleApi {
|
|
6
|
+
/** Day of the month (1-31) for monthly schedules. */
|
|
6
7
|
dayOfMonth?: string;
|
|
8
|
+
/** Day of the week for weekly schedules. */
|
|
7
9
|
dayOfWeek?: string;
|
|
8
10
|
frequency: Polytomic.ScheduleFrequency;
|
|
11
|
+
/** Hour of the day (0-23, in UTC) the schedule fires. */
|
|
9
12
|
hour?: string;
|
|
13
|
+
/** Minute of the hour (0-59) the schedule fires. */
|
|
10
14
|
minute?: string;
|
|
15
|
+
/** Month of the year (1-12) for yearly schedules. */
|
|
11
16
|
month?: string;
|
|
12
17
|
selectiveMode?: Polytomic.BulkSelectiveMode;
|
|
13
18
|
}
|
|
@@ -5,12 +5,13 @@ import * as Polytomic from "../index";
|
|
|
5
5
|
export interface V4RunQueryResult {
|
|
6
6
|
/** The number of rows returned by the query. This will not be returned until the query completes. */
|
|
7
7
|
count?: number;
|
|
8
|
+
/** Error message if the query failed. */
|
|
8
9
|
error?: string;
|
|
9
10
|
/** The time at which the query will expire and be deleted. This will not be returned until the query completes. */
|
|
10
11
|
expires?: string;
|
|
11
12
|
/** The names of the fields returned by the query. This will not be returned until the query completes. */
|
|
12
13
|
fields?: string[];
|
|
13
|
-
/** The ID of the query task. */
|
|
14
|
+
/** The ID of the query task. Poll GET /api/queries/{id} until the task reaches done or failed to retrieve results. */
|
|
14
15
|
id?: string;
|
|
15
16
|
/** The query results, returned as an array of objects. */
|
|
16
17
|
results?: Record<string, unknown>[];
|
|
@@ -3,8 +3,12 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export interface V4UserFieldRequest {
|
|
5
5
|
example?: unknown;
|
|
6
|
+
/** Stable identifier for the user-defined field. Reuse an existing field_id to update a field in place. */
|
|
6
7
|
field_id: string;
|
|
8
|
+
/** Human-readable label shown to users selecting this field in the app. */
|
|
7
9
|
label: string;
|
|
10
|
+
/** JSON path expression that extracts the field's value from the source record. Required for nested or computed fields; omit for top-level fields. */
|
|
8
11
|
path?: string;
|
|
12
|
+
/** Polytomic type of the field (e.g. string, integer, boolean). */
|
|
9
13
|
type: string;
|
|
10
14
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
|
-
export type WorkTaskStatus = "created" | "running" | "done" | "failed";
|
|
4
|
+
export declare type WorkTaskStatus = "created" | "running" | "done" | "failed";
|
|
5
5
|
export declare const WorkTaskStatus: {
|
|
6
6
|
readonly Created: "created";
|
|
7
7
|
readonly Running: "running";
|
|
@@ -4,15 +4,18 @@ export * from "./BackendOAuthPrompt";
|
|
|
4
4
|
export * from "./BulkBulkSyncSchedule";
|
|
5
5
|
export * from "./BulkDiscover";
|
|
6
6
|
export * from "./BulkExecutionStatus";
|
|
7
|
+
export * from "./BulkFilter";
|
|
7
8
|
export * from "./BulkItemizedSchedule";
|
|
8
9
|
export * from "./BulkMultiScheduleConfiguration";
|
|
9
10
|
export * from "./BulkNormalizeNames";
|
|
11
|
+
export * from "./BulkOutputDisposition";
|
|
12
|
+
export * from "./BulkResyncMode";
|
|
10
13
|
export * from "./BulkSchedule";
|
|
11
14
|
export * from "./BulkScheduleSyncMode";
|
|
12
15
|
export * from "./BulkSchemaExecutionStatus";
|
|
13
16
|
export * from "./BulkSelectiveMode";
|
|
14
17
|
export * from "./BulkSyncMode";
|
|
15
|
-
export * from "./
|
|
18
|
+
export * from "./ConfigurationValue";
|
|
16
19
|
export * from "./BulkSyncCanceledEvent";
|
|
17
20
|
export * from "./BulkSyncCompletedEvent";
|
|
18
21
|
export * from "./BulkSyncCompletedWithErrorEvent";
|
|
@@ -33,7 +36,11 @@ export * from "./ModelModelFieldRequest";
|
|
|
33
36
|
export * from "./ModelRelation";
|
|
34
37
|
export * from "./ModelRelationTo";
|
|
35
38
|
export * from "./ModelSyncMode";
|
|
39
|
+
export * from "./OutputActor";
|
|
40
|
+
export * from "./PaginationDetails";
|
|
36
41
|
export * from "./RestErrResponse";
|
|
42
|
+
export * from "./RunAfter";
|
|
43
|
+
export * from "./Schedule";
|
|
37
44
|
export * from "./ScheduleFrequency";
|
|
38
45
|
export * from "./ScheduleScheduleOption";
|
|
39
46
|
export * from "./SchemaAssociation";
|
|
@@ -50,7 +57,6 @@ export * from "./ApiKeyResponseEnvelope";
|
|
|
50
57
|
export * from "./ActivateSyncEnvelope";
|
|
51
58
|
export * from "./ActivateSyncInput";
|
|
52
59
|
export * from "./ActivateSyncOutput";
|
|
53
|
-
export * from "./BulkFilter";
|
|
54
60
|
export * from "./BulkSyncDest";
|
|
55
61
|
export * from "./BulkSyncDestEnvelope";
|
|
56
62
|
export * from "./BulkSyncListEnvelope";
|
|
@@ -60,7 +66,6 @@ export * from "./CancelBulkSyncResponse";
|
|
|
60
66
|
export * from "./CancelBulkSyncResponseEnvelope";
|
|
61
67
|
export * from "./CancelModelSyncResponse";
|
|
62
68
|
export * from "./CancelModelSyncResponseEnvelope";
|
|
63
|
-
export * from "./ConfigurationValue";
|
|
64
69
|
export * from "./V2ConnectionForm";
|
|
65
70
|
export * from "./ConnectionListResponseEnvelope";
|
|
66
71
|
export * from "./ConnectionMeta";
|
|
@@ -76,6 +81,8 @@ export * from "./ConnectionTypeSchema";
|
|
|
76
81
|
export * from "./CreateConnectionResponseEnvelope";
|
|
77
82
|
export * from "./CreateConnectionResponseSchema";
|
|
78
83
|
export * from "./CreateModelRequest";
|
|
84
|
+
export * from "./V2CreateSharedConnectionResponseEnvelope";
|
|
85
|
+
export * from "./CreateSharedConnectionResponseSchema";
|
|
79
86
|
export * from "./V2EnricherConfiguration";
|
|
80
87
|
export * from "./V2EnricherMapping";
|
|
81
88
|
export * from "./Enrichment";
|
|
@@ -116,7 +123,6 @@ export * from "./Organization";
|
|
|
116
123
|
export * from "./OrganizationEnvelope";
|
|
117
124
|
export * from "./OrganizationsEnvelope";
|
|
118
125
|
export * from "./Override";
|
|
119
|
-
export * from "./PaginationDetails";
|
|
120
126
|
export * from "./PolicyAction";
|
|
121
127
|
export * from "./PolicyResponse";
|
|
122
128
|
export * from "./PolicyResponseEnvelope";
|
|
@@ -125,9 +131,7 @@ export * from "./RelationTo";
|
|
|
125
131
|
export * from "./RoleListResponseEnvelope";
|
|
126
132
|
export * from "./RoleResponse";
|
|
127
133
|
export * from "./RoleResponseEnvelope";
|
|
128
|
-
export * from "./RunAfter";
|
|
129
134
|
export * from "./V2SampleRecord";
|
|
130
|
-
export * from "./Schedule";
|
|
131
135
|
export * from "./ScheduleOptionResponse";
|
|
132
136
|
export * from "./ScheduleOptionResponseEnvelope";
|
|
133
137
|
export * from "./V2SchemaConfigurationFieldsItem";
|
|
@@ -156,8 +160,10 @@ export * from "./BulkSchema";
|
|
|
156
160
|
export * from "./BulkSchemaEnvelope";
|
|
157
161
|
export * from "./BulkSyncExecution";
|
|
158
162
|
export * from "./BulkSyncExecutionEnvelope";
|
|
163
|
+
export * from "./BulkSyncIngestionStatus";
|
|
159
164
|
export * from "./BulkSyncSchemaExecution";
|
|
160
165
|
export * from "./BulkSyncSource";
|
|
166
|
+
export * from "./V3BulkSyncSourceCapabilities";
|
|
161
167
|
export * from "./BulkSyncSourceEnvelope";
|
|
162
168
|
export * from "./BulkSyncSourceSchemaEnvelope";
|
|
163
169
|
export * from "./BulkSyncSourceStatus";
|
|
@@ -166,6 +172,7 @@ export * from "./BulkSyncStatusEnvelope";
|
|
|
166
172
|
export * from "./BulkSyncStatusResponse";
|
|
167
173
|
export * from "./ConnectCardResponse";
|
|
168
174
|
export * from "./ConnectCardResponseEnvelope";
|
|
175
|
+
export * from "./IngestionStatusLevel";
|
|
169
176
|
export * from "./ListBulkSchema";
|
|
170
177
|
export * from "./ListBulkSyncExecutionsEnvelope";
|
|
171
178
|
export * from "./PickValue";
|
package/dist/api/types/index.js
CHANGED
|
@@ -20,15 +20,18 @@ __exportStar(require("./BackendOAuthPrompt"), exports);
|
|
|
20
20
|
__exportStar(require("./BulkBulkSyncSchedule"), exports);
|
|
21
21
|
__exportStar(require("./BulkDiscover"), exports);
|
|
22
22
|
__exportStar(require("./BulkExecutionStatus"), exports);
|
|
23
|
+
__exportStar(require("./BulkFilter"), exports);
|
|
23
24
|
__exportStar(require("./BulkItemizedSchedule"), exports);
|
|
24
25
|
__exportStar(require("./BulkMultiScheduleConfiguration"), exports);
|
|
25
26
|
__exportStar(require("./BulkNormalizeNames"), exports);
|
|
27
|
+
__exportStar(require("./BulkOutputDisposition"), exports);
|
|
28
|
+
__exportStar(require("./BulkResyncMode"), exports);
|
|
26
29
|
__exportStar(require("./BulkSchedule"), exports);
|
|
27
30
|
__exportStar(require("./BulkScheduleSyncMode"), exports);
|
|
28
31
|
__exportStar(require("./BulkSchemaExecutionStatus"), exports);
|
|
29
32
|
__exportStar(require("./BulkSelectiveMode"), exports);
|
|
30
33
|
__exportStar(require("./BulkSyncMode"), exports);
|
|
31
|
-
__exportStar(require("./
|
|
34
|
+
__exportStar(require("./ConfigurationValue"), exports);
|
|
32
35
|
__exportStar(require("./BulkSyncCanceledEvent"), exports);
|
|
33
36
|
__exportStar(require("./BulkSyncCompletedEvent"), exports);
|
|
34
37
|
__exportStar(require("./BulkSyncCompletedWithErrorEvent"), exports);
|
|
@@ -49,7 +52,11 @@ __exportStar(require("./ModelModelFieldRequest"), exports);
|
|
|
49
52
|
__exportStar(require("./ModelRelation"), exports);
|
|
50
53
|
__exportStar(require("./ModelRelationTo"), exports);
|
|
51
54
|
__exportStar(require("./ModelSyncMode"), exports);
|
|
55
|
+
__exportStar(require("./OutputActor"), exports);
|
|
56
|
+
__exportStar(require("./PaginationDetails"), exports);
|
|
52
57
|
__exportStar(require("./RestErrResponse"), exports);
|
|
58
|
+
__exportStar(require("./RunAfter"), exports);
|
|
59
|
+
__exportStar(require("./Schedule"), exports);
|
|
53
60
|
__exportStar(require("./ScheduleFrequency"), exports);
|
|
54
61
|
__exportStar(require("./ScheduleScheduleOption"), exports);
|
|
55
62
|
__exportStar(require("./SchemaAssociation"), exports);
|
|
@@ -66,7 +73,6 @@ __exportStar(require("./ApiKeyResponseEnvelope"), exports);
|
|
|
66
73
|
__exportStar(require("./ActivateSyncEnvelope"), exports);
|
|
67
74
|
__exportStar(require("./ActivateSyncInput"), exports);
|
|
68
75
|
__exportStar(require("./ActivateSyncOutput"), exports);
|
|
69
|
-
__exportStar(require("./BulkFilter"), exports);
|
|
70
76
|
__exportStar(require("./BulkSyncDest"), exports);
|
|
71
77
|
__exportStar(require("./BulkSyncDestEnvelope"), exports);
|
|
72
78
|
__exportStar(require("./BulkSyncListEnvelope"), exports);
|
|
@@ -76,7 +82,6 @@ __exportStar(require("./CancelBulkSyncResponse"), exports);
|
|
|
76
82
|
__exportStar(require("./CancelBulkSyncResponseEnvelope"), exports);
|
|
77
83
|
__exportStar(require("./CancelModelSyncResponse"), exports);
|
|
78
84
|
__exportStar(require("./CancelModelSyncResponseEnvelope"), exports);
|
|
79
|
-
__exportStar(require("./ConfigurationValue"), exports);
|
|
80
85
|
__exportStar(require("./V2ConnectionForm"), exports);
|
|
81
86
|
__exportStar(require("./ConnectionListResponseEnvelope"), exports);
|
|
82
87
|
__exportStar(require("./ConnectionMeta"), exports);
|
|
@@ -92,6 +97,8 @@ __exportStar(require("./ConnectionTypeSchema"), exports);
|
|
|
92
97
|
__exportStar(require("./CreateConnectionResponseEnvelope"), exports);
|
|
93
98
|
__exportStar(require("./CreateConnectionResponseSchema"), exports);
|
|
94
99
|
__exportStar(require("./CreateModelRequest"), exports);
|
|
100
|
+
__exportStar(require("./V2CreateSharedConnectionResponseEnvelope"), exports);
|
|
101
|
+
__exportStar(require("./CreateSharedConnectionResponseSchema"), exports);
|
|
95
102
|
__exportStar(require("./V2EnricherConfiguration"), exports);
|
|
96
103
|
__exportStar(require("./V2EnricherMapping"), exports);
|
|
97
104
|
__exportStar(require("./Enrichment"), exports);
|
|
@@ -132,7 +139,6 @@ __exportStar(require("./Organization"), exports);
|
|
|
132
139
|
__exportStar(require("./OrganizationEnvelope"), exports);
|
|
133
140
|
__exportStar(require("./OrganizationsEnvelope"), exports);
|
|
134
141
|
__exportStar(require("./Override"), exports);
|
|
135
|
-
__exportStar(require("./PaginationDetails"), exports);
|
|
136
142
|
__exportStar(require("./PolicyAction"), exports);
|
|
137
143
|
__exportStar(require("./PolicyResponse"), exports);
|
|
138
144
|
__exportStar(require("./PolicyResponseEnvelope"), exports);
|
|
@@ -141,9 +147,7 @@ __exportStar(require("./RelationTo"), exports);
|
|
|
141
147
|
__exportStar(require("./RoleListResponseEnvelope"), exports);
|
|
142
148
|
__exportStar(require("./RoleResponse"), exports);
|
|
143
149
|
__exportStar(require("./RoleResponseEnvelope"), exports);
|
|
144
|
-
__exportStar(require("./RunAfter"), exports);
|
|
145
150
|
__exportStar(require("./V2SampleRecord"), exports);
|
|
146
|
-
__exportStar(require("./Schedule"), exports);
|
|
147
151
|
__exportStar(require("./ScheduleOptionResponse"), exports);
|
|
148
152
|
__exportStar(require("./ScheduleOptionResponseEnvelope"), exports);
|
|
149
153
|
__exportStar(require("./V2SchemaConfigurationFieldsItem"), exports);
|
|
@@ -172,8 +176,10 @@ __exportStar(require("./BulkSchema"), exports);
|
|
|
172
176
|
__exportStar(require("./BulkSchemaEnvelope"), exports);
|
|
173
177
|
__exportStar(require("./BulkSyncExecution"), exports);
|
|
174
178
|
__exportStar(require("./BulkSyncExecutionEnvelope"), exports);
|
|
179
|
+
__exportStar(require("./BulkSyncIngestionStatus"), exports);
|
|
175
180
|
__exportStar(require("./BulkSyncSchemaExecution"), exports);
|
|
176
181
|
__exportStar(require("./BulkSyncSource"), exports);
|
|
182
|
+
__exportStar(require("./V3BulkSyncSourceCapabilities"), exports);
|
|
177
183
|
__exportStar(require("./BulkSyncSourceEnvelope"), exports);
|
|
178
184
|
__exportStar(require("./BulkSyncSourceSchemaEnvelope"), exports);
|
|
179
185
|
__exportStar(require("./BulkSyncSourceStatus"), exports);
|
|
@@ -182,6 +188,7 @@ __exportStar(require("./BulkSyncStatusEnvelope"), exports);
|
|
|
182
188
|
__exportStar(require("./BulkSyncStatusResponse"), exports);
|
|
183
189
|
__exportStar(require("./ConnectCardResponse"), exports);
|
|
184
190
|
__exportStar(require("./ConnectCardResponseEnvelope"), exports);
|
|
191
|
+
__exportStar(require("./IngestionStatusLevel"), exports);
|
|
185
192
|
__exportStar(require("./ListBulkSchema"), exports);
|
|
186
193
|
__exportStar(require("./ListBulkSyncExecutionsEnvelope"), exports);
|
|
187
194
|
__exportStar(require("./PickValue"), exports);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type APIResponse<Success, Failure> = SuccessfulResponse<Success> | FailedResponse<Failure>;
|
|
1
|
+
export declare type APIResponse<Success, Failure> = SuccessfulResponse<Success> | FailedResponse<Failure>;
|
|
2
2
|
export interface SuccessfulResponse<T> {
|
|
3
3
|
ok: true;
|
|
4
4
|
body: T;
|
|
@@ -1,20 +1,18 @@
|
|
|
1
1
|
import { APIResponse } from "./APIResponse";
|
|
2
|
-
export type FetchFunction = <R = unknown>(args: Fetcher.Args) => Promise<APIResponse<R, Fetcher.Error>>;
|
|
2
|
+
export declare 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[]>;
|
|
10
10
|
body?: unknown;
|
|
11
11
|
timeoutMs?: number;
|
|
12
12
|
maxRetries?: number;
|
|
13
13
|
withCredentials?: boolean;
|
|
14
14
|
abortSignal?: AbortSignal;
|
|
15
|
-
|
|
16
|
-
responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer";
|
|
17
|
-
duplex?: "half";
|
|
15
|
+
responseType?: "json" | "blob" | "streaming" | "text";
|
|
18
16
|
}
|
|
19
17
|
type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError;
|
|
20
18
|
interface FailedStatusCodeError {
|
|
@@ -35,5 +33,4 @@ export declare namespace Fetcher {
|
|
|
35
33
|
errorMessage: string;
|
|
36
34
|
}
|
|
37
35
|
}
|
|
38
|
-
export declare function fetcherImpl<R = unknown>(args: Fetcher.Args): Promise<APIResponse<R, Fetcher.Error>>;
|
|
39
36
|
export declare const fetcher: FetchFunction;
|
|
@@ -1,4 +1,27 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
2
25
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
26
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
27
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -8,17 +31,18 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
31
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
32
|
});
|
|
10
33
|
};
|
|
34
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
35
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
36
|
+
};
|
|
11
37
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
38
|
exports.fetcher = void 0;
|
|
13
|
-
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
const
|
|
18
|
-
const getResponseBody_1 = require("./getResponseBody");
|
|
19
|
-
const makeRequest_1 = require("./makeRequest");
|
|
20
|
-
const requestWithRetries_1 = require("./requestWithRetries");
|
|
39
|
+
const qs_1 = __importDefault(require("qs"));
|
|
40
|
+
const runtime_1 = require("../runtime");
|
|
41
|
+
const INITIAL_RETRY_DELAY = 1;
|
|
42
|
+
const MAX_RETRY_DELAY = 60;
|
|
43
|
+
const DEFAULT_MAX_RETRIES = 2;
|
|
21
44
|
function fetcherImpl(args) {
|
|
45
|
+
var _a, _b;
|
|
22
46
|
return __awaiter(this, void 0, void 0, function* () {
|
|
23
47
|
const headers = {};
|
|
24
48
|
if (args.body !== undefined && args.contentType != null) {
|
|
@@ -31,21 +55,116 @@ function fetcherImpl(args) {
|
|
|
31
55
|
}
|
|
32
56
|
}
|
|
33
57
|
}
|
|
34
|
-
const url =
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
58
|
+
const url = Object.keys((_a = args.queryParameters) !== null && _a !== void 0 ? _a : {}).length > 0
|
|
59
|
+
? `${args.url}?${qs_1.default.stringify(args.queryParameters, { arrayFormat: "repeat" })}`
|
|
60
|
+
: args.url;
|
|
61
|
+
let body = undefined;
|
|
62
|
+
const maybeStringifyBody = (body) => {
|
|
63
|
+
if (body instanceof Uint8Array) {
|
|
64
|
+
return body;
|
|
65
|
+
}
|
|
66
|
+
else if (args.contentType === "application/x-www-form-urlencoded" && typeof args.body === "string") {
|
|
67
|
+
return args.body;
|
|
68
|
+
}
|
|
69
|
+
else {
|
|
70
|
+
return JSON.stringify(body);
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
if (runtime_1.RUNTIME.type === "node") {
|
|
74
|
+
if (args.body instanceof (yield Promise.resolve().then(() => __importStar(require("formdata-node")))).FormData) {
|
|
75
|
+
// @ts-expect-error
|
|
76
|
+
body = args.body;
|
|
77
|
+
}
|
|
78
|
+
else if (args.body instanceof (yield Promise.resolve().then(() => __importStar(require("stream")))).Readable) {
|
|
79
|
+
// @ts-expect-error
|
|
80
|
+
body = args.body;
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
body = maybeStringifyBody(args.body);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
else {
|
|
87
|
+
if (args.body instanceof (yield Promise.resolve().then(() => __importStar(require("form-data")))).default) {
|
|
88
|
+
// @ts-expect-error
|
|
89
|
+
body = args.body;
|
|
90
|
+
}
|
|
91
|
+
else {
|
|
92
|
+
body = maybeStringifyBody(args.body);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
const fetchFn = yield getFetchFn();
|
|
96
|
+
const makeRequest = () => __awaiter(this, void 0, void 0, function* () {
|
|
97
|
+
const signals = [];
|
|
98
|
+
// Add timeout signal
|
|
99
|
+
let timeoutAbortId = undefined;
|
|
100
|
+
if (args.timeoutMs != null) {
|
|
101
|
+
const { signal, abortId } = getTimeoutSignal(args.timeoutMs);
|
|
102
|
+
timeoutAbortId = abortId;
|
|
103
|
+
signals.push(signal);
|
|
104
|
+
}
|
|
105
|
+
// Add arbitrary signal
|
|
106
|
+
if (args.abortSignal != null) {
|
|
107
|
+
signals.push(args.abortSignal);
|
|
108
|
+
}
|
|
109
|
+
const response = yield fetchFn(url, {
|
|
110
|
+
method: args.method,
|
|
111
|
+
headers,
|
|
112
|
+
body,
|
|
113
|
+
signal: anySignal(signals),
|
|
114
|
+
credentials: args.withCredentials ? "include" : undefined,
|
|
115
|
+
});
|
|
116
|
+
if (timeoutAbortId != null) {
|
|
117
|
+
clearTimeout(timeoutAbortId);
|
|
118
|
+
}
|
|
119
|
+
return response;
|
|
38
120
|
});
|
|
39
|
-
const fetchFn = yield (0, getFetchFn_1.getFetchFn)();
|
|
40
121
|
try {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
122
|
+
let response = yield makeRequest();
|
|
123
|
+
for (let i = 0; i < ((_b = args.maxRetries) !== null && _b !== void 0 ? _b : DEFAULT_MAX_RETRIES); ++i) {
|
|
124
|
+
if (response.status === 408 ||
|
|
125
|
+
response.status === 409 ||
|
|
126
|
+
response.status === 429 ||
|
|
127
|
+
response.status >= 500) {
|
|
128
|
+
const delay = Math.min(INITIAL_RETRY_DELAY * Math.pow(i, 2), MAX_RETRY_DELAY);
|
|
129
|
+
yield new Promise((resolve) => setTimeout(resolve, delay));
|
|
130
|
+
response = yield makeRequest();
|
|
131
|
+
}
|
|
132
|
+
else {
|
|
133
|
+
break;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
let body;
|
|
137
|
+
if (response.body != null && args.responseType === "blob") {
|
|
138
|
+
body = yield response.blob();
|
|
139
|
+
}
|
|
140
|
+
else if (response.body != null && args.responseType === "streaming") {
|
|
141
|
+
body = response.body;
|
|
142
|
+
}
|
|
143
|
+
else if (response.body != null && args.responseType === "text") {
|
|
144
|
+
body = yield response.text();
|
|
145
|
+
}
|
|
146
|
+
else {
|
|
147
|
+
const text = yield response.text();
|
|
148
|
+
if (text.length > 0) {
|
|
149
|
+
try {
|
|
150
|
+
body = JSON.parse(text);
|
|
151
|
+
}
|
|
152
|
+
catch (err) {
|
|
153
|
+
return {
|
|
154
|
+
ok: false,
|
|
155
|
+
error: {
|
|
156
|
+
reason: "non-json",
|
|
157
|
+
statusCode: response.status,
|
|
158
|
+
rawBody: text,
|
|
159
|
+
},
|
|
160
|
+
};
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
}
|
|
45
164
|
if (response.status >= 200 && response.status < 400) {
|
|
46
165
|
return {
|
|
47
166
|
ok: true,
|
|
48
|
-
body:
|
|
167
|
+
body: body,
|
|
49
168
|
headers: response.headers,
|
|
50
169
|
};
|
|
51
170
|
}
|
|
@@ -55,7 +174,7 @@ function fetcherImpl(args) {
|
|
|
55
174
|
error: {
|
|
56
175
|
reason: "status-code",
|
|
57
176
|
statusCode: response.status,
|
|
58
|
-
body
|
|
177
|
+
body,
|
|
59
178
|
},
|
|
60
179
|
};
|
|
61
180
|
}
|
|
@@ -91,10 +210,60 @@ function fetcherImpl(args) {
|
|
|
91
210
|
ok: false,
|
|
92
211
|
error: {
|
|
93
212
|
reason: "unknown",
|
|
94
|
-
errorMessage:
|
|
213
|
+
errorMessage: JSON.stringify(error),
|
|
95
214
|
},
|
|
96
215
|
};
|
|
97
216
|
}
|
|
98
217
|
});
|
|
99
218
|
}
|
|
219
|
+
const TIMEOUT = "timeout";
|
|
220
|
+
function getTimeoutSignal(timeoutMs) {
|
|
221
|
+
const controller = new AbortController();
|
|
222
|
+
const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs);
|
|
223
|
+
return { signal: controller.signal, abortId };
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* Returns an abort signal that is getting aborted when
|
|
227
|
+
* at least one of the specified abort signals is aborted.
|
|
228
|
+
*
|
|
229
|
+
* Requires at least node.js 18.
|
|
230
|
+
*/
|
|
231
|
+
function anySignal(...args) {
|
|
232
|
+
// Allowing signals to be passed either as array
|
|
233
|
+
// of signals or as multiple arguments.
|
|
234
|
+
const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args);
|
|
235
|
+
const controller = new AbortController();
|
|
236
|
+
for (const signal of signals) {
|
|
237
|
+
if (signal.aborted) {
|
|
238
|
+
// Exiting early if one of the signals
|
|
239
|
+
// is already aborted.
|
|
240
|
+
controller.abort(signal === null || signal === void 0 ? void 0 : signal.reason);
|
|
241
|
+
break;
|
|
242
|
+
}
|
|
243
|
+
// Listening for signals and removing the listeners
|
|
244
|
+
// when at least one symbol is aborted.
|
|
245
|
+
signal.addEventListener("abort", () => controller.abort(signal === null || signal === void 0 ? void 0 : signal.reason), {
|
|
246
|
+
signal: controller.signal,
|
|
247
|
+
});
|
|
248
|
+
}
|
|
249
|
+
return controller.signal;
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* Returns a fetch function based on the runtime
|
|
253
|
+
*/
|
|
254
|
+
function getFetchFn() {
|
|
255
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
256
|
+
// In Node.js environments, the SDK always uses`node-fetch`.
|
|
257
|
+
if (runtime_1.RUNTIME.type === "node") {
|
|
258
|
+
return (yield Promise.resolve().then(() => __importStar(require("node-fetch")))).default;
|
|
259
|
+
}
|
|
260
|
+
// Otherwise the SDK uses global fetch if available,
|
|
261
|
+
// and falls back to node-fetch.
|
|
262
|
+
if (typeof fetch == "function") {
|
|
263
|
+
return fetch;
|
|
264
|
+
}
|
|
265
|
+
// Defaults to node `node-fetch` if global fetch isn't available
|
|
266
|
+
return (yield Promise.resolve().then(() => __importStar(require("node-fetch")))).default;
|
|
267
|
+
});
|
|
268
|
+
}
|
|
100
269
|
exports.fetcher = fetcherImpl;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getHeader =
|
|
3
|
+
exports.getHeader = void 0;
|
|
4
4
|
function getHeader(headers, header) {
|
|
5
5
|
for (const [headerKey, headerValue] of Object.entries(headers)) {
|
|
6
6
|
if (headerKey.toLowerCase() === header.toLowerCase()) {
|
|
@@ -9,3 +9,4 @@ function getHeader(headers, header) {
|
|
|
9
9
|
}
|
|
10
10
|
return undefined;
|
|
11
11
|
}
|
|
12
|
+
exports.getHeader = getHeader;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export declare const RUNTIME: Runtime;
|
|
5
5
|
export interface Runtime {
|
|
6
|
-
type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd"
|
|
6
|
+
type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd";
|
|
7
7
|
version?: string;
|
|
8
|
-
parsedVersion?: number;
|
|
9
8
|
}
|