@burdenoff/cli-sdk 2026.626.1 → 2026.627.2
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/modules/assethandler/index.cjs +255 -0
- package/dist/modules/assethandler/index.d.cts +7 -0
- package/dist/modules/assethandler/index.d.ts +7 -0
- package/dist/modules/assethandler/index.js +255 -0
- package/dist/modules/crewfoundry/index.cjs +196 -0
- package/dist/modules/crewfoundry/index.d.cts +7 -0
- package/dist/modules/crewfoundry/index.d.ts +7 -0
- package/dist/modules/crewfoundry/index.js +196 -0
- package/dist/modules/eventfullymanaged/index.cjs +247 -0
- package/dist/modules/eventfullymanaged/index.d.cts +7 -0
- package/dist/modules/eventfullymanaged/index.d.ts +7 -0
- package/dist/modules/eventfullymanaged/index.js +247 -0
- package/dist/modules/ggnomad/index.cjs +140 -0
- package/dist/modules/ggnomad/index.d.cts +7 -0
- package/dist/modules/ggnomad/index.d.ts +7 -0
- package/dist/modules/ggnomad/index.js +140 -0
- package/dist/modules/headshotmarketing/index.cjs +1083 -0
- package/dist/modules/headshotmarketing/index.d.cts +7 -0
- package/dist/modules/headshotmarketing/index.d.ts +7 -0
- package/dist/modules/headshotmarketing/index.js +1083 -0
- package/dist/modules/housingvista/index.cjs +137 -0
- package/dist/modules/housingvista/index.d.cts +7 -0
- package/dist/modules/housingvista/index.d.ts +7 -0
- package/dist/modules/housingvista/index.js +137 -0
- package/dist/modules/movethewheels/index.cjs +565 -0
- package/dist/modules/movethewheels/index.d.cts +7 -0
- package/dist/modules/movethewheels/index.d.ts +7 -0
- package/dist/modules/movethewheels/index.js +565 -0
- package/dist/modules/planmagnet/index.cjs +795 -0
- package/dist/modules/planmagnet/index.d.cts +7 -0
- package/dist/modules/planmagnet/index.d.ts +7 -0
- package/dist/modules/planmagnet/index.js +795 -0
- package/dist/modules/proserviceworld/index.cjs +193 -0
- package/dist/modules/proserviceworld/index.d.cts +7 -0
- package/dist/modules/proserviceworld/index.d.ts +7 -0
- package/dist/modules/proserviceworld/index.js +193 -0
- package/dist/modules/timecampus/index.cjs +444 -0
- package/dist/modules/timecampus/index.d.cts +7 -0
- package/dist/modules/timecampus/index.d.ts +7 -0
- package/dist/modules/timecampus/index.js +444 -0
- package/package.json +1 -1
|
@@ -0,0 +1,565 @@
|
|
|
1
|
+
import {a,b as b$1,h as h$1,p,g,i}from'../../chunk-WXDQ3S5J.js';import {o}from'../../chunk-TCBALVP4.js';var D=`
|
|
2
|
+
query MovethewheelsGetCustomer($id: ID!) {
|
|
3
|
+
customer(id: $id) {
|
|
4
|
+
id name email phone company type taxId businessLicense address rating
|
|
5
|
+
createdAt updatedAt createdBy updatedBy workspaceId
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
`,O=`
|
|
9
|
+
query MovethewheelsCustomers($filter: CustomerFilterInput, $pagination: PaginationInput) {
|
|
10
|
+
customers(filter: $filter, pagination: $pagination) {
|
|
11
|
+
id name email phone company type rating createdAt
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
`,R=`
|
|
15
|
+
mutation MovethewheelsCreateCustomer($input: CreateCustomerInput!) {
|
|
16
|
+
createCustomer(input: $input) {
|
|
17
|
+
id name email phone company type taxId businessLicense address rating createdAt
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
`,b=`
|
|
21
|
+
mutation MovethewheelsUpdateCustomer($id: ID!, $input: UpdateCustomerInput!) {
|
|
22
|
+
updateCustomer(id: $id, input: $input) {
|
|
23
|
+
id name email phone company type taxId businessLicense address rating updatedAt
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
`,T=`
|
|
27
|
+
mutation MovethewheelsDeleteCustomer($id: ID!) {
|
|
28
|
+
deleteCustomer(id: $id)
|
|
29
|
+
}
|
|
30
|
+
`,C=`
|
|
31
|
+
query MovethewheelsGetDriver($id: ID!) {
|
|
32
|
+
driver(id: $id) {
|
|
33
|
+
id employeeId firstName lastName email phone status licenseNumber
|
|
34
|
+
licenseClass licenseExpiry vehicleId userId rating certifications
|
|
35
|
+
currentLocation performanceMetrics createdAt updatedAt workspaceId
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
`,S=`
|
|
39
|
+
query MovethewheelsDrivers($filter: DriverFilterInput, $pagination: PaginationInput) {
|
|
40
|
+
drivers(filter: $filter, pagination: $pagination) {
|
|
41
|
+
id employeeId firstName lastName email phone status vehicleId rating createdAt
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
`,A=`
|
|
45
|
+
mutation MovethewheelsCreateDriver($input: CreateDriverInput!) {
|
|
46
|
+
createDriver(input: $input) {
|
|
47
|
+
id employeeId firstName lastName email phone status licenseNumber
|
|
48
|
+
licenseClass vehicleId rating createdAt
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
`,N=`
|
|
52
|
+
mutation MovethewheelsUpdateDriver($id: ID!, $input: UpdateDriverInput!) {
|
|
53
|
+
updateDriver(id: $id, input: $input) {
|
|
54
|
+
id employeeId firstName lastName email phone status licenseNumber
|
|
55
|
+
licenseClass vehicleId rating updatedAt
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
`,k=`
|
|
59
|
+
mutation MovethewheelsDeleteDriver($id: ID!) {
|
|
60
|
+
deleteDriver(id: $id)
|
|
61
|
+
}
|
|
62
|
+
`,$=`
|
|
63
|
+
mutation MovethewheelsUpdateDriverStatus($id: ID!, $status: DriverStatus!) {
|
|
64
|
+
updateDriverStatus(id: $id, status: $status) {
|
|
65
|
+
id firstName lastName status updatedAt
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
`,P=`
|
|
69
|
+
mutation MovethewheelsAssignDriverVehicle($id: ID!, $vehicleId: ID) {
|
|
70
|
+
assignDriverVehicle(id: $id, vehicleId: $vehicleId) {
|
|
71
|
+
id firstName lastName vehicleId status updatedAt
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
`,_=`
|
|
75
|
+
query MovethewheelsGetVehicle($id: ID!) {
|
|
76
|
+
vehicle(id: $id) {
|
|
77
|
+
id vehicleNumber type status make model year licensePlate fuelLevel
|
|
78
|
+
mileage ownershipType capacity currentLocation createdAt updatedAt workspaceId
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
`,M=`
|
|
82
|
+
query MovethewheelsVehicles($filter: VehicleFilterInput, $pagination: PaginationInput) {
|
|
83
|
+
vehicles(filter: $filter, pagination: $pagination) {
|
|
84
|
+
id vehicleNumber type status make model year licensePlate fuelLevel createdAt
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
`,U=`
|
|
88
|
+
mutation MovethewheelsCreateVehicle($input: CreateVehicleInput!) {
|
|
89
|
+
createVehicle(input: $input) {
|
|
90
|
+
id vehicleNumber type status make model year licensePlate fuelLevel
|
|
91
|
+
mileage ownershipType createdAt
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
`,L=`
|
|
95
|
+
mutation MovethewheelsUpdateVehicle($id: ID!, $input: UpdateVehicleInput!) {
|
|
96
|
+
updateVehicle(id: $id, input: $input) {
|
|
97
|
+
id vehicleNumber type status make model year licensePlate fuelLevel
|
|
98
|
+
mileage ownershipType updatedAt
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
`,V=`
|
|
102
|
+
mutation MovethewheelsDeleteVehicle($id: ID!) {
|
|
103
|
+
deleteVehicle(id: $id)
|
|
104
|
+
}
|
|
105
|
+
`,q=`
|
|
106
|
+
mutation MovethewheelsUpdateVehicleStatus($id: ID!, $status: VehicleStatus!) {
|
|
107
|
+
updateVehicleStatus(id: $id, status: $status) {
|
|
108
|
+
id vehicleNumber status updatedAt
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
`,x=`
|
|
112
|
+
mutation MovethewheelsUpdateVehicleLocation($id: ID!, $location: JSON!) {
|
|
113
|
+
updateVehicleLocation(id: $id, location: $location) {
|
|
114
|
+
id vehicleNumber currentLocation updatedAt
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
`,F=`
|
|
118
|
+
query MovethewheelsGetProduct($id: ID!) {
|
|
119
|
+
product(id: $id) {
|
|
120
|
+
id sku name description category brand weight value dimensions
|
|
121
|
+
fragile hazardous temperatureControlled createdAt updatedAt workspaceId
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
`,j=`
|
|
125
|
+
query MovethewheelsProducts($filter: ProductFilterInput, $pagination: PaginationInput) {
|
|
126
|
+
products(filter: $filter, pagination: $pagination) {
|
|
127
|
+
id sku name category brand weight value fragile hazardous createdAt
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
`,G=`
|
|
131
|
+
mutation MovethewheelsCreateProduct($input: CreateProductInput!) {
|
|
132
|
+
createProduct(input: $input) {
|
|
133
|
+
id sku name description category brand weight value fragile hazardous
|
|
134
|
+
temperatureControlled createdAt
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
`,W=`
|
|
138
|
+
mutation MovethewheelsUpdateProduct($id: ID!, $input: UpdateProductInput!) {
|
|
139
|
+
updateProduct(id: $id, input: $input) {
|
|
140
|
+
id sku name description category brand weight value fragile hazardous
|
|
141
|
+
temperatureControlled updatedAt
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
`,H=`
|
|
145
|
+
mutation MovethewheelsDeleteProduct($id: ID!) {
|
|
146
|
+
deleteProduct(id: $id)
|
|
147
|
+
}
|
|
148
|
+
`,J=`
|
|
149
|
+
query MovethewheelsGetWarehouse($id: ID!) {
|
|
150
|
+
warehouse(id: $id) {
|
|
151
|
+
id code name type status address contactInfo operatingHours capabilities
|
|
152
|
+
totalCapacity usedCapacity createdAt updatedAt workspaceId
|
|
153
|
+
locations { id locationCode locationType status zone aisle rack shelf bin capacity }
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
`,z=`
|
|
157
|
+
query MovethewheelsWarehouses($filter: WarehouseFilterInput, $pagination: PaginationInput) {
|
|
158
|
+
warehouses(filter: $filter, pagination: $pagination) {
|
|
159
|
+
id code name type status totalCapacity usedCapacity createdAt
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
`,Y=`
|
|
163
|
+
mutation MovethewheelsCreateWarehouse($input: CreateWarehouseInput!) {
|
|
164
|
+
createWarehouse(input: $input) {
|
|
165
|
+
id code name type status address totalCapacity usedCapacity createdAt
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
`,B=`
|
|
169
|
+
mutation MovethewheelsUpdateWarehouse($id: ID!, $input: UpdateWarehouseInput!) {
|
|
170
|
+
updateWarehouse(id: $id, input: $input) {
|
|
171
|
+
id code name type status address totalCapacity usedCapacity updatedAt
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
`,K=`
|
|
175
|
+
mutation MovethewheelsDeleteWarehouse($id: ID!) {
|
|
176
|
+
deleteWarehouse(id: $id)
|
|
177
|
+
}
|
|
178
|
+
`,Z=`
|
|
179
|
+
mutation MovethewheelsCreateWarehouseLocation($input: CreateWarehouseLocationInput!) {
|
|
180
|
+
createWarehouseLocation(input: $input) {
|
|
181
|
+
id warehouseId locationCode locationType status zone aisle rack shelf bin capacity createdAt
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
`,Q=`
|
|
185
|
+
mutation MovethewheelsUpdateWarehouseLocation($id: ID!, $input: UpdateWarehouseLocationInput!) {
|
|
186
|
+
updateWarehouseLocation(id: $id, input: $input) {
|
|
187
|
+
id warehouseId locationCode locationType status zone aisle rack shelf bin capacity updatedAt
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
`,X=`
|
|
191
|
+
query MovethewheelsGetInventoryItem($id: ID!) {
|
|
192
|
+
inventoryItem(id: $id) {
|
|
193
|
+
id productId warehouseId locationId onHand available allocated damaged
|
|
194
|
+
reorderPoint safetyStock unitCost createdAt updatedAt workspaceId
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
`,ee=`
|
|
198
|
+
query MovethewheelsInventoryItems($filter: InventoryFilterInput, $pagination: PaginationInput) {
|
|
199
|
+
inventoryItems(filter: $filter, pagination: $pagination) {
|
|
200
|
+
id productId warehouseId onHand available allocated damaged
|
|
201
|
+
reorderPoint unitCost createdAt
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
`,te=`
|
|
205
|
+
query MovethewheelsInventoryTransactions(
|
|
206
|
+
$filter: InventoryFilterInput
|
|
207
|
+
$pagination: PaginationInput
|
|
208
|
+
) {
|
|
209
|
+
inventoryTransactions(filter: $filter, pagination: $pagination) {
|
|
210
|
+
id transactionNumber type productId warehouseId quantity unitCost
|
|
211
|
+
referenceType referenceId notes createdAt
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
`,ie=`
|
|
215
|
+
query MovethewheelsInventoryStats {
|
|
216
|
+
inventoryStats {
|
|
217
|
+
totalOnHand totalAvailable totalAllocated totalDamaged lowStockCount
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
`,ne=`
|
|
221
|
+
mutation MovethewheelsCreateInventoryItem($input: CreateInventoryItemInput!) {
|
|
222
|
+
createInventoryItem(input: $input) {
|
|
223
|
+
id productId warehouseId locationId onHand available allocated damaged
|
|
224
|
+
reorderPoint safetyStock unitCost createdAt
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
`,re=`
|
|
228
|
+
mutation MovethewheelsUpdateInventoryItem($id: ID!, $input: UpdateInventoryItemInput!) {
|
|
229
|
+
updateInventoryItem(id: $id, input: $input) {
|
|
230
|
+
id productId warehouseId locationId onHand available allocated damaged
|
|
231
|
+
reorderPoint safetyStock unitCost updatedAt
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
`,ae=`
|
|
235
|
+
mutation MovethewheelsDeleteInventoryItem($id: ID!) {
|
|
236
|
+
deleteInventoryItem(id: $id)
|
|
237
|
+
}
|
|
238
|
+
`,oe=`
|
|
239
|
+
mutation MovethewheelsAdjustInventoryStock($input: AdjustInventoryStockInput!) {
|
|
240
|
+
adjustInventoryStock(input: $input) {
|
|
241
|
+
id productId warehouseId onHand available allocated damaged updatedAt
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
`,se=`
|
|
245
|
+
mutation MovethewheelsCreateInventoryTransaction($input: CreateInventoryTransactionInput!) {
|
|
246
|
+
createInventoryTransaction(input: $input) {
|
|
247
|
+
id transactionNumber type productId warehouseId quantity unitCost
|
|
248
|
+
referenceType referenceId notes createdAt
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
`,de=`
|
|
252
|
+
query MovethewheelsGetOrder($id: ID!) {
|
|
253
|
+
movethewheelsOrder(id: $id) {
|
|
254
|
+
id orderNumber customerId driverId vehicleId orderType status priority
|
|
255
|
+
trackingNumber pickupAddress deliveryAddress items pricing
|
|
256
|
+
scheduledDelivery specialInstructions createdAt updatedAt workspaceId
|
|
257
|
+
statusHistory { id status previousStatus notes location createdAt }
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
`,ce=`
|
|
261
|
+
query MovethewheelsOrders($filter: OrderFilterInput, $pagination: PaginationInput) {
|
|
262
|
+
movethewheelsOrders(filter: $filter, pagination: $pagination) {
|
|
263
|
+
id orderNumber customerId driverId orderType status priority
|
|
264
|
+
trackingNumber scheduledDelivery createdAt
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
`,pe=`
|
|
268
|
+
mutation MovethewheelsCreateOrder($input: CreateOrderInput!) {
|
|
269
|
+
createMovethewheelsOrder(input: $input) {
|
|
270
|
+
id orderNumber customerId driverId vehicleId orderType status priority
|
|
271
|
+
trackingNumber pickupAddress deliveryAddress items pricing createdAt
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
`,ue=`
|
|
275
|
+
mutation MovethewheelsUpdateOrder($id: ID!, $input: UpdateOrderInput!) {
|
|
276
|
+
updateMovethewheelsOrder(id: $id, input: $input) {
|
|
277
|
+
id orderNumber customerId driverId vehicleId orderType status priority
|
|
278
|
+
trackingNumber deliveryAddress items pricing updatedAt
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
`,me=`
|
|
282
|
+
mutation MovethewheelsDeleteOrder($id: ID!) {
|
|
283
|
+
deleteMovethewheelsOrder(id: $id)
|
|
284
|
+
}
|
|
285
|
+
`,le=`
|
|
286
|
+
mutation MovethewheelsUpdateOrderStatus($id: ID!, $input: UpdateOrderStatusInput!) {
|
|
287
|
+
updateMovethewheelsOrderStatus(id: $id, input: $input) {
|
|
288
|
+
id orderNumber status priority trackingNumber updatedAt
|
|
289
|
+
statusHistory { id status previousStatus notes createdAt }
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
`,fe=`
|
|
293
|
+
query MovethewheelsOrderStats {
|
|
294
|
+
orderStats {
|
|
295
|
+
total pending inTransit delivered cancelled failed
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
`,ge=`
|
|
299
|
+
query MovethewheelsGetShipment($id: ID!) {
|
|
300
|
+
shipment(id: $id) {
|
|
301
|
+
id shipmentNumber orderId customerId carrierId status trackingNumber
|
|
302
|
+
origin destination cargoDetails estimatedDelivery actualDelivery
|
|
303
|
+
createdAt updatedAt workspaceId
|
|
304
|
+
trackingEvents { id eventType details location timestamp }
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
`,he=`
|
|
308
|
+
query MovethewheelsShipments($filter: ShipmentFilterInput, $pagination: PaginationInput) {
|
|
309
|
+
shipments(filter: $filter, pagination: $pagination) {
|
|
310
|
+
id shipmentNumber orderId customerId carrierId status trackingNumber
|
|
311
|
+
estimatedDelivery createdAt
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
`,ye=`
|
|
315
|
+
query MovethewheelsActiveDeliveries($pagination: PaginationInput) {
|
|
316
|
+
activeDeliveries(pagination: $pagination) {
|
|
317
|
+
id shipmentNumber orderId status trackingNumber estimatedDelivery createdAt
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
`,ve=`
|
|
321
|
+
query MovethewheelsShipmentTracking($shipmentId: ID!, $pagination: PaginationInput) {
|
|
322
|
+
shipmentTracking(shipmentId: $shipmentId, pagination: $pagination) {
|
|
323
|
+
id shipmentId eventType details location timestamp createdAt
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
`,Ie=`
|
|
327
|
+
query MovethewheelsOrderTracking($orderId: ID!, $pagination: PaginationInput) {
|
|
328
|
+
orderTracking(orderId: $orderId, pagination: $pagination) {
|
|
329
|
+
id shipmentId eventType details location timestamp createdAt
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
`,we=`
|
|
333
|
+
query MovethewheelsTrackingAlerts($pagination: PaginationInput) {
|
|
334
|
+
trackingAlerts(pagination: $pagination) {
|
|
335
|
+
alertType message shipmentId shipmentNumber
|
|
336
|
+
}
|
|
337
|
+
}
|
|
338
|
+
`,Ee=`
|
|
339
|
+
mutation MovethewheelsCreateShipment($input: CreateShipmentInput!) {
|
|
340
|
+
createShipment(input: $input) {
|
|
341
|
+
id shipmentNumber orderId customerId carrierId status trackingNumber
|
|
342
|
+
origin destination estimatedDelivery createdAt
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
`,De=`
|
|
346
|
+
mutation MovethewheelsUpdateShipment($id: ID!, $input: UpdateShipmentInput!) {
|
|
347
|
+
updateShipment(id: $id, input: $input) {
|
|
348
|
+
id shipmentNumber orderId customerId carrierId status trackingNumber
|
|
349
|
+
origin destination estimatedDelivery actualDelivery updatedAt
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
`,Oe=`
|
|
353
|
+
mutation MovethewheelsDeleteShipment($id: ID!) {
|
|
354
|
+
deleteShipment(id: $id)
|
|
355
|
+
}
|
|
356
|
+
`,Re=`
|
|
357
|
+
mutation MovethewheelsAddTrackingEvent($input: AddTrackingEventInput!) {
|
|
358
|
+
addTrackingEvent(input: $input) {
|
|
359
|
+
id shipmentId eventType details location timestamp createdAt
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
`,be=`
|
|
363
|
+
query MovethewheelsGetRoute($id: ID!) {
|
|
364
|
+
route(id: $id) {
|
|
365
|
+
id name status driverId vehicleId shipmentId waypoints
|
|
366
|
+
estimatedDistance actualDistance estimatedDuration actualDuration
|
|
367
|
+
fuelCost createdAt updatedAt workspaceId
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
`,Te=`
|
|
371
|
+
query MovethewheelsRoutes($filter: RouteFilterInput, $pagination: PaginationInput) {
|
|
372
|
+
routes(filter: $filter, pagination: $pagination) {
|
|
373
|
+
id name status driverId vehicleId shipmentId estimatedDistance
|
|
374
|
+
estimatedDuration fuelCost createdAt
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
`,Ce=`
|
|
378
|
+
mutation MovethewheelsCreateRoute($input: CreateRouteInput!) {
|
|
379
|
+
createRoute(input: $input) {
|
|
380
|
+
id name status driverId vehicleId shipmentId waypoints
|
|
381
|
+
estimatedDistance estimatedDuration fuelCost createdAt
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
`,Se=`
|
|
385
|
+
mutation MovethewheelsUpdateRoute($id: ID!, $input: UpdateRouteInput!) {
|
|
386
|
+
updateRoute(id: $id, input: $input) {
|
|
387
|
+
id name status driverId vehicleId shipmentId waypoints
|
|
388
|
+
estimatedDistance actualDistance estimatedDuration actualDuration fuelCost updatedAt
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
`,Ae=`
|
|
392
|
+
mutation MovethewheelsDeleteRoute($id: ID!) {
|
|
393
|
+
deleteRoute(id: $id)
|
|
394
|
+
}
|
|
395
|
+
`,Ne=`
|
|
396
|
+
mutation MovethewheelsOptimizeRoute($id: ID!) {
|
|
397
|
+
optimizeRoute(id: $id) {
|
|
398
|
+
id name status estimatedDistance estimatedDuration fuelCost waypoints updatedAt
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
`,ke=`
|
|
402
|
+
query MovethewheelsGetServiceProvider($id: ID!) {
|
|
403
|
+
serviceProvider(id: $id) {
|
|
404
|
+
id name type description isActive isVerified rating contactInfo services
|
|
405
|
+
createdAt updatedAt workspaceId
|
|
406
|
+
offerings { id name category price currency }
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
`,$e=`
|
|
410
|
+
query MovethewheelsServiceProviders(
|
|
411
|
+
$filter: ServiceProviderFilterInput
|
|
412
|
+
$pagination: PaginationInput
|
|
413
|
+
) {
|
|
414
|
+
serviceProviders(filter: $filter, pagination: $pagination) {
|
|
415
|
+
id name type description isActive isVerified rating createdAt
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
`,Pe=`
|
|
419
|
+
mutation MovethewheelsCreateServiceProvider($input: CreateServiceProviderInput!) {
|
|
420
|
+
createServiceProvider(input: $input) {
|
|
421
|
+
id name type description isActive isVerified rating createdAt
|
|
422
|
+
}
|
|
423
|
+
}
|
|
424
|
+
`,_e=`
|
|
425
|
+
mutation MovethewheelsUpdateServiceProvider($id: ID!, $input: UpdateServiceProviderInput!) {
|
|
426
|
+
updateServiceProvider(id: $id, input: $input) {
|
|
427
|
+
id name type description isActive isVerified rating updatedAt
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
`,Me=`
|
|
431
|
+
mutation MovethewheelsDeleteServiceProvider($id: ID!) {
|
|
432
|
+
deleteServiceProvider(id: $id)
|
|
433
|
+
}
|
|
434
|
+
`,Ue=`
|
|
435
|
+
query MovethewheelsGetServiceOffering($id: ID!) {
|
|
436
|
+
serviceOffering(id: $id) {
|
|
437
|
+
id providerId name description category price currency availability
|
|
438
|
+
createdAt updatedAt workspaceId
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
`,Le=`
|
|
442
|
+
query MovethewheelsServiceOfferings(
|
|
443
|
+
$filter: ServiceOfferingFilterInput
|
|
444
|
+
$pagination: PaginationInput
|
|
445
|
+
) {
|
|
446
|
+
serviceOfferings(filter: $filter, pagination: $pagination) {
|
|
447
|
+
id providerId name category price currency createdAt
|
|
448
|
+
}
|
|
449
|
+
}
|
|
450
|
+
`,Ve=`
|
|
451
|
+
mutation MovethewheelsCreateServiceOffering($input: CreateServiceOfferingInput!) {
|
|
452
|
+
createServiceOffering(input: $input) {
|
|
453
|
+
id providerId name description category price currency availability createdAt
|
|
454
|
+
}
|
|
455
|
+
}
|
|
456
|
+
`,qe=`
|
|
457
|
+
mutation MovethewheelsUpdateServiceOffering($id: ID!, $input: UpdateServiceOfferingInput!) {
|
|
458
|
+
updateServiceOffering(id: $id, input: $input) {
|
|
459
|
+
id providerId name description category price currency availability updatedAt
|
|
460
|
+
}
|
|
461
|
+
}
|
|
462
|
+
`,xe=`
|
|
463
|
+
mutation MovethewheelsDeleteServiceOffering($id: ID!) {
|
|
464
|
+
deleteServiceOffering(id: $id)
|
|
465
|
+
}
|
|
466
|
+
`,Fe=`
|
|
467
|
+
query MovethewheelsGetReport($id: ID!) {
|
|
468
|
+
movethewheelsReport(id: $id) {
|
|
469
|
+
id name description type status schedule configuration lastGenerated
|
|
470
|
+
createdAt updatedAt workspaceId
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
`,je=`
|
|
474
|
+
query MovethewheelsReports(
|
|
475
|
+
$filter: MovethewheelsReportFilterInput
|
|
476
|
+
$pagination: PaginationInput
|
|
477
|
+
) {
|
|
478
|
+
movethewheelsReports(filter: $filter, pagination: $pagination) {
|
|
479
|
+
id name type status schedule lastGenerated createdAt
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
`,Ge=`
|
|
483
|
+
mutation MovethewheelsCreateReport($input: CreateMovethewheelsReportInput!) {
|
|
484
|
+
createMovethewheelsReport(input: $input) {
|
|
485
|
+
id name description type status schedule configuration createdAt
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
`,We=`
|
|
489
|
+
mutation MovethewheelsUpdateReport($id: ID!, $input: UpdateMovethewheelsReportInput!) {
|
|
490
|
+
updateMovethewheelsReport(id: $id, input: $input) {
|
|
491
|
+
id name description type status schedule configuration updatedAt
|
|
492
|
+
}
|
|
493
|
+
}
|
|
494
|
+
`,He=`
|
|
495
|
+
mutation MovethewheelsDeleteReport($id: ID!) {
|
|
496
|
+
deleteMovethewheelsReport(id: $id)
|
|
497
|
+
}
|
|
498
|
+
`,Je=`
|
|
499
|
+
mutation MovethewheelsGenerateReport($input: GenerateMovethewheelsReportInput!) {
|
|
500
|
+
generateMovethewheelsReport(input: $input) {
|
|
501
|
+
generatedAt result
|
|
502
|
+
report { id name type status lastGenerated }
|
|
503
|
+
}
|
|
504
|
+
}
|
|
505
|
+
`,ze=`
|
|
506
|
+
mutation MovethewheelsExportData($input: MovethewheelsExportDataInput!) {
|
|
507
|
+
exportData(input: $input) {
|
|
508
|
+
success message payload
|
|
509
|
+
}
|
|
510
|
+
}
|
|
511
|
+
`,Ye=`
|
|
512
|
+
mutation MovethewheelsImportData($input: MovethewheelsImportDataInput!) {
|
|
513
|
+
importData(input: $input) {
|
|
514
|
+
success message payload
|
|
515
|
+
}
|
|
516
|
+
}
|
|
517
|
+
`,Be=`
|
|
518
|
+
query MovethewheelsModuleSettings {
|
|
519
|
+
moduleSettings {
|
|
520
|
+
workspaceId preferences updatedAt
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
`,Ke=`
|
|
524
|
+
mutation MovethewheelsUpdateModuleSettings($input: UpdateMovethewheelsModuleSettingsInput!) {
|
|
525
|
+
updateModuleSettings(input: $input) {
|
|
526
|
+
workspaceId preferences updatedAt
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
`,Ze=`
|
|
530
|
+
query MovethewheelsAnalytics {
|
|
531
|
+
analytics {
|
|
532
|
+
orderTrend { label value }
|
|
533
|
+
revenueTrend { label value }
|
|
534
|
+
deliveryTrend { label value }
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
`,Qe=`
|
|
538
|
+
query MovethewheelsDashboardMetrics {
|
|
539
|
+
dashboardMetrics {
|
|
540
|
+
totalOrders activeDeliveries totalRevenue activeVehicles availableDrivers
|
|
541
|
+
lowStockItems
|
|
542
|
+
recentOrders { id orderNumber status priority createdAt }
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
`,Xe=`
|
|
546
|
+
query MovethewheelsFinanceMetrics {
|
|
547
|
+
financeMetrics {
|
|
548
|
+
fuelCost openInvoices
|
|
549
|
+
revenue { totalRevenue deliveredRevenue averageOrderValue }
|
|
550
|
+
}
|
|
551
|
+
}
|
|
552
|
+
`,et=`
|
|
553
|
+
query MovethewheelsFleetStats {
|
|
554
|
+
fleetStats {
|
|
555
|
+
totalVehicles activeVehicles inTransitVehicles maintenanceVehicles
|
|
556
|
+
totalDrivers availableDrivers onDeliveryDrivers
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
`,tt=`
|
|
560
|
+
query MovethewheelsAssistantInsights($question: String!) {
|
|
561
|
+
assistantInsights(question: $question) {
|
|
562
|
+
question answer generatedAt
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
`;function u(m,r){try{return JSON.parse(r)}catch{throw new o(`--${m} must be valid JSON`)}}function c(m){let r=Number.parseInt(m,10);if(Number.isNaN(r))throw new o(`Expected an integer but got "${m}"`);return r}function l(m){let r=Number.parseFloat(m);if(Number.isNaN(r))throw new o(`Expected a number but got "${m}"`);return r}function h(m){let r={};return m.limit!==void 0&&(r.limit=m.limit),m.offset!==void 0&&(r.offset=m.offset),Object.keys(r).length?r:void 0}function it(m){let r=m.command("customers").description("Movethewheels customers");r.command("list").description("List customers").option("--type <t>","Filter by customer type (b2c/b2b)").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.type&&(e.type=i.type),i.query&&(e.search=i.query);let t=await b$1(O,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.customers,{headers:["ID","Name","Type","Email","Phone","Rating"],rows:t.customers.map(n=>[p(n.id,12),n.name,n.type,n.email??"-",n.phone??"-",n.rating!=null?String(n.rating):"-"])});}catch(e){g(e);}}),r.command("get").description("Get a customer by id").argument("<id>","Customer ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(D,{id:i});if(!t.customer)throw new o(`Customer ${i} not found`);h$1(e,t.customer);}catch(t){g(t);}}),r.command("create").description("Create a customer").requiredOption("--name <name>","Customer name").option("--email <email>","Email").option("--phone <phone>","Phone").option("--company <company>","Company").option("--type <t>","Customer type","b2c").option("--tax-id <s>","Tax ID").option("--business-license <s>","Business license").option("--rating <n>","Rating",l).option("--address <json>","Address JSON").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={name:i$1.name,type:i$1.type??"b2c"};i$1.email&&(e.email=i$1.email),i$1.phone&&(e.phone=i$1.phone),i$1.company&&(e.company=i$1.company),i$1.taxId&&(e.taxId=i$1.taxId),i$1.businessLicense&&(e.businessLicense=i$1.businessLicense),i$1.rating!==void 0&&(e.rating=i$1.rating),i$1.address&&(e.address=u("address",i$1.address));let t=await b$1(R,{input:e});i(`Customer created: ${t.createCustomer.name}`),h$1(i$1,t.createCustomer);}catch(e){g(e);}}),r.command("update").description("Update a customer").argument("<id>","Customer ID").option("--name <name>","Customer name").option("--email <email>","Email").option("--phone <phone>","Phone").option("--company <company>","Company").option("--type <t>","Customer type").option("--tax-id <s>","Tax ID").option("--business-license <s>","Business license").option("--rating <n>","Rating",l).option("--address <json>","Address JSON").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.name&&(t.name=e.name),e.email!==void 0&&(t.email=e.email),e.phone!==void 0&&(t.phone=e.phone),e.company!==void 0&&(t.company=e.company),e.type&&(t.type=e.type),e.taxId!==void 0&&(t.taxId=e.taxId),e.businessLicense!==void 0&&(t.businessLicense=e.businessLicense),e.rating!==void 0&&(t.rating=e.rating),e.address&&(t.address=u("address",e.address)),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(b,{id:i$1,input:t});i("Customer updated"),h$1(e,n.updateCustomer);}catch(t){g(t);}}),r.command("remove").description("Delete a customer").argument("<id>","Customer ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(T,{id:i$1});i(`Customer ${i$1} deleted`),h$1(e,{deleted:t.deleteCustomer});}catch(t){g(t);}});}function nt(m){let r=m.command("drivers").description("Movethewheels drivers");r.command("list").description("List drivers").option("--status <s>","Filter by driver status").option("--vehicle <id>","Filter by vehicle ID").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.status&&(e.status=i.status.toUpperCase()),i.vehicle&&(e.vehicleId=i.vehicle),i.query&&(e.search=i.query);let t=await b$1(S,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.drivers,{headers:["ID","Name","Employee","Status","Vehicle","Rating"],rows:t.drivers.map(n=>[p(n.id,12),`${n.firstName} ${n.lastName}`,n.employeeId,n.status,n.vehicleId?p(n.vehicleId,12):"-",n.rating!=null?String(n.rating):"-"])});}catch(e){g(e);}}),r.command("get").description("Get a driver by id").argument("<id>","Driver ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(C,{id:i});if(!t.driver)throw new o(`Driver ${i} not found`);h$1(e,t.driver);}catch(t){g(t);}}),r.command("create").description("Create a driver").requiredOption("--employee-id <s>","Employee ID").requiredOption("--first-name <s>","First name").requiredOption("--last-name <s>","Last name").option("--email <email>","Email").option("--phone <phone>","Phone").option("--status <s>","Driver status","AVAILABLE").option("--license-number <s>","License number").option("--license-class <s>","License class").option("--license-expiry <s>","License expiry (ISO date)").option("--vehicle-id <id>","Vehicle ID").option("--user-id <id>","User ID").option("--rating <n>","Rating",l).option("--certifications <json>","Certifications JSON").option("--current-location <json>","Current location JSON").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={employeeId:i$1.employeeId,firstName:i$1.firstName,lastName:i$1.lastName,status:(i$1.status??"AVAILABLE").toUpperCase()};i$1.email&&(e.email=i$1.email),i$1.phone&&(e.phone=i$1.phone),i$1.licenseNumber&&(e.licenseNumber=i$1.licenseNumber),i$1.licenseClass&&(e.licenseClass=i$1.licenseClass),i$1.licenseExpiry&&(e.licenseExpiry=i$1.licenseExpiry),i$1.vehicleId&&(e.vehicleId=i$1.vehicleId),i$1.userId&&(e.userId=i$1.userId),i$1.rating!==void 0&&(e.rating=i$1.rating),i$1.certifications&&(e.certifications=u("certifications",i$1.certifications)),i$1.currentLocation&&(e.currentLocation=u("current-location",i$1.currentLocation));let t=await b$1(A,{input:e});i(`Driver created: ${t.createDriver.firstName} ${t.createDriver.lastName}`),h$1(i$1,t.createDriver);}catch(e){g(e);}}),r.command("update").description("Update a driver").argument("<id>","Driver ID").option("--first-name <s>","First name").option("--last-name <s>","Last name").option("--email <email>","Email").option("--phone <phone>","Phone").option("--status <s>","Driver status").option("--license-number <s>","License number").option("--license-class <s>","License class").option("--license-expiry <s>","License expiry (ISO date)").option("--vehicle-id <id>","Vehicle ID").option("--rating <n>","Rating",l).option("--certifications <json>","Certifications JSON").option("--current-location <json>","Current location JSON").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.firstName&&(t.firstName=e.firstName),e.lastName&&(t.lastName=e.lastName),e.email!==void 0&&(t.email=e.email),e.phone!==void 0&&(t.phone=e.phone),e.status&&(t.status=e.status.toUpperCase()),e.licenseNumber!==void 0&&(t.licenseNumber=e.licenseNumber),e.licenseClass!==void 0&&(t.licenseClass=e.licenseClass),e.licenseExpiry&&(t.licenseExpiry=e.licenseExpiry),e.vehicleId!==void 0&&(t.vehicleId=e.vehicleId),e.rating!==void 0&&(t.rating=e.rating),e.certifications&&(t.certifications=u("certifications",e.certifications)),e.currentLocation&&(t.currentLocation=u("current-location",e.currentLocation)),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(N,{id:i$1,input:t});i("Driver updated"),h$1(e,n.updateDriver);}catch(t){g(t);}}),r.command("remove").description("Delete a driver").argument("<id>","Driver ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(k,{id:i$1});i(`Driver ${i$1} deleted`),h$1(e,{deleted:t.deleteDriver});}catch(t){g(t);}}),r.command("set-status").description("Update a driver status").argument("<id>","Driver ID").requiredOption("--status <s>","AVAILABLE|ON_DELIVERY|ON_BREAK|OFF_DUTY|INACTIVE").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1($,{id:i$1,status:e.status.toUpperCase()});i(`Driver status set to ${t.updateDriverStatus.status}`),h$1(e,t.updateDriverStatus);}catch(t){g(t);}}),r.command("assign-vehicle").description("Assign (or clear) a vehicle for a driver").argument("<id>","Driver ID").option("--vehicle <id>","Vehicle ID (omit to clear assignment)").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(P,{id:i$1,vehicleId:e.vehicle});i(e.vehicle?`Vehicle ${e.vehicle} assigned`:"Vehicle assignment cleared"),h$1(e,t.assignDriverVehicle);}catch(t){g(t);}});}function rt(m){let r=m.command("vehicles").description("Movethewheels fleet vehicles");r.command("list").description("List vehicles").option("--type <t>","Filter by vehicle type").option("--status <s>","Filter by vehicle status").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.type&&(e.type=i.type.toUpperCase()),i.status&&(e.status=i.status.toUpperCase()),i.query&&(e.search=i.query);let t=await b$1(M,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.vehicles,{headers:["ID","Number","Type","Status","Make/Model","Plate"],rows:t.vehicles.map(n=>[p(n.id,12),n.vehicleNumber,n.type,n.status,`${n.make??"-"} ${n.model??""}`.trim(),n.licensePlate??"-"])});}catch(e){g(e);}}),r.command("get").description("Get a vehicle by id").argument("<id>","Vehicle ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(_,{id:i});if(!t.vehicle)throw new o(`Vehicle ${i} not found`);h$1(e,t.vehicle);}catch(t){g(t);}}),r.command("create").description("Create a vehicle").requiredOption("--number <s>","Vehicle number").requiredOption("--type <t>","Vehicle type (TRUCK|VAN|MOTORCYCLE|\u2026)").option("--status <s>","Vehicle status","ACTIVE").option("--make <s>","Make").option("--model <s>","Model").option("--year <n>","Year",c).option("--license-plate <s>","License plate").option("--fuel-level <n>","Fuel level",l).option("--mileage <n>","Mileage",l).option("--ownership-type <s>","Ownership type").option("--capacity <json>","Capacity JSON").option("--current-location <json>","Current location JSON").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={vehicleNumber:i$1.number,type:i$1.type.toUpperCase(),status:(i$1.status??"ACTIVE").toUpperCase()};i$1.make&&(e.make=i$1.make),i$1.model&&(e.model=i$1.model),i$1.year!==void 0&&(e.year=i$1.year),i$1.licensePlate&&(e.licensePlate=i$1.licensePlate),i$1.fuelLevel!==void 0&&(e.fuelLevel=i$1.fuelLevel),i$1.mileage!==void 0&&(e.mileage=i$1.mileage),i$1.ownershipType&&(e.ownershipType=i$1.ownershipType),i$1.capacity&&(e.capacity=u("capacity",i$1.capacity)),i$1.currentLocation&&(e.currentLocation=u("current-location",i$1.currentLocation));let t=await b$1(U,{input:e});i(`Vehicle created: ${t.createVehicle.vehicleNumber}`),h$1(i$1,t.createVehicle);}catch(e){g(e);}}),r.command("update").description("Update a vehicle").argument("<id>","Vehicle ID").option("--number <s>","Vehicle number").option("--type <t>","Vehicle type").option("--status <s>","Vehicle status").option("--make <s>","Make").option("--model <s>","Model").option("--year <n>","Year",c).option("--license-plate <s>","License plate").option("--fuel-level <n>","Fuel level",l).option("--mileage <n>","Mileage",l).option("--ownership-type <s>","Ownership type").option("--capacity <json>","Capacity JSON").option("--current-location <json>","Current location JSON").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.number&&(t.vehicleNumber=e.number),e.type&&(t.type=e.type.toUpperCase()),e.status&&(t.status=e.status.toUpperCase()),e.make!==void 0&&(t.make=e.make),e.model!==void 0&&(t.model=e.model),e.year!==void 0&&(t.year=e.year),e.licensePlate!==void 0&&(t.licensePlate=e.licensePlate),e.fuelLevel!==void 0&&(t.fuelLevel=e.fuelLevel),e.mileage!==void 0&&(t.mileage=e.mileage),e.ownershipType!==void 0&&(t.ownershipType=e.ownershipType),e.capacity&&(t.capacity=u("capacity",e.capacity)),e.currentLocation&&(t.currentLocation=u("current-location",e.currentLocation)),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(L,{id:i$1,input:t});i("Vehicle updated"),h$1(e,n.updateVehicle);}catch(t){g(t);}}),r.command("remove").description("Delete a vehicle").argument("<id>","Vehicle ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(V,{id:i$1});i(`Vehicle ${i$1} deleted`),h$1(e,{deleted:t.deleteVehicle});}catch(t){g(t);}}),r.command("set-status").description("Update a vehicle status").argument("<id>","Vehicle ID").requiredOption("--status <s>","ACTIVE|INACTIVE|IN_TRANSIT|MAINTENANCE|DECOMMISSIONED").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(q,{id:i$1,status:e.status.toUpperCase()});i(`Vehicle status set to ${t.updateVehicleStatus.status}`),h$1(e,t.updateVehicleStatus);}catch(t){g(t);}}),r.command("set-location").description("Update a vehicle current location").argument("<id>","Vehicle ID").requiredOption("--location <json>","Location JSON (latitude/longitude/\u2026)").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=u("location",e.location),n=await b$1(x,{id:i$1,location:t});i("Vehicle location updated"),h$1(e,n.updateVehicleLocation);}catch(t){g(t);}});}function at(m){let r=m.command("products").description("Movethewheels catalog products");r.command("list").description("List products").option("--category <c>","Filter by category").option("--sku <s>","Filter by SKU").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.category&&(e.category=i.category),i.sku&&(e.sku=i.sku),i.query&&(e.search=i.query);let t=await b$1(j,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.products,{headers:["ID","SKU","Name","Category","Brand","Weight"],rows:t.products.map(n=>[p(n.id,12),n.sku,n.name,n.category??"-",n.brand??"-",n.weight!=null?String(n.weight):"-"])});}catch(e){g(e);}}),r.command("get").description("Get a product by id").argument("<id>","Product ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(F,{id:i});if(!t.product)throw new o(`Product ${i} not found`);h$1(e,t.product);}catch(t){g(t);}}),r.command("create").description("Create a product").requiredOption("--name <name>","Product name").requiredOption("--sku <sku>","SKU").option("--description <s>","Description").option("--category <c>","Category").option("--brand <s>","Brand").option("--weight <n>","Weight",l).option("--value <n>","Value",l).option("--dimensions <json>","Dimensions JSON").option("--fragile","Mark as fragile").option("--hazardous","Mark as hazardous").option("--temperature-controlled","Mark as temperature controlled").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={name:i$1.name,sku:i$1.sku};i$1.description&&(e.description=i$1.description),i$1.category&&(e.category=i$1.category),i$1.brand&&(e.brand=i$1.brand),i$1.weight!==void 0&&(e.weight=i$1.weight),i$1.value!==void 0&&(e.value=i$1.value),i$1.dimensions&&(e.dimensions=u("dimensions",i$1.dimensions)),i$1.fragile&&(e.fragile=!0),i$1.hazardous&&(e.hazardous=!0),i$1.temperatureControlled&&(e.temperatureControlled=!0);let t=await b$1(G,{input:e});i(`Product created: ${t.createProduct.name}`),h$1(i$1,t.createProduct);}catch(e){g(e);}}),r.command("update").description("Update a product").argument("<id>","Product ID").option("--name <name>","Product name").option("--sku <sku>","SKU").option("--description <s>","Description").option("--category <c>","Category").option("--brand <s>","Brand").option("--weight <n>","Weight",l).option("--value <n>","Value",l).option("--dimensions <json>","Dimensions JSON").option("--fragile <bool>","true|false",i=>i==="true").option("--hazardous <bool>","true|false",i=>i==="true").option("--temperature-controlled <bool>","true|false",i=>i==="true").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.name&&(t.name=e.name),e.sku&&(t.sku=e.sku),e.description!==void 0&&(t.description=e.description),e.category!==void 0&&(t.category=e.category),e.brand!==void 0&&(t.brand=e.brand),e.weight!==void 0&&(t.weight=e.weight),e.value!==void 0&&(t.value=e.value),e.dimensions&&(t.dimensions=u("dimensions",e.dimensions)),e.fragile!==void 0&&(t.fragile=e.fragile),e.hazardous!==void 0&&(t.hazardous=e.hazardous),e.temperatureControlled!==void 0&&(t.temperatureControlled=e.temperatureControlled),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(W,{id:i$1,input:t});i("Product updated"),h$1(e,n.updateProduct);}catch(t){g(t);}}),r.command("remove").description("Delete a product").argument("<id>","Product ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(H,{id:i$1});i(`Product ${i$1} deleted`),h$1(e,{deleted:t.deleteProduct});}catch(t){g(t);}});}function ot(m){let r=m.command("warehouses").description("Movethewheels warehouses & locations");r.command("list").description("List warehouses").option("--type <t>","Filter by warehouse type").option("--status <s>","Filter by status").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.type&&(e.type=i.type.toUpperCase()),i.status&&(e.status=i.status),i.query&&(e.search=i.query);let t=await b$1(z,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.warehouses,{headers:["ID","Code","Name","Type","Status","Capacity"],rows:t.warehouses.map(n=>[p(n.id,12),n.code,n.name,n.type,n.status,`${n.usedCapacity??0}/${n.totalCapacity??0}`])});}catch(e){g(e);}}),r.command("get").description("Get a warehouse by id (includes locations)").argument("<id>","Warehouse ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(J,{id:i});if(!t.warehouse)throw new o(`Warehouse ${i} not found`);h$1(e,t.warehouse);}catch(t){g(t);}}),r.command("create").description("Create a warehouse").requiredOption("--code <code>","Warehouse code").requiredOption("--name <name>","Warehouse name").requiredOption("--type <t>","Warehouse type (DISTRIBUTION|FULFILLMENT|\u2026)").requiredOption("--address <json>","Address JSON").option("--status <s>","Status","ACTIVE").option("--contact-info <json>","Contact info JSON").option("--operating-hours <json>","Operating hours JSON").option("--capabilities <json>","Capabilities JSON").option("--total-capacity <n>","Total capacity",l).option("--used-capacity <n>","Used capacity",l).option("-f, --format <format>","Output format").action(async i$1=>{try{let e={code:i$1.code,name:i$1.name,type:i$1.type.toUpperCase(),address:u("address",i$1.address),status:i$1.status??"ACTIVE"};i$1.contactInfo&&(e.contactInfo=u("contact-info",i$1.contactInfo)),i$1.operatingHours&&(e.operatingHours=u("operating-hours",i$1.operatingHours)),i$1.capabilities&&(e.capabilities=u("capabilities",i$1.capabilities)),i$1.totalCapacity!==void 0&&(e.totalCapacity=i$1.totalCapacity),i$1.usedCapacity!==void 0&&(e.usedCapacity=i$1.usedCapacity);let t=await b$1(Y,{input:e});i(`Warehouse created: ${t.createWarehouse.name}`),h$1(i$1,t.createWarehouse);}catch(e){g(e);}}),r.command("update").description("Update a warehouse").argument("<id>","Warehouse ID").option("--code <code>","Warehouse code").option("--name <name>","Warehouse name").option("--type <t>","Warehouse type").option("--status <s>","Status").option("--address <json>","Address JSON").option("--contact-info <json>","Contact info JSON").option("--operating-hours <json>","Operating hours JSON").option("--capabilities <json>","Capabilities JSON").option("--total-capacity <n>","Total capacity",l).option("--used-capacity <n>","Used capacity",l).option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.code&&(t.code=e.code),e.name&&(t.name=e.name),e.type&&(t.type=e.type.toUpperCase()),e.status&&(t.status=e.status),e.address&&(t.address=u("address",e.address)),e.contactInfo&&(t.contactInfo=u("contact-info",e.contactInfo)),e.operatingHours&&(t.operatingHours=u("operating-hours",e.operatingHours)),e.capabilities&&(t.capabilities=u("capabilities",e.capabilities)),e.totalCapacity!==void 0&&(t.totalCapacity=e.totalCapacity),e.usedCapacity!==void 0&&(t.usedCapacity=e.usedCapacity),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(B,{id:i$1,input:t});i("Warehouse updated"),h$1(e,n.updateWarehouse);}catch(t){g(t);}}),r.command("remove").description("Delete a warehouse").argument("<id>","Warehouse ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(K,{id:i$1});i(`Warehouse ${i$1} deleted`),h$1(e,{deleted:t.deleteWarehouse});}catch(t){g(t);}}),r.command("create-location").description("Create a warehouse location").requiredOption("--warehouse <id>","Warehouse ID").requiredOption("--code <s>","Location code").option("--location-type <s>","Location type").option("--status <s>","Status","ACTIVE").option("--zone <s>","Zone").option("--aisle <s>","Aisle").option("--rack <s>","Rack").option("--shelf <s>","Shelf").option("--bin <s>","Bin").option("--capacity <n>","Capacity",l).option("-f, --format <format>","Output format").action(async i$1=>{try{let e={warehouseId:i$1.warehouse,locationCode:i$1.code,status:i$1.status??"ACTIVE"};i$1.locationType&&(e.locationType=i$1.locationType),i$1.zone&&(e.zone=i$1.zone),i$1.aisle&&(e.aisle=i$1.aisle),i$1.rack&&(e.rack=i$1.rack),i$1.shelf&&(e.shelf=i$1.shelf),i$1.bin&&(e.bin=i$1.bin),i$1.capacity!==void 0&&(e.capacity=i$1.capacity);let t=await b$1(Z,{input:e});i(`Location created: ${t.createWarehouseLocation.locationCode}`),h$1(i$1,t.createWarehouseLocation);}catch(e){g(e);}}),r.command("update-location").description("Update a warehouse location").argument("<id>","Location ID").option("--code <s>","Location code").option("--location-type <s>","Location type").option("--status <s>","Status").option("--zone <s>","Zone").option("--aisle <s>","Aisle").option("--rack <s>","Rack").option("--shelf <s>","Shelf").option("--bin <s>","Bin").option("--capacity <n>","Capacity",l).option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.code&&(t.locationCode=e.code),e.locationType!==void 0&&(t.locationType=e.locationType),e.status&&(t.status=e.status),e.zone!==void 0&&(t.zone=e.zone),e.aisle!==void 0&&(t.aisle=e.aisle),e.rack!==void 0&&(t.rack=e.rack),e.shelf!==void 0&&(t.shelf=e.shelf),e.bin!==void 0&&(t.bin=e.bin),e.capacity!==void 0&&(t.capacity=e.capacity),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(Q,{id:i$1,input:t});i("Location updated"),h$1(e,n.updateWarehouseLocation);}catch(t){g(t);}});}function st(m){let r={};return m.product&&(r.productId=m.product),m.warehouse&&(r.warehouseId=m.warehouse),m.location&&(r.locationId=m.location),m.query&&(r.search=m.query),Object.keys(r).length?r:void 0}function dt(m){let r=m.command("inventory").description("Movethewheels inventory");r.command("list").description("List inventory items").option("--product <id>","Filter by product ID").option("--warehouse <id>","Filter by warehouse ID").option("--location <id>","Filter by location ID").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(ee,{filter:st(i),pagination:h(i)});h$1(i,e.inventoryItems,{headers:["ID","Product","Warehouse","OnHand","Available","Allocated"],rows:e.inventoryItems.map(t=>[p(t.id,12),p(t.productId,12),p(t.warehouseId,12),String(t.onHand),String(t.available),String(t.allocated)])});}catch(e){g(e);}}),r.command("get").description("Get an inventory item by id").argument("<id>","Inventory item ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(X,{id:i});if(!t.inventoryItem)throw new o(`Inventory item ${i} not found`);h$1(e,t.inventoryItem);}catch(t){g(t);}}),r.command("stats").description("Inventory stats (on-hand, available, allocated, damaged, low-stock)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(ie);h$1(i,e.inventoryStats);}catch(e){g(e);}}),r.command("create").description("Create an inventory item").requiredOption("--product <id>","Product ID").requiredOption("--warehouse <id>","Warehouse ID").option("--location <id>","Location ID").option("--on-hand <n>","On-hand quantity",c).option("--available <n>","Available quantity",c).option("--allocated <n>","Allocated quantity",c).option("--damaged <n>","Damaged quantity",c).option("--reorder-point <n>","Reorder point",c).option("--safety-stock <n>","Safety stock",c).option("--unit-cost <n>","Unit cost",l).option("-f, --format <format>","Output format").action(async i$1=>{try{let e={productId:i$1.product,warehouseId:i$1.warehouse};i$1.location&&(e.locationId=i$1.location),i$1.onHand!==void 0&&(e.onHand=i$1.onHand),i$1.available!==void 0&&(e.available=i$1.available),i$1.allocated!==void 0&&(e.allocated=i$1.allocated),i$1.damaged!==void 0&&(e.damaged=i$1.damaged),i$1.reorderPoint!==void 0&&(e.reorderPoint=i$1.reorderPoint),i$1.safetyStock!==void 0&&(e.safetyStock=i$1.safetyStock),i$1.unitCost!==void 0&&(e.unitCost=i$1.unitCost);let t=await b$1(ne,{input:e});i("Inventory item created"),h$1(i$1,t.createInventoryItem);}catch(e){g(e);}}),r.command("update").description("Update an inventory item").argument("<id>","Inventory item ID").option("--location <id>","Location ID").option("--on-hand <n>","On-hand quantity",c).option("--available <n>","Available quantity",c).option("--allocated <n>","Allocated quantity",c).option("--damaged <n>","Damaged quantity",c).option("--reorder-point <n>","Reorder point",c).option("--safety-stock <n>","Safety stock",c).option("--unit-cost <n>","Unit cost",l).option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.location!==void 0&&(t.locationId=e.location),e.onHand!==void 0&&(t.onHand=e.onHand),e.available!==void 0&&(t.available=e.available),e.allocated!==void 0&&(t.allocated=e.allocated),e.damaged!==void 0&&(t.damaged=e.damaged),e.reorderPoint!==void 0&&(t.reorderPoint=e.reorderPoint),e.safetyStock!==void 0&&(t.safetyStock=e.safetyStock),e.unitCost!==void 0&&(t.unitCost=e.unitCost),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(re,{id:i$1,input:t});i("Inventory item updated"),h$1(e,n.updateInventoryItem);}catch(t){g(t);}}),r.command("remove").description("Delete an inventory item").argument("<id>","Inventory item ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(ae,{id:i$1});i(`Inventory item ${i$1} deleted`),h$1(e,{deleted:t.deleteInventoryItem});}catch(t){g(t);}}),r.command("adjust").description("Adjust inventory stock levels").argument("<id>","Inventory item ID").option("--on-hand <n>","On-hand quantity",c).option("--available <n>","Available quantity",c).option("--allocated <n>","Allocated quantity",c).option("--damaged <n>","Damaged quantity",c).option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={id:i$1};if(e.onHand!==void 0&&(t.onHand=e.onHand),e.available!==void 0&&(t.available=e.available),e.allocated!==void 0&&(t.allocated=e.allocated),e.damaged!==void 0&&(t.damaged=e.damaged),Object.keys(t).length===1)throw new o("No stock adjustments specified");let n=await b$1(oe,{input:t});i("Inventory stock adjusted"),h$1(e,n.adjustInventoryStock);}catch(t){g(t);}}),r.command("transactions").description("List inventory transactions").option("--product <id>","Filter by product ID").option("--warehouse <id>","Filter by warehouse ID").option("--location <id>","Filter by location ID").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(te,{filter:st(i),pagination:h(i)});h$1(i,e.inventoryTransactions,{headers:["ID","Number","Type","Product","Warehouse","Qty"],rows:e.inventoryTransactions.map(t=>[p(t.id,12),t.transactionNumber,t.type,p(t.productId,12),p(t.warehouseId,12),String(t.quantity)])});}catch(e){g(e);}}),r.command("record-transaction").description("Record an inventory transaction").requiredOption("--number <s>","Transaction number").requiredOption("--type <t>","Transaction type (RECEIPT|ISSUE|TRANSFER|ADJUSTMENT|RETURN)").requiredOption("--product <id>","Product ID").requiredOption("--warehouse <id>","Warehouse ID").requiredOption("--quantity <n>","Quantity",c).option("--inventory-item <id>","Inventory item ID").option("--unit-cost <n>","Unit cost",l).option("--reference-type <s>","Reference type").option("--reference-id <s>","Reference ID").option("--notes <s>","Notes").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={transactionNumber:i$1.number,type:i$1.type.toUpperCase(),productId:i$1.product,warehouseId:i$1.warehouse,quantity:i$1.quantity};i$1.inventoryItem&&(e.inventoryItemId=i$1.inventoryItem),i$1.unitCost!==void 0&&(e.unitCost=i$1.unitCost),i$1.referenceType&&(e.referenceType=i$1.referenceType),i$1.referenceId&&(e.referenceId=i$1.referenceId),i$1.notes&&(e.notes=i$1.notes);let t=await b$1(se,{input:e});i(`Transaction recorded: ${t.createInventoryTransaction.transactionNumber}`),h$1(i$1,t.createInventoryTransaction);}catch(e){g(e);}});}function ct(m){let r=m.command("orders").description("Movethewheels delivery orders");r.command("list").description("List orders").option("--customer <id>","Filter by customer ID").option("--driver <id>","Filter by driver ID").option("--vehicle <id>","Filter by vehicle ID").option("--status <s>","Filter by order status").option("--order-type <t>","Filter by order type").option("--priority <p>","Filter by priority").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.customer&&(e.customerId=i.customer),i.driver&&(e.driverId=i.driver),i.vehicle&&(e.vehicleId=i.vehicle),i.status&&(e.status=i.status.toUpperCase()),i.orderType&&(e.orderType=i.orderType.toUpperCase()),i.priority&&(e.priority=i.priority.toUpperCase()),i.query&&(e.search=i.query);let t=await b$1(ce,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.movethewheelsOrders,{headers:["ID","Order #","Type","Status","Priority","Tracking"],rows:t.movethewheelsOrders.map(n=>[p(n.id,12),n.orderNumber,n.orderType,n.status,n.priority,n.trackingNumber??"-"])});}catch(e){g(e);}}),r.command("get").description("Get an order by id").argument("<id>","Order ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(de,{id:i});if(!t.movethewheelsOrder)throw new o(`Order ${i} not found`);h$1(e,t.movethewheelsOrder);}catch(t){g(t);}}),r.command("create").description("Create an order").requiredOption("--customer <id>","Customer ID").requiredOption("--order-number <s>","Order number").requiredOption("--pickup-address <json>","Pickup address JSON").requiredOption("--delivery-address <json>","Delivery address JSON").requiredOption("--items <json>","Items JSON").option("--order-type <t>","Order type","B2C").option("--priority <p>","Priority","MEDIUM").option("--status <s>","Status","PENDING").option("--driver <id>","Driver ID").option("--vehicle <id>","Vehicle ID").option("--tracking-number <s>","Tracking number").option("--scheduled-delivery <s>","Scheduled delivery (ISO date)").option("--special-instructions <s>","Special instructions").option("--pricing <json>","Pricing JSON").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={customerId:i$1.customer,orderNumber:i$1.orderNumber,pickupAddress:u("pickup-address",i$1.pickupAddress),deliveryAddress:u("delivery-address",i$1.deliveryAddress),items:u("items",i$1.items),orderType:(i$1.orderType??"B2C").toUpperCase(),priority:(i$1.priority??"MEDIUM").toUpperCase(),status:(i$1.status??"PENDING").toUpperCase()};i$1.driver&&(e.driverId=i$1.driver),i$1.vehicle&&(e.vehicleId=i$1.vehicle),i$1.trackingNumber&&(e.trackingNumber=i$1.trackingNumber),i$1.scheduledDelivery&&(e.scheduledDelivery=i$1.scheduledDelivery),i$1.specialInstructions&&(e.specialInstructions=i$1.specialInstructions),i$1.pricing&&(e.pricing=u("pricing",i$1.pricing));let t=await b$1(pe,{input:e});i(`Order created: ${t.createMovethewheelsOrder.orderNumber}`),h$1(i$1,t.createMovethewheelsOrder);}catch(e){g(e);}}),r.command("update").description("Update an order").argument("<id>","Order ID").option("--customer <id>","Customer ID").option("--driver <id>","Driver ID").option("--vehicle <id>","Vehicle ID").option("--order-type <t>","Order type").option("--priority <p>","Priority").option("--status <s>","Status").option("--tracking-number <s>","Tracking number").option("--scheduled-delivery <s>","Scheduled delivery (ISO date)").option("--special-instructions <s>","Special instructions").option("--delivery-address <json>","Delivery address JSON").option("--pickup-address <json>","Pickup address JSON").option("--items <json>","Items JSON").option("--pricing <json>","Pricing JSON").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.customer&&(t.customerId=e.customer),e.driver!==void 0&&(t.driverId=e.driver),e.vehicle!==void 0&&(t.vehicleId=e.vehicle),e.orderType&&(t.orderType=e.orderType.toUpperCase()),e.priority&&(t.priority=e.priority.toUpperCase()),e.status&&(t.status=e.status.toUpperCase()),e.trackingNumber!==void 0&&(t.trackingNumber=e.trackingNumber),e.scheduledDelivery&&(t.scheduledDelivery=e.scheduledDelivery),e.specialInstructions!==void 0&&(t.specialInstructions=e.specialInstructions),e.deliveryAddress&&(t.deliveryAddress=u("delivery-address",e.deliveryAddress)),e.pickupAddress&&(t.pickupAddress=u("pickup-address",e.pickupAddress)),e.items&&(t.items=u("items",e.items)),e.pricing&&(t.pricing=u("pricing",e.pricing)),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(ue,{id:i$1,input:t});i("Order updated"),h$1(e,n.updateMovethewheelsOrder);}catch(t){g(t);}}),r.command("remove").description("Delete an order").argument("<id>","Order ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(me,{id:i$1});i(`Order ${i$1} deleted`),h$1(e,{deleted:t.deleteMovethewheelsOrder});}catch(t){g(t);}}),r.command("set-status").description("Update an order status").argument("<id>","Order ID").requiredOption("--status <s>","PENDING|CONFIRMED|ASSIGNED|PICKED_UP|IN_TRANSIT|OUT_FOR_DELIVERY|DELIVERED|FAILED|RETURNED|CANCELLED").option("--notes <s>","Status notes").option("--location <json>","Location JSON").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={status:e.status.toUpperCase()};e.notes&&(t.notes=e.notes),e.location&&(t.location=u("location",e.location));let n=await b$1(le,{id:i$1,input:t});i(`Order status set to ${n.updateMovethewheelsOrderStatus.status}`),h$1(e,n.updateMovethewheelsOrderStatus);}catch(t){g(t);}}),r.command("stats").description("Order stats (total, pending, in-transit, delivered, \u2026)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(fe);h$1(i,e.orderStats);}catch(e){g(e);}});}function pt(m){let r=m.command("shipments").description("Movethewheels shipments & tracking");r.command("list").description("List shipments").option("--order <id>","Filter by order ID").option("--customer <id>","Filter by customer ID").option("--carrier <id>","Filter by carrier ID").option("--status <s>","Filter by status").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.order&&(e.orderId=i.order),i.customer&&(e.customerId=i.customer),i.carrier&&(e.carrierId=i.carrier),i.status&&(e.status=i.status.toUpperCase()),i.query&&(e.search=i.query);let t=await b$1(he,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.shipments,{headers:["ID","Shipment #","Order","Status","Tracking"],rows:t.shipments.map(n=>[p(n.id,12),n.shipmentNumber,p(n.orderId,12),n.status,n.trackingNumber??"-"])});}catch(e){g(e);}}),r.command("get").description("Get a shipment by id (includes tracking events)").argument("<id>","Shipment ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(ge,{id:i});if(!t.shipment)throw new o(`Shipment ${i} not found`);h$1(e,t.shipment);}catch(t){g(t);}}),r.command("active").description("List active deliveries (in-transit shipments)").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(ye,{pagination:h(i)});h$1(i,e.activeDeliveries,{headers:["ID","Shipment #","Order","Status","Tracking"],rows:e.activeDeliveries.map(t=>[p(t.id,12),t.shipmentNumber,p(t.orderId,12),t.status,t.trackingNumber??"-"])});}catch(e){g(e);}}),r.command("create").description("Create a shipment").requiredOption("--shipment-number <s>","Shipment number").requiredOption("--order <id>","Order ID").requiredOption("--origin <json>","Origin JSON").requiredOption("--destination <json>","Destination JSON").option("--status <s>","Status","PLANNED").option("--customer <id>","Customer ID").option("--carrier <id>","Carrier ID").option("--tracking-number <s>","Tracking number").option("--cargo-details <json>","Cargo details JSON").option("--estimated-delivery <s>","Estimated delivery (ISO date)").option("--actual-delivery <s>","Actual delivery (ISO date)").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={shipmentNumber:i$1.shipmentNumber,orderId:i$1.order,origin:u("origin",i$1.origin),destination:u("destination",i$1.destination),status:(i$1.status??"PLANNED").toUpperCase()};i$1.customer&&(e.customerId=i$1.customer),i$1.carrier&&(e.carrierId=i$1.carrier),i$1.trackingNumber&&(e.trackingNumber=i$1.trackingNumber),i$1.cargoDetails&&(e.cargoDetails=u("cargo-details",i$1.cargoDetails)),i$1.estimatedDelivery&&(e.estimatedDelivery=i$1.estimatedDelivery),i$1.actualDelivery&&(e.actualDelivery=i$1.actualDelivery);let t=await b$1(Ee,{input:e});i(`Shipment created: ${t.createShipment.shipmentNumber}`),h$1(i$1,t.createShipment);}catch(e){g(e);}}),r.command("update").description("Update a shipment").argument("<id>","Shipment ID").option("--status <s>","Status").option("--customer <id>","Customer ID").option("--carrier <id>","Carrier ID").option("--tracking-number <s>","Tracking number").option("--origin <json>","Origin JSON").option("--destination <json>","Destination JSON").option("--cargo-details <json>","Cargo details JSON").option("--estimated-delivery <s>","Estimated delivery (ISO date)").option("--actual-delivery <s>","Actual delivery (ISO date)").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.status&&(t.status=e.status.toUpperCase()),e.customer!==void 0&&(t.customerId=e.customer),e.carrier!==void 0&&(t.carrierId=e.carrier),e.trackingNumber!==void 0&&(t.trackingNumber=e.trackingNumber),e.origin&&(t.origin=u("origin",e.origin)),e.destination&&(t.destination=u("destination",e.destination)),e.cargoDetails&&(t.cargoDetails=u("cargo-details",e.cargoDetails)),e.estimatedDelivery&&(t.estimatedDelivery=e.estimatedDelivery),e.actualDelivery&&(t.actualDelivery=e.actualDelivery),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(De,{id:i$1,input:t});i("Shipment updated"),h$1(e,n.updateShipment);}catch(t){g(t);}}),r.command("remove").description("Delete a shipment").argument("<id>","Shipment ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(Oe,{id:i$1});i(`Shipment ${i$1} deleted`),h$1(e,{deleted:t.deleteShipment});}catch(t){g(t);}}),r.command("add-event").description("Add a tracking event to a shipment").requiredOption("--shipment <id>","Shipment ID").requiredOption("--event-type <t>","CREATED|PICKED_UP|IN_TRANSIT|ARRIVED|DEPARTED|OUT_FOR_DELIVERY|DELIVERED|FAILED|RETURNED").option("--details <s>","Event details").option("--location <json>","Location JSON").option("--timestamp <s>","Timestamp (ISO date)").option("-f, --format <format>","Output format").action(async i$1=>{try{let e={shipmentId:i$1.shipment,eventType:i$1.eventType.toUpperCase()};i$1.details&&(e.details=i$1.details),i$1.location&&(e.location=u("location",i$1.location)),i$1.timestamp&&(e.timestamp=i$1.timestamp);let t=await b$1(Re,{input:e});i(`Tracking event added: ${t.addTrackingEvent.eventType}`),h$1(i$1,t.addTrackingEvent);}catch(e){g(e);}}),r.command("tracking").description("List tracking events for a shipment").argument("<shipmentId>","Shipment ID").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(ve,{shipmentId:i,pagination:h(e)});h$1(e,t.shipmentTracking,{headers:["ID","Event","Details","Timestamp"],rows:t.shipmentTracking.map(n=>[p(n.id,12),n.eventType,p(n.details??"-",30),n.timestamp])});}catch(t){g(t);}}),r.command("order-tracking").description("List tracking events for an order").argument("<orderId>","Order ID").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(Ie,{orderId:i,pagination:h(e)});h$1(e,t.orderTracking,{headers:["ID","Event","Details","Timestamp"],rows:t.orderTracking.map(n=>[p(n.id,12),n.eventType,p(n.details??"-",30),n.timestamp])});}catch(t){g(t);}}),r.command("alerts").description("List tracking alerts (delayed / at-risk shipments)").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(we,{pagination:h(i)});h$1(i,e.trackingAlerts,{headers:["Type","Shipment #","Message"],rows:e.trackingAlerts.map(t=>[t.alertType,t.shipmentNumber,p(t.message,40)])});}catch(e){g(e);}});}function ut(m){let r=m.command("routes").description("Movethewheels delivery routes");r.command("list").description("List routes").option("--driver <id>","Filter by driver ID").option("--vehicle <id>","Filter by vehicle ID").option("--shipment <id>","Filter by shipment ID").option("--status <s>","Filter by status").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async i=>{try{let e={};i.driver&&(e.driverId=i.driver),i.vehicle&&(e.vehicleId=i.vehicle),i.shipment&&(e.shipmentId=i.shipment),i.status&&(e.status=i.status.toUpperCase()),i.query&&(e.search=i.query);let t=await b$1(Te,{filter:Object.keys(e).length?e:void 0,pagination:h(i)});h$1(i,t.routes,{headers:["ID","Name","Status","Driver","Vehicle","Distance"],rows:t.routes.map(n=>[p(n.id,12),n.name,n.status,n.driverId?p(n.driverId,12):"-",n.vehicleId?p(n.vehicleId,12):"-",n.estimatedDistance!=null?String(n.estimatedDistance):"-"])});}catch(e){g(e);}}),r.command("get").description("Get a route by id").argument("<id>","Route ID").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(be,{id:i});if(!t.route)throw new o(`Route ${i} not found`);h$1(e,t.route);}catch(t){g(t);}}),r.command("create").description("Create a route").requiredOption("--name <name>","Route name").requiredOption("--waypoints <json>","Waypoints JSON").option("--status <s>","Status","PLANNED").option("--driver <id>","Driver ID").option("--vehicle <id>","Vehicle ID").option("--shipment <id>","Shipment ID").option("--estimated-distance <n>","Estimated distance",l).option("--estimated-duration <n>","Estimated duration",l).option("--actual-distance <n>","Actual distance",l).option("--actual-duration <n>","Actual duration",l).option("--fuel-cost <n>","Fuel cost",l).option("-f, --format <format>","Output format").action(async i$1=>{try{let e={name:i$1.name,waypoints:u("waypoints",i$1.waypoints),status:(i$1.status??"PLANNED").toUpperCase()};i$1.driver&&(e.driverId=i$1.driver),i$1.vehicle&&(e.vehicleId=i$1.vehicle),i$1.shipment&&(e.shipmentId=i$1.shipment),i$1.estimatedDistance!==void 0&&(e.estimatedDistance=i$1.estimatedDistance),i$1.estimatedDuration!==void 0&&(e.estimatedDuration=i$1.estimatedDuration),i$1.actualDistance!==void 0&&(e.actualDistance=i$1.actualDistance),i$1.actualDuration!==void 0&&(e.actualDuration=i$1.actualDuration),i$1.fuelCost!==void 0&&(e.fuelCost=i$1.fuelCost);let t=await b$1(Ce,{input:e});i(`Route created: ${t.createRoute.name}`),h$1(i$1,t.createRoute);}catch(e){g(e);}}),r.command("update").description("Update a route").argument("<id>","Route ID").option("--name <name>","Route name").option("--status <s>","Status").option("--driver <id>","Driver ID").option("--vehicle <id>","Vehicle ID").option("--shipment <id>","Shipment ID").option("--waypoints <json>","Waypoints JSON").option("--estimated-distance <n>","Estimated distance",l).option("--estimated-duration <n>","Estimated duration",l).option("--actual-distance <n>","Actual distance",l).option("--actual-duration <n>","Actual duration",l).option("--fuel-cost <n>","Fuel cost",l).option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t={};if(e.name&&(t.name=e.name),e.status&&(t.status=e.status.toUpperCase()),e.driver!==void 0&&(t.driverId=e.driver),e.vehicle!==void 0&&(t.vehicleId=e.vehicle),e.shipment!==void 0&&(t.shipmentId=e.shipment),e.waypoints&&(t.waypoints=u("waypoints",e.waypoints)),e.estimatedDistance!==void 0&&(t.estimatedDistance=e.estimatedDistance),e.estimatedDuration!==void 0&&(t.estimatedDuration=e.estimatedDuration),e.actualDistance!==void 0&&(t.actualDistance=e.actualDistance),e.actualDuration!==void 0&&(t.actualDuration=e.actualDuration),e.fuelCost!==void 0&&(t.fuelCost=e.fuelCost),!Object.keys(t).length)throw new o("No updates specified");let n=await b$1(Se,{id:i$1,input:t});i("Route updated"),h$1(e,n.updateRoute);}catch(t){g(t);}}),r.command("remove").description("Delete a route").argument("<id>","Route ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(Ae,{id:i$1});i(`Route ${i$1} deleted`),h$1(e,{deleted:t.deleteRoute});}catch(t){g(t);}}),r.command("optimize").description("Optimize a route").argument("<id>","Route ID").option("-f, --format <format>","Output format").action(async(i$1,e)=>{try{let t=await b$1(Ne,{id:i$1});i("Route optimized"),h$1(e,t.optimizeRoute);}catch(t){g(t);}});}function mt(m){let r=m.command("marketplace").description("Movethewheels logistics marketplace (providers & offerings)"),i$1=r.command("providers").description("Service providers");i$1.command("list").description("List service providers").option("--type <t>","Filter by provider type").option("--active <bool>","Filter by active state (true|false)",t=>t==="true").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async t=>{try{let n={};t.type&&(n.type=t.type),t.active!==void 0&&(n.isActive=t.active),t.query&&(n.search=t.query);let d=await b$1($e,{filter:Object.keys(n).length?n:void 0,pagination:h(t)});h$1(t,d.serviceProviders,{headers:["ID","Name","Type","Active","Verified","Rating"],rows:d.serviceProviders.map(y=>[p(y.id,12),y.name,y.type,y.isActive?"yes":"no",y.isVerified?"yes":"no",y.rating!=null?String(y.rating):"-"])});}catch(n){g(n);}}),i$1.command("get").description("Get a service provider by id (includes offerings)").argument("<id>","Provider ID").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d=await b$1(ke,{id:t});if(!d.serviceProvider)throw new o(`Provider ${t} not found`);h$1(n,d.serviceProvider);}catch(d){g(d);}}),i$1.command("create").description("Create a service provider").requiredOption("--name <name>","Provider name").requiredOption("--type <t>","Provider type").option("--description <s>","Description").option("--rating <n>","Rating",l).option("--active <bool>","Active (true|false)",t=>t==="true",true).option("--verified <bool>","Verified (true|false)",t=>t==="true",false).option("--contact-info <json>","Contact info JSON").option("--services <json>","Services JSON").option("-f, --format <format>","Output format").action(async t=>{try{let n={name:t.name,type:t.type,isActive:t.active??!0,isVerified:t.verified??!1};t.description&&(n.description=t.description),t.rating!==void 0&&(n.rating=t.rating),t.contactInfo&&(n.contactInfo=u("contact-info",t.contactInfo)),t.services&&(n.services=u("services",t.services));let d=await b$1(Pe,{input:n});i(`Provider created: ${d.createServiceProvider.name}`),h$1(t,d.createServiceProvider);}catch(n){g(n);}}),i$1.command("update").description("Update a service provider").argument("<id>","Provider ID").option("--name <name>","Provider name").option("--type <t>","Provider type").option("--description <s>","Description").option("--rating <n>","Rating",l).option("--active <bool>","Active (true|false)",t=>t==="true").option("--verified <bool>","Verified (true|false)",t=>t==="true").option("--contact-info <json>","Contact info JSON").option("--services <json>","Services JSON").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d={};if(n.name&&(d.name=n.name),n.type&&(d.type=n.type),n.description!==void 0&&(d.description=n.description),n.rating!==void 0&&(d.rating=n.rating),n.active!==void 0&&(d.isActive=n.active),n.verified!==void 0&&(d.isVerified=n.verified),n.contactInfo&&(d.contactInfo=u("contact-info",n.contactInfo)),n.services&&(d.services=u("services",n.services)),!Object.keys(d).length)throw new o("No updates specified");let y=await b$1(_e,{id:t,input:d});i("Provider updated"),h$1(n,y.updateServiceProvider);}catch(d){g(d);}}),i$1.command("remove").description("Delete a service provider").argument("<id>","Provider ID").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d=await b$1(Me,{id:t});i(`Provider ${t} deleted`),h$1(n,{deleted:d.deleteServiceProvider});}catch(d){g(d);}});let e=r.command("offerings").description("Service offerings");e.command("list").description("List service offerings").option("--provider <id>","Filter by provider ID").option("--category <c>","Filter by category").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async t=>{try{let n={};t.provider&&(n.providerId=t.provider),t.category&&(n.category=t.category),t.query&&(n.search=t.query);let d=await b$1(Le,{filter:Object.keys(n).length?n:void 0,pagination:h(t)});h$1(t,d.serviceOfferings,{headers:["ID","Name","Provider","Category","Price","Currency"],rows:d.serviceOfferings.map(y=>[p(y.id,12),y.name,p(y.providerId,12),y.category??"-",String(y.price),y.currency])});}catch(n){g(n);}}),e.command("get").description("Get a service offering by id").argument("<id>","Offering ID").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d=await b$1(Ue,{id:t});if(!d.serviceOffering)throw new o(`Offering ${t} not found`);h$1(n,d.serviceOffering);}catch(d){g(d);}}),e.command("create").description("Create a service offering").requiredOption("--provider <id>","Provider ID").requiredOption("--name <name>","Offering name").requiredOption("--price <n>","Price",l).option("--description <s>","Description").option("--category <c>","Category").option("--currency <c>","Currency","USD").option("--availability <json>","Availability JSON").option("-f, --format <format>","Output format").action(async t=>{try{let n={providerId:t.provider,name:t.name,price:t.price,currency:t.currency??"USD"};t.description&&(n.description=t.description),t.category&&(n.category=t.category),t.availability&&(n.availability=u("availability",t.availability));let d=await b$1(Ve,{input:n});i(`Offering created: ${d.createServiceOffering.name}`),h$1(t,d.createServiceOffering);}catch(n){g(n);}}),e.command("update").description("Update a service offering").argument("<id>","Offering ID").option("--name <name>","Offering name").option("--description <s>","Description").option("--category <c>","Category").option("--price <n>","Price",l).option("--currency <c>","Currency").option("--availability <json>","Availability JSON").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d={};if(n.name&&(d.name=n.name),n.description!==void 0&&(d.description=n.description),n.category!==void 0&&(d.category=n.category),n.price!==void 0&&(d.price=n.price),n.currency&&(d.currency=n.currency),n.availability&&(d.availability=u("availability",n.availability)),!Object.keys(d).length)throw new o("No updates specified");let y=await b$1(qe,{id:t,input:d});i("Offering updated"),h$1(n,y.updateServiceOffering);}catch(d){g(d);}}),e.command("remove").description("Delete a service offering").argument("<id>","Offering ID").option("-f, --format <format>","Output format").action(async(t,n)=>{try{let d=await b$1(xe,{id:t});i(`Offering ${t} deleted`),h$1(n,{deleted:d.deleteServiceOffering});}catch(d){g(d);}});}function lt(m){let r=m.command("reports").description("Movethewheels reports & data import/export");r.command("list").description("List reports").option("--type <t>","Filter by report type").option("--status <s>","Filter by status").option("--query <q>","Free-text search").option("--limit <n>","Page size",c,50).option("--offset <n>","Offset",c,0).option("-f, --format <format>","Output format").action(async e=>{try{let t={};e.type&&(t.type=e.type),e.status&&(t.status=e.status),e.query&&(t.search=e.query);let n=await b$1(je,{filter:Object.keys(t).length?t:void 0,pagination:h(e)});h$1(e,n.movethewheelsReports,{headers:["ID","Name","Type","Status","Schedule","Last Generated"],rows:n.movethewheelsReports.map(d=>[p(d.id,12),d.name,d.type,d.status,d.schedule??"-",d.lastGenerated??"-"])});}catch(t){g(t);}}),r.command("get").description("Get a report by id").argument("<id>","Report ID").option("-f, --format <format>","Output format").action(async(e,t)=>{try{let n=await b$1(Fe,{id:e});if(!n.movethewheelsReport)throw new o(`Report ${e} not found`);h$1(t,n.movethewheelsReport);}catch(n){g(n);}}),r.command("create").description("Create a report").requiredOption("--name <name>","Report name").requiredOption("--type <t>","Report type").option("--description <s>","Description").option("--status <s>","Status","DRAFT").option("--schedule <s>","Schedule (cron-like)").option("--configuration <json>","Configuration JSON").option("-f, --format <format>","Output format").action(async e=>{try{let t={name:e.name,type:e.type,status:e.status??"DRAFT"};e.description&&(t.description=e.description),e.schedule&&(t.schedule=e.schedule),e.configuration&&(t.configuration=u("configuration",e.configuration));let n=await b$1(Ge,{input:t});i(`Report created: ${n.createMovethewheelsReport.name}`),h$1(e,n.createMovethewheelsReport);}catch(t){g(t);}}),r.command("update").description("Update a report").argument("<id>","Report ID").option("--name <name>","Report name").option("--type <t>","Report type").option("--description <s>","Description").option("--status <s>","Status").option("--schedule <s>","Schedule (cron-like)").option("--configuration <json>","Configuration JSON").option("-f, --format <format>","Output format").action(async(e,t)=>{try{let n={};if(t.name&&(n.name=t.name),t.type&&(n.type=t.type),t.description!==void 0&&(n.description=t.description),t.status&&(n.status=t.status),t.schedule!==void 0&&(n.schedule=t.schedule),t.configuration&&(n.configuration=u("configuration",t.configuration)),!Object.keys(n).length)throw new o("No updates specified");let d=await b$1(We,{id:e,input:n});i("Report updated"),h$1(t,d.updateMovethewheelsReport);}catch(n){g(n);}}),r.command("remove").description("Delete a report").argument("<id>","Report ID").option("-f, --format <format>","Output format").action(async(e,t)=>{try{let n=await b$1(He,{id:e});i(`Report ${e} deleted`),h$1(t,{deleted:n.deleteMovethewheelsReport});}catch(n){g(n);}}),r.command("generate").description("Generate a report run").argument("<id>","Report ID").option("--parameters <json>","Parameters JSON").option("-f, --format <format>","Output format").action(async(e,t)=>{try{let n={reportId:e};t.parameters&&(n.parameters=u("parameters",t.parameters));let d=await b$1(Je,{input:n});i("Report generated"),h$1(t,d.generateMovethewheelsReport);}catch(n){g(n);}}),r.command("export").description("Export resource data").requiredOption("--resource <r>","Resource to export").option("--export-format <f>","Export format","json").option("-f, --format <format>","Output format").action(async e=>{try{let t={resource:e.resource,format:e.exportFormat??"json"},n=await b$1(ze,{input:t});i("Data exported"),h$1(e,n.exportData);}catch(t){g(t);}}),r.command("import").description("Import resource data").requiredOption("--resource <r>","Resource to import").requiredOption("--payload <json>","Payload JSON").option("-f, --format <format>","Output format").action(async e=>{try{let t={resource:e.resource,payload:u("payload",e.payload)},n=await b$1(Ye,{input:t});i("Data imported"),h$1(e,n.importData);}catch(t){g(t);}});let i$1=m.command("settings").description("Movethewheels module settings");i$1.command("get").description("Get module settings").option("-f, --format <format>","Output format").action(async e=>{try{let t=await b$1(Be);h$1(e,t.moduleSettings);}catch(t){g(t);}}),i$1.command("update").description("Update module settings preferences").requiredOption("--preferences <json>","Preferences JSON").option("-f, --format <format>","Output format").action(async e=>{try{let t={preferences:u("preferences",e.preferences)},n=await b$1(Ke,{input:t});i("Module settings updated"),h$1(e,n.updateModuleSettings);}catch(t){g(t);}});}function ft(m){let r=m.command("analytics").description("Movethewheels analytics & dashboards");r.command("dashboard").description("Dashboard metrics (orders, deliveries, revenue, fleet, low stock)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(Qe);h$1(i,e.dashboardMetrics);}catch(e){g(e);}}),r.command("trends").description("Analytics time series (order, revenue, delivery trends)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(Ze);h$1(i,e.analytics);}catch(e){g(e);}}),r.command("finance").description("Finance metrics (revenue, fuel cost, open invoices)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(Xe);h$1(i,e.financeMetrics);}catch(e){g(e);}}),r.command("fleet").description("Fleet stats (vehicles & drivers by status)").option("-f, --format <format>","Output format").action(async i=>{try{let e=await b$1(et);h$1(i,e.fleetStats);}catch(e){g(e);}}),r.command("insights").description("AI assistant insights for a question").argument("<question>","Question to ask the assistant").option("-f, --format <format>","Output format").action(async(i,e)=>{try{let t=await b$1(tt,{question:i});h$1(e,t.assistantInsights);}catch(t){g(t);}});}var gt={id:"movethewheels",version:"1.0.0",displayName:"Movethewheels",dependsOn:["auth","workspaces"],register(m,r){a(r);let i=m.command("movethewheels").description("Movethewheels logistics & fleet operations");it(i),nt(i),rt(i),at(i),ot(i),dt(i),ct(i),pt(i),ut(i),mt(i),lt(i),ft(i);}},vi=gt;export{vi as default};
|