@chrt-inc/typescript-sdk 1.319.0 → 1.321.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/dist/cjs/Client.d.ts +6 -0
- package/dist/cjs/Client.js +38 -28
- package/dist/cjs/api/resources/cargos/client/Client.d.ts +48 -0
- package/dist/cjs/api/resources/cargos/client/Client.js +131 -0
- package/dist/cjs/api/resources/connections/client/Client.d.ts +4 -4
- package/dist/cjs/api/resources/connections/client/Client.js +4 -4
- package/dist/cjs/api/resources/courierPayDriverPayouts/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/courierPayDriverPayouts/client/Client.js +2 -2
- package/dist/cjs/api/resources/courierPayDriverRateSheets/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/courierPayDriverRateSheets/client/Client.js +3 -3
- package/dist/cjs/api/resources/courierPayDriverStatements/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/courierPayDriverStatements/client/Client.js +2 -2
- package/dist/cjs/api/resources/dev/client/Client.d.ts +4 -4
- package/dist/cjs/api/resources/dev/client/Client.js +4 -4
- package/dist/cjs/api/resources/drivers/client/Client.d.ts +59 -61
- package/dist/cjs/api/resources/drivers/client/Client.js +140 -139
- package/dist/cjs/api/resources/drivers/client/requests/DriverClientCreate1.d.ts +20 -0
- package/dist/cjs/api/resources/drivers/client/requests/{UpdateDriverDetailsReq.d.ts → DriverClientUpdate1.d.ts} +4 -5
- package/dist/cjs/api/resources/drivers/client/requests/DriverLastSeenReq.d.ts +1 -0
- package/dist/cjs/api/resources/drivers/client/requests/index.d.ts +2 -3
- package/dist/cjs/api/resources/index.d.ts +3 -0
- package/dist/cjs/api/resources/index.js +4 -1
- package/dist/cjs/api/resources/notifications/resources/courier/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/notifications/resources/courier/client/Client.js +2 -2
- package/dist/cjs/api/resources/notifications/resources/shipper/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/notifications/resources/shipper/client/Client.js +2 -2
- package/dist/cjs/api/resources/offChrtShipperOrg/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/offChrtShipperOrg/client/Client.js +3 -3
- package/dist/cjs/api/resources/orders/client/Client.d.ts +13 -0
- package/dist/cjs/api/resources/orders/client/Client.js +59 -0
- package/dist/cjs/api/resources/orgInfoForConnections/resources/courier/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/orgInfoForConnections/resources/courier/client/Client.js +1 -1
- package/dist/cjs/api/resources/orgInfoForConnections/resources/forwarder/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/orgInfoForConnections/resources/forwarder/client/Client.js +1 -1
- package/dist/cjs/api/resources/orgInfoForConnections/resources/shipper/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/orgInfoForConnections/resources/shipper/client/Client.js +1 -1
- package/dist/cjs/api/resources/orgProfiles/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/orgProfiles/client/Client.js +1 -1
- package/dist/cjs/api/resources/orgs/client/Client.d.ts +5 -5
- package/dist/cjs/api/resources/orgs/client/Client.js +5 -5
- package/dist/cjs/api/resources/shipperContactInfo/client/Client.d.ts +36 -23
- package/dist/cjs/api/resources/shipperContactInfo/client/Client.js +94 -35
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/client/Client.js +2 -2
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/resources/courier/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/resources/courier/client/Client.js +1 -1
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/resources/shipper/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/shipperPayCourierLineItemGroups/resources/shipper/client/Client.js +3 -3
- package/dist/cjs/api/resources/taskArtifactNotifications/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/taskArtifactNotifications/client/Client.js +2 -2
- package/dist/cjs/api/resources/taskArtifacts/client/Client.d.ts +37 -24
- package/dist/cjs/api/resources/taskArtifacts/client/Client.js +96 -40
- package/dist/cjs/api/resources/taskArtifacts/client/requests/AddTaskArtifactReq.d.ts +19 -0
- package/dist/cjs/api/resources/taskArtifacts/client/requests/index.d.ts +1 -2
- package/dist/cjs/api/resources/taskArtifacts/resources/index.d.ts +2 -3
- package/dist/cjs/api/resources/taskArtifacts/resources/index.js +3 -7
- package/dist/cjs/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.d.ts +9 -9
- package/dist/cjs/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.js +11 -11
- package/dist/cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/Client.d.ts +47 -0
- package/dist/cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/Client.js +127 -0
- package/dist/cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/index.js +2 -0
- package/dist/cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/index.js +17 -0
- package/dist/cjs/api/resources/taskGroups/client/Client.d.ts +79 -33
- package/dist/cjs/api/resources/taskGroups/client/Client.js +220 -67
- package/dist/cjs/api/resources/taskGroups/client/requests/AddMessageReq.d.ts +13 -0
- package/dist/cjs/api/resources/{taskArtifacts/resources/images/client/requests/BodyPostTaskArtifactsUploadImageV1OortTaskArtifactsImagesUploadV1TaskArtifactIdPost.d.ts → taskGroups/client/requests/BodyPostAddS3ObjectV1OortTaskGroupsAddS3ObjectV1TaskGroupIdPost.d.ts} +2 -2
- package/dist/cjs/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/client/requests/SetTaskOrderingReq.d.ts +3 -2
- package/dist/cjs/api/resources/taskGroups/client/requests/UpdateCourierOrgReq.d.ts +13 -0
- package/dist/cjs/api/resources/taskGroups/client/requests/UpdateDriverReq.d.ts +13 -0
- package/dist/cjs/api/resources/taskGroups/client/requests/index.d.ts +4 -2
- package/dist/cjs/api/resources/taskGroups/resources/expanded/client/Client.d.ts +4 -0
- package/dist/cjs/api/resources/taskGroups/resources/expanded/client/Client.js +18 -2
- package/dist/cjs/api/resources/taskGroups/resources/expanded/client/requests/ExpandedListForCourierDriverV1Request.d.ts +4 -0
- package/dist/cjs/api/resources/taskGroups/resources/expanded/client/requests/ExpandedListForCourierOperatorsV1Request.d.ts +4 -0
- package/dist/cjs/api/resources/taskGroups/resources/index.d.ts +3 -0
- package/dist/cjs/api/resources/taskGroups/resources/index.js +4 -1
- package/dist/cjs/api/resources/taskGroups/resources/s3Object/client/Client.d.ts +46 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3Object/client/Client.js +127 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3Object/client/index.js +2 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3Object/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3Object/index.js +17 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/client/Client.d.ts +47 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/client/Client.js +127 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/client/index.js +2 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/resources/s3ObjectMetadata/index.js +17 -0
- package/dist/cjs/api/resources/taskGroups/resources/taskGroupId/client/Client.d.ts +59 -0
- package/dist/cjs/api/resources/{taskArtifacts/resources/images → taskGroups/resources/taskGroupId}/client/Client.js +24 -87
- package/dist/cjs/api/resources/taskGroups/resources/taskGroupId/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/resources/taskGroupId/client/index.js +2 -0
- package/dist/cjs/api/resources/taskGroups/resources/taskGroupId/index.d.ts +1 -0
- package/dist/cjs/api/resources/taskGroups/resources/taskGroupId/index.js +17 -0
- package/dist/cjs/api/resources/tasks/client/Client.d.ts +107 -0
- package/dist/cjs/api/resources/tasks/client/Client.js +377 -0
- package/dist/cjs/api/resources/tasks/client/requests/AddTaskToGroupReq.d.ts +21 -0
- package/dist/cjs/api/resources/tasks/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/tasks/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/tasks/index.d.ts +1 -0
- package/dist/cjs/api/resources/tasks/index.js +17 -0
- package/dist/cjs/api/resources/tracking/resources/devices/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/tracking/resources/devices/client/Client.js +3 -3
- package/dist/cjs/api/resources/tracking/resources/sessionByDevice/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/tracking/resources/sessionByDevice/client/Client.js +3 -3
- package/dist/cjs/api/resources/users/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/users/client/Client.js +1 -1
- package/dist/cjs/api/types/Cargo1.d.ts +1 -0
- package/dist/cjs/api/types/CargoStatusEnum1.d.ts +2 -1
- package/dist/cjs/api/types/CargoStatusEnum1.js +1 -0
- package/dist/cjs/api/types/ChrtGroundCourierTaskActionEnum1.d.ts +3 -3
- package/dist/cjs/api/types/ChrtGroundCourierTaskActionEnum1.js +2 -2
- package/dist/cjs/api/types/Driver1.d.ts +6 -4
- package/dist/cjs/api/types/DriverStatusEnum.d.ts +3 -3
- package/dist/cjs/api/types/DriverStatusEnum.js +2 -2
- package/dist/cjs/api/types/DriverUpdateAvailabilityReq.d.ts +6 -0
- package/dist/cjs/api/types/DriverUpdateAvailabilityReq.js +5 -0
- package/dist/cjs/api/types/Task1.d.ts +1 -0
- package/dist/cjs/api/types/TaskArtifact1.d.ts +1 -0
- package/dist/cjs/api/types/TaskArtifactClientCreate1.d.ts +8 -0
- package/dist/cjs/api/types/TaskArtifactClientCreate1.js +5 -0
- package/dist/cjs/api/types/TaskArtifactS3ObjectMetadata1.d.ts +15 -0
- package/dist/cjs/api/types/TaskArtifactS3ObjectMetadata1.js +5 -0
- package/dist/cjs/api/types/TaskArtifactStatusEnum1.d.ts +2 -1
- package/dist/cjs/api/types/TaskArtifactStatusEnum1.js +1 -0
- package/dist/cjs/api/types/TaskClientUpdate1.d.ts +0 -1
- package/dist/cjs/api/types/TaskGroup1.d.ts +1 -0
- package/dist/cjs/api/types/TaskGroupS3ObjectMetadata1.d.ts +15 -0
- package/dist/cjs/api/types/TaskGroupS3ObjectMetadata1.js +5 -0
- package/dist/cjs/api/types/TaskGroupSortByEnum.d.ts +2 -1
- package/dist/cjs/api/types/TaskGroupSortByEnum.js +1 -0
- package/dist/cjs/api/types/TaskGroupStatusEnum1.d.ts +2 -1
- package/dist/cjs/api/types/TaskGroupStatusEnum1.js +1 -0
- package/dist/cjs/api/types/TaskStatusEnum1.d.ts +2 -1
- package/dist/cjs/api/types/TaskStatusEnum1.js +1 -0
- package/dist/cjs/api/types/index.d.ts +4 -0
- package/dist/cjs/api/types/index.js +4 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.d.mts +6 -0
- package/dist/esm/Client.mjs +12 -2
- package/dist/esm/api/resources/cargos/client/Client.d.mts +48 -0
- package/dist/esm/api/resources/cargos/client/Client.mjs +94 -0
- package/dist/esm/api/resources/cargos/client/index.d.mts +1 -0
- package/dist/esm/api/resources/cargos/client/index.mjs +1 -0
- package/dist/esm/api/resources/connections/client/Client.d.mts +4 -4
- package/dist/esm/api/resources/connections/client/Client.mjs +4 -4
- package/dist/esm/api/resources/courierPayDriverPayouts/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/courierPayDriverPayouts/client/Client.mjs +2 -2
- package/dist/esm/api/resources/courierPayDriverRateSheets/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/courierPayDriverRateSheets/client/Client.mjs +3 -3
- package/dist/esm/api/resources/courierPayDriverStatements/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/courierPayDriverStatements/client/Client.mjs +2 -2
- package/dist/esm/api/resources/dev/client/Client.d.mts +4 -4
- package/dist/esm/api/resources/dev/client/Client.mjs +4 -4
- package/dist/esm/api/resources/drivers/client/Client.d.mts +59 -61
- package/dist/esm/api/resources/drivers/client/Client.mjs +140 -139
- package/dist/esm/api/resources/drivers/client/requests/DriverClientCreate1.d.mts +20 -0
- package/dist/esm/api/resources/drivers/client/requests/{UpdateDriverDetailsReq.d.mts → DriverClientUpdate1.d.mts} +4 -5
- package/dist/esm/api/resources/drivers/client/requests/DriverLastSeenReq.d.mts +1 -0
- package/dist/esm/api/resources/drivers/client/requests/index.d.mts +2 -3
- package/dist/esm/api/resources/index.d.mts +3 -0
- package/dist/esm/api/resources/index.mjs +3 -0
- package/dist/esm/api/resources/notifications/resources/courier/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/notifications/resources/courier/client/Client.mjs +2 -2
- package/dist/esm/api/resources/notifications/resources/shipper/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/notifications/resources/shipper/client/Client.mjs +2 -2
- package/dist/esm/api/resources/offChrtShipperOrg/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/offChrtShipperOrg/client/Client.mjs +3 -3
- package/dist/esm/api/resources/orders/client/Client.d.mts +13 -0
- package/dist/esm/api/resources/orders/client/Client.mjs +59 -0
- package/dist/esm/api/resources/orgInfoForConnections/resources/courier/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/orgInfoForConnections/resources/courier/client/Client.mjs +1 -1
- package/dist/esm/api/resources/orgInfoForConnections/resources/forwarder/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/orgInfoForConnections/resources/forwarder/client/Client.mjs +1 -1
- package/dist/esm/api/resources/orgInfoForConnections/resources/shipper/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/orgInfoForConnections/resources/shipper/client/Client.mjs +1 -1
- package/dist/esm/api/resources/orgProfiles/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/orgProfiles/client/Client.mjs +1 -1
- package/dist/esm/api/resources/orgs/client/Client.d.mts +5 -5
- package/dist/esm/api/resources/orgs/client/Client.mjs +5 -5
- package/dist/esm/api/resources/shipperContactInfo/client/Client.d.mts +36 -23
- package/dist/esm/api/resources/shipperContactInfo/client/Client.mjs +94 -35
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/client/Client.mjs +2 -2
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/resources/courier/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/resources/courier/client/Client.mjs +1 -1
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/resources/shipper/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/shipperPayCourierLineItemGroups/resources/shipper/client/Client.mjs +3 -3
- package/dist/esm/api/resources/taskArtifactNotifications/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/taskArtifactNotifications/client/Client.mjs +2 -2
- package/dist/esm/api/resources/taskArtifacts/client/Client.d.mts +37 -24
- package/dist/esm/api/resources/taskArtifacts/client/Client.mjs +96 -40
- package/dist/esm/api/resources/taskArtifacts/client/requests/AddTaskArtifactReq.d.mts +19 -0
- package/dist/esm/api/resources/taskArtifacts/client/requests/index.d.mts +1 -2
- package/dist/esm/api/resources/taskArtifacts/resources/index.d.mts +2 -3
- package/dist/esm/api/resources/taskArtifacts/resources/index.mjs +2 -3
- package/dist/esm/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.d.mts +9 -9
- package/dist/esm/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.mjs +9 -9
- package/dist/esm/api/resources/taskArtifacts/resources/s3Object/client/index.d.mts +1 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3Object/client/index.mjs +1 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/Client.d.mts +47 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/Client.mjs +90 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/index.d.mts +1 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/index.mjs +1 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/index.d.mts +1 -0
- package/dist/esm/api/resources/taskArtifacts/resources/s3ObjectMetadata/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/client/Client.d.mts +79 -33
- package/dist/esm/api/resources/taskGroups/client/Client.mjs +218 -65
- package/dist/esm/api/resources/taskGroups/client/requests/AddMessageReq.d.mts +13 -0
- package/dist/esm/api/resources/{taskArtifacts/resources/images/client/requests/BodyPostTaskArtifactsUploadImageV1OortTaskArtifactsImagesUploadV1TaskArtifactIdPost.d.mts → taskGroups/client/requests/BodyPostAddS3ObjectV1OortTaskGroupsAddS3ObjectV1TaskGroupIdPost.d.mts} +2 -2
- package/dist/esm/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/client/requests/SetTaskOrderingReq.d.mts +3 -2
- package/dist/esm/api/resources/taskGroups/client/requests/UpdateCourierOrgReq.d.mts +13 -0
- package/dist/esm/api/resources/taskGroups/client/requests/UpdateDriverReq.d.mts +13 -0
- package/dist/esm/api/resources/taskGroups/client/requests/index.d.mts +4 -2
- package/dist/esm/api/resources/taskGroups/resources/expanded/client/Client.d.mts +4 -0
- package/dist/esm/api/resources/taskGroups/resources/expanded/client/Client.mjs +18 -2
- package/dist/esm/api/resources/taskGroups/resources/expanded/client/requests/ExpandedListForCourierDriverV1Request.d.mts +4 -0
- package/dist/esm/api/resources/taskGroups/resources/expanded/client/requests/ExpandedListForCourierOperatorsV1Request.d.mts +4 -0
- package/dist/esm/api/resources/taskGroups/resources/index.d.mts +3 -0
- package/dist/esm/api/resources/taskGroups/resources/index.mjs +3 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/client/Client.d.mts +46 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/client/Client.mjs +90 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/client/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/client/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3Object/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/client/Client.d.mts +47 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/client/Client.mjs +90 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/client/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/client/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/s3ObjectMetadata/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/resources/taskGroupId/client/Client.d.mts +59 -0
- package/dist/esm/api/resources/{taskArtifacts/resources/images → taskGroups/resources/taskGroupId}/client/Client.mjs +22 -85
- package/dist/esm/api/resources/taskGroups/resources/taskGroupId/client/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/taskGroupId/client/index.mjs +1 -0
- package/dist/esm/api/resources/taskGroups/resources/taskGroupId/index.d.mts +1 -0
- package/dist/esm/api/resources/taskGroups/resources/taskGroupId/index.mjs +1 -0
- package/dist/esm/api/resources/tasks/client/Client.d.mts +107 -0
- package/dist/esm/api/resources/tasks/client/Client.mjs +340 -0
- package/dist/esm/api/resources/tasks/client/requests/AddTaskToGroupReq.d.mts +21 -0
- package/dist/esm/api/resources/tasks/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/tasks/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/tasks/index.d.mts +1 -0
- package/dist/esm/api/resources/tasks/index.mjs +1 -0
- package/dist/esm/api/resources/tracking/resources/devices/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/tracking/resources/devices/client/Client.mjs +3 -3
- package/dist/esm/api/resources/tracking/resources/sessionByDevice/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/tracking/resources/sessionByDevice/client/Client.mjs +3 -3
- package/dist/esm/api/resources/users/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/users/client/Client.mjs +1 -1
- package/dist/esm/api/types/Cargo1.d.mts +1 -0
- package/dist/esm/api/types/CargoStatusEnum1.d.mts +2 -1
- package/dist/esm/api/types/CargoStatusEnum1.mjs +1 -0
- package/dist/esm/api/types/ChrtGroundCourierTaskActionEnum1.d.mts +3 -3
- package/dist/esm/api/types/ChrtGroundCourierTaskActionEnum1.mjs +2 -2
- package/dist/esm/api/types/Driver1.d.mts +6 -4
- package/dist/esm/api/types/DriverStatusEnum.d.mts +3 -3
- package/dist/esm/api/types/DriverStatusEnum.mjs +2 -2
- package/dist/esm/api/types/DriverUpdateAvailabilityReq.d.mts +6 -0
- package/dist/esm/api/types/DriverUpdateAvailabilityReq.mjs +4 -0
- package/dist/esm/api/types/Task1.d.mts +1 -0
- package/dist/esm/api/types/TaskArtifact1.d.mts +1 -0
- package/dist/esm/api/types/TaskArtifactClientCreate1.d.mts +8 -0
- package/dist/esm/api/types/TaskArtifactClientCreate1.mjs +4 -0
- package/dist/esm/api/types/TaskArtifactS3ObjectMetadata1.d.mts +15 -0
- package/dist/esm/api/types/TaskArtifactS3ObjectMetadata1.mjs +4 -0
- package/dist/esm/api/types/TaskArtifactStatusEnum1.d.mts +2 -1
- package/dist/esm/api/types/TaskArtifactStatusEnum1.mjs +1 -0
- package/dist/esm/api/types/TaskClientUpdate1.d.mts +0 -1
- package/dist/esm/api/types/TaskGroup1.d.mts +1 -0
- package/dist/esm/api/types/TaskGroupS3ObjectMetadata1.d.mts +15 -0
- package/dist/esm/api/types/TaskGroupS3ObjectMetadata1.mjs +4 -0
- package/dist/esm/api/types/TaskGroupSortByEnum.d.mts +2 -1
- package/dist/esm/api/types/TaskGroupSortByEnum.mjs +1 -0
- package/dist/esm/api/types/TaskGroupStatusEnum1.d.mts +2 -1
- package/dist/esm/api/types/TaskGroupStatusEnum1.mjs +1 -0
- package/dist/esm/api/types/TaskStatusEnum1.d.mts +2 -1
- package/dist/esm/api/types/TaskStatusEnum1.mjs +1 -0
- package/dist/esm/api/types/index.d.mts +4 -0
- package/dist/esm/api/types/index.mjs +4 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +1163 -267
- package/dist/cjs/api/resources/drivers/client/requests/DriverCreateReq.d.ts +0 -17
- package/dist/cjs/api/resources/drivers/client/requests/SetDriverActivationReq.d.ts +0 -14
- package/dist/cjs/api/resources/taskArtifacts/client/requests/TaskArtifactAddToTaskReq.d.ts +0 -19
- package/dist/cjs/api/resources/taskArtifacts/client/requests/TaskArtifactUpdateCommentsReq.d.ts +0 -14
- package/dist/cjs/api/resources/taskArtifacts/resources/images/client/Client.d.ts +0 -70
- package/dist/cjs/api/resources/taskArtifacts/resources/images/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/taskGroups/client/requests/UpdateTaskGroupCourierOrgReq.d.ts +0 -12
- package/dist/cjs/api/resources/taskGroups/client/requests/UpdateTaskGroupDriverReq.d.ts +0 -11
- package/dist/esm/api/resources/drivers/client/requests/DriverCreateReq.d.mts +0 -17
- package/dist/esm/api/resources/drivers/client/requests/SetDriverActivationReq.d.mts +0 -14
- package/dist/esm/api/resources/taskArtifacts/client/requests/TaskArtifactAddToTaskReq.d.mts +0 -19
- package/dist/esm/api/resources/taskArtifacts/client/requests/TaskArtifactUpdateCommentsReq.d.mts +0 -14
- package/dist/esm/api/resources/taskArtifacts/resources/images/client/Client.d.mts +0 -70
- package/dist/esm/api/resources/taskArtifacts/resources/images/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/taskGroups/client/requests/UpdateTaskGroupCourierOrgReq.d.mts +0 -12
- package/dist/esm/api/resources/taskGroups/client/requests/UpdateTaskGroupDriverReq.d.mts +0 -11
- /package/dist/cjs/api/resources/{taskArtifacts/resources/blurhash → cargos}/client/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/blurhash → cargos}/client/index.js +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/blurhash → cargos}/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/blurhash → cargos}/index.js +0 -0
- /package/dist/cjs/api/resources/drivers/client/requests/{DriverCreateReq.js → DriverClientCreate1.js} +0 -0
- /package/dist/cjs/api/resources/drivers/client/requests/{SetDriverActivationReq.js → DriverClientUpdate1.js} +0 -0
- /package/dist/cjs/api/resources/{drivers/client/requests/UpdateDriverDetailsReq.js → taskArtifacts/client/requests/AddTaskArtifactReq.js} +0 -0
- /package/dist/{esm/api/resources/taskArtifacts/resources/blurhash/client/index.d.mts → cjs/api/resources/taskArtifacts/resources/s3Object/client/index.d.ts} +0 -0
- /package/dist/cjs/api/resources/taskArtifacts/resources/{images/client/requests → s3Object/client}/index.js +0 -0
- /package/dist/cjs/api/resources/taskArtifacts/resources/{images → s3Object}/index.d.ts +0 -0
- /package/dist/cjs/api/resources/taskArtifacts/resources/{images → s3Object}/index.js +0 -0
- /package/dist/{esm/api/resources/taskArtifacts/resources/blurhash/client/index.mjs → cjs/api/resources/taskArtifacts/resources/s3ObjectMetadata/client/index.d.ts} +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/client/requests/TaskArtifactAddToTaskReq.js → taskGroups/client/requests/AddMessageReq.js} +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/client/requests/TaskArtifactUpdateCommentsReq.js → taskGroups/client/requests/BodyPostAddS3ObjectV1OortTaskGroupsAddS3ObjectV1TaskGroupIdPost.js} +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/images/client/requests/BodyPostTaskArtifactsUploadImageV1OortTaskArtifactsImagesUploadV1TaskArtifactIdPost.js → taskGroups/client/requests/UpdateCourierOrgReq.js} +0 -0
- /package/dist/cjs/api/resources/taskGroups/client/requests/{UpdateTaskGroupCourierOrgReq.js → UpdateDriverReq.js} +0 -0
- /package/dist/{esm/api/resources/taskArtifacts/resources/images/client/requests/index.mjs → cjs/api/resources/taskGroups/resources/s3Object/client/index.d.ts} +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/images → tasks}/client/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{taskArtifacts/resources/images → tasks}/client/index.js +0 -0
- /package/dist/cjs/api/resources/{taskGroups/client/requests/UpdateTaskGroupDriverReq.js → tasks/client/requests/AddTaskToGroupReq.js} +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/resources/blurhash → cargos}/index.d.mts +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/resources/blurhash → cargos}/index.mjs +0 -0
- /package/dist/esm/api/resources/drivers/client/requests/{DriverCreateReq.mjs → DriverClientCreate1.mjs} +0 -0
- /package/dist/esm/api/resources/drivers/client/requests/{SetDriverActivationReq.mjs → DriverClientUpdate1.mjs} +0 -0
- /package/dist/esm/api/resources/{drivers/client/requests/UpdateDriverDetailsReq.mjs → taskArtifacts/client/requests/AddTaskArtifactReq.mjs} +0 -0
- /package/dist/esm/api/resources/taskArtifacts/resources/{images → s3Object}/index.d.mts +0 -0
- /package/dist/esm/api/resources/taskArtifacts/resources/{images → s3Object}/index.mjs +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/client/requests/TaskArtifactAddToTaskReq.mjs → taskGroups/client/requests/AddMessageReq.mjs} +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/client/requests/TaskArtifactUpdateCommentsReq.mjs → taskGroups/client/requests/BodyPostAddS3ObjectV1OortTaskGroupsAddS3ObjectV1TaskGroupIdPost.mjs} +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/resources/images/client/requests/BodyPostTaskArtifactsUploadImageV1OortTaskArtifactsImagesUploadV1TaskArtifactIdPost.mjs → taskGroups/client/requests/UpdateCourierOrgReq.mjs} +0 -0
- /package/dist/esm/api/resources/taskGroups/client/requests/{UpdateTaskGroupCourierOrgReq.mjs → UpdateDriverReq.mjs} +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/resources/images → tasks}/client/index.d.mts +0 -0
- /package/dist/esm/api/resources/{taskArtifacts/resources/images → tasks}/client/index.mjs +0 -0
- /package/dist/esm/api/resources/{taskGroups/client/requests/UpdateTaskGroupDriverReq.mjs → tasks/client/requests/AddTaskToGroupReq.mjs} +0 -0
|
@@ -15,22 +15,91 @@ import * as core from "../../../../core/index.mjs";
|
|
|
15
15
|
import * as Chrt from "../../../index.mjs";
|
|
16
16
|
import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.mjs";
|
|
17
17
|
import * as errors from "../../../../errors/index.mjs";
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
18
|
+
import { S3ObjectMetadata } from "../resources/s3ObjectMetadata/client/Client.mjs";
|
|
19
|
+
import { S3Object } from "../resources/s3Object/client/Client.mjs";
|
|
20
20
|
export class TaskArtifacts {
|
|
21
21
|
constructor(_options = {}) {
|
|
22
22
|
this._options = _options;
|
|
23
23
|
}
|
|
24
|
-
get
|
|
24
|
+
get s3ObjectMetadata() {
|
|
25
25
|
var _a;
|
|
26
|
-
return ((_a = this.
|
|
26
|
+
return ((_a = this._s3ObjectMetadata) !== null && _a !== void 0 ? _a : (this._s3ObjectMetadata = new S3ObjectMetadata(this._options)));
|
|
27
27
|
}
|
|
28
|
-
get
|
|
28
|
+
get s3Object() {
|
|
29
29
|
var _a;
|
|
30
|
-
return ((_a = this.
|
|
30
|
+
return ((_a = this._s3Object) !== null && _a !== void 0 ? _a : (this._s3Object = new S3Object(this._options)));
|
|
31
31
|
}
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
33
|
+
* Adds a new task artifact to a task. | authz_personas=[courier_driver, courier_org_operators, forwarder_org_operators] | (AddTaskArtifactReq) -> (PydanticObjectId)
|
|
34
|
+
*
|
|
35
|
+
* @param {string} taskId
|
|
36
|
+
* @param {Chrt.AddTaskArtifactReq} request
|
|
37
|
+
* @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
|
|
38
|
+
*
|
|
39
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* await client.taskArtifacts.addToTaskV1("task_id", {
|
|
43
|
+
* task_artifact: {
|
|
44
|
+
* schema_version: 1,
|
|
45
|
+
* type: "image"
|
|
46
|
+
* },
|
|
47
|
+
* status: "draft"
|
|
48
|
+
* })
|
|
49
|
+
*/
|
|
50
|
+
addToTaskV1(taskId, request, requestOptions) {
|
|
51
|
+
return core.HttpResponsePromise.fromPromise(this.__addToTaskV1(taskId, request, requestOptions));
|
|
52
|
+
}
|
|
53
|
+
__addToTaskV1(taskId, request, requestOptions) {
|
|
54
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
55
|
+
var _a, _b, _c, _d;
|
|
56
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
57
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
58
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/add_to_task/v1/${encodeURIComponent(taskId)}`),
|
|
59
|
+
method: "PUT",
|
|
60
|
+
headers: _headers,
|
|
61
|
+
contentType: "application/json",
|
|
62
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
63
|
+
requestType: "json",
|
|
64
|
+
body: request,
|
|
65
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
66
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
67
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
68
|
+
});
|
|
69
|
+
if (_response.ok) {
|
|
70
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
71
|
+
}
|
|
72
|
+
if (_response.error.reason === "status-code") {
|
|
73
|
+
switch (_response.error.statusCode) {
|
|
74
|
+
case 422:
|
|
75
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
76
|
+
default:
|
|
77
|
+
throw new errors.ChrtError({
|
|
78
|
+
statusCode: _response.error.statusCode,
|
|
79
|
+
body: _response.error.body,
|
|
80
|
+
rawResponse: _response.rawResponse,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
switch (_response.error.reason) {
|
|
85
|
+
case "non-json":
|
|
86
|
+
throw new errors.ChrtError({
|
|
87
|
+
statusCode: _response.error.statusCode,
|
|
88
|
+
body: _response.error.rawBody,
|
|
89
|
+
rawResponse: _response.rawResponse,
|
|
90
|
+
});
|
|
91
|
+
case "timeout":
|
|
92
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling PUT /oort/task_artifacts/add_to_task/v1/{task_id}.");
|
|
93
|
+
case "unknown":
|
|
94
|
+
throw new errors.ChrtError({
|
|
95
|
+
message: _response.error.errorMessage,
|
|
96
|
+
rawResponse: _response.rawResponse,
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Marks a task artifact as COMPLETED. | authz_personas=[courier_driver, courier_org_operators, forwarder_org_operators] | () -> (bool)
|
|
34
103
|
*
|
|
35
104
|
* @param {string} taskArtifactId
|
|
36
105
|
* @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -49,7 +118,7 @@ export class TaskArtifacts {
|
|
|
49
118
|
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
50
119
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
51
120
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/complete/v1/${encodeURIComponent(taskArtifactId)}`),
|
|
52
|
-
method: "
|
|
121
|
+
method: "PUT",
|
|
53
122
|
headers: _headers,
|
|
54
123
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
55
124
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -79,7 +148,7 @@ export class TaskArtifacts {
|
|
|
79
148
|
rawResponse: _response.rawResponse,
|
|
80
149
|
});
|
|
81
150
|
case "timeout":
|
|
82
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling
|
|
151
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling PUT /oort/task_artifacts/complete/v1/{task_artifact_id}.");
|
|
83
152
|
case "unknown":
|
|
84
153
|
throw new errors.ChrtError({
|
|
85
154
|
message: _response.error.errorMessage,
|
|
@@ -89,34 +158,28 @@ export class TaskArtifacts {
|
|
|
89
158
|
});
|
|
90
159
|
}
|
|
91
160
|
/**
|
|
92
|
-
*
|
|
161
|
+
* Marks a task artifact as SKIPPED. | authz_personas=[courier_driver, courier_org_operators, forwarder_org_operators] | () -> (bool)
|
|
93
162
|
*
|
|
94
|
-
* @param {
|
|
163
|
+
* @param {string} taskArtifactId
|
|
95
164
|
* @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
|
|
96
165
|
*
|
|
97
166
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
98
167
|
*
|
|
99
168
|
* @example
|
|
100
|
-
* await client.taskArtifacts.
|
|
101
|
-
* task_artifact_id: "task_artifact_id",
|
|
102
|
-
* completor_comments: "completor_comments"
|
|
103
|
-
* })
|
|
169
|
+
* await client.taskArtifacts.skipV1("task_artifact_id")
|
|
104
170
|
*/
|
|
105
|
-
|
|
106
|
-
return core.HttpResponsePromise.fromPromise(this.
|
|
171
|
+
skipV1(taskArtifactId, requestOptions) {
|
|
172
|
+
return core.HttpResponsePromise.fromPromise(this.__skipV1(taskArtifactId, requestOptions));
|
|
107
173
|
}
|
|
108
|
-
|
|
174
|
+
__skipV1(taskArtifactId, requestOptions) {
|
|
109
175
|
return __awaiter(this, void 0, void 0, function* () {
|
|
110
176
|
var _a, _b, _c, _d;
|
|
111
177
|
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
112
178
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
113
|
-
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local,
|
|
114
|
-
method: "
|
|
179
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/skip/v1/${encodeURIComponent(taskArtifactId)}`),
|
|
180
|
+
method: "PUT",
|
|
115
181
|
headers: _headers,
|
|
116
|
-
contentType: "application/json",
|
|
117
182
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
118
|
-
requestType: "json",
|
|
119
|
-
body: request,
|
|
120
183
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
121
184
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
122
185
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -144,7 +207,7 @@ export class TaskArtifacts {
|
|
|
144
207
|
rawResponse: _response.rawResponse,
|
|
145
208
|
});
|
|
146
209
|
case "timeout":
|
|
147
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling
|
|
210
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling PUT /oort/task_artifacts/skip/v1/{task_artifact_id}.");
|
|
148
211
|
case "unknown":
|
|
149
212
|
throw new errors.ChrtError({
|
|
150
213
|
message: _response.error.errorMessage,
|
|
@@ -154,35 +217,28 @@ export class TaskArtifacts {
|
|
|
154
217
|
});
|
|
155
218
|
}
|
|
156
219
|
/**
|
|
157
|
-
*
|
|
220
|
+
* Deletes a task artifact. | authz_personas=[lig_org_operators] | () -> (bool)
|
|
158
221
|
*
|
|
159
|
-
* @param {
|
|
222
|
+
* @param {string} taskArtifactId
|
|
160
223
|
* @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
|
|
161
224
|
*
|
|
162
225
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
163
226
|
*
|
|
164
227
|
* @example
|
|
165
|
-
* await client.taskArtifacts.
|
|
166
|
-
* task_id: "task_id",
|
|
167
|
-
* task_artifact_type: "image",
|
|
168
|
-
* task_artifact_is_completed: true
|
|
169
|
-
* })
|
|
228
|
+
* await client.taskArtifacts.deleteV1("task_artifact_id")
|
|
170
229
|
*/
|
|
171
|
-
|
|
172
|
-
return core.HttpResponsePromise.fromPromise(this.
|
|
230
|
+
deleteV1(taskArtifactId, requestOptions) {
|
|
231
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteV1(taskArtifactId, requestOptions));
|
|
173
232
|
}
|
|
174
|
-
|
|
233
|
+
__deleteV1(taskArtifactId, requestOptions) {
|
|
175
234
|
return __awaiter(this, void 0, void 0, function* () {
|
|
176
235
|
var _a, _b, _c, _d;
|
|
177
236
|
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
178
237
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
179
|
-
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local,
|
|
180
|
-
method: "
|
|
238
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/delete/v1/${encodeURIComponent(taskArtifactId)}`),
|
|
239
|
+
method: "DELETE",
|
|
181
240
|
headers: _headers,
|
|
182
|
-
contentType: "application/json",
|
|
183
241
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
184
|
-
requestType: "json",
|
|
185
|
-
body: request,
|
|
186
242
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
187
243
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
188
244
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -210,7 +266,7 @@ export class TaskArtifacts {
|
|
|
210
266
|
rawResponse: _response.rawResponse,
|
|
211
267
|
});
|
|
212
268
|
case "timeout":
|
|
213
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling
|
|
269
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /oort/task_artifacts/delete/v1/{task_artifact_id}.");
|
|
214
270
|
case "unknown":
|
|
215
271
|
throw new errors.ChrtError({
|
|
216
272
|
message: _response.error.errorMessage,
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Chrt from "../../../../index.mjs";
|
|
5
|
+
/**
|
|
6
|
+
* @example
|
|
7
|
+
* {
|
|
8
|
+
* task_artifact: {
|
|
9
|
+
* schema_version: 1,
|
|
10
|
+
* type: "image"
|
|
11
|
+
* },
|
|
12
|
+
* status: "draft"
|
|
13
|
+
* }
|
|
14
|
+
*/
|
|
15
|
+
export interface AddTaskArtifactReq {
|
|
16
|
+
task_artifact: Chrt.TaskArtifactClientCreate1;
|
|
17
|
+
/** Initial status of the task artifact. */
|
|
18
|
+
status: Chrt.TaskArtifactStatusEnum1;
|
|
19
|
+
}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export { type
|
|
2
|
-
export { type TaskArtifactAddToTaskReq } from "./TaskArtifactAddToTaskReq.mjs";
|
|
1
|
+
export { type AddTaskArtifactReq } from "./AddTaskArtifactReq.mjs";
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
export * as
|
|
2
|
-
export * as
|
|
3
|
-
export * from "./images/client/requests/index.mjs";
|
|
1
|
+
export * as s3ObjectMetadata from "./s3ObjectMetadata/index.mjs";
|
|
2
|
+
export * as s3Object from "./s3Object/index.mjs";
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
export * as
|
|
2
|
-
export * as
|
|
3
|
-
export * from "./images/client/requests/index.mjs";
|
|
1
|
+
export * as s3ObjectMetadata from "./s3ObjectMetadata/index.mjs";
|
|
2
|
+
export * as s3Object from "./s3Object/index.mjs";
|
package/dist/esm/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.d.mts
RENAMED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as environments from "../../../../../../environments.mjs";
|
|
5
5
|
import * as core from "../../../../../../core/index.mjs";
|
|
6
|
-
export declare namespace
|
|
6
|
+
export declare namespace S3Object {
|
|
7
7
|
interface Options {
|
|
8
8
|
environment?: core.Supplier<environments.ChrtEnvironment | string>;
|
|
9
9
|
/** Specify a custom URL to connect the client to. */
|
|
@@ -26,21 +26,21 @@ export declare namespace Blurhash {
|
|
|
26
26
|
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
export declare class
|
|
30
|
-
protected readonly _options:
|
|
31
|
-
constructor(_options?:
|
|
29
|
+
export declare class S3Object {
|
|
30
|
+
protected readonly _options: S3Object.Options;
|
|
31
|
+
constructor(_options?: S3Object.Options);
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
33
|
+
* Streams a task artifact S3 object file from storage. | authz_personas=[courier_driver, courier_org_operators, shipper_org_operators, forwarder_org_operators] | () -> (StreamingResponse)
|
|
34
34
|
*
|
|
35
35
|
* @param {string} taskArtifactS3ObjectMetadataId
|
|
36
|
-
* @param {
|
|
36
|
+
* @param {S3Object.RequestOptions} requestOptions - Request-specific configuration.
|
|
37
37
|
*
|
|
38
38
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
39
39
|
*
|
|
40
40
|
* @example
|
|
41
|
-
* await client.taskArtifacts.
|
|
41
|
+
* await client.taskArtifacts.s3Object.getV1("task_artifact_s3_object_metadata_id")
|
|
42
42
|
*/
|
|
43
|
-
|
|
44
|
-
private
|
|
43
|
+
getV1(taskArtifactS3ObjectMetadataId: string, requestOptions?: S3Object.RequestOptions): core.HttpResponsePromise<unknown>;
|
|
44
|
+
private __getV1;
|
|
45
45
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
46
46
|
}
|
package/dist/esm/api/resources/taskArtifacts/resources/{blurhash → s3Object}/client/Client.mjs
RENAMED
|
@@ -15,30 +15,30 @@ import * as core from "../../../../../../core/index.mjs";
|
|
|
15
15
|
import * as Chrt from "../../../../../index.mjs";
|
|
16
16
|
import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.mjs";
|
|
17
17
|
import * as errors from "../../../../../../errors/index.mjs";
|
|
18
|
-
export class
|
|
18
|
+
export class S3Object {
|
|
19
19
|
constructor(_options = {}) {
|
|
20
20
|
this._options = _options;
|
|
21
21
|
}
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* Streams a task artifact S3 object file from storage. | authz_personas=[courier_driver, courier_org_operators, shipper_org_operators, forwarder_org_operators] | () -> (StreamingResponse)
|
|
24
24
|
*
|
|
25
25
|
* @param {string} taskArtifactS3ObjectMetadataId
|
|
26
|
-
* @param {
|
|
26
|
+
* @param {S3Object.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
27
|
*
|
|
28
28
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
29
29
|
*
|
|
30
30
|
* @example
|
|
31
|
-
* await client.taskArtifacts.
|
|
31
|
+
* await client.taskArtifacts.s3Object.getV1("task_artifact_s3_object_metadata_id")
|
|
32
32
|
*/
|
|
33
|
-
|
|
34
|
-
return core.HttpResponsePromise.fromPromise(this.
|
|
33
|
+
getV1(taskArtifactS3ObjectMetadataId, requestOptions) {
|
|
34
|
+
return core.HttpResponsePromise.fromPromise(this.__getV1(taskArtifactS3ObjectMetadataId, requestOptions));
|
|
35
35
|
}
|
|
36
|
-
|
|
36
|
+
__getV1(taskArtifactS3ObjectMetadataId, requestOptions) {
|
|
37
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
38
38
|
var _a, _b, _c, _d;
|
|
39
39
|
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
40
40
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
41
|
-
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/
|
|
41
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/s3_object/v1/${encodeURIComponent(taskArtifactS3ObjectMetadataId)}`),
|
|
42
42
|
method: "GET",
|
|
43
43
|
headers: _headers,
|
|
44
44
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -69,7 +69,7 @@ export class Blurhash {
|
|
|
69
69
|
rawResponse: _response.rawResponse,
|
|
70
70
|
});
|
|
71
71
|
case "timeout":
|
|
72
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /oort/task_artifacts/
|
|
72
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /oort/task_artifacts/s3_object/v1/{task_artifact_s3_object_metadata_id}.");
|
|
73
73
|
case "unknown":
|
|
74
74
|
throw new errors.ChrtError({
|
|
75
75
|
message: _response.error.errorMessage,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as environments from "../../../../../../environments.mjs";
|
|
5
|
+
import * as core from "../../../../../../core/index.mjs";
|
|
6
|
+
import * as Chrt from "../../../../../index.mjs";
|
|
7
|
+
export declare namespace S3ObjectMetadata {
|
|
8
|
+
interface Options {
|
|
9
|
+
environment?: core.Supplier<environments.ChrtEnvironment | string>;
|
|
10
|
+
/** Specify a custom URL to connect the client to. */
|
|
11
|
+
baseUrl?: core.Supplier<string>;
|
|
12
|
+
token?: core.Supplier<core.BearerToken | undefined>;
|
|
13
|
+
/** Additional headers to include in requests. */
|
|
14
|
+
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
15
|
+
fetcher?: core.FetchFunction;
|
|
16
|
+
}
|
|
17
|
+
interface RequestOptions {
|
|
18
|
+
/** The maximum time to wait for a response in seconds. */
|
|
19
|
+
timeoutInSeconds?: number;
|
|
20
|
+
/** The number of times to retry the request. Defaults to 2. */
|
|
21
|
+
maxRetries?: number;
|
|
22
|
+
/** A hook to abort the request. */
|
|
23
|
+
abortSignal?: AbortSignal;
|
|
24
|
+
/** Additional query string parameters to include in the request. */
|
|
25
|
+
queryParams?: Record<string, unknown>;
|
|
26
|
+
/** Additional headers to include in the request. */
|
|
27
|
+
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
export declare class S3ObjectMetadata {
|
|
31
|
+
protected readonly _options: S3ObjectMetadata.Options;
|
|
32
|
+
constructor(_options?: S3ObjectMetadata.Options);
|
|
33
|
+
/**
|
|
34
|
+
* Retrieves the metadata for a task artifact S3 object, including blurhash for placeholder loading. | authz_personas=[courier_driver, courier_org_operators, shipper_org_operators, forwarder_org_operators] | () -> (TaskArtifactS3ObjectMetadata1)
|
|
35
|
+
*
|
|
36
|
+
* @param {string} taskArtifactS3ObjectMetadataId
|
|
37
|
+
* @param {S3ObjectMetadata.RequestOptions} requestOptions - Request-specific configuration.
|
|
38
|
+
*
|
|
39
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* await client.taskArtifacts.s3ObjectMetadata.getV1("task_artifact_s3_object_metadata_id")
|
|
43
|
+
*/
|
|
44
|
+
getV1(taskArtifactS3ObjectMetadataId: string, requestOptions?: S3ObjectMetadata.RequestOptions): core.HttpResponsePromise<Chrt.TaskArtifactS3ObjectMetadata1>;
|
|
45
|
+
private __getV1;
|
|
46
|
+
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
47
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
5
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
6
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
7
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
8
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
9
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
10
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
import * as environments from "../../../../../../environments.mjs";
|
|
14
|
+
import * as core from "../../../../../../core/index.mjs";
|
|
15
|
+
import * as Chrt from "../../../../../index.mjs";
|
|
16
|
+
import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.mjs";
|
|
17
|
+
import * as errors from "../../../../../../errors/index.mjs";
|
|
18
|
+
export class S3ObjectMetadata {
|
|
19
|
+
constructor(_options = {}) {
|
|
20
|
+
this._options = _options;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Retrieves the metadata for a task artifact S3 object, including blurhash for placeholder loading. | authz_personas=[courier_driver, courier_org_operators, shipper_org_operators, forwarder_org_operators] | () -> (TaskArtifactS3ObjectMetadata1)
|
|
24
|
+
*
|
|
25
|
+
* @param {string} taskArtifactS3ObjectMetadataId
|
|
26
|
+
* @param {S3ObjectMetadata.RequestOptions} requestOptions - Request-specific configuration.
|
|
27
|
+
*
|
|
28
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
29
|
+
*
|
|
30
|
+
* @example
|
|
31
|
+
* await client.taskArtifacts.s3ObjectMetadata.getV1("task_artifact_s3_object_metadata_id")
|
|
32
|
+
*/
|
|
33
|
+
getV1(taskArtifactS3ObjectMetadataId, requestOptions) {
|
|
34
|
+
return core.HttpResponsePromise.fromPromise(this.__getV1(taskArtifactS3ObjectMetadataId, requestOptions));
|
|
35
|
+
}
|
|
36
|
+
__getV1(taskArtifactS3ObjectMetadataId, requestOptions) {
|
|
37
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
+
var _a, _b, _c, _d;
|
|
39
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
40
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
41
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `oort/task_artifacts/s3_object_metadata/v1/${encodeURIComponent(taskArtifactS3ObjectMetadataId)}`),
|
|
42
|
+
method: "GET",
|
|
43
|
+
headers: _headers,
|
|
44
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
45
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
46
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
47
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
48
|
+
});
|
|
49
|
+
if (_response.ok) {
|
|
50
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
51
|
+
}
|
|
52
|
+
if (_response.error.reason === "status-code") {
|
|
53
|
+
switch (_response.error.statusCode) {
|
|
54
|
+
case 422:
|
|
55
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
56
|
+
default:
|
|
57
|
+
throw new errors.ChrtError({
|
|
58
|
+
statusCode: _response.error.statusCode,
|
|
59
|
+
body: _response.error.body,
|
|
60
|
+
rawResponse: _response.rawResponse,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
switch (_response.error.reason) {
|
|
65
|
+
case "non-json":
|
|
66
|
+
throw new errors.ChrtError({
|
|
67
|
+
statusCode: _response.error.statusCode,
|
|
68
|
+
body: _response.error.rawBody,
|
|
69
|
+
rawResponse: _response.rawResponse,
|
|
70
|
+
});
|
|
71
|
+
case "timeout":
|
|
72
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /oort/task_artifacts/s3_object_metadata/v1/{task_artifact_s3_object_metadata_id}.");
|
|
73
|
+
case "unknown":
|
|
74
|
+
throw new errors.ChrtError({
|
|
75
|
+
message: _response.error.errorMessage,
|
|
76
|
+
rawResponse: _response.rawResponse,
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
_getAuthorizationHeader() {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
83
|
+
const bearer = yield core.Supplier.get(this._options.token);
|
|
84
|
+
if (bearer != null) {
|
|
85
|
+
return `Bearer ${bearer}`;
|
|
86
|
+
}
|
|
87
|
+
return undefined;
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/index.mjs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/index.mjs";
|