@gruncellka/porto-data 0.3.1 → 0.4.1

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 (88) hide show
  1. package/CHANGELOG.md +85 -1
  2. package/LICENSE +199 -5
  3. package/README.md +52 -39
  4. package/index.d.ts +35 -18
  5. package/index.js +2 -1
  6. package/package.json +23 -9
  7. package/porto_data/formats/envelopes.json +120 -0
  8. package/porto_data/formats/layouts.json +288 -0
  9. package/porto_data/mappings.json +65 -10
  10. package/porto_data/metadata.json +662 -125
  11. package/porto_data/policy/jurisdictions.json +839 -0
  12. package/porto_data/policy/markets.json +75 -0
  13. package/porto_data/policy/restrictions.json +668 -0
  14. package/porto_data/providers/deutschepost/features.json +42 -0
  15. package/porto_data/providers/deutschepost/graph.json +203 -0
  16. package/porto_data/providers/deutschepost/limits.json +17 -0
  17. package/porto_data/providers/deutschepost/marks.json +71 -0
  18. package/porto_data/providers/deutschepost/prices/products.json +239 -0
  19. package/porto_data/providers/deutschepost/prices/services.json +51 -0
  20. package/porto_data/providers/deutschepost/products.json +197 -0
  21. package/porto_data/providers/deutschepost/services.json +88 -0
  22. package/porto_data/providers/deutschepost/weights.json +46 -0
  23. package/porto_data/providers/deutschepost/zones.json +231 -0
  24. package/porto_data/providers/laposte/features.json +42 -0
  25. package/porto_data/providers/laposte/graph.json +234 -0
  26. package/porto_data/providers/laposte/limits.json +17 -0
  27. package/porto_data/providers/laposte/marks.json +39 -0
  28. package/porto_data/providers/laposte/prices/products.json +947 -0
  29. package/porto_data/providers/laposte/prices/services.json +41 -0
  30. package/porto_data/providers/laposte/products.json +276 -0
  31. package/porto_data/providers/laposte/services.json +63 -0
  32. package/porto_data/providers/laposte/weights.json +38 -0
  33. package/porto_data/providers/laposte/zones.json +230 -0
  34. package/porto_data/providers/swisspost/features.json +21 -0
  35. package/porto_data/providers/swisspost/graph.json +212 -0
  36. package/porto_data/providers/swisspost/limits.json +17 -0
  37. package/porto_data/providers/swisspost/marks.json +41 -0
  38. package/porto_data/providers/swisspost/prices/products.json +347 -0
  39. package/porto_data/providers/swisspost/prices/services.json +31 -0
  40. package/porto_data/providers/swisspost/products.json +193 -0
  41. package/porto_data/providers/swisspost/rules.json +25 -0
  42. package/porto_data/providers/swisspost/services.json +40 -0
  43. package/porto_data/providers/swisspost/weights.json +38 -0
  44. package/porto_data/providers/swisspost/zones.json +223 -0
  45. package/porto_data/providers/ukrposhta/features.json +28 -0
  46. package/porto_data/providers/ukrposhta/graph.json +148 -0
  47. package/porto_data/providers/ukrposhta/limits.json +17 -0
  48. package/porto_data/providers/ukrposhta/marks.json +25 -0
  49. package/porto_data/providers/ukrposhta/prices/products.json +123 -0
  50. package/porto_data/providers/ukrposhta/prices/services.json +42 -0
  51. package/porto_data/providers/ukrposhta/products.json +74 -0
  52. package/porto_data/providers/ukrposhta/services.json +40 -0
  53. package/porto_data/providers/ukrposhta/weights.json +26 -0
  54. package/porto_data/providers/ukrposhta/zones.json +226 -0
  55. package/porto_data/providers.json +37 -0
  56. package/porto_data/schemas/envelopes.schema.json +120 -0
  57. package/porto_data/schemas/features.schema.json +66 -55
  58. package/porto_data/schemas/graph.schema.json +189 -0
  59. package/porto_data/schemas/jurisdictions.schema.json +116 -0
  60. package/porto_data/schemas/layouts.schema.json +156 -0
  61. package/porto_data/schemas/limits.schema.json +253 -0
  62. package/porto_data/schemas/mappings.schema.json +73 -0
  63. package/porto_data/schemas/markets.schema.json +186 -0
  64. package/porto_data/schemas/marks.schema.json +127 -0
  65. package/porto_data/schemas/metadata.schema.json +183 -0
  66. package/porto_data/schemas/porto_ids.schema.json +45 -0
  67. package/porto_data/schemas/product_prices.schema.json +126 -0
  68. package/porto_data/schemas/products.schema.json +338 -110
  69. package/porto_data/schemas/providers.schema.json +71 -0
  70. package/porto_data/schemas/restrictions.schema.json +175 -355
  71. package/porto_data/schemas/rules.schema.json +104 -0
  72. package/porto_data/schemas/service_prices.schema.json +116 -0
  73. package/porto_data/schemas/services.schema.json +113 -70
  74. package/porto_data/schemas/weights.schema.json +70 -0
  75. package/porto_data/schemas/zones.schema.json +78 -72
  76. package/porto_data/data/data_links.json +0 -148
  77. package/porto_data/data/dimensions.json +0 -158
  78. package/porto_data/data/features.json +0 -66
  79. package/porto_data/data/prices.json +0 -242
  80. package/porto_data/data/products.json +0 -84
  81. package/porto_data/data/restrictions.json +0 -795
  82. package/porto_data/data/services.json +0 -61
  83. package/porto_data/data/weight_tiers.json +0 -54
  84. package/porto_data/data/zones.json +0 -230
  85. package/porto_data/schemas/data_links.schema.json +0 -223
  86. package/porto_data/schemas/dimensions.schema.json +0 -215
  87. package/porto_data/schemas/prices.schema.json +0 -180
  88. package/porto_data/schemas/weight_tiers.schema.json +0 -70
