universal-parcel-scraper 0.1342.2-main.9134 → 0.1346.0-main.9155

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 (47) hide show
  1. package/README.md +2 -2
  2. package/data/catalog.json +9 -5
  3. package/data/coverage-summary.json +1 -1
  4. package/data/detection-golden.json +54 -10
  5. package/dist/browser/scraper.js +8 -5
  6. package/dist/carriers/bfe-express/carrier.json +2 -1
  7. package/dist/carriers/huaya-express/statuses.json +2 -1
  8. package/dist/carriers/instapack/adapter.d.ts +20 -0
  9. package/dist/carriers/instapack/adapter.js +73 -0
  10. package/dist/carriers/instapack/carrier.json +42 -7
  11. package/dist/carriers/instapack/numbers.json +46 -2
  12. package/dist/carriers/instapack/parser.d.ts +27 -0
  13. package/dist/carriers/instapack/parser.js +165 -0
  14. package/dist/carriers/instapack/status.d.ts +6 -0
  15. package/dist/carriers/instapack/status.js +23 -0
  16. package/dist/carriers/instapack/statuses.json +6 -1
  17. package/dist/carriers/jcw-express/numbers.json +21 -2
  18. package/dist/carriers/mondial-relay/adapter.js +25 -0
  19. package/dist/carriers/pasarex/carrier.json +1 -1
  20. package/dist/carriers/pasarex/numbers.json +10 -25
  21. package/dist/carriers/wld-express/adapter.d.ts +21 -0
  22. package/dist/carriers/wld-express/adapter.js +76 -0
  23. package/dist/carriers/wld-express/carrier.json +45 -7
  24. package/dist/carriers/wld-express/numbers.json +21 -2
  25. package/dist/carriers/wld-express/parser.d.ts +15 -0
  26. package/dist/carriers/wld-express/parser.js +161 -0
  27. package/dist/carriers/wld-express/status.d.ts +8 -0
  28. package/dist/carriers/wld-express/status.js +47 -0
  29. package/dist/carriers/wld-express/statuses.json +15 -1
  30. package/dist/carriers/xingyunyi/adapter.d.ts +15 -0
  31. package/dist/carriers/xingyunyi/adapter.js +64 -0
  32. package/dist/carriers/xingyunyi/carrier.json +45 -7
  33. package/dist/carriers/xingyunyi/numbers.json +40 -2
  34. package/dist/carriers/xingyunyi/parser.d.ts +17 -0
  35. package/dist/carriers/xingyunyi/parser.js +194 -0
  36. package/dist/carriers/xingyunyi/status.d.ts +8 -0
  37. package/dist/carriers/xingyunyi/status.js +52 -0
  38. package/dist/carriers/xingyunyi/statuses.json +19 -1
  39. package/dist/carriers/yunexpress/adapter.js +43 -3
  40. package/dist/carriers/yunexpress/status.js +13 -5
  41. package/dist/carriers/yunexpress/statuses.json +5 -1
  42. package/dist/core/catalog/statusMaps.js +5 -2
  43. package/dist/data/catalog.json +9 -5
  44. package/dist/generated/catalog.js +9 -5
  45. package/dist/generated/registry.js +9 -3
  46. package/dist/server/openapi.json +1 -1
  47. package/package.json +1 -1
