@fleetless/contracts 17.0.0-next.1 → 17.0.0-next.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/billing.d.ts CHANGED
@@ -63,12 +63,35 @@ export declare const viesPendingReason: z.ZodEnum<{
63
63
  vies_identifier_missing: "vies_identifier_missing";
64
64
  }>;
65
65
  export type ViesPendingReason = z.infer<typeof viesPendingReason>;
66
- /** Internal decision input; the complete direct response stays in protected Finance storage. */
66
+ /**
67
+ * **Which side of a VIES check was down** (fleetless/fleetless#1181). VIES is
68
+ * a relay: it asks the VAT register of the member state the VAT ID belongs
69
+ * to. `member_state`: VIES answered, and said that this country's register is
70
+ * down or busy. `vies`: VIES itself did not answer, or answered nothing it
71
+ * can be held to. `country` is the country that was asked for, in both
72
+ * scopes: the billing address's, so Greece is `GR` and never VIES's `EL`.
73
+ */
74
+ export declare const viesOutage: z.ZodObject<{
75
+ scope: z.ZodEnum<{
76
+ member_state: "member_state";
77
+ vies: "vies";
78
+ }>;
79
+ country: z.ZodString;
80
+ }, z.core.$strict>;
81
+ export type ViesOutage = z.infer<typeof viesOutage>;
82
+ /**
83
+ * Internal decision input; the complete direct response stays in protected
84
+ * Finance storage. `unavailable` names its outage, which `vatFor` passes on
85
+ * as `vies_outage`.
86
+ */
67
87
  export type ViesVerdict = {
68
88
  status: 'valid';
69
89
  requestIdentifier?: string | null;
70
90
  } | {
71
- status: 'invalid' | 'unavailable' | 'unverified';
91
+ status: 'invalid' | 'unverified';
92
+ } | {
93
+ status: 'unavailable';
94
+ outage: ViesOutage;
72
95
  };
