@fleetless/contracts 9.1.0 → 10.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/artifacts/openapi.json +18597 -10329
  3. package/artifacts/routes.json +96 -16
  4. package/artifacts/schema/billing-change-response.schema.json +1527 -1727
  5. package/artifacts/schema/billing-decision-amounts.schema.json +244 -0
  6. package/artifacts/schema/billing-decision-display-request.schema.json +24 -0
  7. package/artifacts/schema/billing-decision-display-response.schema.json +3130 -0
  8. package/artifacts/schema/billing-decision-period.schema.json +550 -0
  9. package/artifacts/schema/billing-decision-snapshot.schema.json +3103 -0
  10. package/artifacts/schema/checkout-request.schema.json +3 -4
  11. package/artifacts/schema/checkout-response.schema.json +492 -402
  12. package/artifacts/schema/confirmation-proof.schema.json +6 -0
  13. package/artifacts/schema/plan-change-decision-lookup-query.schema.json +16 -0
  14. package/artifacts/schema/plan-change-decision-status-response.schema.json +543 -0
  15. package/artifacts/schema/plan-change-prepare-request.schema.json +84 -0
  16. package/artifacts/schema/plan-change-prepare-response.schema.json +3162 -0
  17. package/artifacts/schema/plan-change-request.schema.json +177 -65
  18. package/artifacts/schema/purchase-conflict-details.schema.json +94 -0
  19. package/artifacts/schema/purchase-intent-accepted-without-payment.schema.json +95 -0
  20. package/artifacts/schema/purchase-intent-confirm-request.schema.json +146 -33
  21. package/artifacts/schema/purchase-intent-draft.schema.json +449 -0
  22. package/artifacts/schema/purchase-intent-payment-started.schema.json +184 -0
  23. package/artifacts/schema/purchase-intent-response.schema.json +1235 -168
  24. package/dist/billing.d.ts +5665 -210
  25. package/dist/billing.js +224 -29
  26. package/dist/confirmation-proof.d.ts +5 -0
  27. package/dist/confirmation-proof.js +6 -0
  28. package/dist/iana-time-zones.d.ts +2 -0
  29. package/dist/iana-time-zones.js +426 -0
  30. package/dist/index.d.ts +5 -4
  31. package/dist/index.js +3 -2
  32. package/dist/plans.d.ts +125 -1
  33. package/dist/plans.js +19 -1
  34. package/dist/purchase-operation-key.d.ts +4 -0
  35. package/dist/purchase-operation-key.js +4 -0
  36. package/dist/routes.js +42 -21
  37. package/package.json +3 -1