package/README.md CHANGED
@@ -13,7 +13,7 @@ The engine behind [Peek](https://peektracker.com) ([GitHub](https://github.com/p
13
13
  [![License: PolyForm Noncommercial 1.0.0](https://img.shields.io/badge/license-PolyForm%20Noncommercial%201.0.0-blue.svg)](LICENSE)
14
14
 
15
15
  <!-- GENERATED:summary -->
16
- **4,500+ carriers** through **1139 dedicated adapters** and **5 universal fallbacks**
16
+ **4,500+ carriers** through **1142 dedicated adapters** and **5 universal fallbacks**
17
17
 
18
18
  <sub>2057 catalog entries · 166 countries represented</sub>
19
19
  <!-- /GENERATED:summary -->
@@ -164,7 +164,7 @@ the command line's `track --source ParcelsApp` does the same.
164
164
  <!-- GENERATED:stages -->
165
165
  <img src="docs/assets/stages.svg" alt="DHL: Die Sendung wurde in das Zustellfahrzeug geladen.; Mondial Relay: En cours de livraison; Correios Brazil: Objeto saiu para entrega ao destinatário; Correos Express: EN REPARTO; Yamato Transport: 配達中; La Poste / Colissimo: DISTOU. All are filed under out_for_delivery." width="760">
166
166
 
167
- The carrier folders record 25,323 such statuses, each filed under one stage.
167
+ The carrier folders record 25,362 such statuses, each filed under one stage.
168
168
  <!-- /GENERATED:stages -->
169
169
 
170
170
  Wording nobody recorded yet goes through a classifier that reads seven European languages.
package/data/catalog.json CHANGED
@@ -12172,7 +12172,8 @@
12172
12172
  "displayName": "BFE Express",
12173
12173
  "color": "#122a88",
12174
12174
  "aliases": [
12175
- "BFEexpress"
12175
+ "BFEexpress",
12176
+ "BFE"
12176
12177
  ],
12177
12178
  "countries": [
12178
12179
  "AR",
@@ -35033,7 +35034,8 @@
35033
35034
  "timezone": "Europe/Madrid",
35034
35035
  "tracking": {
35035
35036
  "mode": "automatic",
35036
- "adapter": "universal"
35037
+ "adapter": "instapack",
35038
+ "localClocks": true
35037
35039
  },
35038
35040
  "canaryUrl": "https://www.instapack.es/",
35039
35041
  "trackingSearchUrl": "https://back.instapack.es/client-dashboard/seguimiento-de-envios/",
@@ -49320,7 +49322,7 @@
49320
49322
  "detectionRules": [
49321
49323
  {
49322
49324
  "pattern": "^AMZPSR\\d{9}$",
49323
- "confidence": "low"
49325
+ "confidence": "high"
49324
49326
  }
49325
49327
  ]
49326
49328
  },
@@ -69295,7 +69297,8 @@
69295
69297
  "timezone": "Asia/Shanghai",
69296
69298
  "tracking": {
69297
69299
  "mode": "automatic",
69298
- "adapter": "universal"
69300
+ "adapter": "wld-express",
69301
+ "localClocks": true
69299
69302
  },
69300
69303
  "canaryUrl": "https://wld-exp.com/",
69301
69304
  "trackingSearchUrl": "https://wld-exp.com/#/baseData/TrackQuery",
@@ -69916,7 +69919,8 @@
69916
69919
  "timezone": "Asia/Shanghai",
69917
69920
  "tracking": {
69918
69921
  "mode": "automatic",
69919
- "adapter": "universal"
69922
+ "adapter": "xingyunyi",
69923
+ "localClocks": true
69920
69924
  },
69921
69925
  "canaryUrl": "https://www.xingyunyi.com/",
69922
69926
  "trackingUrlTemplate": "https://www.xingyunyi.com/tracking?nums={trackingNumber}",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "catalog": 2057,
3
- "activeAdapters": 1139,
3
+ "activeAdapters": 1142,
4
4
  "countries": 166,
5
5
  "referenceCarriers": 100,
6
6
  "comparison": {
@@ -11944,6 +11944,20 @@
11944
11944
  "postlogistics"
11945
11945
  ]
11946
11946
  },
11947
+ {
11948
+ "input": "090420181030503",
11949
+ "carrier": "unknown",
11950
+ "confidence": "low",
11951
+ "candidates": [
11952
+ "dpd-fr",
11953
+ "brt",
11954
+ "yunda",
11955
+ "ozon-logistics"
11956
+ ],
11957
+ "asked": [
11958
+ "brt"
11959
+ ]
11960
+ },
11947
11961
  {
11948
11962
  "input": "09187717",
11949
11963
  "carrier": "unknown",
@@ -84685,40 +84699,40 @@
84685
84699
  },
84686
84700
  {
84687
84701
  "input": "AMZPSR020816106",
84688
- "carrier": "unknown",
84689
- "confidence": "low",
84702
+ "carrier": "pasarex",
84703
+ "confidence": "high",
84690
84704
  "candidates": [
84691
84705
  "pasarex"
84692
84706
  ]
84693
84707
  },
84694
84708
  {
84695
84709
  "input": "AMZPSR020965874",
84696
- "carrier": "unknown",
84697
- "confidence": "low",
84710
+ "carrier": "pasarex",
84711
+ "confidence": "high",
84698
84712
  "candidates": [
84699
84713
  "pasarex"
84700
84714
  ]
84701
84715
  },
84702
84716
  {
84703
84717
  "input": "AMZPSR023935072",
84704
- "carrier": "unknown",
84705
- "confidence": "low",
84718
+ "carrier": "pasarex",
84719
+ "confidence": "high",
84706
84720
  "candidates": [
84707
84721
  "pasarex"
84708
84722
  ]
84709
84723
  },
84710
84724
  {
84711
84725
  "input": "AMZPSR024279529",
84712
- "carrier": "unknown",
84713
- "confidence": "low",
84726
+ "carrier": "pasarex",
84727
+ "confidence": "high",
84714
84728
  "candidates": [
84715
84729
  "pasarex"
84716
84730
  ]
84717
84731
  },
84718
84732
  {
84719
84733
  "input": "AMZPSR025530371",
84720
- "carrier": "unknown",
84721
- "confidence": "low",
84734
+ "carrier": "pasarex",
84735
+ "confidence": "high",
84722
84736
  "candidates": [
84723
84737
  "pasarex"
84724
84738
  ]
@@ -89478,6 +89492,12 @@
89478
89492
  "aliexpress"
89479
89493
  ]
89480
89494
  },
89495
+ {
89496
+ "input": "CNES00102358787",
89497
+ "carrier": "unknown",
89498
+ "confidence": "none",
89499
+ "candidates": []
89500
+ },
89481
89501
  {
89482
89502
  "input": "CNES00602228835",
89483
89503
  "carrier": "unknown",
@@ -99734,6 +99754,12 @@
99734
99754
  "jch"
99735
99755
  ]
99736
99756
  },
