@burdenoff/microfe-movethewheels 2026.1102.2 → 2026.1107.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.
@@ -334,6 +334,18 @@ export type CustomerFilterInput = {
334
334
  type?: InputMaybe<Scalars['String']['input']>;
335
335
  };
336
336
 
337
+ export type DecideMtwFreightInvoiceInput = {
338
+ comparisonId: Scalars['ID']['input'];
339
+ decision: MtwFreightInvoiceDecision;
340
+ /** Required for DISPUTED: the invoice row ids under dispute. */
341
+ disputedLineIds?: InputMaybe<Array<Scalars['ID']['input']>>;
342
+ expectedSequence: Scalars['Int']['input'];
343
+ idempotencyKey: Scalars['String']['input'];
344
+ /** Required for DISPUTED and ACCEPTED_WITH_VARIANCE. */
345
+ reason?: InputMaybe<Scalars['String']['input']>;
346
+ shipmentId: Scalars['ID']['input'];
347
+ };
348
+
337
349
  export type DeliveryJobFilterInput = {
338
350
  customerId?: InputMaybe<Scalars['ID']['input']>;
339
351
  driverId?: InputMaybe<Scalars['ID']['input']>;
@@ -424,6 +436,14 @@ export type FuelType =
424
436
  | 'HYBRID'
425
437
  | 'PETROL';
426
438
 
439
+ export type HandOffMtwFreightInvoiceSettlementInput = {
440
+ comparisonId: Scalars['ID']['input'];
441
+ expectedSequence: Scalars['Int']['input'];
442
+ idempotencyKey: Scalars['String']['input'];
443
+ note?: InputMaybe<Scalars['String']['input']>;
444
+ shipmentId: Scalars['ID']['input'];
445
+ };
446
+
427
447
  export type HoldMtwContainerInput = {
428
448
  containerId: Scalars['ID']['input'];
429
449
  evidence: Array<MtwContainerEvidenceInput>;
@@ -1080,6 +1100,21 @@ export type MtwContainerSuitability =
1080
1100
  | 'REJECTED'
1081
1101
  | 'REVIEW_REQUIRED';
1082
1102
 
1103
+ export type MtwCreateReportInput = {
1104
+ description?: InputMaybe<Scalars['String']['input']>;
1105
+ frequency?: InputMaybe<MtwReportFrequency>;
1106
+ isActive?: InputMaybe<Scalars['Boolean']['input']>;
1107
+ name: Scalars['String']['input'];
1108
+ /** Defaults to the interval between scheduled runs (1, 7 or 30 days), or 30 when not scheduled. */
1109
+ periodDays?: InputMaybe<Scalars['Int']['input']>;
1110
+ runHour?: InputMaybe<Scalars['Int']['input']>;
1111
+ runMonthDay?: InputMaybe<Scalars['Int']['input']>;
1112
+ runWeekday?: InputMaybe<Scalars['Int']['input']>;
1113
+ /** Defaults to the workspace's MoveTheWheels time zone, else UTC. */
1114
+ timezone?: InputMaybe<Scalars['String']['input']>;
1115
+ type: MtwReportType;
1116
+ };
1117
+
1083
1118
  export type MtwCreateServiceOfferingInput = {
1084
1119
  availability?: InputMaybe<MtwServiceAvailability>;
1085
1120
  category: MtwServiceOfferingCategory;
@@ -1343,9 +1378,28 @@ export type MtwDemandForecastPoint = {
1343
1378
  predictedRevenue: Scalars['Float']['output'];
1344
1379
  predictedVolume: Scalars['Int']['output'];
1345
1380
  scopeKey: Scalars['String']['output'];
1381
+ /** Display name: the customer's name for CUSTOMER rows, `Origin → Destination` for LANE rows. */
1382
+ scopeLabel: Scalars['String']['output'];
1346
1383
  scopeType: DemandForecastScope;
1347
1384
  };
1348
1385
 
1386
+ /**
1387
+ * When the workspace's forecast was last recalculated. Reads refresh a forecast
1388
+ * that is more than six hours old or was made before the current ISO week.
1389
+ */
1390
+ export type MtwDemandForecastRunStatus = {
1391
+ __typename?: 'MtwDemandForecastRunStatus';
1392
+ /** A recalculation started within the last 15 minutes and has not finished. */
1393
+ inProgress: Scalars['Boolean']['output'];
1394
+ lastCompletedAt?: Maybe<Scalars['DateTime']['output']>;
1395
+ lastRowsWritten: Scalars['Int']['output'];
1396
+ /** The most recent recalculation failed; it is retried after 15 minutes. */
1397
+ lastRunFailed: Scalars['Boolean']['output'];
1398
+ lastStartedAt: Scalars['DateTime']['output'];
1399
+ /** The next forecast read will recalculate first. */
1400
+ stale: Scalars['Boolean']['output'];
1401
+ };
1402
+
1349
1403
  export type MtwDemandForecastVariance = {
1350
1404
  __typename?: 'MtwDemandForecastVariance';
1351
1405
  actualRevenue: Scalars['Float']['output'];
@@ -1356,6 +1410,8 @@ export type MtwDemandForecastVariance = {
1356
1410
  predictedVolume: Scalars['Int']['output'];
1357
1411
  revenueVariance: Scalars['Float']['output'];
1358
1412
  scopeKey: Scalars['String']['output'];
1413
+ /** Display name: the customer's name for CUSTOMER rows, `Origin → Destination` for LANE rows. */
1414
+ scopeLabel: Scalars['String']['output'];
1359
1415
  scopeType: DemandForecastScope;
1360
1416
  volumeVariance: Scalars['Int']['output'];
1361
1417
  };
@@ -1412,6 +1468,52 @@ export type MtwDriver = {
1412
1468
  workspaceId: Scalars['ID']['output'];
1413
1469
  };
1414
1470
 
1471
+ /** The calling driver's delivery day: the mobile driver task list (BOFF-3991). */
1472
+ export type MtwDriverDay = {
1473
+ __typename?: 'MtwDriverDay';
1474
+ completedStops: Scalars['Int']['output'];
1475
+ /** The requested local calendar date (YYYY-MM-DD). */
1476
+ date: Scalars['String']['output'];
1477
+ /** The calling actor's Driver record, or null when the actor is not a driver in this workspace. */
1478
+ driverId?: Maybe<Scalars['ID']['output']>;
1479
+ driverName?: Maybe<Scalars['String']['output']>;
1480
+ /** The first stop awaiting capture, else the first upcoming stop. */
1481
+ nextStop?: Maybe<MtwDriverStop>;
1482
+ remainingStops: Scalars['Int']['output'];
1483
+ stops: Array<MtwDriverStop>;
1484
+ totalStops: Scalars['Int']['output'];
1485
+ windowEnd: Scalars['DateTime']['output'];
1486
+ windowStart: Scalars['DateTime']['output'];
1487
+ };
1488
+
1489
+ /** One stop in the calling driver's day, in driving sequence order. */
1490
+ export type MtwDriverStop = {
1491
+ __typename?: 'MtwDriverStop';
1492
+ /** True while the job is out for delivery / in transit and can take an ePOD capture. */
1493
+ awaitingCapture: Scalars['Boolean']['output'];
1494
+ /** When the ePOD was captured, for completed stops. */
1495
+ deliveredAt?: Maybe<Scalars['DateTime']['output']>;
1496
+ deliveryJob: MtwDeliveryJob;
1497
+ /** An open job scheduled before the requested day that carried over onto today. */
1498
+ overdue: Scalars['Boolean']['output'];
1499
+ routeId?: Maybe<Scalars['ID']['output']>;
1500
+ routeName?: Maybe<Scalars['String']['output']>;
1501
+ /** 1-based position in the driver's sequence for the day. */
1502
+ sequence: Scalars['Int']['output'];
1503
+ state: MtwDriverStopState;
1504
+ };
1505
+
1506
+ /**
1507
+ * Where a stop sits in the calling driver's day (BOFF-3991): COMPLETED once
1508
+ * delivered, EN_ROUTE while out for delivery / in transit (ePOD capture is
1509
+ * possible), UPCOMING before dispatch, FAILED for failed or returned jobs.
1510
+ */
1511
+ export type MtwDriverStopState =
1512
+ | 'COMPLETED'
1513
+ | 'EN_ROUTE'
1514
+ | 'FAILED'
1515
+ | 'UPCOMING';
1516
+
1415
1517
  export type MtwDriverSuggestion = {
1416
1518
  __typename?: 'MtwDriverSuggestion';
1417
1519
  driver: MtwDriver;
@@ -2232,6 +2334,11 @@ export type MtwFreightInvoiceComparisonPage = {
2232
2334
  total: Scalars['Int']['output'];
2233
2335
  };
2234
2336
 
2337
+ export type MtwFreightInvoiceDecision =
2338
+ | 'ACCEPTED'
2339
+ | 'ACCEPTED_WITH_VARIANCE'
2340
+ | 'DISPUTED';
2341
+
2235
2342
  export type MtwFreightInvoiceEstimatePin = {
2236
2343
  __typename?: 'MtwFreightInvoiceEstimatePin';
2237
2344
  acceptance: MtwFreightInvoiceAcceptance;
@@ -2321,6 +2428,105 @@ export type MtwFreightInvoiceReason =
2321
2428
  | 'UNKNOWN_DISPOSITION'
2322
2429
  | 'UNKNOWN_EXPECTED_CHARGE_COVERAGE';
2323
2430
 
2431
+ export type MtwFreightInvoiceResolution =
2432
+ | 'ACCEPTED'
2433
+ | 'ACCEPTED_WITH_VARIANCE';
2434
+
2435
+ export type MtwFreightInvoiceReview = {
2436
+ __typename?: 'MtwFreightInvoiceReview';
2437
+ /** Lifecycle steps open to the caller. Gateway permissions still apply. */
2438
+ allowedActions: Array<MtwFreightInvoiceReviewAction>;
2439
+ comparisonCreatedBy: Scalars['ID']['output'];
2440
+ comparisonId: Scalars['ID']['output'];
2441
+ comparisonRecordedAt: Scalars['DateTime']['output'];
2442
+ currency: MtwFreightCurrency;
2443
+ events: Array<MtwFreightInvoiceReviewEvent>;
2444
+ /** False when at least one reported row has no amount. */
2445
+ invoiceAmountComplete: Scalars['Boolean']['output'];
2446
+ invoiceIdentityId: Scalars['ID']['output'];
2447
+ invoiceReference: Scalars['String']['output'];
2448
+ /** Sum of the reported invoice amounts that are known. */
2449
+ knownInvoiceAmountMinor: Scalars['String']['output'];
2450
+ latestRevision: Scalars['Int']['output'];
2451
+ /** True when this revision's open dispute was closed by a newer correction revision. */
2452
+ resolvedByCorrection: Scalars['Boolean']['output'];
2453
+ revision: Scalars['Int']['output'];
2454
+ /** Sequence of the last review event (0 when none); pass it as expectedSequence. */
2455
+ sequence: Scalars['Int']['output'];
2456
+ settlementReference?: Maybe<Scalars['String']['output']>;
2457
+ shipmentId: Scalars['ID']['output'];
2458
+ status: MtwFreightInvoiceReviewStatus;
2459
+ supersededByComparisonId?: Maybe<Scalars['ID']['output']>;
2460
+ supplierLabel?: Maybe<Scalars['String']['output']>;
2461
+ supplierReference: Scalars['String']['output'];
2462
+ viewerIsAuthor: Scalars['Boolean']['output'];
2463
+ };
2464
+
2465
+ export type MtwFreightInvoiceReviewAction =
2466
+ | 'DECIDE'
2467
+ | 'HAND_OFF_SETTLEMENT'
2468
+ | 'RECORD_SUPPLIER_RESPONSE'
2469
+ | 'RESOLVE_DISPUTE';
2470
+
2471
+ export type MtwFreightInvoiceReviewEvent = {
2472
+ __typename?: 'MtwFreightInvoiceReviewEvent';
2473
+ actorProvenance: Scalars['String']['output'];
2474
+ comparisonId: Scalars['ID']['output'];
2475
+ createdBy: Scalars['ID']['output'];
2476
+ /** The decision for DECISION, or the accepting outcome for DISPUTE_RESOLUTION. */
2477
+ decision?: Maybe<MtwFreightInvoiceDecision>;
2478
+ disputedLineIds: Array<Scalars['ID']['output']>;
2479
+ id: Scalars['ID']['output'];
2480
+ kind: MtwFreightInvoiceReviewEventKind;
2481
+ onBehalfOf?: Maybe<Scalars['ID']['output']>;
2482
+ previousEventId?: Maybe<Scalars['ID']['output']>;
2483
+ /** Dispute or variance reason, supplier response text, resolution reason or hand-off note. */
2484
+ reason?: Maybe<Scalars['String']['output']>;
2485
+ recordedAt: Scalars['DateTime']['output'];
2486
+ sequence: Scalars['Int']['output'];
2487
+ settlementReference?: Maybe<Scalars['String']['output']>;
2488
+ statusAfter: MtwFreightInvoiceReviewStatus;
2489
+ };
2490
+
2491
+ export type MtwFreightInvoiceReviewEventKind =
2492
+ | 'DECISION'
2493
+ | 'DISPUTE_RESOLUTION'
2494
+ | 'SETTLEMENT_HANDOFF'
2495
+ | 'SUPPLIER_RESPONSE';
2496
+
2497
+ export type MtwFreightInvoiceReviewPage = {
2498
+ __typename?: 'MtwFreightInvoiceReviewPage';
2499
+ hasMore: Scalars['Boolean']['output'];
2500
+ items: Array<MtwFreightInvoiceReview>;
2501
+ limit: Scalars['Int']['output'];
2502
+ nextOffset?: Maybe<Scalars['Int']['output']>;
2503
+ offset: Scalars['Int']['output'];
2504
+ total: Scalars['Int']['output'];
2505
+ };
2506
+
2507
+ /** Review status of one exact invoice comparison revision, derived from its append-only review events. */
2508
+ export type MtwFreightInvoiceReviewStatus =
2509
+ | 'ACCEPTED'
2510
+ | 'ACCEPTED_WITH_VARIANCE'
2511
+ | 'AWAITING_REVIEW'
2512
+ | 'DISPUTED'
2513
+ | 'SETTLEMENT_HANDED_OFF'
2514
+ /** A newer correction revision exists; review continues on that revision. */
2515
+ | 'SUPERSEDED'
2516
+ | 'SUPPLIER_RESPONDED';
2517
+
2518
+ /** Counts over the latest revision of every recorded carrier invoice in the workspace. */
2519
+ export type MtwFreightInvoiceReviewSummary = {
2520
+ __typename?: 'MtwFreightInvoiceReviewSummary';
2521
+ accepted: Scalars['Int']['output'];
2522
+ acceptedWithVariance: Scalars['Int']['output'];
2523
+ awaitingReview: Scalars['Int']['output'];
2524
+ disputed: Scalars['Int']['output'];
2525
+ settlementHandedOff: Scalars['Int']['output'];
2526
+ supplierResponded: Scalars['Int']['output'];
2527
+ total: Scalars['Int']['output'];
2528
+ };
2529
+
2324
2530
  export type MtwFreightInvoiceRow = {
2325
2531
  __typename?: 'MtwFreightInvoiceRow';
2326
2532
  amountMinor?: Maybe<Scalars['String']['output']>;
@@ -2551,6 +2757,13 @@ export type MtwFuelVolumeObservationInput = {
2551
2757
  sourceRevision?: InputMaybe<Scalars['String']['input']>;
2552
2758
  };
2553
2759
 
2760
+ export type MtwGenerateReportInput = {
2761
+ /** Defaults to now. */
2762
+ periodEnd?: InputMaybe<Scalars['DateTime']['input']>;
2763
+ /** Defaults to `periodEnd` minus the report's `periodDays`. */
2764
+ periodStart?: InputMaybe<Scalars['DateTime']['input']>;
2765
+ };
2766
+
2554
2767
  export type MtwImportColumn = {
2555
2768
  __typename?: 'MtwImportColumn';
2556
2769
  allowedValues?: Maybe<Array<Scalars['String']['output']>>;
@@ -2730,7 +2943,8 @@ export type MtwIntegrationProvider =
2730
2943
  | 'DESCARTES'
2731
2944
  | 'FOURKITES'
2732
2945
  | 'GENERIC_WEBHOOK'
2733
- | 'PROJECT44';
2946
+ | 'PROJECT44'
2947
+ | 'SHIPROCKET';
2734
2948
 
2735
2949
  export type MtwInventoryItem = {
2736
2950
  __typename?: 'MtwInventoryItem';
@@ -3421,6 +3635,168 @@ export type MtwProofOfDelivery = {
3421
3635
  workspaceId: Scalars['ID']['output'];
3422
3636
  };
3423
3637
 
3638
+ /** A saved report definition. */
3639
+ export type MtwReport = {
3640
+ __typename?: 'MtwReport';
3641
+ createdAt: Scalars['DateTime']['output'];
3642
+ createdBy: Scalars['String']['output'];
3643
+ description?: Maybe<Scalars['String']['output']>;
3644
+ frequency: MtwReportFrequency;
3645
+ id: Scalars['ID']['output'];
3646
+ /** Paused reports keep their schedule but are not generated automatically. */
3647
+ isActive: Scalars['Boolean']['output'];
3648
+ lastError?: Maybe<Scalars['String']['output']>;
3649
+ lastGeneratedAt?: Maybe<Scalars['DateTime']['output']>;
3650
+ /** COMPLETED or FAILED, from the latest generation. */
3651
+ lastRunStatus?: Maybe<Scalars['String']['output']>;
3652
+ /** The most recent run, if the report was ever generated. */
3653
+ latestRun?: Maybe<MtwReportRun>;
3654
+ name: Scalars['String']['output'];
3655
+ /** Next automatic generation; null when the report is not scheduled or is paused. */
3656
+ nextRunAt?: Maybe<Scalars['DateTime']['output']>;
3657
+ /**
3658
+ * Days of history a generation covers when no explicit period is given. A
3659
+ * scheduled run covers this many days up to the time it was due.
3660
+ */
3661
+ periodDays: Scalars['Int']['output'];
3662
+ /** Local hour (0-23) in `timezone` at which a scheduled report runs. */
3663
+ runHour: Scalars['Int']['output'];
3664
+ /** Day of the month (1-28) a MONTHLY report runs on. */
3665
+ runMonthDay: Scalars['Int']['output'];
3666
+ /** ISO weekday (1 = Monday ... 7 = Sunday) a WEEKLY report runs on. */
3667
+ runWeekday: Scalars['Int']['output'];
3668
+ /** Runs of this report, newest first (the latest 30 are kept). */
3669
+ runs: Array<MtwReportRun>;
3670
+ /** IANA time zone the schedule is evaluated in. */
3671
+ timezone: Scalars['String']['output'];
3672
+ type: MtwReportType;
3673
+ updatedAt: Scalars['DateTime']['output'];
3674
+ updatedBy?: Maybe<Scalars['String']['output']>;
3675
+ workspaceId: Scalars['ID']['output'];
3676
+ };
3677
+
3678
+
3679
+ /** A saved report definition. */
3680
+ export type MtwReportRunsArgs = {
3681
+ pagination?: InputMaybe<PaginationInput>;
3682
+ };
3683
+
3684
+ /** A column of a report run's detail rows. */
3685
+ export type MtwReportColumn = {
3686
+ __typename?: 'MtwReportColumn';
3687
+ /** Key of this column's value in each row object. */
3688
+ key: Scalars['String']['output'];
3689
+ /** TEXT, NUMBER, CURRENCY, DATE (ISO 8601 string) or BOOLEAN. */
3690
+ kind: Scalars['String']['output'];
3691
+ label: Scalars['String']['output'];
3692
+ };
3693
+
3694
+ /** A downloadable report run. */
3695
+ export type MtwReportExport = {
3696
+ __typename?: 'MtwReportExport';
3697
+ content: Scalars['String']['output'];
3698
+ contentType: Scalars['String']['output'];
3699
+ filename: Scalars['String']['output'];
3700
+ rowCount: Scalars['Int']['output'];
3701
+ truncated: Scalars['Boolean']['output'];
3702
+ };
3703
+
3704
+ export type MtwReportFilterInput = {
3705
+ frequency?: InputMaybe<MtwReportFrequency>;
3706
+ isActive?: InputMaybe<Scalars['Boolean']['input']>;
3707
+ /** Case-insensitive match on name and description. */
3708
+ search?: InputMaybe<Scalars['String']['input']>;
3709
+ type?: InputMaybe<MtwReportType>;
3710
+ };
3711
+
3712
+ export type MtwReportFormat =
3713
+ | 'CSV'
3714
+ | 'JSON';
3715
+
3716
+ /** How often a report is generated automatically. */
3717
+ export type MtwReportFrequency =
3718
+ | 'DAILY'
3719
+ | 'MONTHLY'
3720
+ | 'NONE'
3721
+ | 'WEEKLY';
3722
+
3723
+ /** A headline figure of a report run, computed over the whole period. */
3724
+ export type MtwReportMetric = {
3725
+ __typename?: 'MtwReportMetric';
3726
+ /** ISO 4217 code for CURRENCY figures when known. */
3727
+ currency?: Maybe<Scalars['String']['output']>;
3728
+ key: Scalars['String']['output'];
3729
+ /** NUMBER, CURRENCY, PERCENT (a 0-1 ratio), DISTANCE (km) or WEIGHT (kg). */
3730
+ kind: Scalars['String']['output'];
3731
+ label: Scalars['String']['output'];
3732
+ value?: Maybe<Scalars['Float']['output']>;
3733
+ };
3734
+
3735
+ /** One generation of a report. */
3736
+ export type MtwReportRun = {
3737
+ __typename?: 'MtwReportRun';
3738
+ columns: Array<MtwReportColumn>;
3739
+ createdBy: Scalars['String']['output'];
3740
+ durationMs?: Maybe<Scalars['Int']['output']>;
3741
+ error?: Maybe<Scalars['String']['output']>;
3742
+ finishedAt?: Maybe<Scalars['DateTime']['output']>;
3743
+ id: Scalars['ID']['output'];
3744
+ metrics: Array<MtwReportMetric>;
3745
+ periodEnd: Scalars['DateTime']['output'];
3746
+ periodStart: Scalars['DateTime']['output'];
3747
+ /** The report this run belongs to. Resolves even if the report was later deleted. */
3748
+ report?: Maybe<MtwReport>;
3749
+ reportId: Scalars['ID']['output'];
3750
+ reportType: MtwReportType;
3751
+ rowCount: Scalars['Int']['output'];
3752
+ /**
3753
+ * Detail rows as objects keyed by column key, in the order generated. Pages of
3754
+ * at most 500.
3755
+ */
3756
+ rows: Array<Scalars['JSON']['output']>;
3757
+ startedAt: Scalars['DateTime']['output'];
3758
+ /** RUNNING, COMPLETED or FAILED. */
3759
+ status: Scalars['String']['output'];
3760
+ /** MANUAL or SCHEDULED. */
3761
+ trigger: Scalars['String']['output'];
3762
+ /** True when the period had more rows than the 5,000 a run stores. Metrics still cover everything. */
3763
+ truncated: Scalars['Boolean']['output'];
3764
+ workspaceId: Scalars['ID']['output'];
3765
+ };
3766
+
3767
+
3768
+ /** One generation of a report. */
3769
+ export type MtwReportRunRowsArgs = {
3770
+ pagination?: InputMaybe<PaginationInput>;
3771
+ };
3772
+
3773
+ /** The workspace's scheduled-reports job in the platform scheduler. */
3774
+ export type MtwReportSchedule = {
3775
+ __typename?: 'MtwReportSchedule';
3776
+ cronExpression: Scalars['String']['output'];
3777
+ lastError?: Maybe<Scalars['String']['output']>;
3778
+ lastFiredAt?: Maybe<Scalars['DateTime']['output']>;
3779
+ schedulerJobId?: Maybe<Scalars['String']['output']>;
3780
+ /** PENDING, REGISTERING (a registration is in progress), ACTIVE or FAILED. */
3781
+ status: Scalars['String']['output'];
3782
+ timezone: Scalars['String']['output'];
3783
+ updatedAt: Scalars['DateTime']['output'];
3784
+ workspaceId: Scalars['ID']['output'];
3785
+ };
3786
+
3787
+ /** What a report covers. */
3788
+ export type MtwReportType =
3789
+ /** Every customer with their orders, deliveries and revenue in the period. */
3790
+ | 'CUSTOMERS'
3791
+ /** Order revenue, delivered and outstanding amounts, and freight cost in the period, per currency. */
3792
+ | 'FINANCE'
3793
+ /** Every vehicle with its orders, completed routes, distance, fuel cost and emissions in the period. */
3794
+ | 'FLEET'
3795
+ /** Every stock line with its levels, value and movements in the period. */
3796
+ | 'INVENTORY'
3797
+ /** Shipments booked in the period: status, lanes, on-time delivery and freight cost. */
3798
+ | 'OPERATIONS';
3799
+
3424
3800
  export type MtwReuseApprovalKind =
3425
3801
  | 'APPROVED'
3426
3802
  | 'REJECTED'
@@ -3845,6 +4221,22 @@ export type MtwRunRiskSweepInput = {
3845
4221
  triggerData?: InputMaybe<Scalars['JSON']['input']>;
3846
4222
  };
3847
4223
 
4224
+ /** Execution context the platform scheduler adds when it fires the job. */
4225
+ export type MtwRunScheduledReportsInput = {
4226
+ idempotencyKey?: InputMaybe<Scalars['String']['input']>;
4227
+ triggerData?: InputMaybe<Scalars['JSON']['input']>;
4228
+ };
4229
+
4230
+ /** Outcome of one scheduled-reports fire. */
4231
+ export type MtwScheduledReportsRun = {
4232
+ __typename?: 'MtwScheduledReportsRun';
4233
+ ranAt: Scalars['DateTime']['output'];
4234
+ reportsDue: Scalars['Int']['output'];
4235
+ reportsFailed: Scalars['Int']['output'];
4236
+ reportsGenerated: Scalars['Int']['output'];
4237
+ runs: Array<MtwReportRun>;
4238
+ };
4239
+
3848
4240
  /** Whether the provider currently has capacity for an offering. */
3849
4241
  export type MtwServiceAvailability =
3850
4242
  | 'AVAILABLE'
@@ -4622,6 +5014,19 @@ export type MtwTripUtilizationSummary = {
4622
5014
  unknownFactsSegmentCount: Scalars['Int']['output'];
4623
5015
  };
4624
5016
 
5017
+ export type MtwUpdateReportInput = {
5018
+ description?: InputMaybe<Scalars['String']['input']>;
5019
+ frequency?: InputMaybe<MtwReportFrequency>;
5020
+ isActive?: InputMaybe<Scalars['Boolean']['input']>;
5021
+ name?: InputMaybe<Scalars['String']['input']>;
5022
+ periodDays?: InputMaybe<Scalars['Int']['input']>;
5023
+ runHour?: InputMaybe<Scalars['Int']['input']>;
5024
+ runMonthDay?: InputMaybe<Scalars['Int']['input']>;
5025
+ runWeekday?: InputMaybe<Scalars['Int']['input']>;
5026
+ timezone?: InputMaybe<Scalars['String']['input']>;
5027
+ type?: InputMaybe<MtwReportType>;
5028
+ };
5029
+
4625
5030
  export type MtwUpdateServiceOfferingInput = {
4626
5031
  availability?: InputMaybe<MtwServiceAvailability>;
4627
5032
  category?: InputMaybe<MtwServiceOfferingCategory>;
@@ -4856,6 +5261,7 @@ export type Mutation = {
4856
5261
  createInventoryItem: MtwInventoryItem;
4857
5262
  createInventoryTransaction: MtwInventoryTransaction;
4858
5263
  createMtwPickTaskIntent: MtwPickTask;
5264
+ createMtwReport: MtwReport;
4859
5265
  createRoute: MtwRoute;
4860
5266
  createServiceOffering: MtwServiceOffering;
4861
5267
  createServiceProvider: MtwServiceProvider;
@@ -4863,12 +5269,16 @@ export type Mutation = {
4863
5269
  createVehicle: MtwVehicle;
4864
5270
  createWarehouse: MtwWarehouse;
4865
5271
  createWarehouseLocation: MtwWarehouseLocation;
5272
+ /** Accept, accept with variance, or dispute the latest revision. The comparison author cannot decide. */
5273
+ decideMtwFreightInvoice: MtwFreightInvoiceReview;
4866
5274
  deleteCargoItem: Scalars['Boolean']['output'];
4867
5275
  deleteCustomer: Scalars['Boolean']['output'];
4868
5276
  deleteDeliveryJob: Scalars['Boolean']['output'];
4869
5277
  deleteDriver: Scalars['Boolean']['output'];
4870
5278
  deleteIntegration: Scalars['Boolean']['output'];
4871
5279
  deleteInventoryItem: Scalars['Boolean']['output'];
5280
+ /** Soft-deletes the report and stops its schedule. Its past runs stay readable. */
5281
+ deleteMtwReport: Scalars['Boolean']['output'];
4872
5282
  deleteRoute: Scalars['Boolean']['output'];
4873
5283
  deleteServiceOffering: Scalars['Boolean']['output'];
4874
5284
  /** Soft-deletes the provider and its offerings. Shipments that already reference it keep the reference. */
@@ -4877,12 +5287,18 @@ export type Mutation = {
4877
5287
  deleteVehicle: Scalars['Boolean']['output'];
4878
5288
  deleteWarehouse: Scalars['Boolean']['output'];
4879
5289
  exportMtwEntities: MtwExportJob;
5290
+ /** Generate the report now and store the run. */
5291
+ generateMtwReport: MtwReportRun;
5292
+ /** Hand an accepted revision to platform Billing for settlement. MoveTheWheels keeps no ledger. */
5293
+ handOffMtwFreightInvoiceSettlement: MtwFreightInvoiceReview;
4880
5294
  holdMtwContainer: MtwContainerHold;
4881
5295
  importMtwCargoItems: MtwImportResult;
4882
5296
  importMtwCustomers: MtwImportResult;
4883
5297
  importMtwDrivers: MtwImportResult;
4884
5298
  importMtwVehicles: MtwImportResult;
4885
5299
  importMtwWarehouses: MtwImportResult;
5300
+ /** Register, verify or repair the workspace's scheduled-reports job. Idempotent. */
5301
+ mtwEnsureReportSchedule?: Maybe<MtwReportSchedule>;
4886
5302
  /**
4887
5303
  * Register, verify or repair the workspace's risk sweep with the platform
4888
5304
  * scheduler. Idempotent; leaves a job an operator paused alone.
@@ -4901,6 +5317,12 @@ export type Mutation = {
4901
5317
  * actor; a workspace user may also run it on demand.
4902
5318
  */
4903
5319
  mtwRunRiskSweep: MtwRiskSweep;
5320
+ /**
5321
+ * Generate every scheduled report whose next run has passed. Fired hourly by
5322
+ * wspace-scheduler-svc as this service's own service actor; a workspace user
5323
+ * may also run it on demand.
5324
+ */
5325
+ mtwRunScheduledReports: MtwScheduledReportsRun;
4904
5326
  openMtwContainerCycle: MtwContainerCycle;
4905
5327
  openMtwFreeTimeClock: MtwFreeTimeClock;
4906
5328
  optimizeRoute: MtwRoute;
@@ -4915,6 +5337,7 @@ export type Mutation = {
4915
5337
  recordMtwEquipmentReuseApproval: MtwEquipmentReuseApproval;
4916
5338
  recordMtwFreeTimeAgreement: MtwFreeTimeAgreement;
4917
5339
  recordMtwFreeTimeExtensionDecision: MtwFreeTimeExtensionDecision;
5340
+ recordMtwFreightInvoiceSupplierResponse: MtwFreightInvoiceReview;
4918
5341
  recordMtwProcedureDeviation: MtwProcedureDeviation;
4919
5342
  recordMtwProcedureStep: MtwProcedureStepDecision;
4920
5343
  recordMtwReuseProposal: MtwReuseProposal;
@@ -4927,6 +5350,8 @@ export type Mutation = {
4927
5350
  releaseMtwContainerHold: MtwContainerReleaseDecision;
4928
5351
  removeShipmentLeg: Scalars['Boolean']['output'];
4929
5352
  requestMtwFreeTimeExtension: MtwFreeTimeExtension;
5353
+ /** Close an open dispute by acceptance. A dispute can also close through a correction revision. */
5354
+ resolveMtwFreightInvoiceDispute: MtwFreightInvoiceReview;
4930
5355
  revokeMtwInspectorQualification: MtwInspectorQualification;
4931
5356
  revokeMtwPickTaskReview: MtwPickReview;
4932
5357
  revokeMtwProcedureDeviation: MtwProcedureDeviation;
@@ -4950,6 +5375,7 @@ export type Mutation = {
4950
5375
  updateMtwCustomerNotificationSettings: MtwCustomerNotificationSettings;
4951
5376
  /** Save the workspace's MoveTheWheels operational defaults. Every field is validated. */
4952
5377
  updateMtwModuleSettings: MtwModuleSettings;
5378
+ updateMtwReport: MtwReport;
4953
5379
  updateRoute: MtwRoute;
4954
5380
  updateServiceOffering: MtwServiceOffering;
4955
5381
  updateServiceProvider: MtwServiceProvider;
@@ -5068,6 +5494,11 @@ export type MutationCreateMtwPickTaskIntentArgs = {
5068
5494
  };
5069
5495
 
5070
5496
 
5497
+ export type MutationCreateMtwReportArgs = {
5498
+ input: MtwCreateReportInput;
5499
+ };
5500
+
5501
+
5071
5502
  export type MutationCreateRouteArgs = {
5072
5503
  input: CreateRouteInput;
5073
5504
  };
@@ -5103,6 +5534,11 @@ export type MutationCreateWarehouseLocationArgs = {
5103
5534
  };
5104
5535
 
5105
5536
 
5537
+ export type MutationDecideMtwFreightInvoiceArgs = {
5538
+ input: DecideMtwFreightInvoiceInput;
5539
+ };
5540
+
5541
+
5106
5542
  export type MutationDeleteCargoItemArgs = {
5107
5543
  id: Scalars['ID']['input'];
5108
5544
  };
@@ -5133,6 +5569,11 @@ export type MutationDeleteInventoryItemArgs = {
5133
5569
  };
5134
5570
 
5135
5571
 
5572
+ export type MutationDeleteMtwReportArgs = {
5573
+ id: Scalars['ID']['input'];
5574
+ };
5575
+
5576
+
5136
5577
  export type MutationDeleteRouteArgs = {
5137
5578
  id: Scalars['ID']['input'];
5138
5579
  };
@@ -5168,6 +5609,17 @@ export type MutationExportMtwEntitiesArgs = {
5168
5609
  };
5169
5610
 
5170
5611
 
5612
+ export type MutationGenerateMtwReportArgs = {
5613
+ id: Scalars['ID']['input'];
5614
+ input?: InputMaybe<MtwGenerateReportInput>;
5615
+ };
5616
+
5617
+
5618
+ export type MutationHandOffMtwFreightInvoiceSettlementArgs = {
5619
+ input: HandOffMtwFreightInvoiceSettlementInput;
5620
+ };
5621
+
5622
+
5171
5623
  export type MutationHoldMtwContainerArgs = {
5172
5624
  input: HoldMtwContainerInput;
5173
5625
  };
@@ -5208,6 +5660,11 @@ export type MutationMtwRunRiskSweepArgs = {
5208
5660
  };
5209
5661
 
5210
5662
 
5663
+ export type MutationMtwRunScheduledReportsArgs = {
5664
+ input?: InputMaybe<MtwRunScheduledReportsInput>;
5665
+ };
5666
+
5667
+
5211
5668
  export type MutationOpenMtwContainerCycleArgs = {
5212
5669
  input: OpenMtwContainerCycleInput;
5213
5670
  };
@@ -5278,6 +5735,11 @@ export type MutationRecordMtwFreeTimeExtensionDecisionArgs = {
5278
5735
  };
5279
5736
 
5280
5737
 
5738
+ export type MutationRecordMtwFreightInvoiceSupplierResponseArgs = {
5739
+ input: RecordMtwFreightInvoiceSupplierResponseInput;
5740
+ };
5741
+
5742
+
5281
5743
  export type MutationRecordMtwProcedureDeviationArgs = {
5282
5744
  input: RecordMtwProcedureDeviationInput;
5283
5745
  };
@@ -5339,6 +5801,11 @@ export type MutationRequestMtwFreeTimeExtensionArgs = {
5339
5801
  };
5340
5802
 
5341
5803
 
5804
+ export type MutationResolveMtwFreightInvoiceDisputeArgs = {
5805
+ input: ResolveMtwFreightInvoiceDisputeInput;
5806
+ };
5807
+
5808
+
5342
5809
  export type MutationRevokeMtwInspectorQualificationArgs = {
5343
5810
  input: RevokeMtwInspectorQualificationInput;
5344
5811
  };
@@ -5453,6 +5920,12 @@ export type MutationUpdateMtwModuleSettingsArgs = {
5453
5920
  };
5454
5921
 
5455
5922
 
5923
+ export type MutationUpdateMtwReportArgs = {
5924
+ id: Scalars['ID']['input'];
5925
+ input: MtwUpdateReportInput;
5926
+ };
5927
+
5928
+
5456
5929
  export type MutationUpdateRouteArgs = {
5457
5930
  id: Scalars['ID']['input'];
5458
5931
  input: UpdateRouteInput;
@@ -5619,6 +6092,8 @@ export type Query = {
5619
6092
  deliveryJobsCount: Scalars['Int']['output'];
5620
6093
  demandForecastByCustomer: Array<MtwDemandForecastPoint>;
5621
6094
  demandForecastByLane: Array<MtwDemandForecastPoint>;
6095
+ /** Null until the workspace's forecast has been calculated once. */
6096
+ demandForecastRunStatus?: Maybe<MtwDemandForecastRunStatus>;
5622
6097
  demandForecastVariance: Array<MtwDemandForecastVariance>;
5623
6098
  driver?: Maybe<MtwDriver>;
5624
6099
  drivers: Array<MtwDriver>;
@@ -5686,6 +6161,10 @@ export type Query = {
5686
6161
  /** Null is not proof of no effect and never authorizes resubmission. Exact original actor/context only. */
5687
6162
  mtwFreightInvoiceComparisonByRequestKey?: Maybe<MtwFreightInvoiceComparison>;
5688
6163
  mtwFreightInvoiceComparisonPage: MtwFreightInvoiceComparisonPage;
6164
+ mtwFreightInvoiceReview: MtwFreightInvoiceReview;
6165
+ /** Latest revision of each recorded invoice, newest first. */
6166
+ mtwFreightInvoiceReviewPage: MtwFreightInvoiceReviewPage;
6167
+ mtwFreightInvoiceReviewSummary: MtwFreightInvoiceReviewSummary;
5689
6168
  /**
5690
6169
  * Columns accepted by each import, for building templates and showing guidance.
5691
6170
  * This is static reference metadata with no workspace data in it, so it only
@@ -5707,6 +6186,15 @@ export type Query = {
5707
6186
  mtwProcedureStepPage: MtwProcedureStepPage;
5708
6187
  mtwProcedureVersion: MtwProcedureVersion;
5709
6188
  mtwProcedureVersionPage: MtwProcedureVersionPage;
6189
+ mtwReport?: Maybe<MtwReport>;
6190
+ mtwReportRun?: Maybe<MtwReportRun>;
6191
+ /** A completed run as a CSV or JSON file. */
6192
+ mtwReportRunExport: MtwReportExport;
6193
+ mtwReportRuns: Array<MtwReportRun>;
6194
+ /** The workspace's scheduled-reports job; null until a report is first scheduled. */
6195
+ mtwReportSchedule?: Maybe<MtwReportSchedule>;
6196
+ mtwReports: Array<MtwReport>;
6197
+ mtwReportsCount: Scalars['Int']['output'];
5710
6198
  mtwReuseEligibility: MtwReuseEligibility;
5711
6199
  mtwReuseProposalPage: MtwReuseProposalPage;
5712
6200
  mtwReuseReservationPage: MtwReuseReservationPage;
@@ -5723,6 +6211,16 @@ export type Query = {
5723
6211
  mtwStockObservation: MtwStockObservation;
5724
6212
  mtwStockObservationPage: MtwStockObservationPage;
5725
6213
  mtwTripUtilizationReportPage: MtwTripUtilizationReportPage;
6214
+ /**
6215
+ * Type C self-list: the calling driver's stops for one local calendar day,
6216
+ * ordered into a driving sequence. Identity comes from the authenticated
6217
+ * actor only. `timeZone` is the device's IANA zone (for example
6218
+ * `Asia/Kolkata`) so "today" matches the driver's clock, including on DST
6219
+ * transition days. `timezoneOffsetMinutes` (the client's
6220
+ * `Date#getTimezoneOffset()` value) is a fixed-offset fallback used only
6221
+ * when `timeZone` is omitted.
6222
+ */
6223
+ myDeliveryDay: MtwDriverDay;
5726
6224
  myEpodShipmentStatus?: Maybe<MtwOwnedEpodShipmentStatus>;
5727
6225
  /**
5728
6226
  * Type C self-list: delivery jobs assigned to the CALLING driver that are out
@@ -6130,6 +6628,19 @@ export type QueryMtwFreightInvoiceComparisonPageArgs = {
6130
6628
  };
6131
6629
 
6132
6630
 
6631
+ export type QueryMtwFreightInvoiceReviewArgs = {
6632
+ comparisonId: Scalars['ID']['input'];
6633
+ shipmentId: Scalars['ID']['input'];
6634
+ };
6635
+
6636
+
6637
+ export type QueryMtwFreightInvoiceReviewPageArgs = {
6638
+ pagination?: InputMaybe<MtwContainerPagination>;
6639
+ shipmentId?: InputMaybe<Scalars['ID']['input']>;
6640
+ status?: InputMaybe<MtwFreightInvoiceReviewStatus>;
6641
+ };
6642
+
6643
+
6133
6644
  export type QueryMtwPalletGeometryPreviewArgs = {
6134
6645
  input: MtwPalletGeometryPreviewInput;
6135
6646
  };
@@ -6200,6 +6711,39 @@ export type QueryMtwProcedureVersionPageArgs = {
6200
6711
  };
6201
6712
 
6202
6713
 
6714
+ export type QueryMtwReportArgs = {
6715
+ id: Scalars['ID']['input'];
6716
+ };
6717
+
6718
+
6719
+ export type QueryMtwReportRunArgs = {
6720
+ id: Scalars['ID']['input'];
6721
+ };
6722
+
6723
+
6724
+ export type QueryMtwReportRunExportArgs = {
6725
+ format: MtwReportFormat;
6726
+ runId: Scalars['ID']['input'];
6727
+ };
6728
+
6729
+
6730
+ export type QueryMtwReportRunsArgs = {
6731
+ pagination?: InputMaybe<PaginationInput>;
6732
+ reportId: Scalars['ID']['input'];
6733
+ };
6734
+
6735
+
6736
+ export type QueryMtwReportsArgs = {
6737
+ filter?: InputMaybe<MtwReportFilterInput>;
6738
+ pagination?: InputMaybe<PaginationInput>;
6739
+ };
6740
+
6741
+
6742
+ export type QueryMtwReportsCountArgs = {
6743
+ filter?: InputMaybe<MtwReportFilterInput>;
6744
+ };
6745
+
6746
+
6203
6747
  export type QueryMtwReuseEligibilityArgs = {
6204
6748
  approvalId?: InputMaybe<Scalars['ID']['input']>;
6205
6749
  proposalId: Scalars['ID']['input'];
@@ -6269,6 +6813,13 @@ export type QueryMtwTripUtilizationReportPageArgs = {
6269
6813
  };
6270
6814
 
6271
6815
 
6816
+ export type QueryMyDeliveryDayArgs = {
6817
+ date: Scalars['String']['input'];
6818
+ timeZone?: InputMaybe<Scalars['String']['input']>;
6819
+ timezoneOffsetMinutes?: InputMaybe<Scalars['Int']['input']>;
6820
+ };
6821
+
6822
+
6272
6823
  export type QueryMyEpodShipmentStatusArgs = {
6273
6824
  deliveryJobId: Scalars['ID']['input'];
6274
6825
  };
@@ -6526,6 +7077,14 @@ export type RecordMtwFreeTimeExtensionDecisionInput = {
6526
7077
  sourceReference: Scalars['String']['input'];
6527
7078
  };
6528
7079
 
7080
+ export type RecordMtwFreightInvoiceSupplierResponseInput = {
7081
+ comparisonId: Scalars['ID']['input'];
7082
+ expectedSequence: Scalars['Int']['input'];
7083
+ idempotencyKey: Scalars['String']['input'];
7084
+ response: Scalars['String']['input'];
7085
+ shipmentId: Scalars['ID']['input'];
7086
+ };
7087
+
6529
7088
  export type RecordMtwPickReviewInput = {
6530
7089
  actions: Array<MtwPickReviewAction>;
6531
7090
  evidence: Array<MtwContainerEvidenceInput>;
@@ -6680,6 +7239,15 @@ export type RequestMtwFreeTimeExtensionInput = {
6680
7239
  requestedFreeUntil: Scalars['DateTime']['input'];
6681
7240
  };
6682
7241
 
7242
+ export type ResolveMtwFreightInvoiceDisputeInput = {
7243
+ comparisonId: Scalars['ID']['input'];
7244
+ expectedSequence: Scalars['Int']['input'];
7245
+ idempotencyKey: Scalars['String']['input'];
7246
+ reason: Scalars['String']['input'];
7247
+ resolution: MtwFreightInvoiceResolution;
7248
+ shipmentId: Scalars['ID']['input'];
7249
+ };
7250
+
6683
7251
  export type RevokeMtwInspectorQualificationInput = {
6684
7252
  expectedVersion: Scalars['Int']['input'];
6685
7253
  idempotencyKey: Scalars['String']['input'];