@@ -1,77 +1,189 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "type": "object",
4
- "properties": {
5
- "target_plan": {
6
- "type": "string",
7
- "enum": [
8
- "basic",
9
- "plus",
10
- "pro",
11
- "enterprise"
12
- ],
13
- "description": "The lower plan to move to; `basic` cancels."
14
- },
15
- "keep": {
16
- "anyOf": [
17
- {
18
- "type": "object",
19
- "properties": {
20
- "robots": {
21
- "type": "array",
22
- "items": {
23
- "type": "string",
24
- "format": "uuid",
25
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
26
- },
27
- "description": "The robots that stay, by id. Every other robot is deleted when the change takes effect."
28
- },
29
- "apps": {
30
- "type": "array",
31
- "items": {
32
- "type": "string",
33
- "format": "uuid",
34
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
3
+ "oneOf": [
4
+ {
5
+ "type": "object",
6
+ "properties": {
7
+ "change_id": {
8
+ "type": "string",
9
+ "format": "uuid",
10
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
11
+ },
12
+ "operation_key": {
13
+ "type": "string",
14
+ "format": "uuid",
15
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
16
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
17
+ },
18
+ "keep": {
19
+ "anyOf": [
20
+ {
21
+ "type": "object",
22
+ "properties": {
23
+ "robots": {
24
+ "type": "array",
25
+ "items": {
26
+ "type": "string",
27
+ "format": "uuid",
28
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
29
+ },
30
+ "description": "The robots that stay, by id. Every other robot is deleted when the change takes effect."
31
+ },
32
+ "apps": {
33
+ "type": "array",
34
+ "items": {
35
+ "type": "string",
36
+ "format": "uuid",
37
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
38
+ },
39
+ "description": "The apps that stay, by id. Every other app is deleted when the change takes effect."
40
+ },
41
+ "app_users": {
42
+ "type": "array",
43
+ "items": {
44
+ "type": "string",
45
+ "format": "uuid",
46
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
47
+ },
48
+ "description": "The app users that stay, by id, across every app. Every other app user is deleted when the change takes effect."
49
+ },
50
+ "developers": {
51
+ "type": "array",
52
+ "items": {
53
+ "type": "string",
54
+ "format": "uuid",
55
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
56
+ },
57
+ "description": "The developers that stay, by user id, owners never among them: every owner stays. Every other developer is removed from the org when the change takes effect."
58
+ }
35
59
  },
36
- "description": "The apps that stay, by id. Every other app is deleted when the change takes effect."
60
+ "required": [
61
+ "robots",
62
+ "apps",
63
+ "app_users",
64
+ "developers"
65
+ ],
66
+ "additionalProperties": false
37
67
  },
38
- "app_users": {
39
- "type": "array",
40
- "items": {
41
- "type": "string",
42
- "format": "uuid",
43
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
68
+ {
69
+ "type": "null"
70
+ }
71
+ ]
72
+ },
73
+ "confirmation_proof": {
74
+ "type": "string",
75
+ "pattern": "^[A-Za-z0-9_-]{43}$",
76
+ "description": "Opaque 32-byte Cloud proof, unpadded base64url. Syntax alone is not evidence."
77
+ },
78
+ "target_plan": {
79
+ "type": "string",
80
+ "const": "basic"
81
+ },
82
+ "cancellation_reason": {
83
+ "type": "string",
84
+ "maxLength": 500
85
+ }
86
+ },
87
+ "required": [
88
+ "change_id",
89
+ "operation_key",
90
+ "keep",
91
+ "confirmation_proof",
92
+ "target_plan"
93
+ ],
94
+ "additionalProperties": false
95
+ },
96
+ {
97
+ "type": "object",
98
+ "properties": {
99
+ "change_id": {
100
+ "type": "string",
101
+ "format": "uuid",
102
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
103
+ },
104
+ "operation_key": {
105
+ "type": "string",
106
+ "format": "uuid",
107
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
108
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
109
+ },
110
+ "keep": {
111
+ "anyOf": [
112
+ {
113
+ "type": "object",
114
+ "properties": {
115
+ "robots": {
116
+ "type": "array",
117
+ "items": {
118
+ "type": "string",
119
+ "format": "uuid",
120
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
121
+ },
122
+ "description": "The robots that stay, by id. Every other robot is deleted when the change takes effect."
123
+ },
124
+ "apps": {
125
+ "type": "array",
126
+ "items": {
127
+ "type": "string",
128
+ "format": "uuid",
129
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
130
+ },
131
+ "description": "The apps that stay, by id. Every other app is deleted when the change takes effect."
132
+ },
133
+ "app_users": {
134
+ "type": "array",
135
+ "items": {
136
+ "type": "string",
137
+ "format": "uuid",
138
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
139
+ },
140
+ "description": "The app users that stay, by id, across every app. Every other app user is deleted when the change takes effect."
141
+ },
142
+ "developers": {
143
+ "type": "array",
144
+ "items": {
145
+ "type": "string",
146
+ "format": "uuid",
147
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
148
+ },
149
+ "description": "The developers that stay, by user id, owners never among them: every owner stays. Every other developer is removed from the org when the change takes effect."
150
+ }
44
151
  },
45
- "description": "The app users that stay, by id, across every app. Every other app user is deleted when the change takes effect."
152
+ "required": [
153
+ "robots",
154
+ "apps",
155
+ "app_users",
156
+ "developers"
157
+ ],
158
+ "additionalProperties": false
46
159
  },
47
- "developers": {
48
- "type": "array",
49
- "items": {
50
- "type": "string",
51
- "format": "uuid",
52
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
53
- },
54
- "description": "The developers that stay, by user id, owners never among them: every owner stays. Every other developer is removed from the org when the change takes effect."
160
+ {
161
+ "type": "null"
55
162
  }
56
- },
57
- "required": [
58
- "robots",
59
- "apps",
60
- "app_users",
61
- "developers"
62
- ],
63
- "additionalProperties": false
163
+ ]
164
+ },
165
+ "confirmation_proof": {
166
+ "type": "string",
167
+ "pattern": "^[A-Za-z0-9_-]{43}$",
168
+ "description": "Opaque 32-byte Cloud proof, unpadded base64url. Syntax alone is not evidence."
64
169
  },
65
- {
66
- "type": "null"
170
+ "target_plan": {
171
+ "type": "string",
172
+ "enum": [
173
+ "plus",
174
+ "pro",
175
+ "enterprise"
176
+ ]
67
177
  }
178
+ },
179
+ "required": [
180
+ "change_id",
181
+ "operation_key",
182
+ "keep",
183
+ "confirmation_proof",
184
+ "target_plan"
68
185
  ],
69
- "description": "What stays. `null` when the org already fits the target plan, so nothing is deleted."
186
+ "additionalProperties": false
70
187
  }
71
- },
72
- "required": [
73
- "target_plan",
74
- "keep"
75
- ],
76
- "additionalProperties": false
188
+ ]
77
189
  }
@@ -479,6 +479,100 @@
479
479
  "payment"
480
480
  ],
481
481
  "additionalProperties": false
482
+ },
483
+ {
484
+ "type": "object",
485
+ "properties": {
486
+ "intent_id": {
487
+ "type": "string",
488
+ "format": "uuid",
489
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
490
+ },
491
+ "operation_key": {
492
+ "type": "string",
493
+ "format": "uuid",
494
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
495
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
496
+ },
497
+ "operation": {
498
+ "type": "string",
499
+ "const": "paid_change"
500
+ },
501
+ "state": {
502
+ "type": "string",
503
+ "const": "accepted_no_payment"
504
+ },
505
+ "quote_revision": {
506
+ "type": "string",
507
+ "minLength": 1,
508
+ "maxLength": 200,
509
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
510
+ },
511
+ "buyer_fingerprint": {
512
+ "type": "string",
513
+ "minLength": 1,
514
+ "maxLength": 200,
515
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
516
+ },
517
+ "quote": {
518
+ "type": "object",
519
+ "properties": {
520
+ "currency": {
521
+ "type": "string",
522
+ "const": "eur",
523
+ "description": "Every new quote is in EUR."
524
+ },
525
+ "net_cents": {
526
+ "type": "number",
527
+ "const": 0
528
+ },
529
+ "vat_cents": {
530
+ "type": "number",
531
+ "const": 0
532
+ },
533
+ "gross_cents": {
534
+ "type": "number",
535
+ "const": 0
536
+ },
537
+ "rate_percent": {
538
+ "type": "integer",
539
+ "minimum": 0,
540
+ "maximum": 100,
541
+ "description": "VAT rate in whole percent."
542
+ }
543
+ },
544
+ "required": [
545
+ "currency",
546
+ "net_cents",
547
+ "vat_cents",
548
+ "gross_cents",
549
+ "rate_percent"
550
+ ],
551
+ "additionalProperties": false
552
+ },
553
+ "accepted_at": {
554
+ "type": "string",
555
+ "allOf": [
556
+ {
557
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
558
+ },
559
+ {
560
+ "pattern": "Z$"
561
+ }
562
+ ]
563
+ }
564
+ },
565
+ "required": [
566
+ "intent_id",
567
+ "operation_key",
568
+ "operation",
569
+ "state",
570
+ "quote_revision",
571
+ "buyer_fingerprint",
572
+ "quote",
573
+ "accepted_at"
574
+ ],
575
+ "additionalProperties": false
482
576
  }
483
577
  ],
484
578
  "allOf": [
@@ -0,0 +1,95 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "type": "object",
4
+ "properties": {
5
+ "intent_id": {
6
+ "type": "string",
7
+ "format": "uuid",
8
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
9
+ },
10
+ "operation_key": {
11
+ "type": "string",
12
+ "format": "uuid",
13
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
14
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
15
+ },
16
+ "operation": {
17
+ "type": "string",
18
+ "const": "paid_change"
19
+ },
20
+ "state": {
21
+ "type": "string",
22
+ "const": "accepted_no_payment"
23
+ },
24
+ "quote_revision": {
25
+ "type": "string",
26
+ "minLength": 1,
27
+ "maxLength": 200,
28
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
29
+ },
30
+ "buyer_fingerprint": {
31
+ "type": "string",
32
+ "minLength": 1,
33
+ "maxLength": 200,
34
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
35
+ },
36
+ "quote": {
37
+ "type": "object",
38
+ "properties": {
39
+ "currency": {
40
+ "type": "string",
41
+ "const": "eur",
42
+ "description": "Every new quote is in EUR."
43
+ },
44
+ "net_cents": {
45
+ "type": "number",
46
+ "const": 0
47
+ },
48
+ "vat_cents": {
49
+ "type": "number",
50
+ "const": 0
51
+ },
52
+ "gross_cents": {
53
+ "type": "number",
54
+ "const": 0
55
+ },
56
+ "rate_percent": {
57
+ "type": "integer",
58
+ "minimum": 0,
59
+ "maximum": 100,
60
+ "description": "VAT rate in whole percent."
61
+ }
62
+ },
63
+ "required": [
64
+ "currency",
65
+ "net_cents",
66
+ "vat_cents",
67
+ "gross_cents",
68
+ "rate_percent"
69
+ ],
70
+ "additionalProperties": false
71
+ },
72
+ "accepted_at": {
73
+ "type": "string",
74
+ "allOf": [
75
+ {
76
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
77
+ },
78
+ {
79
+ "pattern": "Z$"
80
+ }
81
+ ]
82
+ }
83
+ },
84
+ "required": [
85
+ "intent_id",
86
+ "operation_key",
87
+ "operation",
88
+ "state",
89
+ "quote_revision",
90
+ "buyer_fingerprint",
91
+ "quote",
92
+ "accepted_at"
93
+ ],
94
+ "additionalProperties": false
95
+ }
@@ -1,40 +1,153 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "type": "object",
4
- "properties": {
5
- "operation_key": {
6
- "type": "string",
7
- "format": "uuid",
8
- "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
9
- "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
3
+ "oneOf": [
4
+ {
5
+ "type": "object",
6
+ "properties": {
7
+ "operation_key": {
8
+ "type": "string",
9
+ "format": "uuid",
10
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
11
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
12
+ },
13
+ "quote_revision": {
14
+ "type": "string",
15
+ "minLength": 1,
16
+ "maxLength": 200,
17
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
18
+ },
19
+ "buyer_fingerprint": {
20
+ "type": "string",
21
+ "minLength": 1,
22
+ "maxLength": 200,
23
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
24
+ },
25
+ "confirmation_proof": {
26
+ "type": "string",
27
+ "pattern": "^[A-Za-z0-9_-]{43}$",
28
+ "description": "Opaque 32-byte Cloud proof, unpadded base64url. Syntax alone is not evidence."
29
+ },
30
+ "operation": {
31
+ "type": "string",
32
+ "const": "checkout"
33
+ }
34
+ },
35
+ "required": [
36
+ "operation_key",
37
+ "quote_revision",
38
+ "buyer_fingerprint",
39
+ "confirmation_proof",
40
+ "operation"
41
+ ],
42
+ "additionalProperties": false
10
43
  },
11
- "operation": {
12
- "type": "string",
13
- "enum": [
14
- "checkout",
15
- "paid_change",
16
- "invoice_payment",
17
- "payment_method_invoice"
18
- ]
44
+ {
45
+ "type": "object",
46
+ "properties": {
47
+ "operation_key": {
48
+ "type": "string",
49
+ "format": "uuid",
50
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
51
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
52
+ },
53
+ "quote_revision": {
54
+ "type": "string",
55
+ "minLength": 1,
56
+ "maxLength": 200,
57
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
58
+ },
59
+ "buyer_fingerprint": {
60
+ "type": "string",
61
+ "minLength": 1,
62
+ "maxLength": 200,
63
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
64
+ },
65
+ "confirmation_proof": {
66
+ "type": "string",
67
+ "pattern": "^[A-Za-z0-9_-]{43}$",
68
+ "description": "Opaque 32-byte Cloud proof, unpadded base64url. Syntax alone is not evidence."
69
+ },
70
+ "operation": {
71
+ "type": "string",
72
+ "const": "paid_change"
73
+ }
74
+ },
75
+ "required": [
76
+ "operation_key",
77
+ "quote_revision",
78
+ "buyer_fingerprint",
79
+ "confirmation_proof",
80
+ "operation"
81
+ ],
82
+ "additionalProperties": false
19
83
  },
20
- "quote_revision": {
21
- "type": "string",
22
- "minLength": 1,
23
- "maxLength": 200,
24
- "description": "Opaque revision of the displayed quote; echo it when confirming."
84
+ {
85
+ "type": "object",
86
+ "properties": {
87
+ "operation_key": {
88
+ "type": "string",
89
+ "format": "uuid",
90
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
91
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
92
+ },
93
+ "quote_revision": {
94
+ "type": "string",
95
+ "minLength": 1,
96
+ "maxLength": 200,
97
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
98
+ },
99
+ "buyer_fingerprint": {
100
+ "type": "string",
101
+ "minLength": 1,
102
+ "maxLength": 200,
103
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
104
+ },
105
+ "operation": {
106
+ "type": "string",
107
+ "const": "invoice_payment"
108
+ }
109
+ },
110
+ "required": [
111
+ "operation_key",
112
+ "quote_revision",
113
+ "buyer_fingerprint",
114
+ "operation"
115
+ ],
116
+ "additionalProperties": false
25
117
  },
26
- "buyer_fingerprint": {
27
- "type": "string",
28
- "minLength": 1,
29
- "maxLength": 200,
30
- "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
118
+ {
119
+ "type": "object",
120
+ "properties": {
121
+ "operation_key": {
122
+ "type": "string",
123
+ "format": "uuid",
124
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
125
+ "description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
126
+ },
127
+ "quote_revision": {
128
+ "type": "string",
129
+ "minLength": 1,
130
+ "maxLength": 200,
131
+ "description": "Opaque revision of the displayed quote; echo it when confirming."
132
+ },
133
+ "buyer_fingerprint": {
134
+ "type": "string",
135
+ "minLength": 1,
136
+ "maxLength": 200,
137
+ "description": "Opaque revision of buyer details and email policy; never full VIES evidence."
138
+ },
139
+ "operation": {
140
+ "type": "string",
141
+ "const": "payment_method_invoice"
142
+ }
143
+ },
144
+ "required": [
145
+ "operation_key",
146
+ "quote_revision",
147
+ "buyer_fingerprint",
148
+ "operation"
149
+ ],
150
+ "additionalProperties": false
31
151
  }
32
- },
33
- "required": [
34
- "operation_key",
35
- "operation",
36
- "quote_revision",
37
- "buyer_fingerprint"
38
- ],
39
- "additionalProperties": false
152
+ ]
40
153
  }