polytomic 1.5.0 → 1.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Client.d.ts +10 -0
- package/Client.js +25 -20
- package/api/errors/BadRequestError.d.ts +2 -2
- package/api/errors/BadRequestError.js +1 -1
- package/api/errors/ForbiddenError.d.ts +2 -2
- package/api/errors/ForbiddenError.js +1 -1
- package/api/errors/InternalServerError.d.ts +2 -2
- package/api/errors/InternalServerError.js +1 -1
- package/api/errors/NotFoundError.d.ts +2 -2
- package/api/errors/NotFoundError.js +1 -1
- package/api/errors/UnauthorizedError.d.ts +2 -2
- package/api/errors/UnauthorizedError.js +1 -1
- package/api/errors/UnprocessableEntityError.d.ts +2 -2
- package/api/errors/UnprocessableEntityError.js +1 -1
- package/api/errors/index.d.ts +1 -1
- package/api/errors/index.js +1 -1
- package/api/resources/bulkSync/client/Client.d.ts +55 -13
- package/api/resources/bulkSync/client/Client.js +109 -42
- package/api/resources/bulkSync/client/requests/CreateBulkSyncRequest.d.ts +2 -4
- package/api/resources/bulkSync/client/requests/UpdateBulkSyncRequest.d.ts +2 -4
- package/api/resources/bulkSync/client/requests/index.d.ts +6 -6
- package/api/resources/bulkSync/resources/executions/client/Client.d.ts +31 -3
- package/api/resources/bulkSync/resources/executions/client/Client.js +106 -10
- package/api/resources/bulkSync/resources/executions/client/index.d.ts +1 -1
- package/api/resources/bulkSync/resources/executions/client/index.js +15 -0
- package/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListStatusRequest.d.ts +24 -0
- package/api/resources/bulkSync/resources/executions/client/requests/index.d.ts +1 -0
- package/api/resources/bulkSync/resources/executions/client/requests/index.js +2 -0
- package/api/resources/bulkSync/resources/index.d.ts +1 -0
- package/api/resources/bulkSync/resources/index.js +1 -0
- package/api/resources/bulkSync/resources/schemas/client/Client.d.ts +30 -5
- package/api/resources/bulkSync/resources/schemas/client/Client.js +51 -19
- package/api/resources/bulkSync/resources/schemas/client/requests/BulkSyncSchemasRequest.d.ts +1 -1
- package/api/resources/bulkSync/resources/schemas/client/requests/SchemasListRequest.d.ts +1 -1
- package/api/resources/bulkSync/resources/schemas/client/requests/UpdateBulkSchema.d.ts +2 -1
- package/api/resources/bulkSync/resources/schemas/client/requests/index.d.ts +3 -3
- package/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItem.d.ts +1 -1
- package/api/resources/bulkSync/types/index.d.ts +0 -4
- package/api/resources/bulkSync/types/index.js +0 -4
- package/api/resources/connections/client/Client.d.ts +40 -9
- package/api/resources/connections/client/Client.js +78 -30
- package/api/resources/connections/client/requests/index.d.ts +4 -4
- package/api/resources/events/client/Client.d.ts +15 -3
- package/api/resources/events/client/Client.js +19 -8
- package/api/resources/events/client/requests/index.d.ts +1 -1
- package/api/resources/identity/client/Client.d.ts +11 -2
- package/api/resources/identity/client/Client.js +10 -5
- package/api/resources/index.d.ts +2 -0
- package/api/resources/index.js +3 -1
- package/api/resources/jobs/client/Client.d.ts +13 -2
- package/api/resources/jobs/client/Client.js +13 -6
- package/api/resources/modelSync/client/Client.d.ts +79 -22
- package/api/resources/modelSync/client/Client.js +207 -60
- package/api/resources/modelSync/client/requests/CreateModelSyncRequest.d.ts +4 -7
- package/api/resources/modelSync/client/requests/ModelSyncGetSourceRequest.d.ts +1 -1
- package/api/resources/modelSync/client/requests/UpdateModelSyncRequest.d.ts +4 -7
- package/api/resources/modelSync/client/requests/index.d.ts +6 -6
- package/api/resources/modelSync/resources/executions/client/Client.d.ts +30 -5
- package/api/resources/modelSync/resources/executions/client/Client.js +48 -18
- package/api/resources/models/client/Client.d.ts +46 -9
- package/api/resources/models/client/Client.js +85 -31
- package/api/resources/models/client/requests/GetEnrichmentInputFieldsRequest.d.ts +1 -1
- package/api/resources/models/client/requests/ModelsCreateRequest.d.ts +1 -1
- package/api/resources/models/client/requests/ModelsPreviewRequest.d.ts +1 -1
- package/api/resources/models/client/requests/UpdateModelRequest.d.ts +1 -1
- package/api/resources/models/client/requests/index.d.ts +7 -7
- package/api/resources/organization/client/Client.d.ts +33 -6
- package/api/resources/organization/client/Client.js +55 -20
- package/api/resources/organization/client/requests/index.d.ts +2 -2
- package/api/resources/permissions/client/Client.d.ts +7 -0
- package/api/resources/permissions/resources/policies/client/Client.d.ts +28 -6
- package/api/resources/permissions/resources/policies/client/Client.js +50 -20
- package/api/resources/permissions/resources/policies/client/requests/CreatePolicyRequest.d.ts +1 -1
- package/api/resources/permissions/resources/policies/client/requests/UpdatePolicyRequest.d.ts +1 -1
- package/api/resources/permissions/resources/policies/client/requests/index.d.ts +2 -2
- package/api/resources/permissions/resources/roles/client/Client.d.ts +28 -6
- package/api/resources/permissions/resources/roles/client/Client.js +50 -20
- package/api/resources/permissions/resources/roles/client/requests/index.d.ts +2 -2
- package/api/resources/queryRunner/client/Client.d.ts +58 -0
- package/api/resources/queryRunner/client/Client.js +223 -0
- package/api/resources/queryRunner/client/index.d.ts +1 -0
- package/api/resources/queryRunner/client/index.js +17 -0
- package/api/resources/queryRunner/client/requests/QueryRunnerGetQueryRequest.d.ts +10 -0
- package/api/resources/queryRunner/client/requests/V4RunQueryRequest.d.ts +15 -0
- package/api/resources/queryRunner/client/requests/index.d.ts +2 -0
- package/api/resources/queryRunner/client/requests/index.js +2 -0
- package/api/resources/queryRunner/index.d.ts +1 -0
- package/api/resources/queryRunner/index.js +17 -0
- package/api/resources/schemas/client/Client.d.ts +26 -5
- package/api/resources/schemas/client/Client.js +44 -18
- package/api/resources/users/client/Client.d.ts +45 -7
- package/api/resources/users/client/Client.js +75 -26
- package/api/resources/users/client/requests/index.d.ts +3 -3
- package/api/resources/webhooks/client/Client.d.ts +32 -6
- package/api/resources/webhooks/client/Client.js +54 -20
- package/api/resources/webhooks/client/requests/index.d.ts +2 -2
- package/api/types/ActivateSyncEnvelope.d.ts +1 -1
- package/api/types/ApiKeyResponseEnvelope.d.ts +1 -1
- package/api/types/BulkFilter.d.ts +10 -0
- package/api/types/BulkItemizedSchedule.d.ts +1 -1
- package/api/types/BulkMultiScheduleConfiguration.d.ts +2 -2
- package/api/types/BulkSchedule.d.ts +1 -1
- package/api/types/BulkSchema.d.ts +2 -1
- package/api/types/BulkSchemaEnvelope.d.ts +1 -1
- package/api/types/BulkSyncCanceledEvent.d.ts +11 -0
- package/api/types/BulkSyncCompletedEvent.d.ts +12 -0
- package/api/types/BulkSyncCompletedWithErrorEvent.d.ts +12 -0
- package/api/types/BulkSyncDest.d.ts +2 -2
- package/api/types/BulkSyncDestEnvelope.d.ts +1 -1
- package/api/types/BulkSyncExecution.d.ts +1 -1
- package/api/types/BulkSyncExecutionEnvelope.d.ts +1 -1
- package/api/types/BulkSyncExecutionStatus.d.ts +10 -0
- package/api/types/BulkSyncFailedEvent.d.ts +12 -0
- package/api/types/BulkSyncFailedEvent.js +5 -0
- package/api/types/BulkSyncListEnvelope.d.ts +1 -1
- package/api/types/BulkSyncResponse.d.ts +5 -1
- package/api/types/BulkSyncResponseEnvelope.d.ts +1 -1
- package/api/types/BulkSyncRunningEvent.d.ts +11 -0
- package/api/types/BulkSyncRunningEvent.js +5 -0
- package/api/types/BulkSyncSchemaExecution.d.ts +1 -1
- package/api/types/BulkSyncSchemaExecutionStatus.d.ts +15 -0
- package/api/types/BulkSyncSchemaExecutionStatus.js +5 -0
- package/api/types/BulkSyncSource.d.ts +1 -1
- package/api/types/BulkSyncSourceEnvelope.d.ts +1 -1
- package/api/types/BulkSyncSourceSchemaEnvelope.d.ts +1 -1
- package/api/types/BulkSyncSourceStatusEnvelope.d.ts +1 -1
- package/api/types/BulkSyncStatusEnvelope.d.ts +1 -1
- package/api/types/BulkSyncStatusResponse.d.ts +1 -1
- package/api/types/ConnectCardResponseEnvelope.d.ts +1 -1
- package/api/types/ConnectionListResponseEnvelope.d.ts +1 -1
- package/api/types/ConnectionMetaResponse.d.ts +1 -1
- package/api/types/ConnectionParameterValuesResp.d.ts +1 -1
- package/api/types/ConnectionParameterValuesResponseEnvelope.d.ts +1 -1
- package/api/types/ConnectionResponseEnvelope.d.ts +1 -1
- package/api/types/ConnectionResponseSchema.d.ts +1 -1
- package/api/types/ConnectionTypeResponseEnvelope.d.ts +1 -1
- package/api/types/CreateConnectionResponseEnvelope.d.ts +1 -1
- package/api/types/CreateConnectionResponseSchema.d.ts +1 -1
- package/api/types/CreateModelRequest.d.ts +1 -1
- package/api/types/Enrichment.d.ts +1 -1
- package/api/types/Event.d.ts +2 -1
- package/api/types/EventBody.d.ts +5 -0
- package/api/types/EventBody.js +5 -0
- package/api/types/EventsEnvelope.d.ts +1 -1
- package/api/types/ExecutionLogsResponseEnvelope.d.ts +1 -1
- package/api/types/FieldConfiguration.js +5 -0
- package/api/types/Filter.d.ts +1 -1
- package/api/types/GetConnectionMetaEnvelope.d.ts +1 -1
- package/api/types/GetExecutionResponseEnvelope.d.ts +1 -1
- package/api/types/GetExecutionResponseSchema.d.ts +1 -1
- package/api/types/GetIdentityResponseEnvelope.d.ts +1 -1
- package/api/types/GetModelSyncSourceMetaEnvelope.d.ts +1 -1
- package/api/types/Identity.d.ts +1 -1
- package/api/types/JobResponse.d.ts +1 -1
- package/api/types/JobResponseEnvelope.d.ts +1 -1
- package/api/types/ListBulkSchema.d.ts +1 -1
- package/api/types/ListBulkSyncExecutionStatusEnvelope.d.ts +7 -0
- package/api/types/ListBulkSyncExecutionStatusEnvelope.js +5 -0
- package/api/types/ListBulkSyncExecutionsEnvelope.d.ts +1 -1
- package/api/types/ListExecutionResponseEnvelope.d.ts +1 -1
- package/api/types/ListModelSyncResponseEnvelope.d.ts +1 -1
- package/api/types/ListPoliciesResponseEnvelope.d.ts +1 -1
- package/api/types/ListUsersEnvelope.d.ts +1 -1
- package/api/types/ModelFieldResponse.d.ts +1 -1
- package/api/types/ModelListResponseEnvelope.d.ts +1 -1
- package/api/types/ModelRelation.d.ts +1 -1
- package/api/types/ModelResponse.d.ts +1 -1
- package/api/types/ModelResponseEnvelope.d.ts +1 -1
- package/api/types/ModelSample.d.ts +1 -1
- package/api/types/ModelSampleResponseEnvelope.d.ts +1 -1
- package/api/types/ModelSyncField.d.ts +6 -2
- package/api/types/ModelSyncResponse.d.ts +1 -1
- package/api/types/ModelSyncResponseEnvelope.d.ts +1 -1
- package/api/types/ModelSyncSourceMetaResponse.d.ts +1 -1
- package/api/types/OrganizationEnvelope.d.ts +1 -1
- package/api/types/OrganizationsEnvelope.d.ts +1 -1
- package/api/types/Override.d.ts +1 -1
- package/api/types/Pagination.d.ts +9 -0
- package/api/types/Pagination.js +5 -0
- package/api/types/PolicyResponse.d.ts +1 -1
- package/api/types/PolicyResponseEnvelope.d.ts +1 -1
- package/api/types/Relation.d.ts +1 -1
- package/api/types/RoleListResponseEnvelope.d.ts +1 -1
- package/api/types/RoleResponseEnvelope.d.ts +1 -1
- package/api/types/Schedule.d.ts +1 -1
- package/api/types/ScheduleOptionResponse.d.ts +1 -1
- package/api/types/ScheduleOptionResponseEnvelope.d.ts +1 -1
- package/api/types/ScheduleScheduleOption.d.ts +1 -1
- package/api/types/Schema.d.ts +1 -1
- package/api/{resources/bulkSync/types → types}/SchemaConfiguration.d.ts +3 -2
- package/api/types/SchemaConfiguration.js +5 -0
- package/api/types/SchemaField.d.ts +1 -1
- package/api/types/StartModelSyncResponseEnvelope.d.ts +1 -1
- package/api/types/StartModelSyncResponseSchema.d.ts +1 -1
- package/api/types/SupportedBulkMode.d.ts +12 -0
- package/api/types/SupportedBulkMode.js +5 -0
- package/api/types/SupportedMode.d.ts +6 -5
- package/api/types/SyncCanceledEvent.d.ts +12 -0
- package/api/types/SyncCanceledEvent.js +5 -0
- package/api/types/SyncCompletedEvent.d.ts +25 -0
- package/api/types/SyncCompletedEvent.js +5 -0
- package/api/types/SyncCompletedWithErrorsEvent.d.ts +13 -0
- package/api/types/SyncCompletedWithErrorsEvent.js +5 -0
- package/api/types/SyncDestinationProperties.d.ts +1 -0
- package/api/types/SyncFailedEvent.d.ts +11 -0
- package/api/types/SyncFailedEvent.js +5 -0
- package/api/types/SyncMode.d.ts +17 -0
- package/api/types/SyncMode.js +16 -0
- package/api/types/SyncRunningEvent.d.ts +10 -0
- package/api/types/SyncRunningEvent.js +5 -0
- package/api/types/SyncStatusEnvelope.d.ts +1 -1
- package/api/types/SyncStatusResponse.d.ts +1 -1
- package/api/types/TargetField.d.ts +1 -1
- package/api/types/TargetObject.d.ts +10 -0
- package/api/types/TargetObject.js +5 -0
- package/api/types/TargetResponse.d.ts +1 -1
- package/api/types/TargetResponseEnvelope.d.ts +1 -1
- package/api/types/UserEnvelope.d.ts +1 -1
- package/api/types/V2SchemaConfigurationFieldsItem.d.ts +5 -0
- package/api/types/V2SchemaConfigurationFieldsItem.js +5 -0
- package/api/types/V4QueryResultsEnvelope.d.ts +8 -0
- package/api/types/V4QueryResultsEnvelope.js +5 -0
- package/api/types/V4RunQueryEnvelope.d.ts +7 -0
- package/api/types/V4RunQueryEnvelope.js +5 -0
- package/api/types/V4RunQueryResult.d.ts +18 -0
- package/api/types/V4RunQueryResult.js +5 -0
- package/api/types/V4TargetObjectsResponseEnvelope.d.ts +7 -0
- package/api/types/V4TargetObjectsResponseEnvelope.js +5 -0
- package/api/types/WebhookEnvelope.d.ts +1 -1
- package/api/types/WebhookListEnvelope.d.ts +1 -1
- package/api/types/WorkTaskStatus.d.ts +2 -1
- package/api/types/WorkTaskStatus.js +1 -0
- package/api/types/index.d.ts +27 -1
- package/api/types/index.js +27 -1
- package/core/fetcher/Fetcher.d.ts +3 -2
- package/core/fetcher/Fetcher.js +130 -19
- package/core/runtime/runtime.d.ts +1 -1
- package/core/runtime/runtime.js +11 -1
- package/dist/Client.d.ts +10 -0
- package/dist/Client.js +25 -20
- package/dist/api/errors/BadRequestError.d.ts +2 -2
- package/dist/api/errors/BadRequestError.js +1 -1
- package/dist/api/errors/ForbiddenError.d.ts +2 -2
- package/dist/api/errors/ForbiddenError.js +1 -1
- package/dist/api/errors/InternalServerError.d.ts +2 -2
- package/dist/api/errors/InternalServerError.js +1 -1
- package/dist/api/errors/NotFoundError.d.ts +2 -2
- package/dist/api/errors/NotFoundError.js +1 -1
- package/dist/api/errors/UnauthorizedError.d.ts +2 -2
- package/dist/api/errors/UnauthorizedError.js +1 -1
- package/dist/api/errors/UnprocessableEntityError.d.ts +2 -2
- package/dist/api/errors/UnprocessableEntityError.js +1 -1
- package/dist/api/errors/index.d.ts +1 -1
- package/dist/api/errors/index.js +1 -1
- package/dist/api/resources/bulkSync/client/Client.d.ts +55 -13
- package/dist/api/resources/bulkSync/client/Client.js +109 -42
- package/dist/api/resources/bulkSync/client/requests/CreateBulkSyncRequest.d.ts +2 -4
- package/dist/api/resources/bulkSync/client/requests/UpdateBulkSyncRequest.d.ts +2 -4
- package/dist/api/resources/bulkSync/client/requests/index.d.ts +6 -6
- package/dist/api/resources/bulkSync/resources/executions/client/Client.d.ts +31 -3
- package/dist/api/resources/bulkSync/resources/executions/client/Client.js +106 -10
- package/dist/api/resources/bulkSync/resources/executions/client/index.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/executions/client/index.js +15 -0
- package/dist/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListStatusRequest.d.ts +24 -0
- package/dist/api/resources/bulkSync/resources/executions/client/requests/ExecutionsListStatusRequest.js +5 -0
- package/dist/api/resources/bulkSync/resources/executions/client/requests/index.d.ts +1 -0
- package/dist/api/resources/bulkSync/resources/executions/client/requests/index.js +2 -0
- package/dist/api/resources/bulkSync/resources/index.d.ts +1 -0
- package/dist/api/resources/bulkSync/resources/index.js +1 -0
- package/dist/api/resources/bulkSync/resources/schemas/client/Client.d.ts +30 -5
- package/dist/api/resources/bulkSync/resources/schemas/client/Client.js +51 -19
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/BulkSyncSchemasRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/SchemasListRequest.d.ts +1 -1
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/UpdateBulkSchema.d.ts +2 -1
- package/dist/api/resources/bulkSync/resources/schemas/client/requests/index.d.ts +3 -3
- 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/bulkSync/types/index.d.ts +0 -4
- package/dist/api/resources/bulkSync/types/index.js +0 -4
- package/dist/api/resources/connections/client/Client.d.ts +40 -9
- package/dist/api/resources/connections/client/Client.js +78 -30
- package/dist/api/resources/connections/client/requests/index.d.ts +4 -4
- package/dist/api/resources/events/client/Client.d.ts +15 -3
- package/dist/api/resources/events/client/Client.js +19 -8
- package/dist/api/resources/events/client/requests/index.d.ts +1 -1
- package/dist/api/resources/identity/client/Client.d.ts +11 -2
- package/dist/api/resources/identity/client/Client.js +10 -5
- package/dist/api/resources/index.d.ts +2 -0
- package/dist/api/resources/index.js +3 -1
- package/dist/api/resources/jobs/client/Client.d.ts +13 -2
- package/dist/api/resources/jobs/client/Client.js +13 -6
- package/dist/api/resources/modelSync/client/Client.d.ts +79 -22
- package/dist/api/resources/modelSync/client/Client.js +207 -60
- package/dist/api/resources/modelSync/client/requests/CreateModelSyncRequest.d.ts +4 -7
- package/dist/api/resources/modelSync/client/requests/ModelSyncGetSourceRequest.d.ts +1 -1
- package/dist/api/resources/modelSync/client/requests/UpdateModelSyncRequest.d.ts +4 -7
- package/dist/api/resources/modelSync/client/requests/index.d.ts +6 -6
- package/dist/api/resources/modelSync/resources/executions/client/Client.d.ts +30 -5
- package/dist/api/resources/modelSync/resources/executions/client/Client.js +48 -18
- package/dist/api/resources/models/client/Client.d.ts +46 -9
- package/dist/api/resources/models/client/Client.js +85 -31
- package/dist/api/resources/models/client/requests/GetEnrichmentInputFieldsRequest.d.ts +1 -1
- package/dist/api/resources/models/client/requests/ModelsCreateRequest.d.ts +1 -1
- package/dist/api/resources/models/client/requests/ModelsPreviewRequest.d.ts +1 -1
- package/dist/api/resources/models/client/requests/UpdateModelRequest.d.ts +1 -1
- package/dist/api/resources/models/client/requests/index.d.ts +7 -7
- package/dist/api/resources/organization/client/Client.d.ts +33 -6
- package/dist/api/resources/organization/client/Client.js +55 -20
- package/dist/api/resources/organization/client/requests/index.d.ts +2 -2
- package/dist/api/resources/permissions/client/Client.d.ts +7 -0
- package/dist/api/resources/permissions/resources/policies/client/Client.d.ts +28 -6
- package/dist/api/resources/permissions/resources/policies/client/Client.js +50 -20
- package/dist/api/resources/permissions/resources/policies/client/requests/CreatePolicyRequest.d.ts +1 -1
- package/dist/api/resources/permissions/resources/policies/client/requests/UpdatePolicyRequest.d.ts +1 -1
- package/dist/api/resources/permissions/resources/policies/client/requests/index.d.ts +2 -2
- package/dist/api/resources/permissions/resources/roles/client/Client.d.ts +28 -6
- package/dist/api/resources/permissions/resources/roles/client/Client.js +50 -20
- package/dist/api/resources/permissions/resources/roles/client/requests/index.d.ts +2 -2
- package/dist/api/resources/queryRunner/client/Client.d.ts +58 -0
- package/dist/api/resources/queryRunner/client/Client.js +223 -0
- package/dist/api/resources/queryRunner/client/index.d.ts +1 -0
- package/dist/api/resources/queryRunner/client/index.js +17 -0
- package/dist/api/resources/queryRunner/client/requests/QueryRunnerGetQueryRequest.d.ts +10 -0
- package/dist/api/resources/queryRunner/client/requests/QueryRunnerGetQueryRequest.js +5 -0
- package/dist/api/resources/queryRunner/client/requests/V4RunQueryRequest.d.ts +15 -0
- package/dist/api/resources/queryRunner/client/requests/V4RunQueryRequest.js +5 -0
- package/dist/api/resources/queryRunner/client/requests/index.d.ts +2 -0
- package/dist/api/resources/queryRunner/client/requests/index.js +2 -0
- package/dist/api/resources/queryRunner/index.d.ts +1 -0
- package/dist/api/resources/queryRunner/index.js +17 -0
- package/dist/api/resources/schemas/client/Client.d.ts +26 -5
- package/dist/api/resources/schemas/client/Client.js +44 -18
- package/dist/api/resources/users/client/Client.d.ts +45 -7
- package/dist/api/resources/users/client/Client.js +75 -26
- package/dist/api/resources/users/client/requests/index.d.ts +3 -3
- package/dist/api/resources/webhooks/client/Client.d.ts +32 -6
- package/dist/api/resources/webhooks/client/Client.js +54 -20
- package/dist/api/resources/webhooks/client/requests/index.d.ts +2 -2
- package/dist/api/types/ActivateSyncEnvelope.d.ts +1 -1
- package/dist/api/types/ApiKeyResponseEnvelope.d.ts +1 -1
- package/dist/api/types/BulkFilter.d.ts +10 -0
- package/dist/api/types/BulkFilter.js +5 -0
- package/dist/api/types/BulkItemizedSchedule.d.ts +1 -1
- package/dist/api/types/BulkMultiScheduleConfiguration.d.ts +2 -2
- package/dist/api/types/BulkSchedule.d.ts +1 -1
- package/dist/api/types/BulkSchema.d.ts +2 -1
- package/dist/api/types/BulkSchemaEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncCanceledEvent.d.ts +11 -0
- package/dist/api/types/BulkSyncCanceledEvent.js +5 -0
- package/dist/api/types/BulkSyncCompletedEvent.d.ts +12 -0
- package/dist/api/types/BulkSyncCompletedEvent.js +5 -0
- package/dist/api/types/BulkSyncCompletedWithErrorEvent.d.ts +12 -0
- package/dist/api/types/BulkSyncCompletedWithErrorEvent.js +5 -0
- package/dist/api/types/BulkSyncDest.d.ts +2 -2
- package/dist/api/types/BulkSyncDestEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncExecution.d.ts +1 -1
- package/dist/api/types/BulkSyncExecutionEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncExecutionStatus.d.ts +10 -0
- package/dist/api/types/BulkSyncExecutionStatus.js +5 -0
- package/dist/api/types/BulkSyncFailedEvent.d.ts +12 -0
- package/dist/api/types/BulkSyncFailedEvent.js +5 -0
- package/dist/api/types/BulkSyncListEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncResponse.d.ts +5 -1
- package/dist/api/types/BulkSyncResponseEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncRunningEvent.d.ts +11 -0
- package/dist/api/types/BulkSyncRunningEvent.js +5 -0
- package/dist/api/types/BulkSyncSchemaExecution.d.ts +1 -1
- package/dist/api/types/BulkSyncSchemaExecutionStatus.d.ts +15 -0
- package/dist/api/types/BulkSyncSchemaExecutionStatus.js +5 -0
- package/dist/api/types/BulkSyncSource.d.ts +1 -1
- package/dist/api/types/BulkSyncSourceEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncSourceSchemaEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncSourceStatusEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncStatusEnvelope.d.ts +1 -1
- package/dist/api/types/BulkSyncStatusResponse.d.ts +1 -1
- package/dist/api/types/ConnectCardResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ConnectionListResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ConnectionMetaResponse.d.ts +1 -1
- package/dist/api/types/ConnectionParameterValuesResp.d.ts +1 -1
- package/dist/api/types/ConnectionParameterValuesResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ConnectionResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ConnectionResponseSchema.d.ts +1 -1
- package/dist/api/types/ConnectionTypeResponseEnvelope.d.ts +1 -1
- package/dist/api/types/CreateConnectionResponseEnvelope.d.ts +1 -1
- package/dist/api/types/CreateConnectionResponseSchema.d.ts +1 -1
- package/dist/api/types/CreateModelRequest.d.ts +1 -1
- package/dist/api/types/Enrichment.d.ts +1 -1
- package/dist/api/types/Event.d.ts +2 -1
- package/dist/api/types/EventBody.d.ts +5 -0
- package/dist/api/types/EventBody.js +5 -0
- package/dist/api/types/EventsEnvelope.d.ts +1 -1
- package/dist/api/types/ExecutionLogsResponseEnvelope.d.ts +1 -1
- package/dist/api/types/FieldConfiguration.js +5 -0
- package/dist/api/types/Filter.d.ts +1 -1
- package/dist/api/types/GetConnectionMetaEnvelope.d.ts +1 -1
- package/dist/api/types/GetExecutionResponseEnvelope.d.ts +1 -1
- package/dist/api/types/GetExecutionResponseSchema.d.ts +1 -1
- package/dist/api/types/GetIdentityResponseEnvelope.d.ts +1 -1
- package/dist/api/types/GetModelSyncSourceMetaEnvelope.d.ts +1 -1
- package/dist/api/types/Identity.d.ts +1 -1
- package/dist/api/types/JobResponse.d.ts +1 -1
- package/dist/api/types/JobResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ListBulkSchema.d.ts +1 -1
- package/dist/api/types/ListBulkSyncExecutionStatusEnvelope.d.ts +7 -0
- package/dist/api/types/ListBulkSyncExecutionStatusEnvelope.js +5 -0
- package/dist/api/types/ListBulkSyncExecutionsEnvelope.d.ts +1 -1
- package/dist/api/types/ListExecutionResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ListModelSyncResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ListPoliciesResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ListUsersEnvelope.d.ts +1 -1
- package/dist/api/types/ModelFieldResponse.d.ts +1 -1
- package/dist/api/types/ModelListResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ModelRelation.d.ts +1 -1
- package/dist/api/types/ModelResponse.d.ts +1 -1
- package/dist/api/types/ModelResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ModelSample.d.ts +1 -1
- package/dist/api/types/ModelSampleResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ModelSyncField.d.ts +6 -2
- package/dist/api/types/ModelSyncResponse.d.ts +1 -1
- package/dist/api/types/ModelSyncResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ModelSyncSourceMetaResponse.d.ts +1 -1
- package/dist/api/types/OrganizationEnvelope.d.ts +1 -1
- package/dist/api/types/OrganizationsEnvelope.d.ts +1 -1
- package/dist/api/types/Override.d.ts +1 -1
- package/dist/api/types/Pagination.d.ts +9 -0
- package/dist/api/types/Pagination.js +5 -0
- package/dist/api/types/PolicyResponse.d.ts +1 -1
- package/dist/api/types/PolicyResponseEnvelope.d.ts +1 -1
- package/dist/api/types/Relation.d.ts +1 -1
- package/dist/api/types/RoleListResponseEnvelope.d.ts +1 -1
- package/dist/api/types/RoleResponseEnvelope.d.ts +1 -1
- package/dist/api/types/Schedule.d.ts +1 -1
- package/dist/api/types/ScheduleOptionResponse.d.ts +1 -1
- package/dist/api/types/ScheduleOptionResponseEnvelope.d.ts +1 -1
- package/dist/api/types/ScheduleScheduleOption.d.ts +1 -1
- package/dist/api/types/Schema.d.ts +1 -1
- package/dist/api/{resources/bulkSync/types → types}/SchemaConfiguration.d.ts +3 -2
- package/dist/api/types/SchemaConfiguration.js +5 -0
- package/dist/api/types/SchemaField.d.ts +1 -1
- package/dist/api/types/StartModelSyncResponseEnvelope.d.ts +1 -1
- package/dist/api/types/StartModelSyncResponseSchema.d.ts +1 -1
- package/dist/api/types/SupportedBulkMode.d.ts +12 -0
- package/dist/api/types/SupportedBulkMode.js +5 -0
- package/dist/api/types/SupportedMode.d.ts +6 -5
- package/dist/api/types/SyncCanceledEvent.d.ts +12 -0
- package/dist/api/types/SyncCanceledEvent.js +5 -0
- package/dist/api/types/SyncCompletedEvent.d.ts +25 -0
- package/dist/api/types/SyncCompletedEvent.js +5 -0
- package/dist/api/types/SyncCompletedWithErrorsEvent.d.ts +13 -0
- package/dist/api/types/SyncCompletedWithErrorsEvent.js +5 -0
- package/dist/api/types/SyncDestinationProperties.d.ts +1 -0
- package/dist/api/types/SyncFailedEvent.d.ts +11 -0
- package/dist/api/types/SyncFailedEvent.js +5 -0
- package/dist/api/types/SyncMode.d.ts +17 -0
- package/dist/api/types/SyncMode.js +16 -0
- package/dist/api/types/SyncRunningEvent.d.ts +10 -0
- package/dist/api/types/SyncRunningEvent.js +5 -0
- package/dist/api/types/SyncStatusEnvelope.d.ts +1 -1
- package/dist/api/types/SyncStatusResponse.d.ts +1 -1
- package/dist/api/types/TargetField.d.ts +1 -1
- package/dist/api/types/TargetObject.d.ts +10 -0
- package/dist/api/types/TargetObject.js +5 -0
- package/dist/api/types/TargetResponse.d.ts +1 -1
- package/dist/api/types/TargetResponseEnvelope.d.ts +1 -1
- package/dist/api/types/UserEnvelope.d.ts +1 -1
- package/dist/api/types/V2SchemaConfigurationFieldsItem.d.ts +5 -0
- package/dist/api/types/V2SchemaConfigurationFieldsItem.js +5 -0
- package/dist/api/types/V4QueryResultsEnvelope.d.ts +8 -0
- package/dist/api/types/V4QueryResultsEnvelope.js +5 -0
- package/dist/api/types/V4RunQueryEnvelope.d.ts +7 -0
- package/dist/api/types/V4RunQueryEnvelope.js +5 -0
- package/dist/api/types/V4RunQueryResult.d.ts +18 -0
- package/dist/api/types/V4RunQueryResult.js +5 -0
- package/dist/api/types/V4TargetObjectsResponseEnvelope.d.ts +7 -0
- package/dist/api/types/V4TargetObjectsResponseEnvelope.js +5 -0
- package/dist/api/types/WebhookEnvelope.d.ts +1 -1
- package/dist/api/types/WebhookListEnvelope.d.ts +1 -1
- package/dist/api/types/WorkTaskStatus.d.ts +2 -1
- package/dist/api/types/WorkTaskStatus.js +1 -0
- package/dist/api/types/index.d.ts +27 -1
- package/dist/api/types/index.js +27 -1
- package/dist/core/fetcher/Fetcher.d.ts +3 -2
- package/dist/core/fetcher/Fetcher.js +130 -19
- package/dist/core/runtime/runtime.d.ts +1 -1
- package/dist/core/runtime/runtime.js +11 -1
- package/jest.config.js +2 -2
- package/package.json +13 -6
- package/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItemEnabledFieldsItem.d.ts +0 -5
- package/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItemEnabledFieldsItem.d.ts +0 -5
- package/dist/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItemEnabledFieldsItem.d.ts +0 -5
- package/dist/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItemEnabledFieldsItem.d.ts +0 -5
- package/tests/client.test.ts +0 -11
- /package/api/resources/bulkSync/{types/FieldConfiguration.js → resources/executions/client/requests/ExecutionsListStatusRequest.js} +0 -0
- /package/api/resources/{bulkSync/types/SchemaConfiguration.js → queryRunner/client/requests/QueryRunnerGetQueryRequest.js} +0 -0
- /package/api/resources/{bulkSync/types/V2CreateBulkSyncRequestSchemasItemEnabledFieldsItem.js → queryRunner/client/requests/V4RunQueryRequest.js} +0 -0
- /package/api/{resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItemEnabledFieldsItem.js → types/BulkFilter.js} +0 -0
- /package/{dist/api/resources/bulkSync/types/FieldConfiguration.js → api/types/BulkSyncCanceledEvent.js} +0 -0
- /package/{dist/api/resources/bulkSync/types/SchemaConfiguration.js → api/types/BulkSyncCompletedEvent.js} +0 -0
- /package/{dist/api/resources/bulkSync/types/V2CreateBulkSyncRequestSchemasItemEnabledFieldsItem.js → api/types/BulkSyncCompletedWithErrorEvent.js} +0 -0
- /package/{dist/api/resources/bulkSync/types/V2UpdateBulkSyncRequestSchemasItemEnabledFieldsItem.js → api/types/BulkSyncExecutionStatus.js} +0 -0
- /package/api/{resources/bulkSync/types → types}/FieldConfiguration.d.ts +0 -0
- /package/dist/api/{resources/bulkSync/types → types}/FieldConfiguration.d.ts +0 -0
|
@@ -41,15 +41,19 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
41
41
|
exports.ModelSync = void 0;
|
|
42
42
|
const environments = __importStar(require("../../../../environments"));
|
|
43
43
|
const core = __importStar(require("../../../../core"));
|
|
44
|
-
const Polytomic = __importStar(require("
|
|
44
|
+
const Polytomic = __importStar(require("../../../index"));
|
|
45
45
|
const url_join_1 = __importDefault(require("url-join"));
|
|
46
|
-
const errors = __importStar(require("../../../../errors"));
|
|
46
|
+
const errors = __importStar(require("../../../../errors/index"));
|
|
47
47
|
const Client_1 = require("../resources/executions/client/Client");
|
|
48
48
|
class ModelSync {
|
|
49
49
|
constructor(_options) {
|
|
50
50
|
this._options = _options;
|
|
51
51
|
}
|
|
52
52
|
/**
|
|
53
|
+
* @param {string} id
|
|
54
|
+
* @param {Polytomic.ModelSyncGetSourceRequest} request
|
|
55
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
56
|
+
*
|
|
53
57
|
* @throws {@link Polytomic.BadRequestError}
|
|
54
58
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
55
59
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -57,7 +61,7 @@ class ModelSync {
|
|
|
57
61
|
* @throws {@link Polytomic.InternalServerError}
|
|
58
62
|
*
|
|
59
63
|
* @example
|
|
60
|
-
* await
|
|
64
|
+
* await client.modelSync.getSource("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
61
65
|
*/
|
|
62
66
|
getSource(id, request = {}, requestOptions) {
|
|
63
67
|
var _a;
|
|
@@ -65,17 +69,19 @@ class ModelSync {
|
|
|
65
69
|
const { params } = request;
|
|
66
70
|
const _queryParams = {};
|
|
67
71
|
if (params != null) {
|
|
68
|
-
_queryParams["params"] = params;
|
|
72
|
+
_queryParams["params"] = JSON.stringify(params);
|
|
69
73
|
}
|
|
70
74
|
const _response = yield core.fetcher({
|
|
71
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${id}/modelsync/source`),
|
|
75
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${encodeURIComponent(id)}/modelsync/source`),
|
|
72
76
|
method: "GET",
|
|
73
77
|
headers: {
|
|
74
78
|
Authorization: yield this._getAuthorizationHeader(),
|
|
75
|
-
"X-Polytomic-Version":
|
|
79
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
80
|
+
? yield core.Supplier.get(this._options.version)
|
|
81
|
+
: undefined,
|
|
76
82
|
"X-Fern-Language": "JavaScript",
|
|
77
83
|
"X-Fern-SDK-Name": "polytomic",
|
|
78
|
-
"X-Fern-SDK-Version": "1.
|
|
84
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
79
85
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
80
86
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
81
87
|
},
|
|
@@ -83,6 +89,7 @@ class ModelSync {
|
|
|
83
89
|
queryParameters: _queryParams,
|
|
84
90
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
85
91
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
92
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
86
93
|
});
|
|
87
94
|
if (_response.ok) {
|
|
88
95
|
return _response.body;
|
|
@@ -122,6 +129,9 @@ class ModelSync {
|
|
|
122
129
|
});
|
|
123
130
|
}
|
|
124
131
|
/**
|
|
132
|
+
* @param {string} id
|
|
133
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
134
|
+
*
|
|
125
135
|
* @throws {@link Polytomic.BadRequestError}
|
|
126
136
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
127
137
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -129,26 +139,29 @@ class ModelSync {
|
|
|
129
139
|
* @throws {@link Polytomic.InternalServerError}
|
|
130
140
|
*
|
|
131
141
|
* @example
|
|
132
|
-
* await
|
|
142
|
+
* await client.modelSync.getSourceFields("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
133
143
|
*/
|
|
134
144
|
getSourceFields(id, requestOptions) {
|
|
135
145
|
var _a;
|
|
136
146
|
return __awaiter(this, void 0, void 0, function* () {
|
|
137
147
|
const _response = yield core.fetcher({
|
|
138
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${id}/modelsync/source/fields`),
|
|
148
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${encodeURIComponent(id)}/modelsync/source/fields`),
|
|
139
149
|
method: "GET",
|
|
140
150
|
headers: {
|
|
141
151
|
Authorization: yield this._getAuthorizationHeader(),
|
|
142
|
-
"X-Polytomic-Version":
|
|
152
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
153
|
+
? yield core.Supplier.get(this._options.version)
|
|
154
|
+
: undefined,
|
|
143
155
|
"X-Fern-Language": "JavaScript",
|
|
144
156
|
"X-Fern-SDK-Name": "polytomic",
|
|
145
|
-
"X-Fern-SDK-Version": "1.
|
|
157
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
146
158
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
147
159
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
148
160
|
},
|
|
149
161
|
contentType: "application/json",
|
|
150
162
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
151
163
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
164
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
152
165
|
});
|
|
153
166
|
if (_response.ok) {
|
|
154
167
|
return _response.body;
|
|
@@ -188,6 +201,10 @@ class ModelSync {
|
|
|
188
201
|
});
|
|
189
202
|
}
|
|
190
203
|
/**
|
|
204
|
+
* @param {string} id
|
|
205
|
+
* @param {Polytomic.ModelSyncGetTargetRequest} request
|
|
206
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
207
|
+
*
|
|
191
208
|
* @throws {@link Polytomic.BadRequestError}
|
|
192
209
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
193
210
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -195,7 +212,7 @@ class ModelSync {
|
|
|
195
212
|
* @throws {@link Polytomic.InternalServerError}
|
|
196
213
|
*
|
|
197
214
|
* @example
|
|
198
|
-
* await
|
|
215
|
+
* await client.modelSync.getTarget("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
199
216
|
*/
|
|
200
217
|
getTarget(id, request = {}, requestOptions) {
|
|
201
218
|
var _a;
|
|
@@ -209,14 +226,16 @@ class ModelSync {
|
|
|
209
226
|
_queryParams["search"] = search;
|
|
210
227
|
}
|
|
211
228
|
const _response = yield core.fetcher({
|
|
212
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${id}/modelsync/target`),
|
|
229
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${encodeURIComponent(id)}/modelsync/target`),
|
|
213
230
|
method: "GET",
|
|
214
231
|
headers: {
|
|
215
232
|
Authorization: yield this._getAuthorizationHeader(),
|
|
216
|
-
"X-Polytomic-Version":
|
|
233
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
234
|
+
? yield core.Supplier.get(this._options.version)
|
|
235
|
+
: undefined,
|
|
217
236
|
"X-Fern-Language": "JavaScript",
|
|
218
237
|
"X-Fern-SDK-Name": "polytomic",
|
|
219
|
-
"X-Fern-SDK-Version": "1.
|
|
238
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
220
239
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
221
240
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
222
241
|
},
|
|
@@ -224,6 +243,7 @@ class ModelSync {
|
|
|
224
243
|
queryParameters: _queryParams,
|
|
225
244
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
226
245
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
246
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
227
247
|
});
|
|
228
248
|
if (_response.ok) {
|
|
229
249
|
return _response.body;
|
|
@@ -263,13 +283,17 @@ class ModelSync {
|
|
|
263
283
|
});
|
|
264
284
|
}
|
|
265
285
|
/**
|
|
286
|
+
* @param {string} id
|
|
287
|
+
* @param {Polytomic.ModelSyncGetTargetFieldsRequest} request
|
|
288
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
289
|
+
*
|
|
266
290
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
267
291
|
* @throws {@link Polytomic.ForbiddenError}
|
|
268
292
|
* @throws {@link Polytomic.NotFoundError}
|
|
269
293
|
* @throws {@link Polytomic.InternalServerError}
|
|
270
294
|
*
|
|
271
295
|
* @example
|
|
272
|
-
* await
|
|
296
|
+
* await client.modelSync.getTargetFields("248df4b7-aa70-47b8-a036-33ac447e668d", {
|
|
273
297
|
* target: "database.table",
|
|
274
298
|
* refresh: false
|
|
275
299
|
* })
|
|
@@ -284,14 +308,16 @@ class ModelSync {
|
|
|
284
308
|
_queryParams["refresh"] = refresh.toString();
|
|
285
309
|
}
|
|
286
310
|
const _response = yield core.fetcher({
|
|
287
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${id}/modelsync/target/fields`),
|
|
311
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${encodeURIComponent(id)}/modelsync/target/fields`),
|
|
288
312
|
method: "GET",
|
|
289
313
|
headers: {
|
|
290
314
|
Authorization: yield this._getAuthorizationHeader(),
|
|
291
|
-
"X-Polytomic-Version":
|
|
315
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
316
|
+
? yield core.Supplier.get(this._options.version)
|
|
317
|
+
: undefined,
|
|
292
318
|
"X-Fern-Language": "JavaScript",
|
|
293
319
|
"X-Fern-SDK-Name": "polytomic",
|
|
294
|
-
"X-Fern-SDK-Version": "1.
|
|
320
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
295
321
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
296
322
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
297
323
|
},
|
|
@@ -299,12 +325,85 @@ class ModelSync {
|
|
|
299
325
|
queryParameters: _queryParams,
|
|
300
326
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
301
327
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
328
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
329
|
+
});
|
|
330
|
+
if (_response.ok) {
|
|
331
|
+
return _response.body;
|
|
332
|
+
}
|
|
333
|
+
if (_response.error.reason === "status-code") {
|
|
334
|
+
switch (_response.error.statusCode) {
|
|
335
|
+
case 401:
|
|
336
|
+
throw new Polytomic.UnauthorizedError(_response.error.body);
|
|
337
|
+
case 403:
|
|
338
|
+
throw new Polytomic.ForbiddenError(_response.error.body);
|
|
339
|
+
case 404:
|
|
340
|
+
throw new Polytomic.NotFoundError(_response.error.body);
|
|
341
|
+
case 500:
|
|
342
|
+
throw new Polytomic.InternalServerError(_response.error.body);
|
|
343
|
+
default:
|
|
344
|
+
throw new errors.PolytomicError({
|
|
345
|
+
statusCode: _response.error.statusCode,
|
|
346
|
+
body: _response.error.body,
|
|
347
|
+
});
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
switch (_response.error.reason) {
|
|
351
|
+
case "non-json":
|
|
352
|
+
throw new errors.PolytomicError({
|
|
353
|
+
statusCode: _response.error.statusCode,
|
|
354
|
+
body: _response.error.rawBody,
|
|
355
|
+
});
|
|
356
|
+
case "timeout":
|
|
357
|
+
throw new errors.PolytomicTimeoutError();
|
|
358
|
+
case "unknown":
|
|
359
|
+
throw new errors.PolytomicError({
|
|
360
|
+
message: _response.error.errorMessage,
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
});
|
|
364
|
+
}
|
|
365
|
+
/**
|
|
366
|
+
* @param {string} id
|
|
367
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
368
|
+
*
|
|
369
|
+
* @throws {@link Polytomic.BadRequestError}
|
|
370
|
+
* @throws {@link Polytomic.UnauthorizedError}
|
|
371
|
+
* @throws {@link Polytomic.ForbiddenError}
|
|
372
|
+
* @throws {@link Polytomic.NotFoundError}
|
|
373
|
+
* @throws {@link Polytomic.InternalServerError}
|
|
374
|
+
*
|
|
375
|
+
* @example
|
|
376
|
+
* await client.modelSync.getTargetObjects("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
377
|
+
*/
|
|
378
|
+
getTargetObjects(id, requestOptions) {
|
|
379
|
+
var _a;
|
|
380
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
381
|
+
const _response = yield core.fetcher({
|
|
382
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/connections/${encodeURIComponent(id)}/modelsync/targetobjects`),
|
|
383
|
+
method: "GET",
|
|
384
|
+
headers: {
|
|
385
|
+
Authorization: yield this._getAuthorizationHeader(),
|
|
386
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
387
|
+
? yield core.Supplier.get(this._options.version)
|
|
388
|
+
: undefined,
|
|
389
|
+
"X-Fern-Language": "JavaScript",
|
|
390
|
+
"X-Fern-SDK-Name": "polytomic",
|
|
391
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
392
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
393
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
394
|
+
},
|
|
395
|
+
contentType: "application/json",
|
|
396
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
397
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
398
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
302
399
|
});
|
|
303
400
|
if (_response.ok) {
|
|
304
401
|
return _response.body;
|
|
305
402
|
}
|
|
306
403
|
if (_response.error.reason === "status-code") {
|
|
307
404
|
switch (_response.error.statusCode) {
|
|
405
|
+
case 400:
|
|
406
|
+
throw new Polytomic.BadRequestError(_response.error.body);
|
|
308
407
|
case 401:
|
|
309
408
|
throw new Polytomic.UnauthorizedError(_response.error.body);
|
|
310
409
|
case 403:
|
|
@@ -336,12 +435,14 @@ class ModelSync {
|
|
|
336
435
|
});
|
|
337
436
|
}
|
|
338
437
|
/**
|
|
438
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
439
|
+
*
|
|
339
440
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
340
441
|
* @throws {@link Polytomic.NotFoundError}
|
|
341
442
|
* @throws {@link Polytomic.InternalServerError}
|
|
342
443
|
*
|
|
343
444
|
* @example
|
|
344
|
-
* await
|
|
445
|
+
* await client.modelSync.list()
|
|
345
446
|
*/
|
|
346
447
|
list(requestOptions) {
|
|
347
448
|
var _a;
|
|
@@ -351,16 +452,19 @@ class ModelSync {
|
|
|
351
452
|
method: "GET",
|
|
352
453
|
headers: {
|
|
353
454
|
Authorization: yield this._getAuthorizationHeader(),
|
|
354
|
-
"X-Polytomic-Version":
|
|
455
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
456
|
+
? yield core.Supplier.get(this._options.version)
|
|
457
|
+
: undefined,
|
|
355
458
|
"X-Fern-Language": "JavaScript",
|
|
356
459
|
"X-Fern-SDK-Name": "polytomic",
|
|
357
|
-
"X-Fern-SDK-Version": "1.
|
|
460
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
358
461
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
359
462
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
360
463
|
},
|
|
361
464
|
contentType: "application/json",
|
|
362
465
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
363
466
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
467
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
364
468
|
});
|
|
365
469
|
if (_response.ok) {
|
|
366
470
|
return _response.body;
|
|
@@ -396,6 +500,9 @@ class ModelSync {
|
|
|
396
500
|
});
|
|
397
501
|
}
|
|
398
502
|
/**
|
|
503
|
+
* @param {Polytomic.CreateModelSyncRequest} request
|
|
504
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
505
|
+
*
|
|
399
506
|
* @throws {@link Polytomic.BadRequestError}
|
|
400
507
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
401
508
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -403,12 +510,8 @@ class ModelSync {
|
|
|
403
510
|
* @throws {@link Polytomic.InternalServerError}
|
|
404
511
|
*
|
|
405
512
|
* @example
|
|
406
|
-
* await
|
|
513
|
+
* await client.modelSync.create({
|
|
407
514
|
* fields: [{
|
|
408
|
-
* source: {
|
|
409
|
-
* field: "id",
|
|
410
|
-
* model_id: "248df4b7-aa70-47b8-a036-33ac447e668d"
|
|
411
|
-
* },
|
|
412
515
|
* target: "name"
|
|
413
516
|
* }],
|
|
414
517
|
* mode: "create",
|
|
@@ -428,10 +531,12 @@ class ModelSync {
|
|
|
428
531
|
method: "POST",
|
|
429
532
|
headers: {
|
|
430
533
|
Authorization: yield this._getAuthorizationHeader(),
|
|
431
|
-
"X-Polytomic-Version":
|
|
534
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
535
|
+
? yield core.Supplier.get(this._options.version)
|
|
536
|
+
: undefined,
|
|
432
537
|
"X-Fern-Language": "JavaScript",
|
|
433
538
|
"X-Fern-SDK-Name": "polytomic",
|
|
434
|
-
"X-Fern-SDK-Version": "1.
|
|
539
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
435
540
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
436
541
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
437
542
|
},
|
|
@@ -439,6 +544,7 @@ class ModelSync {
|
|
|
439
544
|
body: request,
|
|
440
545
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
441
546
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
547
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
442
548
|
});
|
|
443
549
|
if (_response.ok) {
|
|
444
550
|
return _response.body;
|
|
@@ -478,11 +584,13 @@ class ModelSync {
|
|
|
478
584
|
});
|
|
479
585
|
}
|
|
480
586
|
/**
|
|
587
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
588
|
+
*
|
|
481
589
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
482
590
|
* @throws {@link Polytomic.InternalServerError}
|
|
483
591
|
*
|
|
484
592
|
* @example
|
|
485
|
-
* await
|
|
593
|
+
* await client.modelSync.getScheduleOptions()
|
|
486
594
|
*/
|
|
487
595
|
getScheduleOptions(requestOptions) {
|
|
488
596
|
var _a;
|
|
@@ -492,16 +600,19 @@ class ModelSync {
|
|
|
492
600
|
method: "GET",
|
|
493
601
|
headers: {
|
|
494
602
|
Authorization: yield this._getAuthorizationHeader(),
|
|
495
|
-
"X-Polytomic-Version":
|
|
603
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
604
|
+
? yield core.Supplier.get(this._options.version)
|
|
605
|
+
: undefined,
|
|
496
606
|
"X-Fern-Language": "JavaScript",
|
|
497
607
|
"X-Fern-SDK-Name": "polytomic",
|
|
498
|
-
"X-Fern-SDK-Version": "1.
|
|
608
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
499
609
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
500
610
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
501
611
|
},
|
|
502
612
|
contentType: "application/json",
|
|
503
613
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
504
614
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
615
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
505
616
|
});
|
|
506
617
|
if (_response.ok) {
|
|
507
618
|
return _response.body;
|
|
@@ -535,31 +646,37 @@ class ModelSync {
|
|
|
535
646
|
});
|
|
536
647
|
}
|
|
537
648
|
/**
|
|
649
|
+
* @param {string} id
|
|
650
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
651
|
+
*
|
|
538
652
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
539
653
|
* @throws {@link Polytomic.NotFoundError}
|
|
540
654
|
* @throws {@link Polytomic.InternalServerError}
|
|
541
655
|
*
|
|
542
656
|
* @example
|
|
543
|
-
* await
|
|
657
|
+
* await client.modelSync.get("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
544
658
|
*/
|
|
545
659
|
get(id, requestOptions) {
|
|
546
660
|
var _a;
|
|
547
661
|
return __awaiter(this, void 0, void 0, function* () {
|
|
548
662
|
const _response = yield core.fetcher({
|
|
549
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}`),
|
|
663
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}`),
|
|
550
664
|
method: "GET",
|
|
551
665
|
headers: {
|
|
552
666
|
Authorization: yield this._getAuthorizationHeader(),
|
|
553
|
-
"X-Polytomic-Version":
|
|
667
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
668
|
+
? yield core.Supplier.get(this._options.version)
|
|
669
|
+
: undefined,
|
|
554
670
|
"X-Fern-Language": "JavaScript",
|
|
555
671
|
"X-Fern-SDK-Name": "polytomic",
|
|
556
|
-
"X-Fern-SDK-Version": "1.
|
|
672
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
557
673
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
558
674
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
559
675
|
},
|
|
560
676
|
contentType: "application/json",
|
|
561
677
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
562
678
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
679
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
563
680
|
});
|
|
564
681
|
if (_response.ok) {
|
|
565
682
|
return _response.body;
|
|
@@ -595,6 +712,10 @@ class ModelSync {
|
|
|
595
712
|
});
|
|
596
713
|
}
|
|
597
714
|
/**
|
|
715
|
+
* @param {string} id
|
|
716
|
+
* @param {Polytomic.UpdateModelSyncRequest} request
|
|
717
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
718
|
+
*
|
|
598
719
|
* @throws {@link Polytomic.BadRequestError}
|
|
599
720
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
600
721
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -603,12 +724,8 @@ class ModelSync {
|
|
|
603
724
|
* @throws {@link Polytomic.InternalServerError}
|
|
604
725
|
*
|
|
605
726
|
* @example
|
|
606
|
-
* await
|
|
727
|
+
* await client.modelSync.update("248df4b7-aa70-47b8-a036-33ac447e668d", {
|
|
607
728
|
* fields: [{
|
|
608
|
-
* source: {
|
|
609
|
-
* field: "id",
|
|
610
|
-
* model_id: "248df4b7-aa70-47b8-a036-33ac447e668d"
|
|
611
|
-
* },
|
|
612
729
|
* target: "name"
|
|
613
730
|
* }],
|
|
614
731
|
* mode: "create",
|
|
@@ -624,14 +741,16 @@ class ModelSync {
|
|
|
624
741
|
var _a;
|
|
625
742
|
return __awaiter(this, void 0, void 0, function* () {
|
|
626
743
|
const _response = yield core.fetcher({
|
|
627
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}`),
|
|
744
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}`),
|
|
628
745
|
method: "PUT",
|
|
629
746
|
headers: {
|
|
630
747
|
Authorization: yield this._getAuthorizationHeader(),
|
|
631
|
-
"X-Polytomic-Version":
|
|
748
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
749
|
+
? yield core.Supplier.get(this._options.version)
|
|
750
|
+
: undefined,
|
|
632
751
|
"X-Fern-Language": "JavaScript",
|
|
633
752
|
"X-Fern-SDK-Name": "polytomic",
|
|
634
|
-
"X-Fern-SDK-Version": "1.
|
|
753
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
635
754
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
636
755
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
637
756
|
},
|
|
@@ -639,6 +758,7 @@ class ModelSync {
|
|
|
639
758
|
body: request,
|
|
640
759
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
641
760
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
761
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
642
762
|
});
|
|
643
763
|
if (_response.ok) {
|
|
644
764
|
return _response.body;
|
|
@@ -680,32 +800,38 @@ class ModelSync {
|
|
|
680
800
|
});
|
|
681
801
|
}
|
|
682
802
|
/**
|
|
803
|
+
* @param {string} id
|
|
804
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
805
|
+
*
|
|
683
806
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
684
807
|
* @throws {@link Polytomic.ForbiddenError}
|
|
685
808
|
* @throws {@link Polytomic.NotFoundError}
|
|
686
809
|
* @throws {@link Polytomic.InternalServerError}
|
|
687
810
|
*
|
|
688
811
|
* @example
|
|
689
|
-
* await
|
|
812
|
+
* await client.modelSync.remove("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
690
813
|
*/
|
|
691
814
|
remove(id, requestOptions) {
|
|
692
815
|
var _a;
|
|
693
816
|
return __awaiter(this, void 0, void 0, function* () {
|
|
694
817
|
const _response = yield core.fetcher({
|
|
695
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}`),
|
|
818
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}`),
|
|
696
819
|
method: "DELETE",
|
|
697
820
|
headers: {
|
|
698
821
|
Authorization: yield this._getAuthorizationHeader(),
|
|
699
|
-
"X-Polytomic-Version":
|
|
822
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
823
|
+
? yield core.Supplier.get(this._options.version)
|
|
824
|
+
: undefined,
|
|
700
825
|
"X-Fern-Language": "JavaScript",
|
|
701
826
|
"X-Fern-SDK-Name": "polytomic",
|
|
702
|
-
"X-Fern-SDK-Version": "1.
|
|
827
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
703
828
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
704
829
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
705
830
|
},
|
|
706
831
|
contentType: "application/json",
|
|
707
832
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
708
833
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
834
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
709
835
|
});
|
|
710
836
|
if (_response.ok) {
|
|
711
837
|
return;
|
|
@@ -743,13 +869,17 @@ class ModelSync {
|
|
|
743
869
|
});
|
|
744
870
|
}
|
|
745
871
|
/**
|
|
872
|
+
* @param {string} id
|
|
873
|
+
* @param {Polytomic.ActivateSyncInput} request
|
|
874
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
875
|
+
*
|
|
746
876
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
747
877
|
* @throws {@link Polytomic.ForbiddenError}
|
|
748
878
|
* @throws {@link Polytomic.NotFoundError}
|
|
749
879
|
* @throws {@link Polytomic.InternalServerError}
|
|
750
880
|
*
|
|
751
881
|
* @example
|
|
752
|
-
* await
|
|
882
|
+
* await client.modelSync.activate("248df4b7-aa70-47b8-a036-33ac447e668d", {
|
|
753
883
|
* active: true
|
|
754
884
|
* })
|
|
755
885
|
*/
|
|
@@ -757,14 +887,16 @@ class ModelSync {
|
|
|
757
887
|
var _a;
|
|
758
888
|
return __awaiter(this, void 0, void 0, function* () {
|
|
759
889
|
const _response = yield core.fetcher({
|
|
760
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}/activate`),
|
|
890
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}/activate`),
|
|
761
891
|
method: "POST",
|
|
762
892
|
headers: {
|
|
763
893
|
Authorization: yield this._getAuthorizationHeader(),
|
|
764
|
-
"X-Polytomic-Version":
|
|
894
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
895
|
+
? yield core.Supplier.get(this._options.version)
|
|
896
|
+
: undefined,
|
|
765
897
|
"X-Fern-Language": "JavaScript",
|
|
766
898
|
"X-Fern-SDK-Name": "polytomic",
|
|
767
|
-
"X-Fern-SDK-Version": "1.
|
|
899
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
768
900
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
769
901
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
770
902
|
},
|
|
@@ -772,6 +904,7 @@ class ModelSync {
|
|
|
772
904
|
body: request,
|
|
773
905
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
774
906
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
907
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
775
908
|
});
|
|
776
909
|
if (_response.ok) {
|
|
777
910
|
return _response.body;
|
|
@@ -812,6 +945,11 @@ class ModelSync {
|
|
|
812
945
|
* > 🚧 Force full resync
|
|
813
946
|
* >
|
|
814
947
|
* > Use caution when setting the `resync` parameter to `true`. This will force a full resync of the data from the source system. This can be a time-consuming operation and may impact the performance of the source system. It is recommended to only use this option when necessary.
|
|
948
|
+
*
|
|
949
|
+
* @param {string} id
|
|
950
|
+
* @param {Polytomic.StartModelSyncRequest} request
|
|
951
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
952
|
+
*
|
|
815
953
|
* @throws {@link Polytomic.BadRequestError}
|
|
816
954
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
817
955
|
* @throws {@link Polytomic.ForbiddenError}
|
|
@@ -819,20 +957,22 @@ class ModelSync {
|
|
|
819
957
|
* @throws {@link Polytomic.InternalServerError}
|
|
820
958
|
*
|
|
821
959
|
* @example
|
|
822
|
-
* await
|
|
960
|
+
* await client.modelSync.start("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
823
961
|
*/
|
|
824
962
|
start(id, request = {}, requestOptions) {
|
|
825
963
|
var _a;
|
|
826
964
|
return __awaiter(this, void 0, void 0, function* () {
|
|
827
965
|
const _response = yield core.fetcher({
|
|
828
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}/executions`),
|
|
966
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}/executions`),
|
|
829
967
|
method: "POST",
|
|
830
968
|
headers: {
|
|
831
969
|
Authorization: yield this._getAuthorizationHeader(),
|
|
832
|
-
"X-Polytomic-Version":
|
|
970
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
971
|
+
? yield core.Supplier.get(this._options.version)
|
|
972
|
+
: undefined,
|
|
833
973
|
"X-Fern-Language": "JavaScript",
|
|
834
974
|
"X-Fern-SDK-Name": "polytomic",
|
|
835
|
-
"X-Fern-SDK-Version": "1.
|
|
975
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
836
976
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
837
977
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
838
978
|
},
|
|
@@ -840,6 +980,7 @@ class ModelSync {
|
|
|
840
980
|
body: request,
|
|
841
981
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
842
982
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
983
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
843
984
|
});
|
|
844
985
|
if (_response.ok) {
|
|
845
986
|
return _response.body;
|
|
@@ -879,31 +1020,37 @@ class ModelSync {
|
|
|
879
1020
|
});
|
|
880
1021
|
}
|
|
881
1022
|
/**
|
|
1023
|
+
* @param {string} id
|
|
1024
|
+
* @param {ModelSync.RequestOptions} requestOptions - Request-specific configuration.
|
|
1025
|
+
*
|
|
882
1026
|
* @throws {@link Polytomic.UnauthorizedError}
|
|
883
1027
|
* @throws {@link Polytomic.NotFoundError}
|
|
884
1028
|
* @throws {@link Polytomic.InternalServerError}
|
|
885
1029
|
*
|
|
886
1030
|
* @example
|
|
887
|
-
* await
|
|
1031
|
+
* await client.modelSync.getStatus("248df4b7-aa70-47b8-a036-33ac447e668d")
|
|
888
1032
|
*/
|
|
889
1033
|
getStatus(id, requestOptions) {
|
|
890
1034
|
var _a;
|
|
891
1035
|
return __awaiter(this, void 0, void 0, function* () {
|
|
892
1036
|
const _response = yield core.fetcher({
|
|
893
|
-
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${id}/status`),
|
|
1037
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.PolytomicEnvironment.Default, `api/syncs/${encodeURIComponent(id)}/status`),
|
|
894
1038
|
method: "GET",
|
|
895
1039
|
headers: {
|
|
896
1040
|
Authorization: yield this._getAuthorizationHeader(),
|
|
897
|
-
"X-Polytomic-Version":
|
|
1041
|
+
"X-Polytomic-Version": (yield core.Supplier.get(this._options.version)) != null
|
|
1042
|
+
? yield core.Supplier.get(this._options.version)
|
|
1043
|
+
: undefined,
|
|
898
1044
|
"X-Fern-Language": "JavaScript",
|
|
899
1045
|
"X-Fern-SDK-Name": "polytomic",
|
|
900
|
-
"X-Fern-SDK-Version": "1.
|
|
1046
|
+
"X-Fern-SDK-Version": "1.9.0",
|
|
901
1047
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
902
1048
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
903
1049
|
},
|
|
904
1050
|
contentType: "application/json",
|
|
905
1051
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
906
1052
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1053
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
907
1054
|
});
|
|
908
1055
|
if (_response.ok) {
|
|
909
1056
|
return _response.body;
|