99757
+ {
99758
+ "input": "JCW00002276193",
99759
+ "carrier": "unknown",
99760
+ "confidence": "none",
99761
+ "candidates": []
99762
+ },
99737
99763
  {
99738
99764
  "input": "JCZ0318108989DH",
99739
99765
  "carrier": "jcex",
@@ -120025,6 +120051,12 @@
120025
120051
  "confidence": "none",
120026
120052
  "candidates": []
120027
120053
  },
120054
+ {
120055
+ "input": "WLDME6071800028",
120056
+ "carrier": "unknown",
120057
+ "confidence": "none",
120058
+ "candidates": []
120059
+ },
120028
120060
  {
120029
120061
  "input": "WLWHGB2582814",
120030
120062
  "carrier": "unknown",
@@ -120859,6 +120891,18 @@
120859
120891
  "dhlink"
120860
120892
  ]
120861
120893
  },
120894
+ {
120895
+ "input": "XYYEX0035607568YQ",
120896
+ "carrier": "unknown",
120897
+ "confidence": "none",
120898
+ "candidates": []
120899
+ },
120900
+ {
120901
+ "input": "XYYEX1036968315YQ",
120902
+ "carrier": "unknown",
120903
+ "confidence": "none",
120904
+ "candidates": []
120905
+ },
120862
120906
  {
120863
120907
  "input": "XYZ000000001",
120864
120908
  "carrier": "unknown",
@@ -9522,7 +9522,7 @@ var r = {
9522
9522
  "bfe-express": {
9523
9523
  displayName: "BFE Express",
9524
9524
  color: "#122a88",
9525
- aliases: ["BFEexpress"],
9525
+ aliases: ["BFEexpress", "BFE"],
9526
9526
  countries: [
9527
9527
  "AR",
9528
9528
  "PE",
@@ -26948,7 +26948,8 @@ var r = {
26948
26948
  timezone: "Europe/Madrid",
26949
26949
  tracking: {
26950
26950
  mode: "automatic",
26951
- adapter: "universal"
26951
+ adapter: "instapack",
26952
+ localClocks: !0
26952
26953
  },
26953
26954
  canaryUrl: "https://www.instapack.es/",
26954
26955
  trackingSearchUrl: "https://back.instapack.es/client-dashboard/seguimiento-de-envios/",
@@ -37947,7 +37948,7 @@ var r = {
37947
37948
  }],
37948
37949
  detectionRules: [{
37949
37950
  pattern: "^AMZPSR\\d{9}$",
37950
- confidence: "low"
37951
+ confidence: "high"
37951
37952
  }]
37952
37953
  },
37953
37954
  "pasha-hawaii": {
@@ -53189,7 +53190,8 @@ var r = {
53189
53190
  timezone: "Asia/Shanghai",
53190
53191
  tracking: {
53191
53192
  mode: "automatic",
53192
- adapter: "universal"
53193
+ adapter: "wld-express",
53194
+ localClocks: !0
53193
53195
  },
53194
53196
  canaryUrl: "https://wld-exp.com/",
53195
53197
  trackingSearchUrl: "https://wld-exp.com/#/baseData/TrackQuery",
@@ -53664,7 +53666,8 @@ var r = {
53664
53666
  timezone: "Asia/Shanghai",
53665
53667
  tracking: {
53666
53668
  mode: "automatic",
53667
- adapter: "universal"
53669
+ adapter: "xingyunyi",
53670
+ localClocks: !0
53668
53671
  },
53669
53672
  canaryUrl: "https://www.xingyunyi.com/",
53670
53673
  trackingUrlTemplate: "https://www.xingyunyi.com/tracking?nums={trackingNumber}",
@@ -2,7 +2,8 @@
2
2
  "id": "bfe-express",
3
3
  "displayName": "BFE Express",
4
4
  "aliases": [
5
- "BFEexpress"
5
+ "BFEexpress",
6
+ "BFE"
6
7
  ],
7
8
  "region": {
8
9
  "countries": [
@@ -50,6 +50,7 @@
50
50
  {"wording": "【…】【…】¡Recolección exitosa!. El mensajero de J&T asignado … recolectó tu envío.", "language": "es", "stage": "in_transit", "confirmedBy": "live", "firstSeen": "2026-11-21", "note": "Copied from J&T Express Mexico, which delivers the last leg on the line into Mexico: its courier collects the cleared parcel. It is not the first acceptance. The town, the site, the courier and what follows the sentence are read as ellipses."},
51
51
  {"wording": "【…】Tu envío ha salido de【…】con destino a【…】", "language": "es", "stage": "in_transit", "confirmedBy": "live", "firstSeen": "2026-11-21", "note": "Copied from J&T Express Mexico: the parcel leaves one of its sites for the next. The towns and sites are read as ellipses."},
52
52
  {"wording": "【…】Tu envío ha llegado a【…】", "language": "es", "stage": "in_transit", "confirmedBy": "live", "firstSeen": "2026-11-21", "note": "Copied from J&T Express Mexico: the parcel reaches one of its sites."},
53
- {"wording": "【…】【…】El mensajero de J&T Express … está en camino a tu domicilio.", "language": "es", "stage": "out_for_delivery", "confirmedBy": "source", "note": "J&T Express Mexico's courier on the way to the recipient's home, as JRT's tracker copies it from the same feed on the same platform. The town, the site, the courier and what follows the sentence are read as ellipses."}
53
+ {"wording": "【…】【…】El mensajero de J&T Express … está en camino a tu domicilio.", "language": "es", "stage": "out_for_delivery", "confirmedBy": "source", "note": "J&T Express Mexico's courier on the way to the recipient's home, as JRT's tracker copies it from the same feed on the same platform. The town, the site, the courier and what follows the sentence are read as ellipses."},
54
+ {"wording": "la spedizione è in transito", "language": "it", "stage": "in_transit", "confirmedBy": "live", "firstSeen": "2026-11-24", "note": "The Italian last mile's sentence, as Poste Italiane opens its own: the parcel in transit, at a town and its province."}
54
55
  ]
55
56
  }
@@ -0,0 +1,20 @@
1
+ import type { AdapterFactory, TrackingContext } from '../../core/adapter/index.js';
2
+ import type { CarrierResult } from '../../core/result/index.js';
3
+ import { type StepRecorder } from '../../core/telemetry/index.js';
4
+ export { INSTAPACK_TRACKING, normalizeInstapackNumber, parseInstapack } from './parser.js';
5
+ export declare class InstapackTracker {
6
+ private readonly options;
7
+ constructor(options?: {
8
+ fetcher?: typeof fetch;
9
+ recorder?: StepRecorder;
10
+ userAgent?: string;
11
+ });
12
+ private request;
13
+ /**
14
+ * The form posted with the code. A known code is redirected to the parcel's signed page, read
15
+ * next; an unknown one gets the form again with a message.
16
+ */
17
+ private read;
18
+ fetch(raw: string, context?: TrackingContext): Promise<CarrierResult>;
19
+ }
20
+ export declare const adapter: AdapterFactory;
@@ -0,0 +1,73 @@
1
+ import { ChallengeError, MaintenanceError, RateLimitedError, SchemaError, TransportError } from '../../core/errors/index.js';
2
+ import { runSteps } from '../../core/runner/index.js';
3
+ import { firstAttemptMs, networkRetryStep } from '../../core/runner/networkRetry.js';
4
+ import { NOOP_RECORDER } from '../../core/telemetry/index.js';
5
+ import { decodeText, fetchBounded, userAgentOf } from '../../core/transport/index.js';
6
+ import { INSTAPACK_MAX_BYTES, INSTAPACK_TRACKING, instapackResultPath, isInstapackBlocked, normalizeInstapackNumber, parseInstapack, parseInstapackRefusal, PROVIDER, } from './parser.js';
7
+ export { INSTAPACK_TRACKING, normalizeInstapackNumber, parseInstapack } from './parser.js';
8
+ const ORIGIN = 'https://back.instapack.es';
9
+ const REDIRECTS = [301, 302, 303, 307, 308];
10
+ const GONE = [404, 405, 410];
11
+ const DEFAULT_BUDGET_MS = 20_000;
12
+ export class InstapackTracker {
13
+ options;
14
+ constructor(options = {}) {
15
+ this.options = options;
16
+ }
17
+ async request(url, init, signal, timeoutMs) {
18
+ const { response, bytes } = await fetchBounded(url, { ...init, signal, headers: {
19
+ ...init.headers, Accept: 'text/html', 'User-Agent': userAgentOf(this.options.userAgent),
20
+ } }, { provider: PROVIDER, timeoutMs: Math.max(1, Math.floor(timeoutMs)), maxBytes: INSTAPACK_MAX_BYTES, redirect: 'manual',
21
+ fetcher: this.options.fetcher, allowHttpStatuses: [...REDIRECTS, ...GONE, 403, 429, 503] });
22
+ const { status } = response;
23
+ const html = decodeText(bytes);
24
+ if (status === 429)
25
+ throw new RateLimitedError(PROVIDER);
26
+ if (status === 403 || (status === 503 && isInstapackBlocked(html)))
27
+ throw new ChallengeError(PROVIDER, 'Instapack refused the lookup', { status });
28
+ if (status === 503)
29
+ throw new MaintenanceError(PROVIDER, undefined, { status });
30
+ if (GONE.includes(status))
31
+ throw new TransportError(PROVIDER, 'Instapack tracking is unavailable', { status });
32
+ return { response, html };
33
+ }
34
+ /**
35
+ * The form posted with the code. A known code is redirected to the parcel's signed page, read
36
+ * next; an unknown one gets the form again with a message.
37
+ */
38
+ async read(number, signal, timeoutMs) {
39
+ const deadline = performance.now() + timeoutMs;
40
+ const left = () => Math.max(1, deadline - performance.now());
41
+ const posted = await this.request(INSTAPACK_TRACKING, { method: 'POST', headers: {
42
+ 'Content-Type': 'application/x-www-form-urlencoded', Origin: ORIGIN, Referer: INSTAPACK_TRACKING,
43
+ }, body: new URLSearchParams({ code: number }).toString() }, signal, left());
44
+ if (posted.response.status === 200)
45
+ parseInstapackRefusal(posted.html);
46
+ const path = REDIRECTS.includes(posted.response.status) ? instapackResultPath(posted.response.headers.get('location')) : undefined;
47
+ if (!path)
48
+ throw new SchemaError(PROVIDER, 'Instapack sent the lookup somewhere other than a parcel’s page', { status: posted.response.status });
49
+ const page = await this.request(`${ORIGIN}${path}`, { method: 'GET', headers: { Referer: INSTAPACK_TRACKING } }, signal, left());
50
+ if (page.response.status !== 200)
51
+ throw new SchemaError(PROVIDER, 'Instapack redirected the parcel’s page', { status: page.response.status });
52
+ return parseInstapack(page.html, number);
53
+ }
54
+ async fetch(raw, context = {}) {
55
+ const number = normalizeInstapackNumber(raw);
56
+ // A lookup that fails to reach Instapack, or hangs, starts again once: the first try gets
57
+ // half of the budget. An HTTP status or a page is never sent again.
58
+ return runSteps({ carrier: PROVIDER, budgetMs: context.budgetMs ?? DEFAULT_BUDGET_MS, signal: context.signal,
59
+ recorder: this.options.recorder ?? NOOP_RECORDER }, [
60
+ { id: 'direct', run: ({ signal, remainingMs }) => this.read(number, signal, firstAttemptMs(remainingMs)) },
61
+ networkRetryStep(({ signal, remainingMs }) => this.read(number, signal, remainingMs)),
62
+ ]);
63
+ }
64
+ }
65
+ // No recognition: Instapack tracks the codes its senders give, marketplace numbers among them, and
66
+ // no detection rule offers it, so preflight never asks it.
67
+ export const adapter = (environment) => {
68
+ const tracker = new InstapackTracker({ fetcher: environment.fetcher, recorder: environment.recorder, userAgent: environment.userAgent });
69
+ return {
70
+ id: PROVIDER, recordsSteps: true, steps: ['direct', 'retry'],
71
+ track: (input, context) => tracker.fetch(input.number, context),
72
+ };
73
+ };
@@ -18,17 +18,52 @@
18
18
  "timezone": "Europe/Madrid",
19
19
  "tracking": {
20
20
  "mode": "automatic",
21
- "adapter": "universal",
22
- "steps": []
21
+ "adapter": "instapack",
22
+ "steps": [
23
+ "direct",
24
+ "retry"
25
+ ],
26
+ "localClocks": true
23
27
  },
24
- "capabilities": [],
28
+ "capabilities": [
29
+ "history"
30
+ ],
25
31
  "portal": {
26
32
  "searchUrl": "https://back.instapack.es/client-dashboard/seguimiento-de-envios/",
27
33
  "canaryUrl": "https://www.instapack.es/",
28
- "shows": [],
29
- "scraped": [],
30
- "discarded": [],
31
- "unavailable": []
34
+ "shows": [
35
+ "status",
36
+ "history",
37
+ "scan_times",
38
+ "recipient_address",
39
+ "driver_name",
40
+ "contact_details",
41
+ "parcel_count",
42
+ "customer_reference",
43
+ "coordinates"
44
+ ],
45
+ "scraped": [
46
+ "status",
47
+ "history",
48
+ "scan_times"
49
+ ],
50
+ "discarded": [
51
+ "recipient_address",
52
+ "driver_name",
53
+ "contact_details",
54
+ "parcel_count",
55
+ "customer_reference",
56
+ "coordinates"
57
+ ],
58
+ "unavailable": [
59
+ "location",
60
+ "eta",
61
+ "offset_timestamps",
62
+ "sender_name",
63
+ "recipient_name",
64
+ "weight",
65
+ "service_name"
66
+ ]
32
67
  },
33
68
  "links": [],
34
69
  "detection": []
@@ -1,5 +1,49 @@
1
1
  {
2
2
  "carrier": "instapack",
3
- "gap": "No public page shows a current Instapack tracking code; the only ones archived are 2018 order ids of fifteen digits, a length many carriers share.",
4
- "records": []
3
+ "records": [
4
+ {
5
+ "number": "CNES00102358787",
6
+ "role": "shipment",
7
+ "evidence": "public_shipment_report",
8
+ "source": {
9
+ "url": "https://es.trustpilot.com/reviews/62421cd6f144199fc9ccd94b",
10
+ "date": "2022-03-28",
11
+ "dateKind": "publication",
12
+ "access": "full_page"
13
+ },
14
+ "context": {
15
+ "assessment": "confirmed"
16
+ },
17
+ "expect": {
18
+ "carrier": "unknown",
19
+ "confidence": "none"
20
+ },
21
+ "note": "Review on Instapack's Trustpilot page denying the recipient was out, with this AliExpress economy number. Instapack's tracker answers it with a delivery round, two incidents for an absent recipient and the delivery."
22
+ },
23
+ {
24
+ "number": "090420181030503",
25
+ "role": "shipment",
26
+ "evidence": "public_shipment_report",
27
+ "source": {
28
+ "url": "https://web.archive.org/web/20230316041846/http://instapack.es/check-order/090420181030503",
29
+ "date": "2023-03-16",
30
+ "dateKind": "capture",
31
+ "access": "full_page"
32
+ },
33
+ "context": {
34
+ "assessment": "confirmed"
35
+ },
36
+ "expect": {
37
+ "carrier": "unknown",
38
+ "confidence": "low",
39
+ "candidates": [
40
+ "dpd-fr",
41
+ "brt",
42
+ "yunda",
43
+ "ozon-logistics"
44
+ ]
45
+ },
46
+ "note": "Archived link to Instapack's former order page with one of its own order ids, the order's day and a counter. Instapack's tracker answers it with a delivery in Madrid."
47
+ }
48
+ ]
5
49
  }
@@ -0,0 +1,27 @@
1
+ import type { CarrierResult } from '../../core/result/index.js';
2
+ export declare const PROVIDER = "instapack";
3
+ /** The tracking page instapack.es links to; its form posts `code` back to the same address. */
4
+ export declare const INSTAPACK_TRACKING = "https://back.instapack.es/client-dashboard/seguimiento-de-envios/";
5
+ export declare const INSTAPACK_MAX_BYTES: number;
6
+ /** A code for Instapack's tracker: letters and digits with at least one digit, in capitals. */
7
+ export declare function normalizeInstapackNumber(raw: string): string;
8
+ /** Whether a reply is a block page instead of the tracker's. */
9
+ export declare function isInstapackBlocked(html: string): boolean;
10
+ /** The path of the parcel's page the form's redirect names, or nothing when it names another. */
11
+ export declare function instapackResultPath(location: string | null): string | undefined;
12
+ /**
13
+ * The tracking form again, HTTP 200, for a code without a redirect: its message saying there is
14
+ * no such parcel is not found. Any other message, or none, is not.
15
+ */
16
+ export declare function parseInstapackRefusal(html: string): never;
17
+ /**
18
+ * The parcel's page, which the form redirects to for a code the tracker knows. A heading panel
19
+ * names the code; then a panel lists the driver's steps, `dd/mm/yy HH:MM - <step>`, under a title
20
+ * naming the driver and their phone; a panel lists the delivery incidents, `dd/mm/yyyy HH:MM-
21
+ * <type> - <reason>`; and a delivered parcel's last panel is titled with the delivery's time and
22
+ * wording over the delivery address. Times are wall clocks without a zone.
23
+ *
24
+ * The delivery address, the driver's name and phone, the parcel count, the sender's references
25
+ * and the map's coordinates are never read.
26
+ */
27
+ export declare function parseInstapack(html: string, raw: string): CarrierResult;