@chrt-inc/typescript-sdk 1.363.0 → 1.363.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Client.d.ts +6 -6
- package/dist/cjs/Client.js +36 -36
- package/dist/cjs/api/resources/billing/resources/lineItemGroups/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/billing/resources/lineItemGroups/client/Client.js +1 -1
- package/dist/cjs/api/resources/directoryEntries/client/Client.d.ts +99 -0
- package/dist/cjs/api/resources/directoryEntries/client/Client.js +364 -0
- package/dist/cjs/api/{types/ShipperContactClientCreate1.d.ts → resources/directoryEntries/client/requests/DirectoryEntryClientCreate1.d.ts} +11 -7
- package/dist/cjs/api/resources/{shipperContactInfo/client/requests/ShipperContactClientUpdate1.d.ts → directoryEntries/client/requests/DirectoryEntryClientUpdate1.d.ts} +2 -2
- package/dist/cjs/api/resources/directoryEntries/client/requests/index.d.ts +2 -0
- package/dist/cjs/api/resources/drivers/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/index.d.ts +3 -4
- package/dist/cjs/api/resources/index.js +4 -5
- package/dist/cjs/api/resources/notifications/client/Client.d.ts +12 -41
- package/dist/cjs/api/resources/notifications/client/Client.js +16 -169
- package/dist/cjs/api/resources/notifications/client/index.d.ts +0 -1
- package/dist/cjs/api/resources/notifications/client/index.js +0 -15
- package/dist/cjs/api/resources/notifications/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/index.js +1 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/Client.d.ts +77 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/Client.js +252 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/requests/NotificationIntentAdHocClientCreate1.d.ts +18 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/adHoc/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/Client.d.ts +209 -0
- package/dist/cjs/api/resources/{shipperContactInfo → notifications/resources/groups}/client/Client.js +305 -118
- package/dist/cjs/api/resources/notifications/resources/groups/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/requests/GroupsUpdateNameV1Request.d.ts +12 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/requests/NotificationGroupClientCreate1.d.ts +14 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/requests/index.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/resources/groups/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/notifications/resources/groups/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/groups/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/index.d.ts +7 -0
- package/dist/cjs/api/resources/notifications/resources/index.js +46 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/Client.d.ts +67 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/Client.js +232 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/requests/UserNotificationPreferencesUpdateRequest.d.ts +15 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/userPreferences/index.js +17 -0
- package/dist/cjs/api/resources/notifications/resources/webhookSetup/client/Client.d.ts +74 -0
- package/dist/cjs/api/resources/notifications/resources/webhookSetup/client/Client.js +271 -0
- package/dist/cjs/api/resources/notifications/resources/webhookSetup/client/index.js +2 -0
- package/dist/cjs/api/resources/notifications/resources/webhookSetup/index.d.ts +1 -0
- package/dist/cjs/api/resources/notifications/resources/webhookSetup/index.js +17 -0
- package/dist/cjs/api/types/BillingLineItemGroupMessageWebhookPayload.d.ts +13 -0
- package/dist/cjs/api/types/BillingLineItemGroupS3ObjectAddedWebhookPayload.d.ts +13 -0
- package/dist/cjs/api/types/BillingLineItemGroupS3ObjectAddedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/BillingStatementOpenedWebhookPayload.d.ts +11 -0
- package/dist/cjs/api/types/BillingStatementOpenedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/BillingStatementPaidWebhookPayload.d.ts +11 -0
- package/dist/cjs/api/types/BillingStatementPaidWebhookPayload.js +5 -0
- package/dist/cjs/api/types/{ShipperContact1.d.ts → DirectoryEntry1.d.ts} +4 -6
- package/dist/cjs/api/types/DirectoryEntry1.js +5 -0
- package/dist/cjs/api/types/{Driver1.d.ts → Driver1Input.d.ts} +1 -1
- package/dist/cjs/api/types/Driver1Input.js +5 -0
- package/dist/cjs/api/types/Driver1Output.d.ts +27 -0
- package/dist/cjs/api/types/Driver1Output.js +5 -0
- package/dist/cjs/api/types/NotificationChannelsEnum.d.ts +12 -0
- package/dist/cjs/api/types/NotificationChannelsEnum.js +11 -0
- package/dist/cjs/api/types/NotificationEventsForAdHocEnum.d.ts +14 -0
- package/dist/cjs/api/types/NotificationEventsForAdHocEnum.js +10 -0
- package/dist/cjs/api/types/NotificationEventsForOrgsEnum.d.ts +29 -0
- package/dist/cjs/api/types/NotificationEventsForOrgsEnum.js +26 -0
- package/dist/cjs/api/types/NotificationEventsForUsersEnum.d.ts +20 -0
- package/dist/cjs/api/types/NotificationEventsForUsersEnum.js +15 -0
- package/dist/cjs/api/types/NotificationGroup1.d.ts +18 -0
- package/dist/cjs/api/types/NotificationGroup1.js +5 -0
- package/dist/cjs/api/types/NotificationGroupLimitedForDriver1.d.ts +23 -0
- package/dist/cjs/api/types/NotificationGroupLimitedForDriver1.js +5 -0
- package/dist/cjs/api/types/NotificationIntentAdHoc1.d.ts +18 -0
- package/dist/cjs/api/types/NotificationIntentAdHoc1.js +5 -0
- package/dist/cjs/api/types/NotificationUserPreferences1.d.ts +15 -0
- package/dist/cjs/api/types/NotificationUserPreferences1.js +5 -0
- package/dist/cjs/api/types/OrderAndTaskGroupExpandedReq.d.ts +1 -1
- package/dist/cjs/api/types/OrgMembersAndDrivers.d.ts +1 -1
- package/dist/cjs/api/types/OrgPrivateData1.d.ts +2 -0
- package/dist/cjs/api/types/ShippingOrderCancelledWebhookPayload.d.ts +11 -0
- package/dist/cjs/api/types/ShippingOrderCancelledWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingOrderCompletedWebhookPayload.d.ts +11 -0
- package/dist/cjs/api/types/ShippingOrderCompletedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingOrderStagedWebhookPayload.d.ts +11 -0
- package/dist/cjs/api/types/ShippingOrderStagedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskAddedWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskAddedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskCompletedWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskCompletedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskDeletedWebhookPayload.d.ts +14 -0
- package/dist/cjs/api/types/ShippingTaskDeletedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupCourierOrgAssignedWebhookPayload.d.ts +14 -0
- package/dist/cjs/api/types/ShippingTaskGroupCourierOrgAssignedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupDriverAssignedWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskGroupDriverAssignedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.d.ts +16 -0
- package/dist/cjs/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupInProgressWebhookPayload.d.ts +13 -0
- package/dist/cjs/api/types/ShippingTaskGroupInProgressWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupMessageWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskGroupMessageWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupS3ObjectAddedWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskGroupS3ObjectAddedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskGroupTasksOrderingUpdatedWebhookPayload.d.ts +14 -0
- package/dist/cjs/api/types/ShippingTaskGroupTasksOrderingUpdatedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/ShippingTaskSkippedWebhookPayload.d.ts +15 -0
- package/dist/cjs/api/types/ShippingTaskSkippedWebhookPayload.js +5 -0
- package/dist/cjs/api/types/Statement1.d.ts +1 -1
- package/dist/cjs/api/types/{Task1.d.ts → Task1Input.d.ts} +4 -8
- package/dist/cjs/api/types/Task1Input.js +5 -0
- package/dist/cjs/api/types/Task1Output.d.ts +36 -0
- package/dist/cjs/api/types/Task1Output.js +5 -0
- package/dist/cjs/api/types/TaskClientCreate1.d.ts +1 -1
- package/dist/cjs/api/types/TaskClientUpdate1.d.ts +1 -1
- package/dist/cjs/api/types/TaskExpanded.d.ts +2 -2
- package/dist/cjs/api/types/TaskGroupExpanded.d.ts +1 -1
- package/dist/cjs/api/types/UserPublicData1.d.ts +0 -1
- package/dist/cjs/api/types/WebhookAppPortalAccessRes.d.ts +10 -0
- package/dist/cjs/api/types/WebhookAppPortalAccessRes.js +5 -0
- package/dist/cjs/api/types/index.d.ts +32 -6
- package/dist/cjs/api/types/index.js +32 -6
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.d.mts +6 -6
- package/dist/esm/Client.mjs +10 -10
- package/dist/esm/api/resources/billing/resources/lineItemGroups/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/billing/resources/lineItemGroups/client/Client.mjs +1 -1
- package/dist/esm/api/resources/directoryEntries/client/Client.d.mts +99 -0
- package/dist/esm/api/resources/directoryEntries/client/Client.mjs +327 -0
- package/dist/esm/api/{types/ShipperContactClientCreate1.d.mts → resources/directoryEntries/client/requests/DirectoryEntryClientCreate1.d.mts} +11 -7
- package/dist/esm/api/resources/{shipperContactInfo/client/requests/ShipperContactClientUpdate1.d.mts → directoryEntries/client/requests/DirectoryEntryClientUpdate1.d.mts} +2 -2
- package/dist/esm/api/resources/directoryEntries/client/requests/index.d.mts +2 -0
- package/dist/esm/api/resources/drivers/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/index.d.mts +3 -4
- package/dist/esm/api/resources/index.mjs +3 -4
- package/dist/esm/api/resources/notifications/client/Client.d.mts +12 -41
- package/dist/esm/api/resources/notifications/client/Client.mjs +16 -136
- package/dist/esm/api/resources/notifications/client/index.d.mts +0 -1
- package/dist/esm/api/resources/notifications/client/index.mjs +1 -1
- package/dist/esm/api/resources/notifications/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/Client.d.mts +77 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/Client.mjs +215 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/index.d.mts +2 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/requests/NotificationIntentAdHocClientCreate1.d.mts +18 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/adHoc/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/Client.d.mts +209 -0
- package/dist/esm/api/resources/{shipperContactInfo → notifications/resources/groups}/client/Client.mjs +303 -116
- package/dist/esm/api/resources/notifications/resources/groups/client/index.d.mts +2 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/requests/GroupsUpdateNameV1Request.d.mts +12 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/requests/NotificationGroupClientCreate1.d.mts +14 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/requests/index.d.mts +2 -0
- package/dist/esm/api/resources/notifications/resources/groups/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/groups/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/groups/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/index.d.mts +7 -0
- package/dist/esm/api/resources/notifications/resources/index.mjs +7 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/Client.d.mts +67 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/Client.mjs +195 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/index.d.mts +2 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/requests/UserNotificationPreferencesUpdateRequest.d.mts +15 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/userPreferences/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/client/Client.d.mts +74 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/client/Client.mjs +234 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/client/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/client/index.mjs +1 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/index.d.mts +1 -0
- package/dist/esm/api/resources/notifications/resources/webhookSetup/index.mjs +1 -0
- package/dist/esm/api/types/BillingLineItemGroupMessageWebhookPayload.d.mts +13 -0
- package/dist/esm/api/types/BillingLineItemGroupS3ObjectAddedWebhookPayload.d.mts +13 -0
- package/dist/esm/api/types/BillingLineItemGroupS3ObjectAddedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/BillingStatementOpenedWebhookPayload.d.mts +11 -0
- package/dist/esm/api/types/BillingStatementOpenedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/BillingStatementPaidWebhookPayload.d.mts +11 -0
- package/dist/esm/api/types/BillingStatementPaidWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/{ShipperContact1.d.mts → DirectoryEntry1.d.mts} +4 -6
- package/dist/esm/api/types/DirectoryEntry1.mjs +4 -0
- package/dist/esm/api/types/{Driver1.d.mts → Driver1Input.d.mts} +1 -1
- package/dist/esm/api/types/Driver1Input.mjs +4 -0
- package/dist/esm/api/types/Driver1Output.d.mts +27 -0
- package/dist/esm/api/types/Driver1Output.mjs +4 -0
- package/dist/esm/api/types/NotificationChannelsEnum.d.mts +12 -0
- package/dist/esm/api/types/NotificationChannelsEnum.mjs +8 -0
- package/dist/esm/api/types/NotificationEventsForAdHocEnum.d.mts +14 -0
- package/dist/esm/api/types/NotificationEventsForAdHocEnum.mjs +7 -0
- package/dist/esm/api/types/NotificationEventsForOrgsEnum.d.mts +29 -0
- package/dist/esm/api/types/NotificationEventsForOrgsEnum.mjs +23 -0
- package/dist/esm/api/types/NotificationEventsForUsersEnum.d.mts +20 -0
- package/dist/esm/api/types/NotificationEventsForUsersEnum.mjs +12 -0
- package/dist/esm/api/types/NotificationGroup1.d.mts +18 -0
- package/dist/esm/api/types/NotificationGroup1.mjs +4 -0
- package/dist/esm/api/types/NotificationGroupLimitedForDriver1.d.mts +23 -0
- package/dist/esm/api/types/NotificationGroupLimitedForDriver1.mjs +4 -0
- package/dist/esm/api/types/NotificationIntentAdHoc1.d.mts +18 -0
- package/dist/esm/api/types/NotificationIntentAdHoc1.mjs +4 -0
- package/dist/esm/api/types/NotificationUserPreferences1.d.mts +15 -0
- package/dist/esm/api/types/NotificationUserPreferences1.mjs +4 -0
- package/dist/esm/api/types/OrderAndTaskGroupExpandedReq.d.mts +1 -1
- package/dist/esm/api/types/OrgMembersAndDrivers.d.mts +1 -1
- package/dist/esm/api/types/OrgPrivateData1.d.mts +2 -0
- package/dist/esm/api/types/ShippingOrderCancelledWebhookPayload.d.mts +11 -0
- package/dist/esm/api/types/ShippingOrderCancelledWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingOrderCompletedWebhookPayload.d.mts +11 -0
- package/dist/esm/api/types/ShippingOrderCompletedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingOrderStagedWebhookPayload.d.mts +11 -0
- package/dist/esm/api/types/ShippingOrderStagedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskAddedWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskAddedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskCompletedWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskCompletedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskDeletedWebhookPayload.d.mts +14 -0
- package/dist/esm/api/types/ShippingTaskDeletedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupCourierOrgAssignedWebhookPayload.d.mts +14 -0
- package/dist/esm/api/types/ShippingTaskGroupCourierOrgAssignedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupDriverAssignedWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskGroupDriverAssignedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.d.mts +16 -0
- package/dist/esm/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupInProgressWebhookPayload.d.mts +13 -0
- package/dist/esm/api/types/ShippingTaskGroupInProgressWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupMessageWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskGroupMessageWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupS3ObjectAddedWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskGroupS3ObjectAddedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskGroupTasksOrderingUpdatedWebhookPayload.d.mts +14 -0
- package/dist/esm/api/types/ShippingTaskGroupTasksOrderingUpdatedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/ShippingTaskSkippedWebhookPayload.d.mts +15 -0
- package/dist/esm/api/types/ShippingTaskSkippedWebhookPayload.mjs +4 -0
- package/dist/esm/api/types/Statement1.d.mts +1 -1
- package/dist/esm/api/types/{Task1.d.mts → Task1Input.d.mts} +4 -8
- package/dist/esm/api/types/Task1Input.mjs +4 -0
- package/dist/esm/api/types/Task1Output.d.mts +36 -0
- package/dist/esm/api/types/Task1Output.mjs +4 -0
- package/dist/esm/api/types/TaskClientCreate1.d.mts +1 -1
- package/dist/esm/api/types/TaskClientUpdate1.d.mts +1 -1
- package/dist/esm/api/types/TaskExpanded.d.mts +2 -2
- package/dist/esm/api/types/TaskGroupExpanded.d.mts +1 -1
- package/dist/esm/api/types/UserPublicData1.d.mts +0 -1
- package/dist/esm/api/types/WebhookAppPortalAccessRes.d.mts +10 -0
- package/dist/esm/api/types/WebhookAppPortalAccessRes.mjs +4 -0
- package/dist/esm/api/types/index.d.mts +32 -6
- package/dist/esm/api/types/index.mjs +32 -6
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +1786 -754
- package/dist/cjs/api/resources/notifications/client/requests/NotificationReq.d.ts +0 -17
- package/dist/cjs/api/resources/notifications/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/shipperContactInfo/client/Client.d.ts +0 -163
- package/dist/cjs/api/resources/shipperContactInfo/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/types/ChrtEmailRecipient.d.ts +0 -10
- package/dist/cjs/api/types/ChrtEmailRecipient.js +0 -12
- package/dist/cjs/api/types/NotificationRes.d.ts +0 -10
- package/dist/esm/api/resources/notifications/client/requests/NotificationReq.d.mts +0 -17
- package/dist/esm/api/resources/notifications/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/shipperContactInfo/client/Client.d.mts +0 -163
- package/dist/esm/api/resources/shipperContactInfo/client/requests/index.d.mts +0 -1
- package/dist/esm/api/types/ChrtEmailRecipient.d.mts +0 -10
- package/dist/esm/api/types/ChrtEmailRecipient.mjs +0 -9
- package/dist/esm/api/types/NotificationRes.d.mts +0 -10
- /package/dist/cjs/api/resources/{shipperContactInfo → directoryEntries}/client/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{shipperContactInfo → directoryEntries}/client/index.js +0 -0
- /package/dist/cjs/api/resources/{notifications/client/requests/NotificationReq.js → directoryEntries/client/requests/DirectoryEntryClientCreate1.js} +0 -0
- /package/dist/cjs/api/resources/{shipperContactInfo/client/requests/ShipperContactClientUpdate1.js → directoryEntries/client/requests/DirectoryEntryClientUpdate1.js} +0 -0
- /package/dist/cjs/api/resources/{notifications → directoryEntries}/client/requests/index.js +0 -0
- /package/dist/cjs/api/resources/{shipperContactInfo → directoryEntries}/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{shipperContactInfo → directoryEntries}/index.js +0 -0
- /package/dist/cjs/api/{types/Driver1.js → resources/notifications/resources/adHoc/client/requests/NotificationIntentAdHocClientCreate1.js} +0 -0
- /package/dist/cjs/api/resources/{shipperContactInfo → notifications/resources/adHoc}/client/requests/index.js +0 -0
- /package/dist/cjs/api/{types/NotificationRes.js → resources/notifications/resources/groups/client/requests/GroupsUpdateNameV1Request.js} +0 -0
- /package/dist/cjs/api/{types/ShipperContact1.js → resources/notifications/resources/groups/client/requests/NotificationGroupClientCreate1.js} +0 -0
- /package/dist/cjs/api/{types/ShipperContactClientCreate1.js → resources/notifications/resources/userPreferences/client/requests/UserNotificationPreferencesUpdateRequest.js} +0 -0
- /package/dist/{esm/api/resources/notifications/client/requests/index.mjs → cjs/api/resources/notifications/resources/webhookSetup/client/index.d.ts} +0 -0
- /package/dist/cjs/api/types/{Task1.js → BillingLineItemGroupMessageWebhookPayload.js} +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo → directoryEntries}/client/index.d.mts +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo → directoryEntries}/client/index.mjs +0 -0
- /package/dist/esm/api/resources/{notifications/client/requests/NotificationReq.mjs → directoryEntries/client/requests/DirectoryEntryClientCreate1.mjs} +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo/client/requests/ShipperContactClientUpdate1.mjs → directoryEntries/client/requests/DirectoryEntryClientUpdate1.mjs} +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo → directoryEntries}/client/requests/index.mjs +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo → directoryEntries}/index.d.mts +0 -0
- /package/dist/esm/api/resources/{shipperContactInfo → directoryEntries}/index.mjs +0 -0
- /package/dist/esm/api/{types/Driver1.mjs → resources/notifications/resources/adHoc/client/requests/NotificationIntentAdHocClientCreate1.mjs} +0 -0
- /package/dist/esm/api/{types/NotificationRes.mjs → resources/notifications/resources/groups/client/requests/GroupsUpdateNameV1Request.mjs} +0 -0
- /package/dist/esm/api/{types/ShipperContact1.mjs → resources/notifications/resources/groups/client/requests/NotificationGroupClientCreate1.mjs} +0 -0
- /package/dist/esm/api/{types/ShipperContactClientCreate1.mjs → resources/notifications/resources/userPreferences/client/requests/UserNotificationPreferencesUpdateRequest.mjs} +0 -0
- /package/dist/esm/api/types/{Task1.mjs → BillingLineItemGroupMessageWebhookPayload.mjs} +0 -0
|
@@ -2,184 +2,31 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* This file was auto-generated by Fern from our API Definition.
|
|
4
4
|
*/
|
|
5
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
-
}
|
|
11
|
-
Object.defineProperty(o, k2, desc);
|
|
12
|
-
}) : (function(o, m, k, k2) {
|
|
13
|
-
if (k2 === undefined) k2 = k;
|
|
14
|
-
o[k2] = m[k];
|
|
15
|
-
}));
|
|
16
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
-
}) : function(o, v) {
|
|
19
|
-
o["default"] = v;
|
|
20
|
-
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
-
var ownKeys = function(o) {
|
|
23
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
-
var ar = [];
|
|
25
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
-
return ar;
|
|
27
|
-
};
|
|
28
|
-
return ownKeys(o);
|
|
29
|
-
};
|
|
30
|
-
return function (mod) {
|
|
31
|
-
if (mod && mod.__esModule) return mod;
|
|
32
|
-
var result = {};
|
|
33
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
-
__setModuleDefault(result, mod);
|
|
35
|
-
return result;
|
|
36
|
-
};
|
|
37
|
-
})();
|
|
38
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
39
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
40
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
41
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
42
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
43
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
44
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
45
|
-
});
|
|
46
|
-
};
|
|
47
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
6
|
exports.Notifications = void 0;
|
|
49
|
-
const
|
|
50
|
-
const
|
|
51
|
-
const
|
|
52
|
-
const
|
|
53
|
-
const Chrt = __importStar(require("../../../index.js"));
|
|
7
|
+
const Client_js_1 = require("../resources/adHoc/client/Client.js");
|
|
8
|
+
const Client_js_2 = require("../resources/groups/client/Client.js");
|
|
9
|
+
const Client_js_3 = require("../resources/userPreferences/client/Client.js");
|
|
10
|
+
const Client_js_4 = require("../resources/webhookSetup/client/Client.js");
|
|
54
11
|
class Notifications {
|
|
55
12
|
constructor(_options = {}) {
|
|
56
13
|
this._options = _options;
|
|
57
14
|
}
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
* @param {Notifications.RequestOptions} requestOptions - Request-specific configuration.
|
|
62
|
-
*
|
|
63
|
-
* @example
|
|
64
|
-
* await client.notifications.getNotificationV1()
|
|
65
|
-
*/
|
|
66
|
-
getNotificationV1(requestOptions) {
|
|
67
|
-
return core.HttpResponsePromise.fromPromise(this.__getNotificationV1(requestOptions));
|
|
68
|
-
}
|
|
69
|
-
__getNotificationV1(requestOptions) {
|
|
70
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
71
|
-
var _a, _b, _c, _d;
|
|
72
|
-
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
73
|
-
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
74
|
-
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, "notifications/v1"),
|
|
75
|
-
method: "GET",
|
|
76
|
-
headers: _headers,
|
|
77
|
-
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
78
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
79
|
-
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
80
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
81
|
-
});
|
|
82
|
-
if (_response.ok) {
|
|
83
|
-
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
84
|
-
}
|
|
85
|
-
if (_response.error.reason === "status-code") {
|
|
86
|
-
throw new errors.ChrtError({
|
|
87
|
-
statusCode: _response.error.statusCode,
|
|
88
|
-
body: _response.error.body,
|
|
89
|
-
rawResponse: _response.rawResponse,
|
|
90
|
-
});
|
|
91
|
-
}
|
|
92
|
-
switch (_response.error.reason) {
|
|
93
|
-
case "non-json":
|
|
94
|
-
throw new errors.ChrtError({
|
|
95
|
-
statusCode: _response.error.statusCode,
|
|
96
|
-
body: _response.error.rawBody,
|
|
97
|
-
rawResponse: _response.rawResponse,
|
|
98
|
-
});
|
|
99
|
-
case "timeout":
|
|
100
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /notifications/v1.");
|
|
101
|
-
case "unknown":
|
|
102
|
-
throw new errors.ChrtError({
|
|
103
|
-
message: _response.error.errorMessage,
|
|
104
|
-
rawResponse: _response.rawResponse,
|
|
105
|
-
});
|
|
106
|
-
}
|
|
107
|
-
});
|
|
15
|
+
get adHoc() {
|
|
16
|
+
var _a;
|
|
17
|
+
return ((_a = this._adHoc) !== null && _a !== void 0 ? _a : (this._adHoc = new Client_js_1.AdHoc(this._options)));
|
|
108
18
|
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
* @param {Chrt.NotificationReq} request
|
|
113
|
-
* @param {Notifications.RequestOptions} requestOptions - Request-specific configuration.
|
|
114
|
-
*
|
|
115
|
-
* @throws {@link Chrt.UnprocessableEntityError}
|
|
116
|
-
*
|
|
117
|
-
* @example
|
|
118
|
-
* await client.notifications.createNotificationV1({
|
|
119
|
-
* recipient: "aaron",
|
|
120
|
-
* name: "name",
|
|
121
|
-
* message: "message"
|
|
122
|
-
* })
|
|
123
|
-
*/
|
|
124
|
-
createNotificationV1(request, requestOptions) {
|
|
125
|
-
return core.HttpResponsePromise.fromPromise(this.__createNotificationV1(request, requestOptions));
|
|
19
|
+
get groups() {
|
|
20
|
+
var _a;
|
|
21
|
+
return ((_a = this._groups) !== null && _a !== void 0 ? _a : (this._groups = new Client_js_2.Groups(this._options)));
|
|
126
22
|
}
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
131
|
-
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
132
|
-
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, "notifications/v1"),
|
|
133
|
-
method: "POST",
|
|
134
|
-
headers: _headers,
|
|
135
|
-
contentType: "application/json",
|
|
136
|
-
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
137
|
-
requestType: "json",
|
|
138
|
-
body: request,
|
|
139
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
140
|
-
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
141
|
-
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
142
|
-
});
|
|
143
|
-
if (_response.ok) {
|
|
144
|
-
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
145
|
-
}
|
|
146
|
-
if (_response.error.reason === "status-code") {
|
|
147
|
-
switch (_response.error.statusCode) {
|
|
148
|
-
case 422:
|
|
149
|
-
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
150
|
-
default:
|
|
151
|
-
throw new errors.ChrtError({
|
|
152
|
-
statusCode: _response.error.statusCode,
|
|
153
|
-
body: _response.error.body,
|
|
154
|
-
rawResponse: _response.rawResponse,
|
|
155
|
-
});
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
switch (_response.error.reason) {
|
|
159
|
-
case "non-json":
|
|
160
|
-
throw new errors.ChrtError({
|
|
161
|
-
statusCode: _response.error.statusCode,
|
|
162
|
-
body: _response.error.rawBody,
|
|
163
|
-
rawResponse: _response.rawResponse,
|
|
164
|
-
});
|
|
165
|
-
case "timeout":
|
|
166
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /notifications/v1.");
|
|
167
|
-
case "unknown":
|
|
168
|
-
throw new errors.ChrtError({
|
|
169
|
-
message: _response.error.errorMessage,
|
|
170
|
-
rawResponse: _response.rawResponse,
|
|
171
|
-
});
|
|
172
|
-
}
|
|
173
|
-
});
|
|
23
|
+
get userPreferences() {
|
|
24
|
+
var _a;
|
|
25
|
+
return ((_a = this._userPreferences) !== null && _a !== void 0 ? _a : (this._userPreferences = new Client_js_3.UserPreferences(this._options)));
|
|
174
26
|
}
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
if (bearer != null) {
|
|
179
|
-
return `Bearer ${bearer}`;
|
|
180
|
-
}
|
|
181
|
-
return undefined;
|
|
182
|
-
});
|
|
27
|
+
get webhookSetup() {
|
|
28
|
+
var _a;
|
|
29
|
+
return ((_a = this._webhookSetup) !== null && _a !== void 0 ? _a : (this._webhookSetup = new Client_js_4.WebhookSetup(this._options)));
|
|
183
30
|
}
|
|
184
31
|
}
|
|
185
32
|
exports.Notifications = Notifications;
|
|
@@ -1,17 +1,2 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./requests/index.js"), exports);
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as environments from "../../../../../../environments.js";
|
|
5
|
+
import * as core from "../../../../../../core/index.js";
|
|
6
|
+
import * as Chrt from "../../../../../index.js";
|
|
7
|
+
export declare namespace AdHoc {
|
|
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 AdHoc {
|
|
31
|
+
protected readonly _options: AdHoc.Options;
|
|
32
|
+
constructor(_options?: AdHoc.Options);
|
|
33
|
+
/**
|
|
34
|
+
* Lists all ad-hoc notification intents for an order. | authz: min_org_role=operator | () -> (list[NotificationIntentAdHoc1])
|
|
35
|
+
*
|
|
36
|
+
* @param {string} orderId
|
|
37
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
38
|
+
*
|
|
39
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* await client.notifications.adHoc.listByOrderIdV1("order_id")
|
|
43
|
+
*/
|
|
44
|
+
listByOrderIdV1(orderId: string, requestOptions?: AdHoc.RequestOptions): core.HttpResponsePromise<Chrt.NotificationIntentAdHoc1[]>;
|
|
45
|
+
private __listByOrderIdV1;
|
|
46
|
+
/**
|
|
47
|
+
* Creates a new ad-hoc notification intent for an order. | authz: min_org_role=operator | (NotificationIntentAdHocClientCreate1) -> (PydanticObjectId)
|
|
48
|
+
*
|
|
49
|
+
* @param {string} orderId
|
|
50
|
+
* @param {Chrt.notifications.NotificationIntentAdHocClientCreate1} request
|
|
51
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
52
|
+
*
|
|
53
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* await client.notifications.adHoc.createV1("order_id", {
|
|
57
|
+
* schema_version: 1,
|
|
58
|
+
* directory_entry_id: "directory_entry_id"
|
|
59
|
+
* })
|
|
60
|
+
*/
|
|
61
|
+
createV1(orderId: string, request: Chrt.notifications.NotificationIntentAdHocClientCreate1, requestOptions?: AdHoc.RequestOptions): core.HttpResponsePromise<string>;
|
|
62
|
+
private __createV1;
|
|
63
|
+
/**
|
|
64
|
+
* Deletes an ad-hoc notification intent. | authz: min_org_role=operator | () -> (bool)
|
|
65
|
+
*
|
|
66
|
+
* @param {string} adHocId
|
|
67
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
|
+
*
|
|
69
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* await client.notifications.adHoc.deleteV1("ad_hoc_id")
|
|
73
|
+
*/
|
|
74
|
+
deleteV1(adHocId: string, requestOptions?: AdHoc.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
75
|
+
private __deleteV1;
|
|
76
|
+
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
77
|
+
}
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
38
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
39
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
40
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
41
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
42
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
43
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
44
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
45
|
+
});
|
|
46
|
+
};
|
|
47
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
|
+
exports.AdHoc = void 0;
|
|
49
|
+
const environments = __importStar(require("../../../../../../environments.js"));
|
|
50
|
+
const core = __importStar(require("../../../../../../core/index.js"));
|
|
51
|
+
const Chrt = __importStar(require("../../../../../index.js"));
|
|
52
|
+
const headers_js_1 = require("../../../../../../core/headers.js");
|
|
53
|
+
const errors = __importStar(require("../../../../../../errors/index.js"));
|
|
54
|
+
class AdHoc {
|
|
55
|
+
constructor(_options = {}) {
|
|
56
|
+
this._options = _options;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Lists all ad-hoc notification intents for an order. | authz: min_org_role=operator | () -> (list[NotificationIntentAdHoc1])
|
|
60
|
+
*
|
|
61
|
+
* @param {string} orderId
|
|
62
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
63
|
+
*
|
|
64
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
65
|
+
*
|
|
66
|
+
* @example
|
|
67
|
+
* await client.notifications.adHoc.listByOrderIdV1("order_id")
|
|
68
|
+
*/
|
|
69
|
+
listByOrderIdV1(orderId, requestOptions) {
|
|
70
|
+
return core.HttpResponsePromise.fromPromise(this.__listByOrderIdV1(orderId, requestOptions));
|
|
71
|
+
}
|
|
72
|
+
__listByOrderIdV1(orderId, requestOptions) {
|
|
73
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
74
|
+
var _a, _b, _c, _d;
|
|
75
|
+
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
76
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
77
|
+
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, `notifications/ad_hoc/list_by_order_id/v1/${encodeURIComponent(orderId)}`),
|
|
78
|
+
method: "GET",
|
|
79
|
+
headers: _headers,
|
|
80
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
81
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
82
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
83
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
84
|
+
});
|
|
85
|
+
if (_response.ok) {
|
|
86
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
87
|
+
}
|
|
88
|
+
if (_response.error.reason === "status-code") {
|
|
89
|
+
switch (_response.error.statusCode) {
|
|
90
|
+
case 422:
|
|
91
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
92
|
+
default:
|
|
93
|
+
throw new errors.ChrtError({
|
|
94
|
+
statusCode: _response.error.statusCode,
|
|
95
|
+
body: _response.error.body,
|
|
96
|
+
rawResponse: _response.rawResponse,
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
switch (_response.error.reason) {
|
|
101
|
+
case "non-json":
|
|
102
|
+
throw new errors.ChrtError({
|
|
103
|
+
statusCode: _response.error.statusCode,
|
|
104
|
+
body: _response.error.rawBody,
|
|
105
|
+
rawResponse: _response.rawResponse,
|
|
106
|
+
});
|
|
107
|
+
case "timeout":
|
|
108
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /notifications/ad_hoc/list_by_order_id/v1/{order_id}.");
|
|
109
|
+
case "unknown":
|
|
110
|
+
throw new errors.ChrtError({
|
|
111
|
+
message: _response.error.errorMessage,
|
|
112
|
+
rawResponse: _response.rawResponse,
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Creates a new ad-hoc notification intent for an order. | authz: min_org_role=operator | (NotificationIntentAdHocClientCreate1) -> (PydanticObjectId)
|
|
119
|
+
*
|
|
120
|
+
* @param {string} orderId
|
|
121
|
+
* @param {Chrt.notifications.NotificationIntentAdHocClientCreate1} request
|
|
122
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
123
|
+
*
|
|
124
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
125
|
+
*
|
|
126
|
+
* @example
|
|
127
|
+
* await client.notifications.adHoc.createV1("order_id", {
|
|
128
|
+
* schema_version: 1,
|
|
129
|
+
* directory_entry_id: "directory_entry_id"
|
|
130
|
+
* })
|
|
131
|
+
*/
|
|
132
|
+
createV1(orderId, request, requestOptions) {
|
|
133
|
+
return core.HttpResponsePromise.fromPromise(this.__createV1(orderId, request, requestOptions));
|
|
134
|
+
}
|
|
135
|
+
__createV1(orderId, request, requestOptions) {
|
|
136
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
137
|
+
var _a, _b, _c, _d;
|
|
138
|
+
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
139
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
140
|
+
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, `notifications/ad_hoc/create/v1/${encodeURIComponent(orderId)}`),
|
|
141
|
+
method: "POST",
|
|
142
|
+
headers: _headers,
|
|
143
|
+
contentType: "application/json",
|
|
144
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
145
|
+
requestType: "json",
|
|
146
|
+
body: request,
|
|
147
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
148
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
149
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
150
|
+
});
|
|
151
|
+
if (_response.ok) {
|
|
152
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
153
|
+
}
|
|
154
|
+
if (_response.error.reason === "status-code") {
|
|
155
|
+
switch (_response.error.statusCode) {
|
|
156
|
+
case 422:
|
|
157
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
158
|
+
default:
|
|
159
|
+
throw new errors.ChrtError({
|
|
160
|
+
statusCode: _response.error.statusCode,
|
|
161
|
+
body: _response.error.body,
|
|
162
|
+
rawResponse: _response.rawResponse,
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
switch (_response.error.reason) {
|
|
167
|
+
case "non-json":
|
|
168
|
+
throw new errors.ChrtError({
|
|
169
|
+
statusCode: _response.error.statusCode,
|
|
170
|
+
body: _response.error.rawBody,
|
|
171
|
+
rawResponse: _response.rawResponse,
|
|
172
|
+
});
|
|
173
|
+
case "timeout":
|
|
174
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /notifications/ad_hoc/create/v1/{order_id}.");
|
|
175
|
+
case "unknown":
|
|
176
|
+
throw new errors.ChrtError({
|
|
177
|
+
message: _response.error.errorMessage,
|
|
178
|
+
rawResponse: _response.rawResponse,
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
});
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* Deletes an ad-hoc notification intent. | authz: min_org_role=operator | () -> (bool)
|
|
185
|
+
*
|
|
186
|
+
* @param {string} adHocId
|
|
187
|
+
* @param {AdHoc.RequestOptions} requestOptions - Request-specific configuration.
|
|
188
|
+
*
|
|
189
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
190
|
+
*
|
|
191
|
+
* @example
|
|
192
|
+
* await client.notifications.adHoc.deleteV1("ad_hoc_id")
|
|
193
|
+
*/
|
|
194
|
+
deleteV1(adHocId, requestOptions) {
|
|
195
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteV1(adHocId, requestOptions));
|
|
196
|
+
}
|
|
197
|
+
__deleteV1(adHocId, requestOptions) {
|
|
198
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
199
|
+
var _a, _b, _c, _d;
|
|
200
|
+
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
201
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
202
|
+
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, `notifications/ad_hoc/delete/v1/${encodeURIComponent(adHocId)}`),
|
|
203
|
+
method: "DELETE",
|
|
204
|
+
headers: _headers,
|
|
205
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
206
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
207
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
208
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
209
|
+
});
|
|
210
|
+
if (_response.ok) {
|
|
211
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
212
|
+
}
|
|
213
|
+
if (_response.error.reason === "status-code") {
|
|
214
|
+
switch (_response.error.statusCode) {
|
|
215
|
+
case 422:
|
|
216
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
217
|
+
default:
|
|
218
|
+
throw new errors.ChrtError({
|
|
219
|
+
statusCode: _response.error.statusCode,
|
|
220
|
+
body: _response.error.body,
|
|
221
|
+
rawResponse: _response.rawResponse,
|
|
222
|
+
});
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
switch (_response.error.reason) {
|
|
226
|
+
case "non-json":
|
|
227
|
+
throw new errors.ChrtError({
|
|
228
|
+
statusCode: _response.error.statusCode,
|
|
229
|
+
body: _response.error.rawBody,
|
|
230
|
+
rawResponse: _response.rawResponse,
|
|
231
|
+
});
|
|
232
|
+
case "timeout":
|
|
233
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /notifications/ad_hoc/delete/v1/{ad_hoc_id}.");
|
|
234
|
+
case "unknown":
|
|
235
|
+
throw new errors.ChrtError({
|
|
236
|
+
message: _response.error.errorMessage,
|
|
237
|
+
rawResponse: _response.rawResponse,
|
|
238
|
+
});
|
|
239
|
+
}
|
|
240
|
+
});
|
|
241
|
+
}
|
|
242
|
+
_getAuthorizationHeader() {
|
|
243
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
244
|
+
const bearer = yield core.Supplier.get(this._options.token);
|
|
245
|
+
if (bearer != null) {
|
|
246
|
+
return `Bearer ${bearer}`;
|
|
247
|
+
}
|
|
248
|
+
return undefined;
|
|
249
|
+
});
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
exports.AdHoc = AdHoc;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./requests/index.js"), exports);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Chrt from "../../../../../../index.js";
|
|
5
|
+
/**
|
|
6
|
+
* @example
|
|
7
|
+
* {
|
|
8
|
+
* schema_version: 1,
|
|
9
|
+
* directory_entry_id: "directory_entry_id"
|
|
10
|
+
* }
|
|
11
|
+
*/
|
|
12
|
+
export interface NotificationIntentAdHocClientCreate1 {
|
|
13
|
+
schema_version: number;
|
|
14
|
+
directory_entry_id: string;
|
|
15
|
+
email_events?: Chrt.NotificationEventsForAdHocEnum[];
|
|
16
|
+
push_events?: Chrt.NotificationEventsForAdHocEnum[];
|
|
17
|
+
sms_events?: Chrt.NotificationEventsForAdHocEnum[];
|
|
18
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { type NotificationIntentAdHocClientCreate1 } from "./NotificationIntentAdHocClientCreate1.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|