@de./sdk 1.0.4 → 2.0.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/allend/Access.d.ts +39 -3
- package/dist/allend/Access.js +147 -114
- package/dist/allend/Access.js.map +1 -1
- package/dist/allend/Agent/consolidation.d.ts +16 -0
- package/dist/allend/Agent/consolidation.js +38 -0
- package/dist/allend/Agent/consolidation.js.map +1 -0
- package/dist/allend/Agent/delivery.d.ts +11 -0
- package/dist/allend/Agent/delivery.js +43 -0
- package/dist/allend/Agent/delivery.js.map +1 -0
- package/dist/allend/Agent/dispatch.d.ts +8 -0
- package/dist/allend/Agent/dispatch.js +24 -0
- package/dist/allend/Agent/dispatch.js.map +1 -0
- package/dist/allend/Agent/index.d.ts +49 -0
- package/dist/allend/Agent/index.js +74 -0
- package/dist/allend/Agent/index.js.map +1 -0
- package/dist/allend/Agent/navigation.d.ts +8 -0
- package/dist/allend/Agent/navigation.js +25 -0
- package/dist/allend/Agent/navigation.js.map +1 -0
- package/dist/allend/Agent/origin.d.ts +9 -0
- package/dist/allend/Agent/origin.js +31 -0
- package/dist/allend/Agent/origin.js.map +1 -0
- package/dist/allend/Agent/reallocation.d.ts +7 -0
- package/dist/allend/Agent/reallocation.js +17 -0
- package/dist/allend/Agent/reallocation.js.map +1 -0
- package/dist/allend/Agent/realtime.d.ts +36 -0
- package/dist/allend/Agent/realtime.js +111 -0
- package/dist/allend/Agent/realtime.js.map +1 -0
- package/dist/allend/Agent/rides.d.ts +12 -0
- package/dist/allend/Agent/rides.js +51 -0
- package/dist/allend/Agent/rides.js.map +1 -0
- package/dist/allend/Agent/shipping.d.ts +11 -0
- package/dist/allend/Agent/shipping.js +43 -0
- package/dist/allend/Agent/shipping.js.map +1 -0
- package/dist/allend/CSP/analytics.d.ts +12 -0
- package/dist/allend/CSP/analytics.js +51 -0
- package/dist/allend/CSP/analytics.js.map +1 -0
- package/dist/allend/CSP/index.d.ts +25 -0
- package/dist/allend/CSP/index.js +43 -0
- package/dist/allend/CSP/index.js.map +1 -0
- package/dist/allend/CSP/inventory.d.ts +16 -0
- package/dist/allend/CSP/inventory.js +78 -0
- package/dist/allend/CSP/inventory.js.map +1 -0
- package/dist/allend/CSP/orders.d.ts +19 -0
- package/dist/allend/CSP/orders.js +97 -0
- package/dist/allend/CSP/orders.js.map +1 -0
- package/dist/allend/CSP/webhooks.d.ts +13 -0
- package/dist/allend/CSP/webhooks.js +56 -0
- package/dist/allend/CSP/webhooks.js.map +1 -0
- package/dist/allend/Customer/index.d.ts +27 -0
- package/dist/allend/Customer/index.js +39 -0
- package/dist/allend/Customer/index.js.map +1 -0
- package/dist/allend/Customer/intents.d.ts +12 -0
- package/dist/allend/Customer/intents.js +55 -0
- package/dist/allend/Customer/intents.js.map +1 -0
- package/dist/allend/Customer/orders.d.ts +11 -0
- package/dist/allend/Customer/orders.js +43 -0
- package/dist/allend/Customer/orders.js.map +1 -0
- package/dist/allend/Customer/rides.d.ts +12 -0
- package/dist/allend/Customer/rides.js +50 -0
- package/dist/allend/Customer/rides.js.map +1 -0
- package/dist/allend/DEV/developers.d.ts +11 -0
- package/dist/allend/DEV/developers.js +35 -0
- package/dist/allend/DEV/developers.js.map +1 -0
- package/dist/allend/DEV/index.d.ts +19 -0
- package/dist/allend/DEV/index.js +37 -0
- package/dist/allend/DEV/index.js.map +1 -0
- package/dist/allend/IoTClient.js +29 -35
- package/dist/allend/IoTClient.js.map +1 -1
- package/dist/allend/IoTSP/backend.d.ts +29 -0
- package/dist/allend/IoTSP/backend.js +75 -0
- package/dist/allend/IoTSP/backend.js.map +1 -0
- package/dist/allend/IoTSP/devices.d.ts +14 -0
- package/dist/allend/IoTSP/devices.js +61 -0
- package/dist/allend/IoTSP/devices.js.map +1 -0
- package/dist/allend/IoTSP/index.d.ts +28 -0
- package/dist/allend/IoTSP/index.js +84 -0
- package/dist/allend/IoTSP/index.js.map +1 -0
- package/dist/allend/IoTSP/rules.d.ts +17 -0
- package/dist/allend/IoTSP/rules.js +81 -0
- package/dist/allend/IoTSP/rules.js.map +1 -0
- package/dist/allend/IoTSP/topics.d.ts +17 -0
- package/dist/allend/IoTSP/topics.js +81 -0
- package/dist/allend/IoTSP/topics.js.map +1 -0
- package/dist/allend/LSP/agents.d.ts +20 -0
- package/dist/allend/LSP/agents.js +89 -0
- package/dist/allend/LSP/agents.js.map +1 -0
- package/dist/allend/LSP/carriers.d.ts +54 -0
- package/dist/allend/LSP/carriers.js +315 -0
- package/dist/allend/LSP/carriers.js.map +1 -0
- package/dist/allend/LSP/coverage.d.ts +44 -0
- package/dist/allend/LSP/coverage.js +135 -0
- package/dist/allend/LSP/coverage.js.map +1 -0
- package/dist/allend/LSP/fleets.d.ts +66 -0
- package/dist/allend/LSP/fleets.js +381 -0
- package/dist/allend/LSP/fleets.js.map +1 -0
- package/dist/allend/LSP/hubs.d.ts +39 -0
- package/dist/allend/LSP/hubs.js +186 -0
- package/dist/allend/LSP/hubs.js.map +1 -0
- package/dist/allend/LSP/index.d.ts +37 -0
- package/dist/allend/LSP/index.js +55 -0
- package/dist/allend/LSP/index.js.map +1 -0
- package/dist/allend/LSP/inventory.d.ts +13 -0
- package/dist/allend/LSP/inventory.js +56 -0
- package/dist/allend/LSP/inventory.js.map +1 -0
- package/dist/allend/LSP/operations.d.ts +47 -0
- package/dist/allend/LSP/operations.js +156 -0
- package/dist/allend/LSP/operations.js.map +1 -0
- package/dist/allend/LSP/orders.d.ts +69 -0
- package/dist/allend/LSP/orders.js +303 -0
- package/dist/allend/LSP/orders.js.map +1 -0
- package/dist/allend/LSP/pods.d.ts +26 -0
- package/dist/allend/LSP/pods.js +137 -0
- package/dist/allend/LSP/pods.js.map +1 -0
- package/dist/allend/LSP/pricing.d.ts +35 -0
- package/dist/allend/LSP/pricing.js +151 -0
- package/dist/allend/LSP/pricing.js.map +1 -0
- package/dist/allend/LSP/psl.d.ts +15 -0
- package/dist/allend/LSP/psl.js +68 -0
- package/dist/allend/LSP/psl.js.map +1 -0
- package/dist/allend/LSP/warehouses.d.ts +23 -0
- package/dist/allend/LSP/warehouses.js +94 -0
- package/dist/allend/LSP/warehouses.js.map +1 -0
- package/dist/allend/MSI/Controls.d.ts +9 -5
- package/dist/allend/MSI/Controls.js +269 -297
- package/dist/allend/MSI/Controls.js.map +1 -1
- package/dist/allend/MSI/Handles.d.ts +5 -4
- package/dist/allend/MSI/Handles.js +136 -233
- package/dist/allend/MSI/Handles.js.map +1 -1
- package/dist/allend/MSI/Plugins.d.ts +2 -2
- package/dist/allend/MSI/Plugins.js +12 -15
- package/dist/allend/MSI/Plugins.js.map +1 -1
- package/dist/allend/MSI/index.d.ts +4 -3
- package/dist/allend/MSI/index.js +123 -87
- package/dist/allend/MSI/index.js.map +1 -1
- package/dist/allend/MSI/native.d.ts +32 -0
- package/dist/allend/MSI/native.js +246 -0
- package/dist/allend/MSI/native.js.map +1 -0
- package/dist/allend/MSI/token.d.ts +12 -0
- package/dist/allend/MSI/token.js +21 -0
- package/dist/allend/MSI/token.js.map +1 -0
- package/dist/allend/OTPAuth/index.d.ts +77 -0
- package/dist/allend/OTPAuth/index.js +69 -0
- package/dist/allend/OTPAuth/index.js.map +1 -0
- package/dist/allend/Pipelines/analytics.d.ts +8 -0
- package/dist/allend/Pipelines/analytics.js +24 -0
- package/dist/allend/Pipelines/analytics.js.map +1 -0
- package/dist/allend/Pipelines/escalations.d.ts +8 -0
- package/dist/allend/Pipelines/escalations.js +25 -0
- package/dist/allend/Pipelines/escalations.js.map +1 -0
- package/dist/allend/Pipelines/executions.d.ts +11 -0
- package/dist/allend/Pipelines/executions.js +44 -0
- package/dist/allend/Pipelines/executions.js.map +1 -0
- package/dist/allend/Pipelines/index.d.ts +42 -0
- package/dist/allend/Pipelines/index.js +88 -0
- package/dist/allend/Pipelines/index.js.map +1 -0
- package/dist/allend/Pipelines/interventions.d.ts +8 -0
- package/dist/allend/Pipelines/interventions.js +25 -0
- package/dist/allend/Pipelines/interventions.js.map +1 -0
- package/dist/allend/Pipelines/monitor.d.ts +9 -0
- package/dist/allend/Pipelines/monitor.js +30 -0
- package/dist/allend/Pipelines/monitor.js.map +1 -0
- package/dist/allend/Pipelines/queries.d.ts +8 -0
- package/dist/allend/Pipelines/queries.js +25 -0
- package/dist/allend/Pipelines/queries.js.map +1 -0
- package/dist/allend/Pipelines/templates.d.ts +11 -0
- package/dist/allend/Pipelines/templates.js +46 -0
- package/dist/allend/Pipelines/templates.js.map +1 -0
- package/dist/allend/Pipelines/utils.d.ts +0 -0
- package/dist/allend/Pipelines/utils.js +2 -0
- package/dist/allend/Pipelines/utils.js.map +1 -0
- package/dist/allend/Pipelines/webhooks.d.ts +9 -0
- package/dist/allend/Pipelines/webhooks.js +35 -0
- package/dist/allend/Pipelines/webhooks.js.map +1 -0
- package/dist/allend/Pipelines/workers.d.ts +11 -0
- package/dist/allend/Pipelines/workers.js +45 -0
- package/dist/allend/Pipelines/workers.js.map +1 -0
- package/dist/allend/Queries/capacity.d.ts +11 -0
- package/dist/allend/Queries/capacity.js +44 -0
- package/dist/allend/Queries/capacity.js.map +1 -0
- package/dist/allend/Queries/discovery.d.ts +11 -0
- package/dist/allend/Queries/discovery.js +45 -0
- package/dist/allend/Queries/discovery.js.map +1 -0
- package/dist/allend/Queries/index.d.ts +27 -0
- package/dist/allend/Queries/index.js +40 -0
- package/dist/allend/Queries/index.js.map +1 -0
- package/dist/allend/Queries/matching.d.ts +7 -0
- package/dist/allend/Queries/matching.js +18 -0
- package/dist/allend/Queries/matching.js.map +1 -0
- package/dist/allend/Queries/performance.d.ts +9 -0
- package/dist/allend/Queries/performance.js +31 -0
- package/dist/allend/Queries/performance.js.map +1 -0
- package/dist/allend/Queries/pricing.d.ts +11 -0
- package/dist/allend/Queries/pricing.js +43 -0
- package/dist/allend/Queries/pricing.js.map +1 -0
- package/dist/allend/{DClient/Event.d.ts → Realtime/index.d.ts} +2 -6
- package/dist/allend/Realtime/index.js +62 -0
- package/dist/allend/Realtime/index.js.map +1 -0
- package/dist/allend/Shared/account.d.ts +10 -0
- package/dist/allend/Shared/account.js +22 -0
- package/dist/allend/Shared/account.js.map +1 -0
- package/dist/allend/Shared/buckets.d.ts +21 -0
- package/dist/allend/Shared/buckets.js +95 -0
- package/dist/allend/Shared/buckets.js.map +1 -0
- package/dist/allend/Shared/context.d.ts +14 -0
- package/dist/allend/Shared/context.js +33 -0
- package/dist/allend/Shared/context.js.map +1 -0
- package/dist/allend/Shared/faqs.d.ts +20 -0
- package/dist/allend/Shared/faqs.js +87 -0
- package/dist/allend/Shared/faqs.js.map +1 -0
- package/dist/allend/Shared/invitation.d.ts +42 -0
- package/dist/allend/Shared/invitation.js +40 -0
- package/dist/allend/Shared/invitation.js.map +1 -0
- package/dist/allend/Shared/operators.d.ts +39 -0
- package/dist/allend/Shared/operators.js +37 -0
- package/dist/allend/Shared/operators.js.map +1 -0
- package/dist/allend/Shared/users.d.ts +11 -0
- package/dist/allend/Shared/users.js +29 -0
- package/dist/allend/Shared/users.js.map +1 -0
- package/dist/allend/Tracking/index.d.ts +17 -0
- package/dist/allend/Tracking/index.js +39 -0
- package/dist/allend/Tracking/index.js.map +1 -0
- package/dist/allend/Utilities/common.d.ts +12 -0
- package/dist/allend/Utilities/common.js +53 -0
- package/dist/allend/Utilities/common.js.map +1 -0
- package/dist/allend/Utilities/fares.d.ts +10 -0
- package/dist/allend/Utilities/fares.js +39 -0
- package/dist/allend/Utilities/fares.js.map +1 -0
- package/dist/allend/Utilities/index.d.ts +23 -0
- package/dist/allend/Utilities/index.js +36 -0
- package/dist/allend/Utilities/index.js.map +1 -0
- package/dist/allend/Utilities/nearby.d.ts +9 -0
- package/dist/allend/Utilities/nearby.js +32 -0
- package/dist/allend/Utilities/nearby.js.map +1 -0
- package/dist/allend/Workflows/Client.d.ts +17 -0
- package/dist/allend/Workflows/Client.js +50 -0
- package/dist/allend/Workflows/Client.js.map +1 -0
- package/dist/allend/Workflows/Delivery.d.ts +36 -0
- package/dist/allend/Workflows/Delivery.js +16 -0
- package/dist/allend/Workflows/Delivery.js.map +1 -0
- package/dist/allend/Workflows/index.d.ts +11 -0
- package/dist/allend/Workflows/index.js +25 -0
- package/dist/allend/Workflows/index.js.map +1 -0
- package/dist/allend/Workspace/index.d.ts +162 -0
- package/dist/allend/Workspace/index.js +220 -0
- package/dist/allend/Workspace/index.js.map +1 -0
- package/dist/allend/index.d.ts +8 -5
- package/dist/allend/index.js +15 -8
- package/dist/allend/index.js.map +1 -1
- package/dist/backend/Auth.d.ts +28 -4
- package/dist/backend/Auth.js +125 -245
- package/dist/backend/Auth.js.map +1 -1
- package/dist/baseUrl.d.ts +56 -0
- package/dist/baseUrl.js +72 -4
- package/dist/baseUrl.js.map +1 -1
- package/dist/core.d.ts +88 -0
- package/dist/core.js +121 -0
- package/dist/core.js.map +1 -0
- package/dist/error.d.ts +17 -0
- package/dist/error.js +26 -0
- package/dist/error.js.map +1 -0
- package/dist/index.d.ts +30 -12
- package/dist/index.js +38 -14
- package/dist/index.js.map +1 -1
- package/dist/react-native.d.ts +30 -0
- package/dist/react-native.js +55 -0
- package/dist/react-native.js.map +1 -0
- package/dist/types/access.d.ts +64 -7
- package/dist/types/auth.d.ts +17 -17
- package/dist/types/channel.d.ts +45 -0
- package/dist/types/index.d.ts +379 -237
- package/dist/utils/index.d.ts +25 -0
- package/dist/utils/index.js +11 -1
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/stream.js +25 -26
- package/dist/utils/stream.js.map +1 -1
- package/package.json +38 -18
- package/src/allend/Access.ts +143 -13
- package/src/allend/Agent/consolidation.ts +43 -0
- package/src/allend/Agent/delivery.ts +51 -0
- package/src/allend/Agent/dispatch.ts +27 -0
- package/src/allend/Agent/index.ts +113 -0
- package/src/allend/Agent/navigation.ts +27 -0
- package/src/allend/Agent/origin.ts +36 -0
- package/src/allend/Agent/reallocation.ts +16 -0
- package/src/allend/Agent/realtime.ts +140 -0
- package/src/allend/Agent/rides.ts +61 -0
- package/src/allend/Agent/shipping.ts +51 -0
- package/src/allend/CSP/analytics.ts +61 -0
- package/src/allend/CSP/index.ts +57 -0
- package/src/allend/CSP/inventory.ts +96 -0
- package/src/allend/CSP/orders.ts +121 -0
- package/src/allend/CSP/webhooks.ts +68 -0
- package/src/allend/Customer/index.ts +56 -0
- package/src/allend/Customer/intents.ts +66 -0
- package/src/allend/Customer/orders.ts +51 -0
- package/src/allend/Customer/rides.ts +60 -0
- package/src/allend/DEV/developers.ts +42 -0
- package/src/allend/DEV/index.ts +48 -0
- package/src/allend/IoTSP/backend.ts +103 -0
- package/src/allend/IoTSP/devices.ts +74 -0
- package/src/allend/IoTSP/index.ts +69 -0
- package/src/allend/IoTSP/rules.ts +99 -0
- package/src/allend/IoTSP/topics.ts +99 -0
- package/src/allend/LSP/agents.ts +115 -0
- package/src/allend/LSP/carriers.ts +408 -0
- package/src/allend/LSP/coverage.ts +212 -0
- package/src/allend/LSP/fleets.ts +505 -0
- package/src/allend/LSP/hubs.ts +245 -0
- package/src/allend/LSP/index.ts +75 -0
- package/src/allend/LSP/inventory.ts +65 -0
- package/src/allend/LSP/operations.ts +202 -0
- package/src/allend/LSP/orders.ts +397 -0
- package/src/allend/LSP/pods.ts +176 -0
- package/src/allend/LSP/pricing.ts +192 -0
- package/src/allend/LSP/psl.ts +81 -0
- package/src/allend/LSP/warehouses.ts +118 -0
- package/src/allend/MSI/Controls.ts +109 -90
- package/src/allend/MSI/Handles.ts +24 -15
- package/src/allend/MSI/Plugins.ts +3 -3
- package/src/allend/MSI/index.ts +85 -16
- package/src/allend/MSI/native.tsx +314 -0
- package/src/allend/MSI/token.ts +20 -0
- package/src/allend/OTPAuth/index.ts +130 -0
- package/src/allend/Pipelines/analytics.ts +25 -0
- package/src/allend/Pipelines/escalations.ts +26 -0
- package/src/allend/Pipelines/executions.ts +51 -0
- package/src/allend/Pipelines/index.ts +125 -0
- package/src/allend/Pipelines/interventions.ts +27 -0
- package/src/allend/Pipelines/monitor.ts +33 -0
- package/src/allend/Pipelines/queries.ts +27 -0
- package/src/allend/Pipelines/templates.ts +51 -0
- package/src/allend/Pipelines/utils.ts +0 -0
- package/src/allend/Pipelines/webhooks.ts +36 -0
- package/src/allend/Pipelines/workers.ts +49 -0
- package/src/allend/Queries/capacity.ts +51 -0
- package/src/allend/Queries/discovery.ts +53 -0
- package/src/allend/Queries/index.ts +58 -0
- package/src/allend/Queries/matching.ts +16 -0
- package/src/allend/Queries/performance.ts +35 -0
- package/src/allend/Queries/pricing.ts +51 -0
- package/src/allend/{DClient/Event.ts → Realtime/index.ts} +23 -22
- package/src/allend/Shared/account.ts +24 -0
- package/src/allend/Shared/buckets.ts +117 -0
- package/src/allend/Shared/context.ts +36 -0
- package/src/allend/Shared/faqs.ts +106 -0
- package/src/allend/Shared/invitation.ts +77 -0
- package/src/allend/Shared/operators.ts +84 -0
- package/src/allend/Shared/users.ts +32 -0
- package/src/allend/Tracking/index.ts +48 -0
- package/src/allend/Utilities/common.ts +63 -0
- package/src/allend/Utilities/fares.ts +45 -0
- package/src/allend/Utilities/index.ts +52 -0
- package/src/allend/Utilities/nearby.ts +36 -0
- package/src/allend/{DClient → Workflows}/Client.ts +12 -22
- package/src/allend/Workflows/Delivery.ts +94 -0
- package/src/allend/Workflows/index.ts +31 -0
- package/src/allend/Workspace/index.ts +302 -0
- package/src/allend/index.ts +23 -10
- package/src/backend/Auth.ts +68 -35
- package/src/baseUrl.ts +81 -7
- package/src/core.ts +145 -0
- package/src/error.ts +27 -0
- package/src/index.ts +25 -17
- package/src/react-native.ts +43 -0
- package/src/types/access.d.ts +64 -7
- package/src/types/auth.d.ts +17 -17
- package/src/types/channel.d.ts +45 -0
- package/src/types/index.d.ts +379 -237
- package/src/utils/index.ts +33 -1
- package/dist/allend/DAuth/index.d.ts +0 -20
- package/dist/allend/DAuth/index.js +0 -92
- package/dist/allend/DAuth/index.js.map +0 -1
- package/dist/allend/DClient/Client.d.ts +0 -10
- package/dist/allend/DClient/Client.js +0 -144
- package/dist/allend/DClient/Client.js.map +0 -1
- package/dist/allend/DClient/Event.js +0 -100
- package/dist/allend/DClient/Event.js.map +0 -1
- package/dist/allend/DClient/Order.d.ts +0 -49
- package/dist/allend/DClient/Order.js +0 -601
- package/dist/allend/DClient/Order.js.map +0 -1
- package/dist/bundle.js +0 -1
- package/src/allend/DAuth/index.ts +0 -39
- package/src/allend/DClient/Order.ts +0 -452
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import type { APIResponseBase } from '@de./types'
|
|
2
|
+
import type {
|
|
3
|
+
LSPPricingAddValidation,
|
|
4
|
+
LSPPricingRetrieveValidation,
|
|
5
|
+
LSPPricingFetchValidation,
|
|
6
|
+
LSPPricingUpdateValidation,
|
|
7
|
+
LSPPricingRemoveValidation,
|
|
8
|
+
LSPPricingAddTierValidation,
|
|
9
|
+
LSPPricingUpdateTierValidation,
|
|
10
|
+
LSPPricingRemoveTierValidation,
|
|
11
|
+
LSPPricingAddSeasonalAdjustmentValidation,
|
|
12
|
+
LSPPricingRemoveSeasonalAdjustmentValidation,
|
|
13
|
+
LSPPricingUpdateFuelSurchargeValidation,
|
|
14
|
+
LSPPricingBulkUpdateByCategoryValidation,
|
|
15
|
+
LSPPricingAddContractTermsValidation,
|
|
16
|
+
LSPPricingUpdateContractTermsValidation,
|
|
17
|
+
LSPPricingValidateValidation,
|
|
18
|
+
LSPPricingGetTemplatesValidation,
|
|
19
|
+
LSPPricingCreateFromTemplateValidation,
|
|
20
|
+
LSPPricingBindToValidation,
|
|
21
|
+
LSPPricingAdoptValidation
|
|
22
|
+
} from '@de./types/lsp/pricing'
|
|
23
|
+
import { qs, type Http, type Res, type Data } from '../../utils'
|
|
24
|
+
|
|
25
|
+
// ── LSP Pricing ───────────────────────────────────────────────────────────────
|
|
26
|
+
|
|
27
|
+
export default class LSPPricing {
|
|
28
|
+
constructor( private http: Http ){}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Take the platform's own rate card as this workspace's starting point.
|
|
32
|
+
*
|
|
33
|
+
* The platform rules are code, not rows, so a workspace that has never
|
|
34
|
+
* priced anything quotes off them implicitly and cannot edit them. Adopting
|
|
35
|
+
* writes them in as this workspace's own rules, which is what makes them
|
|
36
|
+
* editable — and is idempotent on rule code, so a second call adopts only
|
|
37
|
+
* what is missing and reports the rest as `skipped`.
|
|
38
|
+
*/
|
|
39
|
+
async adopt( body?: LSPPricingAdoptValidation['body'] ): Promise<LSPPricingAdoptValidation['response']> {
|
|
40
|
+
return await this.http.request<LSPPricingAdoptValidation['response']>({
|
|
41
|
+
url: '/lsp/pricing/rules/adopt',
|
|
42
|
+
method: 'POST',
|
|
43
|
+
body: body ?? {}
|
|
44
|
+
})
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
async add( body: LSPPricingAddValidation['body'] ): Promise<LSPPricingAddValidation['response']> {
|
|
48
|
+
return await this.http.request<LSPPricingAddValidation['response']>({
|
|
49
|
+
url: '/lsp/pricing/rules',
|
|
50
|
+
method: 'POST',
|
|
51
|
+
body
|
|
52
|
+
})
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
async list( querystring?: LSPPricingFetchValidation['querystring'] ): Promise<LSPPricingFetchValidation['response']> {
|
|
56
|
+
return await this.http.request<LSPPricingFetchValidation['response']>({
|
|
57
|
+
url: `/lsp/pricing/rules${qs( querystring )}`,
|
|
58
|
+
method: 'GET'
|
|
59
|
+
})
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
async retrieve( id: string ): Promise<LSPPricingRetrieveValidation['response']> {
|
|
63
|
+
return await this.http.request<LSPPricingRetrieveValidation['response']>({
|
|
64
|
+
url: `/lsp/pricing/rules/${id}`,
|
|
65
|
+
method: 'GET'
|
|
66
|
+
})
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
async update( id: string, body: LSPPricingUpdateValidation['body'] ): Promise<LSPPricingUpdateValidation['response']> {
|
|
70
|
+
return await this.http.request<LSPPricingUpdateValidation['response']>({
|
|
71
|
+
url: `/lsp/pricing/rules/${id}`,
|
|
72
|
+
method: 'PATCH',
|
|
73
|
+
body
|
|
74
|
+
})
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
async remove( id: string ): Promise<APIResponseBase> {
|
|
78
|
+
return await this.http.request<APIResponseBase>({
|
|
79
|
+
url: `/lsp/pricing/rules/${id}`,
|
|
80
|
+
method: 'DELETE'
|
|
81
|
+
})
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
async bindTo( id: string, action: 'add' | 'remove', body: LSPPricingBindToValidation['body'] ): Promise<LSPPricingBindToValidation['response']> {
|
|
85
|
+
return await this.http.request<LSPPricingBindToValidation['response']>({
|
|
86
|
+
url: `/lsp/pricing/rules/${id}/bind/${action}`,
|
|
87
|
+
method: 'PUT',
|
|
88
|
+
body
|
|
89
|
+
})
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// ── Tiers ─────────────────────────────────────────────────────────────────
|
|
93
|
+
|
|
94
|
+
async addTier( id: string, body: LSPPricingAddTierValidation['body'] ): Promise<LSPPricingAddTierValidation['response']> {
|
|
95
|
+
return await this.http.request<LSPPricingAddTierValidation['response']>({
|
|
96
|
+
url: `/lsp/pricing/rules/${id}/tiers`,
|
|
97
|
+
method: 'POST',
|
|
98
|
+
body
|
|
99
|
+
})
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
async updateTier( id: string, index: number, body: LSPPricingUpdateTierValidation['body'] ): Promise<LSPPricingUpdateTierValidation['response']> {
|
|
103
|
+
return await this.http.request<LSPPricingUpdateTierValidation['response']>({
|
|
104
|
+
url: `/lsp/pricing/rules/${id}/tiers/${index}`,
|
|
105
|
+
method: 'PATCH',
|
|
106
|
+
body
|
|
107
|
+
})
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
async removeTier( id: string, index: number ): Promise<APIResponseBase> {
|
|
111
|
+
return await this.http.request<APIResponseBase>({
|
|
112
|
+
url: `/lsp/pricing/rules/${id}/tiers/${index}`,
|
|
113
|
+
method: 'DELETE'
|
|
114
|
+
})
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// ── Contract ──────────────────────────────────────────────────────────────
|
|
118
|
+
|
|
119
|
+
async addContractTerms( id: string, body: LSPPricingAddContractTermsValidation['body'] ): Promise<LSPPricingAddContractTermsValidation['response']> {
|
|
120
|
+
return await this.http.request<LSPPricingAddContractTermsValidation['response']>({
|
|
121
|
+
url: `/lsp/pricing/rules/${id}/contract`,
|
|
122
|
+
method: 'POST',
|
|
123
|
+
body
|
|
124
|
+
})
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
async updateContractTerms( id: string, body: LSPPricingUpdateContractTermsValidation['body'] ): Promise<LSPPricingUpdateContractTermsValidation['response']> {
|
|
128
|
+
return await this.http.request<LSPPricingUpdateContractTermsValidation['response']>({
|
|
129
|
+
url: `/lsp/pricing/rules/${id}/contract`,
|
|
130
|
+
method: 'PATCH',
|
|
131
|
+
body
|
|
132
|
+
})
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
// ── Adjustments ───────────────────────────────────────────────────────────
|
|
136
|
+
|
|
137
|
+
async addSeasonalAdjustment( id: string, body: LSPPricingAddSeasonalAdjustmentValidation['body'] ): Promise<LSPPricingAddSeasonalAdjustmentValidation['response']> {
|
|
138
|
+
return await this.http.request<LSPPricingAddSeasonalAdjustmentValidation['response']>({
|
|
139
|
+
url: `/lsp/pricing/rules/${id}/adjustments`,
|
|
140
|
+
method: 'POST',
|
|
141
|
+
body
|
|
142
|
+
})
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
async removeSeasonalAdjustment( id: string, index: number ): Promise<APIResponseBase> {
|
|
146
|
+
return await this.http.request<APIResponseBase>({
|
|
147
|
+
url: `/lsp/pricing/rules/${id}/adjustments/${index}`,
|
|
148
|
+
method: 'DELETE'
|
|
149
|
+
})
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
async updateFuelSurcharge( id: string, body: LSPPricingUpdateFuelSurchargeValidation['body'] ): Promise<LSPPricingUpdateFuelSurchargeValidation['response']> {
|
|
153
|
+
return await this.http.request<LSPPricingUpdateFuelSurchargeValidation['response']>({
|
|
154
|
+
url: `/lsp/pricing/utils/rules/${id}/fuel-surcharge`,
|
|
155
|
+
method: 'PATCH',
|
|
156
|
+
body
|
|
157
|
+
})
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
async bulkUpdateByCategory( body: LSPPricingBulkUpdateByCategoryValidation['body'] ): Promise<LSPPricingBulkUpdateByCategoryValidation['response']> {
|
|
161
|
+
return await this.http.request<LSPPricingBulkUpdateByCategoryValidation['response']>({
|
|
162
|
+
url: '/lsp/pricing/utils/bulk/update',
|
|
163
|
+
method: 'PATCH',
|
|
164
|
+
body
|
|
165
|
+
})
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
// ── Templates ─────────────────────────────────────────────────────────────
|
|
169
|
+
|
|
170
|
+
async getTemplates( querystring?: LSPPricingGetTemplatesValidation['querystring'] ): Promise<LSPPricingGetTemplatesValidation['response']> {
|
|
171
|
+
return await this.http.request<LSPPricingGetTemplatesValidation['response']>({
|
|
172
|
+
url: `/lsp/pricing/templates${qs( querystring )}`,
|
|
173
|
+
method: 'GET'
|
|
174
|
+
})
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
async createFromTemplate( body: LSPPricingCreateFromTemplateValidation['body'] ): Promise<LSPPricingCreateFromTemplateValidation['response']> {
|
|
178
|
+
return await this.http.request<LSPPricingCreateFromTemplateValidation['response']>({
|
|
179
|
+
url: '/lsp/pricing/templates/create',
|
|
180
|
+
method: 'POST',
|
|
181
|
+
body
|
|
182
|
+
})
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
async validate( body: LSPPricingValidateValidation['body'] ): Promise<LSPPricingValidateValidation['response']> {
|
|
186
|
+
return await this.http.request<LSPPricingValidateValidation['response']>({
|
|
187
|
+
url: '/lsp/pricing/utils/validate',
|
|
188
|
+
method: 'POST',
|
|
189
|
+
body
|
|
190
|
+
})
|
|
191
|
+
}
|
|
192
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
LSPPSLCreateValidation,
|
|
3
|
+
LSPPSLFetchValidation,
|
|
4
|
+
LSPPSLRetrieveValidation,
|
|
5
|
+
LSPPSLUpdateValidation,
|
|
6
|
+
LSPPSLUpdateStatusValidation,
|
|
7
|
+
LSPPSLHierarchyValidation,
|
|
8
|
+
LSPPSLAvailableValidation,
|
|
9
|
+
LSPPSLRemoveValidation
|
|
10
|
+
} from '@de./types/lsp/psl'
|
|
11
|
+
import { qs, type Http, type Res, type Data } from '../../utils'
|
|
12
|
+
|
|
13
|
+
// ── LSP Facility PSL (Pick/Sort/Locations) ──────────────────────────────────────
|
|
14
|
+
//
|
|
15
|
+
// Dual-mounted under hubs and warehouses: /lsp/{hubs|warehouses}/:id/psl
|
|
16
|
+
// Instantiated per facility segment; each method takes the facility id.
|
|
17
|
+
//
|
|
18
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
19
|
+
|
|
20
|
+
export default class LSPFacilityPSL {
|
|
21
|
+
constructor( private http: Http, private segment: 'hubs' | 'warehouses' ){}
|
|
22
|
+
|
|
23
|
+
async create( facilityId: string, body: LSPPSLCreateValidation['body'] ): Promise<LSPPSLCreateValidation['response']> {
|
|
24
|
+
return await this.http.request<LSPPSLCreateValidation['response']>({
|
|
25
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/create`,
|
|
26
|
+
method: 'POST',
|
|
27
|
+
body
|
|
28
|
+
})
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
async list( facilityId: string, querystring?: LSPPSLFetchValidation['querystring'] ): Promise<LSPPSLFetchValidation['response']> {
|
|
32
|
+
return await this.http.request<LSPPSLFetchValidation['response']>({
|
|
33
|
+
url: `/lsp/${this.segment}/${facilityId}/psl${qs( querystring )}`,
|
|
34
|
+
method: 'GET'
|
|
35
|
+
})
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
async retrieve( facilityId: string, locationId: string ): Promise<LSPPSLRetrieveValidation['response']> {
|
|
39
|
+
return await this.http.request<LSPPSLRetrieveValidation['response']>({
|
|
40
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/${locationId}`,
|
|
41
|
+
method: 'GET'
|
|
42
|
+
})
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
async update( facilityId: string, locationId: string, body: LSPPSLUpdateValidation['body'] ): Promise<LSPPSLUpdateValidation['response']> {
|
|
46
|
+
return await this.http.request<LSPPSLUpdateValidation['response']>({
|
|
47
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/${locationId}`,
|
|
48
|
+
method: 'PATCH',
|
|
49
|
+
body
|
|
50
|
+
})
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
async updateStatus( facilityId: string, locationId: string, body: LSPPSLUpdateStatusValidation['body'] ): Promise<LSPPSLUpdateStatusValidation['response']> {
|
|
54
|
+
return await this.http.request<LSPPSLUpdateStatusValidation['response']>({
|
|
55
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/${locationId}/status`,
|
|
56
|
+
method: 'PATCH',
|
|
57
|
+
body
|
|
58
|
+
})
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
async hierarchy( facilityId: string, locationId: string ): Promise<LSPPSLHierarchyValidation['response']> {
|
|
62
|
+
return await this.http.request<LSPPSLHierarchyValidation['response']>({
|
|
63
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/${locationId}/hierarchy`,
|
|
64
|
+
method: 'GET'
|
|
65
|
+
})
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
async available( facilityId: string, querystring?: LSPPSLAvailableValidation['querystring'] ): Promise<LSPPSLAvailableValidation['response']> {
|
|
69
|
+
return await this.http.request<LSPPSLAvailableValidation['response']>({
|
|
70
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/query/available${qs( querystring )}`,
|
|
71
|
+
method: 'GET'
|
|
72
|
+
})
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
async remove( facilityId: string, locationId: string ): Promise<LSPPSLRemoveValidation['response']> {
|
|
76
|
+
return await this.http.request<LSPPSLRemoveValidation['response']>({
|
|
77
|
+
url: `/lsp/${this.segment}/${facilityId}/psl/${locationId}`,
|
|
78
|
+
method: 'DELETE'
|
|
79
|
+
})
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import type { APIResponseBase } from '@de./types'
|
|
2
|
+
import type {
|
|
3
|
+
LSPWarehouseCreateValidation,
|
|
4
|
+
LSPWarehouseRetrieveValidation,
|
|
5
|
+
LSPWarehouseListValidation,
|
|
6
|
+
LSPWarehouseUpdateValidation,
|
|
7
|
+
LSPWarehouseUpdateStatusValidation,
|
|
8
|
+
LSPWarehouseRemoveValidation,
|
|
9
|
+
LSPWarehouseGetStorageCapabilityValidation,
|
|
10
|
+
LSPWarehouseSetStorageCapabilityValidation,
|
|
11
|
+
LSPWarehouseGetPhysicalCapacityValidation,
|
|
12
|
+
LSPWarehouseSetPhysicalCapacityValidation
|
|
13
|
+
} from '@de./types/lsp/warehouse'
|
|
14
|
+
import type { LSPPricingBindToValidation } from '@de./types/lsp/pricing'
|
|
15
|
+
import { qs, type Http, type Res, type Data } from '../../utils'
|
|
16
|
+
import LSPFacilityPSL from './psl'
|
|
17
|
+
import LSPFacilityInventory from './inventory'
|
|
18
|
+
|
|
19
|
+
// ── LSP Warehouses ────────────────────────────────────────────────────────────
|
|
20
|
+
|
|
21
|
+
export default class LSPWarehouses {
|
|
22
|
+
psl: LSPFacilityPSL
|
|
23
|
+
inventory: LSPFacilityInventory
|
|
24
|
+
|
|
25
|
+
constructor( private http: Http ){
|
|
26
|
+
this.psl = new LSPFacilityPSL( this.http, 'warehouses' )
|
|
27
|
+
this.inventory = new LSPFacilityInventory( this.http, 'warehouses' )
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
async create( body: LSPWarehouseCreateValidation['body'] ): Promise<LSPWarehouseCreateValidation['response']> {
|
|
31
|
+
return await this.http.request<LSPWarehouseCreateValidation['response']>({
|
|
32
|
+
url: '/lsp/warehouses/create',
|
|
33
|
+
method: 'POST',
|
|
34
|
+
body
|
|
35
|
+
})
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
async list( querystring?: LSPWarehouseListValidation['querystring'] ): Promise<LSPWarehouseListValidation['response']> {
|
|
39
|
+
return await this.http.request<LSPWarehouseListValidation['response']>({
|
|
40
|
+
url: `/lsp/warehouses${qs( querystring )}`,
|
|
41
|
+
method: 'GET'
|
|
42
|
+
})
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
async retrieve( id: string ): Promise<LSPWarehouseRetrieveValidation['response']> {
|
|
46
|
+
return await this.http.request<LSPWarehouseRetrieveValidation['response']>({
|
|
47
|
+
url: `/lsp/warehouses/${id}`,
|
|
48
|
+
method: 'GET'
|
|
49
|
+
})
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
async update( id: string, body: LSPWarehouseUpdateValidation['body'] ): Promise<LSPWarehouseUpdateValidation['response']> {
|
|
53
|
+
return await this.http.request<LSPWarehouseUpdateValidation['response']>({
|
|
54
|
+
url: `/lsp/warehouses/${id}`,
|
|
55
|
+
method: 'PATCH',
|
|
56
|
+
body
|
|
57
|
+
})
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
async updateStatus( id: string, body: LSPWarehouseUpdateStatusValidation['body'] ): Promise<LSPWarehouseUpdateStatusValidation['response']> {
|
|
61
|
+
return await this.http.request<LSPWarehouseUpdateStatusValidation['response']>({
|
|
62
|
+
url: `/lsp/warehouses/${id}/status`,
|
|
63
|
+
method: 'PATCH',
|
|
64
|
+
body
|
|
65
|
+
})
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
async remove( id: string ): Promise<APIResponseBase> {
|
|
69
|
+
return await this.http.request<APIResponseBase>({
|
|
70
|
+
url: `/lsp/warehouses/${id}`,
|
|
71
|
+
method: 'DELETE'
|
|
72
|
+
})
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
async bindPricing( id: string, action: LSPPricingBindToValidation['params']['action'], body: LSPPricingBindToValidation['body'] ): Promise<LSPPricingBindToValidation['response']> {
|
|
76
|
+
return await this.http.request<LSPPricingBindToValidation['response']>({
|
|
77
|
+
url: `/lsp/warehouses/${id}/pricing/${action}`,
|
|
78
|
+
method: 'PUT',
|
|
79
|
+
body
|
|
80
|
+
})
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// ── Capabilities ──────────────────────────────────────────────────────────
|
|
84
|
+
// Generic accessors — representative Validation (Storage) used for typing.
|
|
85
|
+
|
|
86
|
+
async getCapability( id: string, type: string ): Promise<LSPWarehouseGetStorageCapabilityValidation['response']> {
|
|
87
|
+
return await this.http.request<LSPWarehouseGetStorageCapabilityValidation['response']>({
|
|
88
|
+
url: `/lsp/warehouses/${id}/capabilities/${type}`,
|
|
89
|
+
method: 'GET'
|
|
90
|
+
})
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
async setCapability( id: string, type: string, body: LSPWarehouseSetStorageCapabilityValidation['body'] ): Promise<LSPWarehouseSetStorageCapabilityValidation['response']> {
|
|
94
|
+
return await this.http.request<LSPWarehouseSetStorageCapabilityValidation['response']>({
|
|
95
|
+
url: `/lsp/warehouses/${id}/capabilities/${type}`,
|
|
96
|
+
method: 'PUT',
|
|
97
|
+
body
|
|
98
|
+
})
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
// ── Capacities ────────────────────────────────────────────────────────────
|
|
102
|
+
// Generic accessors — representative Validation (Physical) used for typing.
|
|
103
|
+
|
|
104
|
+
async getCapacity( id: string, type: string ): Promise<LSPWarehouseGetPhysicalCapacityValidation['response']> {
|
|
105
|
+
return await this.http.request<LSPWarehouseGetPhysicalCapacityValidation['response']>({
|
|
106
|
+
url: `/lsp/warehouses/${id}/capacities/${type}`,
|
|
107
|
+
method: 'GET'
|
|
108
|
+
})
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
async setCapacity( id: string, type: string, body: LSPWarehouseSetPhysicalCapacityValidation['body'] ): Promise<LSPWarehouseSetPhysicalCapacityValidation['response']> {
|
|
112
|
+
return await this.http.request<LSPWarehouseSetPhysicalCapacityValidation['response']>({
|
|
113
|
+
url: `/lsp/warehouses/${id}/capacities/${type}`,
|
|
114
|
+
method: 'PUT',
|
|
115
|
+
body
|
|
116
|
+
})
|
|
117
|
+
}
|
|
118
|
+
}
|