@fleetless/contracts 16.1.0-next.2 → 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/CHANGELOG.md +20 -25
- package/artifacts/openapi.json +540 -380
- package/artifacts/routes.json +4 -4
- package/artifacts/schema/billing-change-response.schema.json +0 -48
- package/artifacts/schema/billing-view.schema.json +0 -24
- package/artifacts/schema/checkout-response.schema.json +133 -53
- package/artifacts/schema/checkout-start-response.schema.json +73 -23
- package/artifacts/schema/purchase-conflict-details.schema.json +135 -54
- package/artifacts/schema/purchase-intent-draft.schema.json +135 -54
- package/artifacts/schema/purchase-intent-response.schema.json +135 -102
- package/artifacts/schema/vat-decision.schema.json +63 -18
- package/artifacts/schema/vat-id-check-response.schema.json +108 -39
- package/artifacts/schema/vies-outage.schema.json +24 -0
- package/artifacts/schema/vies-unavailable-details.schema.json +73 -23
- package/dist/billing.d.ts +218 -71
- package/dist/billing.js +42 -22
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/plans.d.ts +2 -15
- package/dist/plans.js +14 -27
- package/dist/routes.js +8 -3
- package/package.json +1 -1
|
@@ -4,62 +4,143 @@
|
|
|
4
4
|
{
|
|
5
5
|
"oneOf": [
|
|
6
6
|
{
|
|
7
|
-
"
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
7
|
+
"oneOf": [
|
|
8
|
+
{
|
|
9
|
+
"type": "object",
|
|
10
|
+
"properties": {
|
|
11
|
+
"intent_id": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"format": "uuid",
|
|
14
|
+
"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)$",
|
|
15
|
+
"description": "Opaque persisted purchase intent identity."
|
|
16
|
+
},
|
|
17
|
+
"operation_key": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"format": "uuid",
|
|
20
|
+
"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)$",
|
|
21
|
+
"description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
|
|
22
|
+
},
|
|
23
|
+
"operation": {
|
|
24
|
+
"type": "string",
|
|
25
|
+
"enum": [
|
|
26
|
+
"checkout",
|
|
27
|
+
"paid_change",
|
|
28
|
+
"invoice_payment",
|
|
29
|
+
"payment_method_invoice"
|
|
30
|
+
]
|
|
31
|
+
},
|
|
32
|
+
"invoice_id": {
|
|
33
|
+
"description": "For an invoice-paying operation, the due charge or issued invoice being paid. For a confirmed paid_change with payment_started, the charge or invoice created for that decision; when the charge was issued through Lexware (`charged` is `null`), it identifies the matching billing.charges[].id. Absent on a paid_change in any other state.",
|
|
34
|
+
"type": "string",
|
|
35
|
+
"format": "uuid",
|
|
36
|
+
"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)$"
|
|
37
|
+
},
|
|
38
|
+
"state": {
|
|
39
|
+
"type": "string",
|
|
40
|
+
"const": "awaiting_vies"
|
|
41
|
+
},
|
|
42
|
+
"next_attempt_at": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"format": "date-time",
|
|
45
|
+
"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))$"
|
|
46
|
+
},
|
|
47
|
+
"reason": {
|
|
48
|
+
"type": "string",
|
|
49
|
+
"const": "vies_unavailable"
|
|
50
|
+
},
|
|
51
|
+
"vies_outage": {
|
|
52
|
+
"type": "object",
|
|
53
|
+
"properties": {
|
|
54
|
+
"scope": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"enum": [
|
|
57
|
+
"member_state",
|
|
58
|
+
"vies"
|
|
59
|
+
],
|
|
60
|
+
"description": "`member_state`: the VAT register of `country` does not answer VIES. `vies`: VIES itself does not answer."
|
|
61
|
+
},
|
|
62
|
+
"country": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"pattern": "^[A-Z]{2}$",
|
|
65
|
+
"description": "The billing address's country whose VAT ID was asked for. Greece is `GR`, never VIES's `EL`."
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"required": [
|
|
69
|
+
"scope",
|
|
70
|
+
"country"
|
|
71
|
+
],
|
|
72
|
+
"additionalProperties": false
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"required": [
|
|
76
|
+
"intent_id",
|
|
77
|
+
"operation_key",
|
|
78
|
+
"operation",
|
|
79
|
+
"state",
|
|
80
|
+
"next_attempt_at",
|
|
81
|
+
"reason",
|
|
82
|
+
"vies_outage"
|
|
83
|
+
],
|
|
84
|
+
"additionalProperties": false
|
|
47
85
|
},
|
|
48
|
-
|
|
49
|
-
"type": "
|
|
50
|
-
"
|
|
51
|
-
|
|
86
|
+
{
|
|
87
|
+
"type": "object",
|
|
88
|
+
"properties": {
|
|
89
|
+
"intent_id": {
|
|
90
|
+
"type": "string",
|
|
91
|
+
"format": "uuid",
|
|
92
|
+
"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)$",
|
|
93
|
+
"description": "Opaque persisted purchase intent identity."
|
|
94
|
+
},
|
|
95
|
+
"operation_key": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"format": "uuid",
|
|
98
|
+
"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)$",
|
|
99
|
+
"description": "Client-generated UUID persisted before the start request. Unique per org and reused only for identical input."
|
|
100
|
+
},
|
|
101
|
+
"operation": {
|
|
102
|
+
"type": "string",
|
|
103
|
+
"enum": [
|
|
104
|
+
"checkout",
|
|
105
|
+
"paid_change",
|
|
106
|
+
"invoice_payment",
|
|
107
|
+
"payment_method_invoice"
|
|
108
|
+
]
|
|
109
|
+
},
|
|
110
|
+
"invoice_id": {
|
|
111
|
+
"description": "For an invoice-paying operation, the due charge or issued invoice being paid. For a confirmed paid_change with payment_started, the charge or invoice created for that decision; when the charge was issued through Lexware (`charged` is `null`), it identifies the matching billing.charges[].id. Absent on a paid_change in any other state.",
|
|
112
|
+
"type": "string",
|
|
113
|
+
"format": "uuid",
|
|
114
|
+
"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)$"
|
|
115
|
+
},
|
|
116
|
+
"state": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"const": "awaiting_vies"
|
|
119
|
+
},
|
|
120
|
+
"next_attempt_at": {
|
|
121
|
+
"type": "string",
|
|
122
|
+
"format": "date-time",
|
|
123
|
+
"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))$"
|
|
124
|
+
},
|
|
125
|
+
"reason": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"enum": [
|
|
128
|
+
"vies_unverified",
|
|
129
|
+
"vies_identifier_missing"
|
|
130
|
+
]
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
"required": [
|
|
134
|
+
"intent_id",
|
|
135
|
+
"operation_key",
|
|
136
|
+
"operation",
|
|
137
|
+
"state",
|
|
138
|
+
"next_attempt_at",
|
|
139
|
+
"reason"
|
|
140
|
+
],
|
|
141
|
+
"additionalProperties": false
|
|
52
142
|
}
|
|
53
|
-
|
|
54
|
-
"required": [
|
|
55
|
-
"intent_id",
|
|
56
|
-
"operation_key",
|
|
57
|
-
"operation",
|
|
58
|
-
"state",
|
|
59
|
-
"reason",
|
|
60
|
-
"next_attempt_at"
|
|
61
|
-
],
|
|
62
|
-
"additionalProperties": false
|
|
143
|
+
]
|
|
63
144
|
},
|
|
64
145
|
{
|
|
65
146
|
"type": "object",
|
|
@@ -989,29 +1070,6 @@
|
|
|
989
1070
|
],
|
|
990
1071
|
"description": "`null` while a cancel is pending or nothing else renews."
|
|
991
1072
|
},
|
|
992
|
-
"current_price": {
|
|
993
|
-
"anyOf": [
|
|
994
|
-
{
|
|
995
|
-
"type": "object",
|
|
996
|
-
"properties": {
|
|
997
|
-
"net_cents": {
|
|
998
|
-
"type": "integer",
|
|
999
|
-
"minimum": -9007199254740991,
|
|
1000
|
-
"maximum": 9007199254740991,
|
|
1001
|
-
"description": "One period of the current plan, cycle and add-ons at the agreed price, excluding VAT, in integer cents."
|
|
1002
|
-
}
|
|
1003
|
-
},
|
|
1004
|
-
"required": [
|
|
1005
|
-
"net_cents"
|
|
1006
|
-
],
|
|
1007
|
-
"additionalProperties": false
|
|
1008
|
-
},
|
|
1009
|
-
{
|
|
1010
|
-
"type": "null"
|
|
1011
|
-
}
|
|
1012
|
-
],
|
|
1013
|
-
"description": "What one period (`cycle`) of the current plan costs this organization: the price it agreed, which stays when the catalogue changes. Show this, not the catalogue price, as the price of a billed organization. `null` when no agreed price is recorded for the current plan, cycle and add-ons."
|
|
1014
|
-
},
|
|
1015
1073
|
"scheduled": {
|
|
1016
1074
|
"type": "object",
|
|
1017
1075
|
"properties": {
|
|
@@ -1170,7 +1228,6 @@
|
|
|
1170
1228
|
"period_starts_at",
|
|
1171
1229
|
"period_ends_at",
|
|
1172
1230
|
"next_charge",
|
|
1173
|
-
"current_price",
|
|
1174
1231
|
"scheduled",
|
|
1175
1232
|
"dunning"
|
|
1176
1233
|
],
|
|
@@ -2185,29 +2242,6 @@
|
|
|
2185
2242
|
],
|
|
2186
2243
|
"description": "`null` while a cancel is pending or nothing else renews."
|
|
2187
2244
|
},
|
|
2188
|
-
"current_price": {
|
|
2189
|
-
"anyOf": [
|
|
2190
|
-
{
|
|
2191
|
-
"type": "object",
|
|
2192
|
-
"properties": {
|
|
2193
|
-
"net_cents": {
|
|
2194
|
-
"type": "integer",
|
|
2195
|
-
"minimum": -9007199254740991,
|
|
2196
|
-
"maximum": 9007199254740991,
|
|
2197
|
-
"description": "One period of the current plan, cycle and add-ons at the agreed price, excluding VAT, in integer cents."
|
|
2198
|
-
}
|
|
2199
|
-
},
|
|
2200
|
-
"required": [
|
|
2201
|
-
"net_cents"
|
|
2202
|
-
],
|
|
2203
|
-
"additionalProperties": false
|
|
2204
|
-
},
|
|
2205
|
-
{
|
|
2206
|
-
"type": "null"
|
|
2207
|
-
}
|
|
2208
|
-
],
|
|
2209
|
-
"description": "What one period (`cycle`) of the current plan costs this organization: the price it agreed, which stays when the catalogue changes. Show this, not the catalogue price, as the price of a billed organization. `null` when no agreed price is recorded for the current plan, cycle and add-ons."
|
|
2210
|
-
},
|
|
2211
2245
|
"scheduled": {
|
|
2212
2246
|
"type": "object",
|
|
2213
2247
|
"properties": {
|
|
@@ -2366,7 +2400,6 @@
|
|
|
2366
2400
|
"period_starts_at",
|
|
2367
2401
|
"period_ends_at",
|
|
2368
2402
|
"next_charge",
|
|
2369
|
-
"current_price",
|
|
2370
2403
|
"scheduled",
|
|
2371
2404
|
"dunning"
|
|
2372
2405
|
],
|
|
@@ -30,26 +30,71 @@
|
|
|
30
30
|
"additionalProperties": false
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
|
-
"
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
"
|
|
37
|
-
|
|
33
|
+
"oneOf": [
|
|
34
|
+
{
|
|
35
|
+
"type": "object",
|
|
36
|
+
"properties": {
|
|
37
|
+
"state": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"const": "pending"
|
|
40
|
+
},
|
|
41
|
+
"reason": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"const": "vies_unavailable"
|
|
44
|
+
},
|
|
45
|
+
"vies_outage": {
|
|
46
|
+
"type": "object",
|
|
47
|
+
"properties": {
|
|
48
|
+
"scope": {
|
|
49
|
+
"type": "string",
|
|
50
|
+
"enum": [
|
|
51
|
+
"member_state",
|
|
52
|
+
"vies"
|
|
53
|
+
],
|
|
54
|
+
"description": "`member_state`: the VAT register of `country` does not answer VIES. `vies`: VIES itself does not answer."
|
|
55
|
+
},
|
|
56
|
+
"country": {
|
|
57
|
+
"type": "string",
|
|
58
|
+
"pattern": "^[A-Z]{2}$",
|
|
59
|
+
"description": "The billing address's country whose VAT ID was asked for. Greece is `GR`, never VIES's `EL`."
|
|
60
|
+
}
|
|
61
|
+
},
|
|
62
|
+
"required": [
|
|
63
|
+
"scope",
|
|
64
|
+
"country"
|
|
65
|
+
],
|
|
66
|
+
"additionalProperties": false
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"required": [
|
|
70
|
+
"state",
|
|
71
|
+
"reason",
|
|
72
|
+
"vies_outage"
|
|
73
|
+
],
|
|
74
|
+
"additionalProperties": false
|
|
38
75
|
},
|
|
39
|
-
|
|
40
|
-
"type": "
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
76
|
+
{
|
|
77
|
+
"type": "object",
|
|
78
|
+
"properties": {
|
|
79
|
+
"state": {
|
|
80
|
+
"type": "string",
|
|
81
|
+
"const": "pending"
|
|
82
|
+
},
|
|
83
|
+
"reason": {
|
|
84
|
+
"type": "string",
|
|
85
|
+
"enum": [
|
|
86
|
+
"vies_unverified",
|
|
87
|
+
"vies_identifier_missing"
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
"required": [
|
|
92
|
+
"state",
|
|
93
|
+
"reason"
|
|
94
|
+
],
|
|
95
|
+
"additionalProperties": false
|
|
46
96
|
}
|
|
47
|
-
|
|
48
|
-
"required": [
|
|
49
|
-
"state",
|
|
50
|
-
"reason"
|
|
51
|
-
],
|
|
52
|
-
"additionalProperties": false
|
|
97
|
+
]
|
|
53
98
|
},
|
|
54
99
|
{
|
|
55
100
|
"type": "object",
|
|
@@ -73,50 +73,119 @@
|
|
|
73
73
|
"additionalProperties": false
|
|
74
74
|
},
|
|
75
75
|
{
|
|
76
|
-
"
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
"
|
|
80
|
-
|
|
81
|
-
"name": {
|
|
82
|
-
"anyOf": [
|
|
83
|
-
{
|
|
76
|
+
"oneOf": [
|
|
77
|
+
{
|
|
78
|
+
"type": "object",
|
|
79
|
+
"properties": {
|
|
80
|
+
"vat_id": {
|
|
84
81
|
"type": "string"
|
|
85
82
|
},
|
|
86
|
-
{
|
|
87
|
-
"
|
|
83
|
+
"name": {
|
|
84
|
+
"anyOf": [
|
|
85
|
+
{
|
|
86
|
+
"type": "string"
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"type": "null"
|
|
90
|
+
}
|
|
91
|
+
]
|
|
92
|
+
},
|
|
93
|
+
"state": {
|
|
94
|
+
"type": "string",
|
|
95
|
+
"const": "pending"
|
|
96
|
+
},
|
|
97
|
+
"status": {
|
|
98
|
+
"type": "string",
|
|
99
|
+
"enum": [
|
|
100
|
+
"valid",
|
|
101
|
+
"unverified",
|
|
102
|
+
"unavailable"
|
|
103
|
+
]
|
|
104
|
+
},
|
|
105
|
+
"reason": {
|
|
106
|
+
"type": "string",
|
|
107
|
+
"const": "vies_unavailable"
|
|
108
|
+
},
|
|
109
|
+
"vies_outage": {
|
|
110
|
+
"type": "object",
|
|
111
|
+
"properties": {
|
|
112
|
+
"scope": {
|
|
113
|
+
"type": "string",
|
|
114
|
+
"enum": [
|
|
115
|
+
"member_state",
|
|
116
|
+
"vies"
|
|
117
|
+
],
|
|
118
|
+
"description": "`member_state`: the VAT register of `country` does not answer VIES. `vies`: VIES itself does not answer."
|
|
119
|
+
},
|
|
120
|
+
"country": {
|
|
121
|
+
"type": "string",
|
|
122
|
+
"pattern": "^[A-Z]{2}$",
|
|
123
|
+
"description": "The billing address's country whose VAT ID was asked for. Greece is `GR`, never VIES's `EL`."
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"required": [
|
|
127
|
+
"scope",
|
|
128
|
+
"country"
|
|
129
|
+
],
|
|
130
|
+
"additionalProperties": false
|
|
88
131
|
}
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
"unverified",
|
|
100
|
-
"unavailable"
|
|
101
|
-
]
|
|
132
|
+
},
|
|
133
|
+
"required": [
|
|
134
|
+
"vat_id",
|
|
135
|
+
"name",
|
|
136
|
+
"state",
|
|
137
|
+
"status",
|
|
138
|
+
"reason",
|
|
139
|
+
"vies_outage"
|
|
140
|
+
],
|
|
141
|
+
"additionalProperties": false
|
|
102
142
|
},
|
|
103
|
-
|
|
104
|
-
"type": "
|
|
105
|
-
"
|
|
106
|
-
"
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
143
|
+
{
|
|
144
|
+
"type": "object",
|
|
145
|
+
"properties": {
|
|
146
|
+
"vat_id": {
|
|
147
|
+
"type": "string"
|
|
148
|
+
},
|
|
149
|
+
"name": {
|
|
150
|
+
"anyOf": [
|
|
151
|
+
{
|
|
152
|
+
"type": "string"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"type": "null"
|
|
156
|
+
}
|
|
157
|
+
]
|
|
158
|
+
},
|
|
159
|
+
"state": {
|
|
160
|
+
"type": "string",
|
|
161
|
+
"const": "pending"
|
|
162
|
+
},
|
|
163
|
+
"status": {
|
|
164
|
+
"type": "string",
|
|
165
|
+
"enum": [
|
|
166
|
+
"valid",
|
|
167
|
+
"unverified",
|
|
168
|
+
"unavailable"
|
|
169
|
+
]
|
|
170
|
+
},
|
|
171
|
+
"reason": {
|
|
172
|
+
"type": "string",
|
|
173
|
+
"enum": [
|
|
174
|
+
"vies_unverified",
|
|
175
|
+
"vies_identifier_missing"
|
|
176
|
+
]
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
"required": [
|
|
180
|
+
"vat_id",
|
|
181
|
+
"name",
|
|
182
|
+
"state",
|
|
183
|
+
"status",
|
|
184
|
+
"reason"
|
|
185
|
+
],
|
|
186
|
+
"additionalProperties": false
|
|
110
187
|
}
|
|
111
|
-
|
|
112
|
-
"required": [
|
|
113
|
-
"vat_id",
|
|
114
|
-
"name",
|
|
115
|
-
"state",
|
|
116
|
-
"status",
|
|
117
|
-
"reason"
|
|
118
|
-
],
|
|
119
|
-
"additionalProperties": false
|
|
188
|
+
]
|
|
120
189
|
}
|
|
121
190
|
]
|
|
122
191
|
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"properties": {
|
|
5
|
+
"scope": {
|
|
6
|
+
"type": "string",
|
|
7
|
+
"enum": [
|
|
8
|
+
"member_state",
|
|
9
|
+
"vies"
|
|
10
|
+
],
|
|
11
|
+
"description": "`member_state`: the VAT register of `country` does not answer VIES. `vies`: VIES itself does not answer."
|
|
12
|
+
},
|
|
13
|
+
"country": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"pattern": "^[A-Z]{2}$",
|
|
16
|
+
"description": "The billing address's country whose VAT ID was asked for. Greece is `GR`, never VIES's `EL`."
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"required": [
|
|
20
|
+
"scope",
|
|
21
|
+
"country"
|
|
22
|
+
],
|
|
23
|
+
"additionalProperties": false
|
|
24
|
+
}
|
|
@@ -1,28 +1,78 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
"
|
|
7
|
-
|
|
3
|
+
"oneOf": [
|
|
4
|
+
{
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"field": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"const": "billing.vat_id"
|
|
10
|
+
},
|
|
11
|
+
"rule": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"const": "vies_unavailable"
|
|
14
|
+
},
|
|
15
|
+
"reason": {
|
|
16
|
+
"type": "string",
|
|
17
|
+
"const": "vies_unavailable"
|
|
18
|
+
},
|
|
19
|
+
"vies_outage": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"properties": {
|
|
22
|
+
"scope": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"enum": [
|
|
25
|
+
"member_state",
|
|
26
|
+
"vies"
|
|
27
|
+
],
|
|
28
|
+
"description": "`member_state`: the VAT register of `country` does not answer VIES. `vies`: VIES itself does not answer."
|
|
29
|
+
},
|
|
30
|
+
"country": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"pattern": "^[A-Z]{2}$",
|
|
33
|
+
"description": "The billing address's country whose VAT ID was asked for. Greece is `GR`, never VIES's `EL`."
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
"required": [
|
|
37
|
+
"scope",
|
|
38
|
+
"country"
|
|
39
|
+
],
|
|
40
|
+
"additionalProperties": false
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"required": [
|
|
44
|
+
"field",
|
|
45
|
+
"rule",
|
|
46
|
+
"reason",
|
|
47
|
+
"vies_outage"
|
|
48
|
+
],
|
|
49
|
+
"additionalProperties": false
|
|
8
50
|
},
|
|
9
|
-
|
|
10
|
-
"type": "
|
|
11
|
-
"
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
51
|
+
{
|
|
52
|
+
"type": "object",
|
|
53
|
+
"properties": {
|
|
54
|
+
"field": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"const": "billing.vat_id"
|
|
57
|
+
},
|
|
58
|
+
"rule": {
|
|
59
|
+
"type": "string",
|
|
60
|
+
"const": "vies_unavailable"
|
|
61
|
+
},
|
|
62
|
+
"reason": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"enum": [
|
|
65
|
+
"vies_unverified",
|
|
66
|
+
"vies_identifier_missing"
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"required": [
|
|
71
|
+
"field",
|
|
72
|
+
"rule",
|
|
73
|
+
"reason"
|
|
74
|
+
],
|
|
75
|
+
"additionalProperties": false
|
|
20
76
|
}
|
|
21
|
-
|
|
22
|
-
"required": [
|
|
23
|
-
"field",
|
|
24
|
-
"rule",
|
|
25
|
-
"reason"
|
|
26
|
-
],
|
|
27
|
-
"additionalProperties": false
|
|
77
|
+
]
|
|
28
78
|
}
|