73
96
  export declare const vatDecision: z.ZodDiscriminatedUnion<[z.ZodObject<{
74
97
  state: z.ZodLiteral<"eligible">;
@@ -78,14 +101,23 @@ export declare const vatDecision: z.ZodDiscriminatedUnion<[z.ZodObject<{
78
101
  outside_eu: "outside_eu";
79
102
  }>;
80
103
  rate_percent: z.ZodNumber;
104
+ }, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
105
+ state: z.ZodLiteral<"pending">;
106
+ reason: z.ZodLiteral<"vies_unavailable">;
107
+ vies_outage: z.ZodObject<{
108
+ scope: z.ZodEnum<{
109
+ member_state: "member_state";
110
+ vies: "vies";
111
+ }>;
112
+ country: z.ZodString;
113
+ }, z.core.$strict>;
81
114
  }, z.core.$strict>, z.ZodObject<{
82
115
  state: z.ZodLiteral<"pending">;
83
116
  reason: z.ZodEnum<{
84
- vies_unavailable: "vies_unavailable";
85
117
  vies_unverified: "vies_unverified";
86
118
  vies_identifier_missing: "vies_identifier_missing";
87
119
  }>;
88
- }, z.core.$strict>, z.ZodObject<{
120
+ }, z.core.$strict>], "reason">, z.ZodObject<{
89
121
  state: z.ZodLiteral<"refused">;
90
122
  rule: z.ZodEnum<{
91
123
  company_required: "company_required";
@@ -7375,8 +7407,6 @@ export type PlanChangePrepareResponse = z.infer<typeof planChangePrepareResponse
7375
7407
  * Why an intent is held. Lexware never holds a purchase: its contact and
7376
7408
  * invoice follow the payment. A checkout or paid change is held only while an
7377
7409
  * issuer cutover runs (`issuer_cutover_in_progress`, minutes, then try again).
7378
- * `mandate_policy_unresolved` is written no more (fleetless/fleetless#1185): it
7379
- * stays for the method changes stored while they were on hold.
7380
7410
  */
7381
7411
  export declare const purchaseHoldReason: z.ZodEnum<{
7382
7412
  legacy_usd_invoice: "legacy_usd_invoice";
@@ -7393,13 +7423,8 @@ export declare const purchaseRefusalRule: z.ZodEnum<{
7393
7423
  public_email_domain: "public_email_domain";
7394
7424
  invoice_not_open: "invoice_not_open";
7395
7425
  }>;
7396
- export declare const purchaseIntentDraft: z.ZodDiscriminatedUnion<readonly [z.ZodObject<{
7426
+ export declare const purchaseIntentDraft: z.ZodDiscriminatedUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodObject<{
7397
7427
  state: z.ZodLiteral<"awaiting_vies">;
7398
- reason: z.ZodEnum<{
7399
- vies_unavailable: "vies_unavailable";
7400
- vies_unverified: "vies_unverified";
7401
- vies_identifier_missing: "vies_identifier_missing";
7402
- }>;
7403
7428
  next_attempt_at: z.ZodISODateTime;
7404
7429
  intent_id: z.ZodUUID;
7405
7430
  operation_key: z.ZodUUID;
@@ -7410,7 +7435,31 @@ export declare const purchaseIntentDraft: z.ZodDiscriminatedUnion<readonly [z.Zo
7410
7435
  payment_method_invoice: "payment_method_invoice";
7411
7436
  }>;
7412
7437
  invoice_id: z.ZodOptional<z.ZodUUID>;
7438
+ reason: z.ZodLiteral<"vies_unavailable">;
7439
+ vies_outage: z.ZodObject<{
7440
+ scope: z.ZodEnum<{
7441
+ member_state: "member_state";
7442
+ vies: "vies";
7443
+ }>;
7444
+ country: z.ZodString;
7445
+ }, z.core.$strict>;
7413
7446
  }, z.core.$strict>, z.ZodObject<{
7447
+ state: z.ZodLiteral<"awaiting_vies">;
7448
+ next_attempt_at: z.ZodISODateTime;
7449
+ intent_id: z.ZodUUID;
7450
+ operation_key: z.ZodUUID;
7451
+ operation: z.ZodEnum<{
7452
+ checkout: "checkout";
7453
+ paid_change: "paid_change";
7454
+ invoice_payment: "invoice_payment";
7455
+ payment_method_invoice: "payment_method_invoice";
7456
+ }>;
7457
+ invoice_id: z.ZodOptional<z.ZodUUID>;
7458
+ reason: z.ZodEnum<{
7459
+ vies_unverified: "vies_unverified";
7460
+ vies_identifier_missing: "vies_identifier_missing";
7461
+ }>;
7462
+ }, z.core.$strict>], "reason">, z.ZodObject<{
7414
7463
  state: z.ZodLiteral<"eligible">;
7415
7464
  quote: z.ZodObject<{
7416
7465
  currency: z.ZodLiteral<"eur">;
@@ -7492,13 +7541,6 @@ export declare const purchaseIntentDraft: z.ZodDiscriminatedUnion<readonly [z.Zo
7492
7541
  }, z.core.$strict>], "state">;
7493
7542
  export type PurchaseIntentDraft = z.infer<typeof purchaseIntentDraft>;
7494
7543
  export declare const purchaseIntentPaymentStarted: z.ZodObject<{
7495
- operation: z.ZodEnum<{
7496
- checkout: "checkout";
7497
- paid_change: "paid_change";
7498
- invoice_payment: "invoice_payment";
7499
- payment_method_invoice: "payment_method_invoice";
7500
- mandate_setup: "mandate_setup";
7501
- }>;
7502
7544
  state: z.ZodLiteral<"payment_started">;
7503
7545
  payment_id: z.ZodUUID;
7504
7546
  payment: z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -7510,6 +7552,12 @@ export declare const purchaseIntentPaymentStarted: z.ZodObject<{
7510
7552
  }, z.core.$strict>], "kind">;
7511
7553
  intent_id: z.ZodUUID;
7512
7554
  operation_key: z.ZodUUID;
7555
+ operation: z.ZodEnum<{
7556
+ checkout: "checkout";
7557
+ paid_change: "paid_change";
7558
+ invoice_payment: "invoice_payment";
7559
+ payment_method_invoice: "payment_method_invoice";
7560
+ }>;
7513
7561
  invoice_id: z.ZodOptional<z.ZodUUID>;
7514
7562
  }, z.core.$strict>;
7515
7563
  export type PurchaseIntentPaymentStarted = z.infer<typeof purchaseIntentPaymentStarted>;
@@ -7531,13 +7579,8 @@ export declare const purchaseIntentAcceptedWithoutPayment: z.ZodObject<{
7531
7579
  }, z.core.$strict>;
7532
7580
  export type PurchaseIntentAcceptedWithoutPayment = z.infer<typeof purchaseIntentAcceptedWithoutPayment>;
7533
7581
  /** Public owner read. Accepted zero-charge changes have no provider payment. */
7534
- export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodObject<{
7582
+ export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion<[z.ZodObject<{
7535
7583
  state: z.ZodLiteral<"awaiting_vies">;
7536
- reason: z.ZodEnum<{
7537
- vies_unavailable: "vies_unavailable";
7538
- vies_unverified: "vies_unverified";
7539
- vies_identifier_missing: "vies_identifier_missing";
7540
- }>;
7541
7584
  next_attempt_at: z.ZodISODateTime;
7542
7585
  intent_id: z.ZodUUID;
7543
7586
  operation_key: z.ZodUUID;
@@ -7548,7 +7591,31 @@ export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodObject<{
7548
7591
  payment_method_invoice: "payment_method_invoice";
7549
7592
  }>;
7550
7593
  invoice_id: z.ZodOptional<z.ZodUUID>;
7594
+ reason: z.ZodLiteral<"vies_unavailable">;
7595
+ vies_outage: z.ZodObject<{
7596
+ scope: z.ZodEnum<{
7597
+ member_state: "member_state";
7598
+ vies: "vies";
7599
+ }>;
7600
+ country: z.ZodString;
7601
+ }, z.core.$strict>;
7551
7602
  }, z.core.$strict>, z.ZodObject<{
7603
+ state: z.ZodLiteral<"awaiting_vies">;
7604
+ next_attempt_at: z.ZodISODateTime;
7605
+ intent_id: z.ZodUUID;
7606
+ operation_key: z.ZodUUID;
7607
+ operation: z.ZodEnum<{
7608
+ checkout: "checkout";
7609
+ paid_change: "paid_change";
7610
+ invoice_payment: "invoice_payment";
7611
+ payment_method_invoice: "payment_method_invoice";
7612
+ }>;
7613
+ invoice_id: z.ZodOptional<z.ZodUUID>;
7614
+ reason: z.ZodEnum<{
7615
+ vies_unverified: "vies_unverified";
7616
+ vies_identifier_missing: "vies_identifier_missing";
7617
+ }>;
7618
+ }, z.core.$strict>], "reason">, z.ZodObject<{
7552
7619
  state: z.ZodLiteral<"eligible">;
7553
7620
  quote: z.ZodObject<{
7554
7621
  currency: z.ZodLiteral<"eur">;
@@ -7628,13 +7695,6 @@ export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodObject<{
7628
7695
  }>;
7629
7696
  invoice_id: z.ZodOptional<z.ZodUUID>;
7630
7697
  }, z.core.$strict>, z.ZodObject<{
7631
- operation: z.ZodEnum<{
7632
- checkout: "checkout";
7633
- paid_change: "paid_change";
7634
- invoice_payment: "invoice_payment";
7635
- payment_method_invoice: "payment_method_invoice";
7636
- mandate_setup: "mandate_setup";
7637
- }>;
7638
7698
  state: z.ZodLiteral<"payment_started">;
7639
7699
  payment_id: z.ZodUUID;
7640
7700
  payment: z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -7646,6 +7706,12 @@ export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodObject<{
7646
7706
  }, z.core.$strict>], "kind">;
7647
7707
  intent_id: z.ZodUUID;
7648
7708
  operation_key: z.ZodUUID;
7709
+ operation: z.ZodEnum<{
7710
+ checkout: "checkout";
7711
+ paid_change: "paid_change";
7712
+ invoice_payment: "invoice_payment";
7713
+ payment_method_invoice: "payment_method_invoice";
7714
+ }>;
7649
7715
  invoice_id: z.ZodOptional<z.ZodUUID>;
7650
7716
  }, z.core.$strict>, z.ZodObject<{
7651
7717
  quote: z.ZodObject<{
@@ -7664,23 +7730,41 @@ export declare const purchaseIntent: z.ZodDiscriminatedUnion<[z.ZodObject<{
7664
7730
  state: z.ZodLiteral<"accepted_no_payment">;
7665
7731
  }, z.core.$strict>], "state">;
7666
7732
  export type PurchaseIntent = z.infer<typeof purchaseIntent>;
7667
- export declare const checkoutResponse: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodObject<{
7668
- state: z.ZodLiteral<"awaiting_vies">;
7669
- reason: z.ZodEnum<{
7670
- vies_unavailable: "vies_unavailable";
7671
- vies_unverified: "vies_unverified";
7672
- vies_identifier_missing: "vies_identifier_missing";
7733
+ export declare const checkoutResponse: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion<[z.ZodObject<{
7734
+ operation: z.ZodEnum<{
7735
+ checkout: "checkout";
7736
+ invoice_payment: "invoice_payment";
7737
+ payment_method_invoice: "payment_method_invoice";
7673
7738
  }>;
7739
+ state: z.ZodLiteral<"awaiting_vies">;
7674
7740
  next_attempt_at: z.ZodISODateTime;
7675
7741
  intent_id: z.ZodUUID;
7676
7742
  operation_key: z.ZodUUID;
7677
7743
  invoice_id: z.ZodOptional<z.ZodUUID>;
7744
+ reason: z.ZodLiteral<"vies_unavailable">;
7745
+ vies_outage: z.ZodObject<{
7746
+ scope: z.ZodEnum<{
7747
+ member_state: "member_state";
7748
+ vies: "vies";
7749
+ }>;
7750
+ country: z.ZodString;
7751
+ }, z.core.$strict>;
7752
+ }, z.core.$strict>, z.ZodObject<{
7678
7753
  operation: z.ZodEnum<{
7679
7754
  checkout: "checkout";
7680
7755
  invoice_payment: "invoice_payment";
7681
7756
  payment_method_invoice: "payment_method_invoice";
7682
7757
  }>;
7683
- }, z.core.$strict>, z.ZodObject<{
7758
+ state: z.ZodLiteral<"awaiting_vies">;
7759
+ next_attempt_at: z.ZodISODateTime;
7760
+ intent_id: z.ZodUUID;
7761
+ operation_key: z.ZodUUID;
7762
+ invoice_id: z.ZodOptional<z.ZodUUID>;
7763
+ reason: z.ZodEnum<{
7764
+ vies_unverified: "vies_unverified";
7765
+ vies_identifier_missing: "vies_identifier_missing";
7766
+ }>;
7767
+ }, z.core.$strict>], "reason">, z.ZodObject<{
7684
7768
  state: z.ZodLiteral<"eligible">;
7685
7769
  quote: z.ZodObject<{
7686
7770
  currency: z.ZodLiteral<"eur">;
@@ -7772,7 +7856,6 @@ export declare const checkoutResponse: z.ZodUnion<readonly [z.ZodDiscriminatedUn
7772
7856
  checkout: "checkout";
7773
7857
  invoice_payment: "invoice_payment";
7774
7858
  payment_method_invoice: "payment_method_invoice";
7775
- mandate_setup: "mandate_setup";
7776
7859
  }>;
7777
7860
  }, z.core.$strict>]>;
7778
7861
  export type CheckoutResponse = z.infer<typeof checkoutResponse>;
@@ -9406,15 +9489,25 @@ export declare const checkoutStartResponse: z.ZodDiscriminatedUnion<[z.ZodObject
9406
9489
  intent_id: z.ZodUUID;
9407
9490
  operation_key: z.ZodUUID;
9408
9491
  operation: z.ZodLiteral<"checkout">;
9492
+ }, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
9493
+ state: z.ZodLiteral<"vies_unavailable">;
9494
+ field: z.ZodLiteral<"billing.vat_id">;
9495
+ reason: z.ZodLiteral<"vies_unavailable">;
9496
+ vies_outage: z.ZodObject<{
9497
+ scope: z.ZodEnum<{
9498
+ member_state: "member_state";
9499
+ vies: "vies";
9500
+ }>;
9501
+ country: z.ZodString;
9502
+ }, z.core.$strict>;
9409
9503
  }, z.core.$strict>, z.ZodObject<{
9410
9504
  state: z.ZodLiteral<"vies_unavailable">;
9411
9505
  field: z.ZodLiteral<"billing.vat_id">;
9412
9506
  reason: z.ZodEnum<{
9413
- vies_unavailable: "vies_unavailable";
9414
9507
  vies_unverified: "vies_unverified";
9415
9508
  vies_identifier_missing: "vies_identifier_missing";
9416
9509
  }>;
9417
- }, z.core.$strict>, z.ZodObject<{
9510
+ }, z.core.$strict>], "reason">, z.ZodObject<{
9418
9511
  state: z.ZodLiteral<"invalid_vat_id">;
9419
9512
  field: z.ZodLiteral<"billing.vat_id">;
9420
9513
  rule: z.ZodLiteral<"vat_id_invalid">;
@@ -9519,16 +9612,29 @@ export declare const checkoutOpenDetails: z.ZodObject<{
9519
9612
  checkout_url: z.ZodNullable<z.ZodURL>;
9520
9613
  }, z.core.$strict>;
9521
9614
  export type CheckoutOpenDetails = z.infer<typeof checkoutOpenDetails>;
9522
- /** `409 target_state_conflict` details when a paid change or a billing-details edit needs VIES and VIES did not answer. Nothing is stored. */
9523
- export declare const viesUnavailableDetails: z.ZodObject<{
9615
+ /**
9616
+ * `409 target_state_conflict` details when a paid change needs VIES and VIES did not answer. Nothing is stored.
9617
+ * With `reason: vies_unavailable`, `vies_outage` says which side was down.
9618
+ */
9619
+ export declare const viesUnavailableDetails: z.ZodDiscriminatedUnion<[z.ZodObject<{
9620
+ field: z.ZodLiteral<"billing.vat_id">;
9621
+ rule: z.ZodLiteral<"vies_unavailable">;
9622
+ reason: z.ZodLiteral<"vies_unavailable">;
9623
+ vies_outage: z.ZodObject<{
9624
+ scope: z.ZodEnum<{
9625
+ member_state: "member_state";
9626
+ vies: "vies";
9627
+ }>;
9628
+ country: z.ZodString;
9629
+ }, z.core.$strict>;
9630
+ }, z.core.$strict>, z.ZodObject<{
9524
9631
  field: z.ZodLiteral<"billing.vat_id">;
9525
9632
  rule: z.ZodLiteral<"vies_unavailable">;
9526
9633
  reason: z.ZodEnum<{
9527
- vies_unavailable: "vies_unavailable";
9528
9634
  vies_unverified: "vies_unverified";
9529
9635
  vies_identifier_missing: "vies_identifier_missing";
9530
9636
  }>;
9531
- }, z.core.$strict>;
9637
+ }, z.core.$strict>], "reason">;
9532
9638
  export type ViesUnavailableDetails = z.infer<typeof viesUnavailableDetails>;
9533
9639
  /** Lookup needs one identity, plus the expected operation; a mismatch discloses nothing. */
9534
9640
  export declare const purchaseIntentLookupQuery: z.ZodObject<{
@@ -9582,13 +9688,8 @@ export declare const purchaseConflictDetails: z.ZodDiscriminatedUnion<[z.ZodObje
9582
9688
  buyer_changed: "buyer_changed";
9583
9689
  not_eligible: "not_eligible";
9584
9690
  }>;
9585
- current_intent: z.ZodDiscriminatedUnion<[z.ZodObject<{
9691
+ current_intent: z.ZodDiscriminatedUnion<[z.ZodDiscriminatedUnion<[z.ZodObject<{
9586
9692
  state: z.ZodLiteral<"awaiting_vies">;
9587
- reason: z.ZodEnum<{
9588
- vies_unavailable: "vies_unavailable";
9589
- vies_unverified: "vies_unverified";
9590
- vies_identifier_missing: "vies_identifier_missing";
9591
- }>;
9592
9693
  next_attempt_at: z.ZodISODateTime;
9593
9694
  intent_id: z.ZodUUID;
9594
9695
  operation_key: z.ZodUUID;
@@ -9599,7 +9700,31 @@ export declare const purchaseConflictDetails: z.ZodDiscriminatedUnion<[z.ZodObje
9599
9700
  payment_method_invoice: "payment_method_invoice";
9600
9701
  }>;
9601
9702
  invoice_id: z.ZodOptional<z.ZodUUID>;
9703
+ reason: z.ZodLiteral<"vies_unavailable">;
9704
+ vies_outage: z.ZodObject<{
9705
+ scope: z.ZodEnum<{
9706
+ member_state: "member_state";
9707
+ vies: "vies";
9708
+ }>;
9709
+ country: z.ZodString;
9710
+ }, z.core.$strict>;
9602
9711
  }, z.core.$strict>, z.ZodObject<{
9712
+ state: z.ZodLiteral<"awaiting_vies">;
9713
+ next_attempt_at: z.ZodISODateTime;
9714
+ intent_id: z.ZodUUID;
9715
+ operation_key: z.ZodUUID;
9716
+ operation: z.ZodEnum<{
9717
+ checkout: "checkout";
9718
+ paid_change: "paid_change";
9719
+ invoice_payment: "invoice_payment";
9720
+ payment_method_invoice: "payment_method_invoice";
9721
+ }>;
9722
+ invoice_id: z.ZodOptional<z.ZodUUID>;
9723
+ reason: z.ZodEnum<{
9724
+ vies_unverified: "vies_unverified";
9725
+ vies_identifier_missing: "vies_identifier_missing";
9726
+ }>;
9727
+ }, z.core.$strict>], "reason">, z.ZodObject<{
9603
9728
  state: z.ZodLiteral<"eligible">;
9604
9729
  quote: z.ZodObject<{
9605
9730
  currency: z.ZodLiteral<"eur">;
@@ -9679,13 +9804,6 @@ export declare const purchaseConflictDetails: z.ZodDiscriminatedUnion<[z.ZodObje
9679
9804
  }>;
9680
9805
  invoice_id: z.ZodOptional<z.ZodUUID>;
9681
9806
  }, z.core.$strict>, z.ZodObject<{
9682
- operation: z.ZodEnum<{
9683
- checkout: "checkout";
9684
- paid_change: "paid_change";
9685
- invoice_payment: "invoice_payment";
9686
- payment_method_invoice: "payment_method_invoice";
9687
- mandate_setup: "mandate_setup";
9688
- }>;
9689
9807
  state: z.ZodLiteral<"payment_started">;
9690
9808
  payment_id: z.ZodUUID;
9691
9809
  payment: z.ZodDiscriminatedUnion<[z.ZodObject<{
@@ -9697,6 +9815,12 @@ export declare const purchaseConflictDetails: z.ZodDiscriminatedUnion<[z.ZodObje
9697
9815
  }, z.core.$strict>], "kind">;
9698
9816
  intent_id: z.ZodUUID;
9699
9817
  operation_key: z.ZodUUID;
9818
+ operation: z.ZodEnum<{
9819
+ checkout: "checkout";
9820
+ paid_change: "paid_change";
9821
+ invoice_payment: "invoice_payment";
9822
+ payment_method_invoice: "payment_method_invoice";
9823
+ }>;
9700
9824
  invoice_id: z.ZodOptional<z.ZodUUID>;
9701
9825
  }, z.core.$strict>, z.ZodObject<{
9702
9826
  quote: z.ZodObject<{
@@ -9747,8 +9871,8 @@ export type CheckoutStatus = z.infer<typeof checkoutStatus>;
9747
9871
  export declare const vatIdStatus: z.ZodEnum<{
9748
9872
  valid: "valid";
9749
9873
  invalid: "invalid";
9750
- unavailable: "unavailable";
9751
9874
  unverified: "unverified";
9875
+ unavailable: "unavailable";
9752
9876
  }>;
9753
9877
  export type VatIdStatus = z.infer<typeof vatIdStatus>;
9754
9878
  /** `POST /api/billing/vat-id/check`'s body: the VAT-ID-on-blur check the checkout and `PATCH /api/billing/details` both use. */
@@ -9768,21 +9892,37 @@ export declare const vatIdCheckResponse: z.ZodDiscriminatedUnion<[z.ZodObject<{
9768
9892
  rule: z.ZodLiteral<"vat_id_invalid">;
9769
9893
  vat_id: z.ZodString;
9770
9894
  name: z.ZodNullable<z.ZodString>;
9771
- }, z.core.$strict>, z.ZodObject<{
9895
+ }, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
9772
9896
  state: z.ZodLiteral<"pending">;
9773
9897
  status: z.ZodEnum<{
9774
9898
  valid: "valid";
9899
+ unverified: "unverified";
9775
9900
  unavailable: "unavailable";
9901
+ }>;
9902
+ vat_id: z.ZodString;
9903
+ name: z.ZodNullable<z.ZodString>;
9904
+ reason: z.ZodLiteral<"vies_unavailable">;
9905
+ vies_outage: z.ZodObject<{
9906
+ scope: z.ZodEnum<{
9907
+ member_state: "member_state";
9908
+ vies: "vies";
9909
+ }>;
9910
+ country: z.ZodString;
9911
+ }, z.core.$strict>;
9912
+ }, z.core.$strict>, z.ZodObject<{
9913
+ state: z.ZodLiteral<"pending">;
9914
+ status: z.ZodEnum<{
9915
+ valid: "valid";
9776
9916
  unverified: "unverified";
9917
+ unavailable: "unavailable";
9777
9918
  }>;
9919
+ vat_id: z.ZodString;
9920
+ name: z.ZodNullable<z.ZodString>;
9778
9921
  reason: z.ZodEnum<{
9779
- vies_unavailable: "vies_unavailable";
9780
9922
  vies_unverified: "vies_unverified";
9781
9923
  vies_identifier_missing: "vies_identifier_missing";
9782
9924
  }>;
9783
- vat_id: z.ZodString;
9784
- name: z.ZodNullable<z.ZodString>;
9785
- }, z.core.$strict>], "state">;
9925
+ }, z.core.$strict>], "reason">], "state">;
9786
9926
  export type VatIdCheckResponse = z.infer<typeof vatIdCheckResponse>;
9787
9927
  /**
9788
9928
  * `POST /api/billing/change`'s body: the **absolute** target state, never a
@@ -9833,42 +9973,6 @@ export declare const billingDetailsUpdate: z.ZodObject<{
9833
9973
  vat_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
9834
9974
  }, z.core.$strict>;
9835
9975
  export type BillingDetailsUpdate = z.infer<typeof billingDetailsUpdate>;
9836
- /**
9837
- * `PATCH /api/billing/details`'s `409 target_state_conflict` details
9838
- * (fleetless/fleetless#1185). Nothing is saved in any of them.
9839
- *
9840
- * - A field a purchase would refuse: `field` as the checkout names it
9841
- * (`billing.kind`, `billing.vat_id`, `billing.tax_id`,
9842
- * `billing.address.state`, `billing.invoice_email`), `rule` the refusal.
9843
- * - `vies_unavailable` (`viesUnavailableDetails`): the country or the VAT ID
9844
- * changed and VIES did not answer; check again.
9845
- * - `buyer_changed`: the billing details changed while this edit was decided;
9846
- * read them again.
9847
- */
9848
- export declare const billingDetailsConflictDetails: z.ZodUnion<readonly [z.ZodObject<{
9849
- field: z.ZodString;
9850
- rule: z.ZodEnum<{
9851
- company_required: "company_required";
9852
- vat_id_required: "vat_id_required";
9853
- vat_id_invalid: "vat_id_invalid";
9854
- tax_id_required: "tax_id_required";
9855
- us_state_required: "us_state_required";
9856
- public_email_domain: "public_email_domain";
9857
- invoice_not_open: "invoice_not_open";
9858
- }>;
9859
- }, z.core.$strict>, z.ZodObject<{
9860
- field: z.ZodLiteral<"billing.vat_id">;
9861
- rule: z.ZodLiteral<"vies_unavailable">;
9862
- reason: z.ZodEnum<{
9863
- vies_unavailable: "vies_unavailable";
9864
- vies_unverified: "vies_unverified";
9865
- vies_identifier_missing: "vies_identifier_missing";
9866
- }>;
9867
- }, z.core.$strict>, z.ZodObject<{
9868
- field: z.ZodLiteral<"billing">;
9869
- rule: z.ZodLiteral<"buyer_changed">;
9870
- }, z.core.$strict>]>;
9871
- export type BillingDetailsConflictDetails = z.infer<typeof billingDetailsConflictDetails>;
9872
9976
  /**
9873
9977
  * The payment methods Fleetless takes: card, PayPal and Apple Pay, in EUR and USD, and no others (André, 2026-10-04).
9874
9978
  * Apple Pay is a Mollie method of its own at checkout and for a change, but the mandate it leaves is a card mandate.
@@ -9879,7 +9983,7 @@ export declare const paymentMethodKind: z.ZodEnum<{
9879
9983
  applepay: "applepay";
9880
9984
  }>;
9881
9985
  export type PaymentMethodKind = z.infer<typeof paymentMethodKind>;
9882
- /** `POST /api/billing/payment-method`'s body. One operation key names one method: keep the key until its payment is finished. */
9986
+ /** `POST /api/billing/payment-method`'s body. */
9883
9987
  export declare const paymentMethodChangeRequest: z.ZodObject<{
9884
9988
  operation_key: z.ZodUUID;
9885
9989
  method: z.ZodEnum<{
@@ -9989,8 +10093,8 @@ export declare const billingAccount: z.ZodObject<{
9989
10093
  vat_id_status: z.ZodNullable<z.ZodEnum<{
9990
10094
  valid: "valid";
9991
10095
  invalid: "invalid";
9992
- unavailable: "unavailable";
9993
10096
  unverified: "unverified";
10097
+ unavailable: "unavailable";
9994
10098
  }>>;
9995
10099
  vat: z.ZodNullable<z.ZodObject<{
9996
10100
  treatment: z.ZodEnum<{
@@ -10144,8 +10248,8 @@ export declare const billingView: z.ZodObject<{
10144
10248
  vat_id_status: z.ZodNullable<z.ZodEnum<{
10145
10249
  valid: "valid";
10146
10250
  invalid: "invalid";
10147
- unavailable: "unavailable";
10148
10251
  unverified: "unverified";
10252
+ unavailable: "unavailable";
10149
10253
  }>>;
10150
10254
  vat: z.ZodNullable<z.ZodObject<{
10151
10255
  treatment: z.ZodEnum<{
@@ -10554,8 +10658,8 @@ export declare const billingChangeResponse: z.ZodUnion<readonly [z.ZodObject<{
10554
10658
  vat_id_status: z.ZodNullable<z.ZodEnum<{
10555
10659
  valid: "valid";
10556
10660
  invalid: "invalid";
10557
- unavailable: "unavailable";
10558
10661
  unverified: "unverified";
10662
+ unavailable: "unavailable";
10559
10663
  }>>;
10560
10664
  vat: z.ZodNullable<z.ZodObject<{
10561
10665
  treatment: z.ZodEnum<{
@@ -10741,8 +10845,8 @@ export declare const billingChangeResponse: z.ZodUnion<readonly [z.ZodObject<{
10741
10845
  vat_id_status: z.ZodNullable<z.ZodEnum<{
10742
10846
  valid: "valid";
10743
10847
  invalid: "invalid";
10744
- unavailable: "unavailable";
10745
10848
  unverified: "unverified";
10849
+ unavailable: "unavailable";
10746
10850
  }>>;
10747
10851
  vat: z.ZodNullable<z.ZodObject<{
10748
10852
  treatment: z.ZodEnum<{
@@ -10894,13 +10998,8 @@ export declare const billingChangeResponse: z.ZodUnion<readonly [z.ZodObject<{
10894
10998
  }, z.core.$strict>]>;
10895
10999
  export type BillingChangeResponse = z.infer<typeof billingChangeResponse>;
10896
11000
  /** Confirmation/lookup recover the original decision, never a bare accepted change. */
10897
- export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<readonly [z.ZodObject<{
11001
+ export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodObject<{
10898
11002
  state: z.ZodLiteral<"awaiting_vies">;
10899
- reason: z.ZodEnum<{
10900
- vies_unavailable: "vies_unavailable";
10901
- vies_unverified: "vies_unverified";
10902
- vies_identifier_missing: "vies_identifier_missing";
10903
- }>;
10904
11003
  next_attempt_at: z.ZodISODateTime;
10905
11004
  intent_id: z.ZodUUID;
10906
11005
  operation_key: z.ZodUUID;
@@ -10911,7 +11010,31 @@ export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscrimin
10911
11010
  payment_method_invoice: "payment_method_invoice";
10912
11011
  }>;
10913
11012
  invoice_id: z.ZodOptional<z.ZodUUID>;
11013
+ reason: z.ZodLiteral<"vies_unavailable">;
11014
+ vies_outage: z.ZodObject<{
11015
+ scope: z.ZodEnum<{
11016
+ member_state: "member_state";
11017
+ vies: "vies";
11018
+ }>;
11019
+ country: z.ZodString;
11020
+ }, z.core.$strict>;
10914
11021
  }, z.core.$strict>, z.ZodObject<{
11022
+ state: z.ZodLiteral<"awaiting_vies">;
11023
+ next_attempt_at: z.ZodISODateTime;
11024
+ intent_id: z.ZodUUID;
11025
+ operation_key: z.ZodUUID;
11026
+ operation: z.ZodEnum<{
11027
+ checkout: "checkout";
11028
+ paid_change: "paid_change";
11029
+ invoice_payment: "invoice_payment";
11030
+ payment_method_invoice: "payment_method_invoice";
11031
+ }>;
11032
+ invoice_id: z.ZodOptional<z.ZodUUID>;
11033
+ reason: z.ZodEnum<{
11034
+ vies_unverified: "vies_unverified";
11035
+ vies_identifier_missing: "vies_identifier_missing";
11036
+ }>;
11037
+ }, z.core.$strict>], "reason">, z.ZodObject<{
10915
11038
  state: z.ZodLiteral<"eligible">;
10916
11039
  quote: z.ZodObject<{
10917
11040
  currency: z.ZodLiteral<"eur">;
@@ -11007,7 +11130,6 @@ export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscrimin
11007
11130
  checkout: "checkout";
11008
11131
  invoice_payment: "invoice_payment";
11009
11132
  payment_method_invoice: "payment_method_invoice";
11010
- mandate_setup: "mandate_setup";
11011
11133
  }>;
11012
11134
  }, z.core.$strict>, z.ZodObject<{
11013
11135
  intent: z.ZodObject<{
@@ -11058,8 +11180,8 @@ export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscrimin
11058
11180
  vat_id_status: z.ZodNullable<z.ZodEnum<{
11059
11181
  valid: "valid";
11060
11182
  invalid: "invalid";
11061
- unavailable: "unavailable";
11062
11183
  unverified: "unverified";
11184
+ unavailable: "unavailable";
11063
11185
  }>>;
11064
11186
  vat: z.ZodNullable<z.ZodObject<{
11065
11187
  treatment: z.ZodEnum<{
@@ -11245,8 +11367,8 @@ export declare const purchaseIntentResponse: z.ZodUnion<readonly [z.ZodDiscrimin
11245
11367
  vat_id_status: z.ZodNullable<z.ZodEnum<{
11246
11368
  valid: "valid";
11247
11369
  invalid: "invalid";
11248
- unavailable: "unavailable";
11249
11370
  unverified: "unverified";
11371
+ unavailable: "unavailable";
11250
11372
  }>>;
11251
11373
  vat: z.ZodNullable<z.ZodObject<{
11252
11374
  treatment: z.ZodEnum<{