@@ -0,0 +1,197 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/gruncellka/porto-data/refs/heads/main/porto_data/schemas/products.schema.json",
3
+ "file_type": "products",
4
+ "provider": "deutschepost",
5
+ "unit": {
6
+ "weight": "g"
7
+ },
8
+ "products": [
9
+ {
10
+ "id": "standardbrief",
11
+ "native_id": 10001,
12
+ "porto_id": "small",
13
+ "name": "Standardbrief",
14
+ "envelope_ids": [
15
+ "DL",
16
+ "C6"
17
+ ],
18
+ "zones": [
19
+ "domestic",
20
+ "zone_1_eu",
21
+ "zone_2_europe",
22
+ "world"
23
+ ],
24
+ "weight_tier": "W0020",
25
+ "effective_from": "2026-01-01",
26
+ "effective_to": null,
27
+ "mark_type": "stamp",
28
+ "tracking_mode": "optional",
29
+ "delivery": [
30
+ {
31
+ "zones": [
32
+ "domestic"
33
+ ],
34
+ "span": "between",
35
+ "days_min": 1,
36
+ "days_max": 2
37
+ },
38
+ {
39
+ "zones": [
40
+ "zone_1_eu",
41
+ "zone_2_europe",
42
+ "world"
43
+ ],
44
+ "span": "within",
45
+ "days_max": 12
46
+ }
47
+ ]
48
+ },
49
+ {
50
+ "id": "kompaktbrief",
51
+ "native_id": 10002,
52
+ "porto_id": "medium",
53
+ "name": "Kompaktbrief",
54
+ "envelope_ids": [
55
+ "C5"
56
+ ],
57
+ "zones": [
58
+ "domestic",
59
+ "zone_1_eu",
60
+ "zone_2_europe",
61
+ "world"
62
+ ],
63
+ "weight_tier": "W0050",
64
+ "effective_from": "2026-01-01",
65
+ "effective_to": null,
66
+ "mark_type": "stamp",
67
+ "tracking_mode": "optional",
68
+ "delivery": [
69
+ {
70
+ "zones": [
71
+ "domestic"
72
+ ],
73
+ "span": "between",
74
+ "days_min": 1,
75
+ "days_max": 2
76
+ },
77
+ {
78
+ "zones": [
79
+ "zone_1_eu",
80
+ "zone_2_europe",
81
+ "world"
82
+ ],
83
+ "span": "within",
84
+ "days_max": 12
85
+ }
86
+ ]
87
+ },
88
+ {
89
+ "id": "grossbrief",
90
+ "native_id": 10003,
91
+ "porto_id": "large",
92
+ "name": "Großbrief",
93
+ "envelope_ids": [
94
+ "C4"
95
+ ],
96
+ "zones": [
97
+ "domestic",
98
+ "zone_1_eu",
99
+ "zone_2_europe",
100
+ "world"
101
+ ],
102
+ "weight_tier": "W0500",
103
+ "effective_from": "2026-01-01",
104
+ "effective_to": null,
105
+ "mark_type": "stamp",
106
+ "tracking_mode": "optional",
107
+ "delivery": [
108
+ {
109
+ "zones": [
110
+ "domestic"
111
+ ],
112
+ "span": "between",
113
+ "days_min": 1,
114
+ "days_max": 2
115
+ },
116
+ {
117
+ "zones": [
118
+ "zone_1_eu",
119
+ "zone_2_europe",
120
+ "world"
121
+ ],
122
+ "span": "within",
123
+ "days_max": 12
124
+ }
125
+ ]
126
+ },
127
+ {
128
+ "id": "maxibrief",
129
+ "native_id": 10004,
130
+ "porto_id": "extra_large",
131
+ "name": "Maxibrief",
132
+ "envelope_ids": [
133
+ "B4"
134
+ ],
135
+ "zones": [
136
+ "domestic",
137
+ "zone_1_eu",
138
+ "zone_2_europe",
139
+ "world"
140
+ ],
141
+ "weight_tier": "W1000",
142
+ "effective_from": "2026-01-01",
143
+ "effective_to": null,
144
+ "mark_type": "stamp",
145
+ "tracking_mode": "optional",
146
+ "delivery": [
147
+ {
148
+ "zones": [
149
+ "domestic"
150
+ ],
151
+ "span": "between",
152
+ "days_min": 1,
153
+ "days_max": 2
154
+ },
155
+ {
156
+ "zones": [
157
+ "zone_1_eu",
158
+ "zone_2_europe",
159
+ "world"
160
+ ],
161
+ "span": "within",
162
+ "days_max": 12
163
+ }
164
+ ]
165
+ },
166
+ {
167
+ "id": "maxibrief_international_heavy",
168
+ "native_id": 10005,
169
+ "porto_id": "extra_large",
170
+ "name": "Maxibrief International (bis 2.000 g)",
171
+ "envelope_ids": [
172
+ "B4"
173
+ ],
174
+ "zones": [
175
+ "zone_1_eu",
176
+ "zone_2_europe",
177
+ "world"
178
+ ],
179
+ "weight_tier": "W2000",
180
+ "effective_from": "2026-01-01",
181
+ "effective_to": null,
182
+ "mark_type": "stamp",
183
+ "tracking_mode": "optional",
184
+ "delivery": [
185
+ {
186
+ "zones": [
187
+ "zone_1_eu",
188
+ "zone_2_europe",
189
+ "world"
190
+ ],
191
+ "span": "within",
192
+ "days_max": 12
193
+ }
194
+ ]
195
+ }
196
+ ]
197
+ }
@@ -0,0 +1,88 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/gruncellka/porto-data/refs/heads/main/porto_data/schemas/services.schema.json",
3
+ "file_type": "services",
4
+ "provider": "deutschepost",
5
+ "services": [
6
+ {
7
+ "id": "einschreiben",
8
+ "porto_id": "registered",
9
+ "name": "Einschreiben",
10
+ "label": "Registered mail",
11
+ "description": "Tracking with proof of mailing",
12
+ "features": [
13
+ "tracking_number",
14
+ "proof_of_mailing"
15
+ ],
16
+ "enables_tracking": true,
17
+ "online_supported": true,
18
+ "integrations": {
19
+ "internetmarke": true
20
+ },
21
+ "supported_zones": [
22
+ "domestic",
23
+ "zone_1_eu",
24
+ "zone_2_europe",
25
+ "world"
26
+ ]
27
+ },
28
+ {
29
+ "id": "einschreiben_einwurf",
30
+ "porto_id": "registered",
31
+ "name": "Einschreiben Einwurf",
32
+ "label": "Registered mail (mailbox delivery)",
33
+ "description": "Registered delivery into mailbox (service variant, not a feature). Internetmarke API: domestic only.",
34
+ "features": [
35
+ "tracking_number"
36
+ ],
37
+ "enables_tracking": true,
38
+ "online_supported": true,
39
+ "integrations": {
40
+ "internetmarke": true
41
+ },
42
+ "supported_zones": [
43
+ "domestic"
44
+ ]
45
+ },
46
+ {
47
+ "id": "einschreiben_rueckschein",
48
+ "porto_id": "registered_return_receipt",
49
+ "name": "Einschreiben Rückschein",
50
+ "label": "Registered mail with return receipt",
51
+ "description": "Registered mail with signature and return receipt. Internetmarke API: domestic only.",
52
+ "features": [
53
+ "tracking_number",
54
+ "recipient_signature",
55
+ "return_receipt",
56
+ "proof_of_delivery"
57
+ ],
58
+ "enables_tracking": true,
59
+ "online_supported": true,
60
+ "integrations": {
61
+ "internetmarke": true
62
+ },
63
+ "supported_zones": [
64
+ "domestic"
65
+ ]
66
+ },
67
+ {
68
+ "id": "zusatzversicherung",
69
+ "porto_id": "insurance",
70
+ "name": "Zusatzversicherung 500",
71
+ "label": "Additional insurance (500 EUR)",
72
+ "description": "Additional insurance up to 500 EUR",
73
+ "features": [
74
+ "tracking_number"
75
+ ],
76
+ "online_supported": true,
77
+ "integrations": {
78
+ "internetmarke": true
79
+ },
80
+ "supported_zones": [
81
+ "domestic",
82
+ "zone_1_eu",
83
+ "zone_2_europe",
84
+ "world"
85
+ ]
86
+ }
87
+ ]
88
+ }
@@ -0,0 +1,46 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/gruncellka/porto-data/refs/heads/main/porto_data/schemas/weights.schema.json",
3
+ "file_type": "weights",
4
+ "provider": "deutschepost",
5
+ "unit": {
6
+ "weight": "g"
7
+ },
8
+ "weights": {
9
+ "W0020": {
10
+ "min": 0,
11
+ "max": 20
12
+ },
13
+ "W0050": {
14
+ "min": 21,
15
+ "max": 50
16
+ },
17
+ "W0500": {
18
+ "min": 51,
19
+ "max": 500
20
+ },
21
+ "W1000": {
22
+ "min": 501,
23
+ "max": 1000
24
+ },
25
+ "W2000": {
26
+ "min": 1001,
27
+ "max": 2000
28
+ },
29
+ "W5000": {
30
+ "min": 2001,
31
+ "max": 5000
32
+ },
33
+ "W10000": {
34
+ "min": 5001,
35
+ "max": 10000
36
+ },
37
+ "W20000": {
38
+ "min": 10001,
39
+ "max": 20000
40
+ },
41
+ "W31500": {
42
+ "min": 20001,
43
+ "max": 31500
44
+ }
45
+ }
46
+ }
@@ -0,0 +1,231 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/gruncellka/porto-data/refs/heads/main/porto_data/schemas/zones.schema.json",
3
+ "file_type": "zones",
4
+ "provider": "deutschepost",
5
+ "unit": {
6
+ "country_code": "ISO 3166-1 alpha-2"
7
+ },
8
+ "zones": [
9
+ {
10
+ "id": "domestic",
11
+ "name": "Deutschland",
12
+ "description": "Germany",
13
+ "country_codes": [
14
+ "DE"
15
+ ]
16
+ },
17
+ {
18
+ "id": "zone_1_eu",
19
+ "name": "Zone 1 - EU",
20
+ "description": "European Union member countries",
21
+ "country_codes": [
22
+ "AT",
23
+ "BE",
24
+ "BG",
25
+ "HR",
26
+ "CY",
27
+ "CZ",
28
+ "DK",
29
+ "EE",
30
+ "FI",
31
+ "FR",
32
+ "GR",
33
+ "HU",
34
+ "IE",
35
+ "IT",
36
+ "LV",
37
+ "LT",
38
+ "LU",
39
+ "MT",
40
+ "NL",
41
+ "PL",
42
+ "PT",
43
+ "RO",
44
+ "SK",
45
+ "SI",
46
+ "ES",
47
+ "SE"
48
+ ]
49
+ },
50
+ {
51
+ "id": "zone_2_europe",
52
+ "name": "Zone 2 - Europa",
53
+ "description": "European countries outside EU (CH, NO, GB, etc.)",
54
+ "country_codes": [
55
+ "AL",
56
+ "AD",
57
+ "BY",
58
+ "BA",
59
+ "FO",
60
+ "GI",
61
+ "GL",
62
+ "IS",
63
+ "XK",
64
+ "LI",
65
+ "MD",
66
+ "MC",
67
+ "ME",
68
+ "MK",
69
+ "NO",
70
+ "RU",
71
+ "SM",
72
+ "RS",
73
+ "CH",
74
+ "TR",
75
+ "UA",
76
+ "GB",
77
+ "VA"
78
+ ]
79
+ },
80
+ {
81
+ "id": "world",
82
+ "name": "Welt",
83
+ "description": "All countries outside Europe (international mail)",
84
+ "country_codes": [
85
+ "AF",
86
+ "DZ",
87
+ "AO",
88
+ "AR",
89
+ "AM",
90
+ "AU",
91
+ "AZ",
92
+ "BH",
93
+ "BD",
94
+ "BB",
95
+ "BZ",
96
+ "BJ",
97
+ "BT",
98
+ "BO",
99
+ "BW",
100
+ "BR",
101
+ "BN",
102
+ "BF",
103
+ "BI",
104
+ "KH",
105
+ "CM",
106
+ "CA",
107
+ "CV",
108
+ "CF",
109
+ "TD",
110
+ "CL",
111
+ "CN",
112
+ "CO",
113
+ "KM",
114
+ "CG",
115
+ "CD",
116
+ "CR",
117
+ "CI",
118
+ "CU",
119
+ "DJ",
120
+ "DM",
121
+ "DO",
122
+ "EC",
123
+ "EG",
124
+ "SV",
125
+ "GQ",
126
+ "ER",
127
+ "ET",
128
+ "FJ",
129
+ "GA",
130
+ "GM",
131
+ "GE",
132
+ "GH",
133
+ "GD",
134
+ "GT",
135
+ "GN",
136
+ "GW",
137
+ "GY",
138
+ "HT",
139
+ "HN",
140
+ "IN",
141
+ "ID",
142
+ "IR",
143
+ "IQ",
144
+ "IL",
145
+ "JM",
146
+ "JP",
147
+ "JO",
148
+ "KZ",
149
+ "KE",
150
+ "KI",
151
+ "KP",
152
+ "KR",
153
+ "KW",
154
+ "KG",
155
+ "LA",
156
+ "LB",
157
+ "LS",
158
+ "LR",
159
+ "LY",
160
+ "MG",
161
+ "MW",
162
+ "MY",
163
+ "MV",
164
+ "ML",
165
+ "MH",
166
+ "MR",
167
+ "MU",
168
+ "MX",
169
+ "FM",
170
+ "MN",
171
+ "MA",
172
+ "MZ",
173
+ "MM",
174
+ "NA",
175
+ "NR",
176
+ "NP",
177
+ "NZ",
178
+ "NI",
179
+ "NE",
180
+ "NG",
181
+ "OM",
182
+ "PK",
183
+ "PW",
184
+ "PA",
185
+ "PG",
186
+ "PY",
187
+ "PE",
188
+ "PH",
189
+ "QA",
190
+ "RW",
191
+ "WS",
192
+ "ST",
193
+ "SA",
194
+ "SN",
195
+ "SC",
196
+ "SL",
197
+ "SG",
198
+ "SB",
199
+ "SO",
200
+ "ZA",
201
+ "LK",
202
+ "SD",
203
+ "SR",
204
+ "SZ",
205
+ "SY",
206
+ "TW",
207
+ "TJ",
208
+ "TZ",
209
+ "TH",
210
+ "TL",
211
+ "TG",
212
+ "TO",
213
+ "TT",
214
+ "TN",
215
+ "TM",
216
+ "TV",
217
+ "UG",
218
+ "AE",
219
+ "US",
220
+ "UY",
221
+ "UZ",
222
+ "VU",
223
+ "VE",
224
+ "VN",
225
+ "YE",
226
+ "ZM",
227
+ "ZW"
228
+ ]
229
+ }
230
+ ]
231
+ }
@@ -0,0 +1,42 @@
1
+ {
2
+ "$schema": "https://raw.githubusercontent.com/gruncellka/porto-data/refs/heads/main/porto_data/schemas/features.schema.json",
3
+ "file_type": "features",
4
+ "provider": "laposte",
5
+ "features": [
6
+ {
7
+ "id": "numero_suivi",
8
+ "porto_id": "tracking_number",
9
+ "name": "Numéro de suivi",
10
+ "label": "Tracking number",
11
+ "description": "Suivi / Lettre suivie style tracking when the ordered service provides it"
12
+ },
13
+ {
14
+ "id": "preuve_depot",
15
+ "porto_id": "proof_of_mailing",
16
+ "name": "Preuve de dépôt",
17
+ "label": "Proof of mailing",
18
+ "description": "Attestation de dépôt (recommandé and similar services)"
19
+ },
20
+ {
21
+ "id": "signature_destinataire",
22
+ "porto_id": "recipient_signature",
23
+ "name": "Signature du destinataire",
24
+ "label": "Recipient signature",
25
+ "description": "Signature upon delivery when offered by the service"
26
+ },
27
+ {
28
+ "id": "avis_reception",
29
+ "porto_id": "return_receipt",
30
+ "name": "Avis de réception",
31
+ "label": "Return receipt",
32
+ "description": "Avis de réception returned to the sender (recommandé AR)"
33
+ },
34
+ {
35
+ "id": "preuve_livraison",
36
+ "porto_id": "proof_of_delivery",
37
+ "name": "Preuve de distribution",
38
+ "label": "Proof of delivery",
39
+ "description": "Derived from delivery confirmation / tracking outcome where applicable"
40
+ }
41
+ ]
42
+ }