universal-parcel-scraper 0.95.0-main.992 → 0.97.0-main.997
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/README.md +2 -2
- package/data/catalog.json +24 -3
- package/data/coverage-summary.json +1 -1
- package/data/detection-golden.json +41 -0
- package/dist/browser/scraper.js +20 -4
- package/dist/carriers/apc-overnight/adapter.d.ts +14 -0
- package/dist/carriers/apc-overnight/adapter.js +53 -0
- package/dist/carriers/apc-overnight/carrier.json +55 -8
- package/dist/carriers/apc-overnight/numbers.json +7 -7
- package/dist/carriers/apc-overnight/parser.d.ts +17 -0
- package/dist/carriers/apc-overnight/parser.js +166 -0
- package/dist/carriers/apc-overnight/status.d.ts +12 -0
- package/dist/carriers/apc-overnight/status.js +44 -0
- package/dist/carriers/apc-overnight/statuses.json +10 -1
- package/dist/carriers/lietuvos-pastas/adapter.d.ts +15 -0
- package/dist/carriers/lietuvos-pastas/adapter.js +65 -0
- package/dist/carriers/lietuvos-pastas/carrier.json +52 -7
- package/dist/carriers/lietuvos-pastas/numbers.json +51 -9
- package/dist/carriers/lietuvos-pastas/parser.d.ts +15 -0
- package/dist/carriers/lietuvos-pastas/parser.js +198 -0
- package/dist/carriers/lietuvos-pastas/status.d.ts +13 -0
- package/dist/carriers/lietuvos-pastas/status.js +95 -0
- package/dist/carriers/lietuvos-pastas/statuses.json +53 -1
- package/dist/core/catalog/statusMaps.js +7 -5
- package/dist/data/catalog.json +24 -3
- package/dist/generated/catalog.d.ts +17 -3
- package/dist/generated/catalog.js +25 -4
- package/dist/generated/recognition.js +2 -0
- package/dist/generated/registry.js +6 -2
- package/dist/server/openapi.json +1 -1
- 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)
|
|
14
14
|
|
|
15
15
|
<!-- GENERATED:summary -->
|
|
16
|
-
**3,500+ carriers** through **
|
|
16
|
+
**3,500+ carriers** through **156 dedicated adapters** and **5 universal fallbacks**
|
|
17
17
|
|
|
18
18
|
<sub>208 catalog entries · 66 countries represented</sub>
|
|
19
19
|
<!-- /GENERATED:summary -->
|
|
@@ -155,7 +155,7 @@ createTracker({ providers: ['ParcelsApp', 'Ship24', '17TRACK', 'Postal Ninja', '
|
|
|
155
155
|
<!-- GENERATED:stages -->
|
|
156
156
|
<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">
|
|
157
157
|
|
|
158
|
-
The carrier folders record 4,
|
|
158
|
+
The carrier folders record 4,357 such statuses, each filed under one stage.
|
|
159
159
|
<!-- /GENERATED:stages -->
|
|
160
160
|
|
|
161
161
|
Wording nobody recorded yet goes through a classifier that reads seven European languages.
|
package/data/catalog.json
CHANGED
|
@@ -4852,11 +4852,24 @@
|
|
|
4852
4852
|
"timezone": "Europe/London",
|
|
4853
4853
|
"tracking": {
|
|
4854
4854
|
"mode": "automatic",
|
|
4855
|
-
"adapter": "
|
|
4855
|
+
"adapter": "apc-overnight",
|
|
4856
|
+
"recognitionRank": 870,
|
|
4857
|
+
"localClocks": true
|
|
4856
4858
|
},
|
|
4857
4859
|
"canaryUrl": "https://apc.co.uk/",
|
|
4860
|
+
"trackingUrlTemplate": "https://apcchoice.apc-overnight.com/track-parcel?id={trackingNumber}",
|
|
4858
4861
|
"trackingSearchUrl": "https://apc.co.uk/",
|
|
4859
|
-
"linkRules": [
|
|
4862
|
+
"linkRules": [
|
|
4863
|
+
{
|
|
4864
|
+
"domains": [
|
|
4865
|
+
"apcchoice.apc-overnight.com"
|
|
4866
|
+
],
|
|
4867
|
+
"pathPattern": "^/track-parcel/?$",
|
|
4868
|
+
"params": [
|
|
4869
|
+
"id"
|
|
4870
|
+
]
|
|
4871
|
+
}
|
|
4872
|
+
],
|
|
4860
4873
|
"detectionRules": [
|
|
4861
4874
|
{
|
|
4862
4875
|
"pattern": "^20[12]\\d(?:0[1-9]|1[0-2])(?:0[1-9]|[12]\\d|3[01])\\d{14}$",
|
|
@@ -7024,7 +7037,9 @@
|
|
|
7024
7037
|
"timezone": "Europe/Vilnius",
|
|
7025
7038
|
"tracking": {
|
|
7026
7039
|
"mode": "automatic",
|
|
7027
|
-
"adapter": "
|
|
7040
|
+
"adapter": "lietuvos-pastas",
|
|
7041
|
+
"recognitionRank": 860,
|
|
7042
|
+
"localClocks": true
|
|
7028
7043
|
},
|
|
7029
7044
|
"canaryUrl": "https://lpexpress.lt/track",
|
|
7030
7045
|
"trackingUrlTemplate": "https://lpexpress.lt/track?parcel={trackingNumber}",
|
|
@@ -7059,6 +7074,12 @@
|
|
|
7059
7074
|
{
|
|
7060
7075
|
"pattern": "^(?:CC|CH|HC)\\d{9}LT$",
|
|
7061
7076
|
"confidence": "low"
|
|
7077
|
+
},
|
|
7078
|
+
{
|
|
7079
|
+
"pattern": "^[A-Z]{2}\\d{9}LT$",
|
|
7080
|
+
"confidence": "low",
|
|
7081
|
+
"checksum": "s10",
|
|
7082
|
+
"preferred": true
|
|
7062
7083
|
}
|
|
7063
7084
|
]
|
|
7064
7085
|
},
|
|
@@ -9600,6 +9600,7 @@
|
|
|
9600
9600
|
"apc-overnight"
|
|
9601
9601
|
],
|
|
9602
9602
|
"asked": [
|
|
9603
|
+
"apc-overnight",
|
|
9603
9604
|
"austrian-post"
|
|
9604
9605
|
]
|
|
9605
9606
|
},
|
|
@@ -9663,6 +9664,7 @@
|
|
|
9663
9664
|
"apc-overnight"
|
|
9664
9665
|
],
|
|
9665
9666
|
"asked": [
|
|
9667
|
+
"apc-overnight",
|
|
9666
9668
|
"austrian-post"
|
|
9667
9669
|
]
|
|
9668
9670
|
},
|
|
@@ -9686,6 +9688,7 @@
|
|
|
9686
9688
|
"apc-overnight"
|
|
9687
9689
|
],
|
|
9688
9690
|
"asked": [
|
|
9691
|
+
"apc-overnight",
|
|
9689
9692
|
"austrian-post"
|
|
9690
9693
|
]
|
|
9691
9694
|
},
|
|
@@ -9703,6 +9706,7 @@
|
|
|
9703
9706
|
"apc-overnight"
|
|
9704
9707
|
],
|
|
9705
9708
|
"asked": [
|
|
9709
|
+
"apc-overnight",
|
|
9706
9710
|
"austrian-post"
|
|
9707
9711
|
]
|
|
9708
9712
|
},
|
|
@@ -24785,6 +24789,7 @@
|
|
|
24785
24789
|
"intl-post"
|
|
24786
24790
|
],
|
|
24787
24791
|
"asked": [
|
|
24792
|
+
"lietuvos-pastas",
|
|
24788
24793
|
"chronopost"
|
|
24789
24794
|
]
|
|
24790
24795
|
},
|
|
@@ -25654,6 +25659,7 @@
|
|
|
25654
25659
|
"lietuvos-pastas"
|
|
25655
25660
|
],
|
|
25656
25661
|
"asked": [
|
|
25662
|
+
"lietuvos-pastas",
|
|
25657
25663
|
"chronopost"
|
|
25658
25664
|
]
|
|
25659
25665
|
},
|
|
@@ -25666,6 +25672,7 @@
|
|
|
25666
25672
|
"lietuvos-pastas"
|
|
25667
25673
|
],
|
|
25668
25674
|
"asked": [
|
|
25675
|
+
"lietuvos-pastas",
|
|
25669
25676
|
"chronopost"
|
|
25670
25677
|
]
|
|
25671
25678
|
},
|
|
@@ -25677,6 +25684,19 @@
|
|
|
25677
25684
|
"intl-post"
|
|
25678
25685
|
],
|
|
25679
25686
|
"asked": [
|
|
25687
|
+
"lietuvos-pastas",
|
|
25688
|
+
"chronopost"
|
|
25689
|
+
]
|
|
25690
|
+
},
|
|
25691
|
+
{
|
|
25692
|
+
"input": "CC929125681LT",
|
|
25693
|
+
"carrier": "intl-post",
|
|
25694
|
+
"confidence": "high",
|
|
25695
|
+
"candidates": [
|
|
25696
|
+
"intl-post"
|
|
25697
|
+
],
|
|
25698
|
+
"asked": [
|
|
25699
|
+
"lietuvos-pastas",
|
|
25680
25700
|
"chronopost"
|
|
25681
25701
|
]
|
|
25682
25702
|
},
|
|
@@ -26052,6 +26072,7 @@
|
|
|
26052
26072
|
"lietuvos-pastas"
|
|
26053
26073
|
],
|
|
26054
26074
|
"asked": [
|
|
26075
|
+
"lietuvos-pastas",
|
|
26055
26076
|
"chronopost"
|
|
26056
26077
|
]
|
|
26057
26078
|
},
|
|
@@ -26064,6 +26085,7 @@
|
|
|
26064
26085
|
"lietuvos-pastas"
|
|
26065
26086
|
],
|
|
26066
26087
|
"asked": [
|
|
26088
|
+
"lietuvos-pastas",
|
|
26067
26089
|
"chronopost"
|
|
26068
26090
|
]
|
|
26069
26091
|
},
|
|
@@ -26088,6 +26110,7 @@
|
|
|
26088
26110
|
"lietuvos-pastas"
|
|
26089
26111
|
],
|
|
26090
26112
|
"asked": [
|
|
26113
|
+
"lietuvos-pastas",
|
|
26091
26114
|
"chronopost"
|
|
26092
26115
|
]
|
|
26093
26116
|
},
|
|
@@ -27580,6 +27603,7 @@
|
|
|
27580
27603
|
"intl-post"
|
|
27581
27604
|
],
|
|
27582
27605
|
"asked": [
|
|
27606
|
+
"lietuvos-pastas",
|
|
27583
27607
|
"chronopost"
|
|
27584
27608
|
]
|
|
27585
27609
|
},
|
|
@@ -29161,6 +29185,20 @@
|
|
|
29161
29185
|
"lietuvos-pastas"
|
|
29162
29186
|
],
|
|
29163
29187
|
"asked": [
|
|
29188
|
+
"lietuvos-pastas",
|
|
29189
|
+
"chronopost"
|
|
29190
|
+
]
|
|
29191
|
+
},
|
|
29192
|
+
{
|
|
29193
|
+
"input": "HC019942965LT",
|
|
29194
|
+
"carrier": "unknown",
|
|
29195
|
+
"confidence": "low",
|
|
29196
|
+
"candidates": [
|
|
29197
|
+
"chronopost",
|
|
29198
|
+
"lietuvos-pastas"
|
|
29199
|
+
],
|
|
29200
|
+
"asked": [
|
|
29201
|
+
"lietuvos-pastas",
|
|
29164
29202
|
"chronopost"
|
|
29165
29203
|
]
|
|
29166
29204
|
},
|
|
@@ -29173,6 +29211,7 @@
|
|
|
29173
29211
|
"lietuvos-pastas"
|
|
29174
29212
|
],
|
|
29175
29213
|
"asked": [
|
|
29214
|
+
"lietuvos-pastas",
|
|
29176
29215
|
"chronopost"
|
|
29177
29216
|
]
|
|
29178
29217
|
},
|
|
@@ -33473,6 +33512,7 @@
|
|
|
33473
33512
|
"intl-post"
|
|
33474
33513
|
],
|
|
33475
33514
|
"asked": [
|
|
33515
|
+
"lietuvos-pastas",
|
|
33476
33516
|
"chronopost"
|
|
33477
33517
|
]
|
|
33478
33518
|
},
|
|
@@ -33930,6 +33970,7 @@
|
|
|
33930
33970
|
"intl-post"
|
|
33931
33971
|
],
|
|
33932
33972
|
"asked": [
|
|
33973
|
+
"lietuvos-pastas",
|
|
33933
33974
|
"chronopost"
|
|
33934
33975
|
]
|
|
33935
33976
|
},
|
package/dist/browser/scraper.js
CHANGED
|
@@ -3976,11 +3976,18 @@ var be = {
|
|
|
3976
3976
|
timezone: "Europe/London",
|
|
3977
3977
|
tracking: {
|
|
3978
3978
|
mode: "automatic",
|
|
3979
|
-
adapter: "
|
|
3979
|
+
adapter: "apc-overnight",
|
|
3980
|
+
recognitionRank: 870,
|
|
3981
|
+
localClocks: !0
|
|
3980
3982
|
},
|
|
3981
3983
|
canaryUrl: "https://apc.co.uk/",
|
|
3984
|
+
trackingUrlTemplate: "https://apcchoice.apc-overnight.com/track-parcel?id={trackingNumber}",
|
|
3982
3985
|
trackingSearchUrl: "https://apc.co.uk/",
|
|
3983
|
-
linkRules: [
|
|
3986
|
+
linkRules: [{
|
|
3987
|
+
domains: ["apcchoice.apc-overnight.com"],
|
|
3988
|
+
pathPattern: "^/track-parcel/?$",
|
|
3989
|
+
params: ["id"]
|
|
3990
|
+
}],
|
|
3984
3991
|
detectionRules: [{
|
|
3985
3992
|
pattern: "^20[12]\\d(?:0[1-9]|1[0-2])(?:0[1-9]|[12]\\d|3[01])\\d{14}$",
|
|
3986
3993
|
confidence: "low",
|
|
@@ -5589,7 +5596,9 @@ var be = {
|
|
|
5589
5596
|
timezone: "Europe/Vilnius",
|
|
5590
5597
|
tracking: {
|
|
5591
5598
|
mode: "automatic",
|
|
5592
|
-
adapter: "
|
|
5599
|
+
adapter: "lietuvos-pastas",
|
|
5600
|
+
recognitionRank: 860,
|
|
5601
|
+
localClocks: !0
|
|
5593
5602
|
},
|
|
5594
5603
|
canaryUrl: "https://lpexpress.lt/track",
|
|
5595
5604
|
trackingUrlTemplate: "https://lpexpress.lt/track?parcel={trackingNumber}",
|
|
@@ -5613,6 +5622,11 @@ var be = {
|
|
|
5613
5622
|
detectionRules: [{
|
|
5614
5623
|
pattern: "^(?:CC|CH|HC)\\d{9}LT$",
|
|
5615
5624
|
confidence: "low"
|
|
5625
|
+
}, {
|
|
5626
|
+
pattern: "^[A-Z]{2}\\d{9}LT$",
|
|
5627
|
+
confidence: "low",
|
|
5628
|
+
checksum: "s10",
|
|
5629
|
+
preferred: !0
|
|
5616
5630
|
}]
|
|
5617
5631
|
},
|
|
5618
5632
|
"loomis-express": {
|
|
@@ -7168,7 +7182,7 @@ var be = {
|
|
|
7168
7182
|
"kuehne-nagel": ["kuehne-nagel-1", "kuehne-nagel-2"],
|
|
7169
7183
|
"latvijas-pasts": ["latvijas-pasts-s10"],
|
|
7170
7184
|
"lbc-express": ["lbc-domestic"],
|
|
7171
|
-
"lietuvos-pastas": ["lietuvos-pastas-1"],
|
|
7185
|
+
"lietuvos-pastas": ["lietuvos-pastas-1", "lietuvos-pastas-s10"],
|
|
7172
7186
|
"loomis-express": ["loomis-express-1", "loomis-express-2"],
|
|
7173
7187
|
lso: ["lso-1"],
|
|
7174
7188
|
"magyar-posta": [],
|
|
@@ -11913,6 +11927,7 @@ var bc = {
|
|
|
11913
11927
|
"acs-courier": 570,
|
|
11914
11928
|
aliexpress: 140,
|
|
11915
11929
|
"allegro-one": 770,
|
|
11930
|
+
"apc-overnight": 870,
|
|
11916
11931
|
"aras-kargo": 670,
|
|
11917
11932
|
"australia-post": 60,
|
|
11918
11933
|
"austrian-post": 390,
|
|
@@ -11962,6 +11977,7 @@ var bc = {
|
|
|
11962
11977
|
"j-and-t-cargo": 470,
|
|
11963
11978
|
"la-poste": 800,
|
|
11964
11979
|
"latvijas-pasts": 820,
|
|
11980
|
+
"lietuvos-pastas": 860,
|
|
11965
11981
|
matkahuolto: 690,
|
|
11966
11982
|
"mng-kargo": 740,
|
|
11967
11983
|
nacex: 410,
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type AdapterFactory, type 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 declare const APC_OVERNIGHT_ENDPOINT = "https://apcchoice.apc-overnight.com/track-parcel";
|
|
5
|
+
export declare class ApcOvernightTracker {
|
|
6
|
+
private readonly options;
|
|
7
|
+
constructor(options?: {
|
|
8
|
+
fetcher?: typeof fetch;
|
|
9
|
+
recorder?: StepRecorder;
|
|
10
|
+
userAgent?: string;
|
|
11
|
+
});
|
|
12
|
+
fetch(raw: string, context?: TrackingContext): Promise<CarrierResult>;
|
|
13
|
+
}
|
|
14
|
+
export declare const adapter: AdapterFactory;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { accepted, recognizeFromLookup } from '../../core/adapter/index.js';
|
|
2
|
+
import { IndeterminateError, TransportError } from '../../core/errors/index.js';
|
|
3
|
+
import { runSteps } from '../../core/runner/index.js';
|
|
4
|
+
import { firstAttemptMs, networkRetryStep } from '../../core/runner/networkRetry.js';
|
|
5
|
+
import { NOOP_RECORDER } from '../../core/telemetry/index.js';
|
|
6
|
+
import { decodeText, fetchBounded, userAgentOf } from '../../core/transport/index.js';
|
|
7
|
+
import { APC_OVERNIGHT_MAX_BYTES, normalizeApcOvernightNumber, parseApcOvernight, PROVIDER } from './parser.js';
|
|
8
|
+
// APC Choice's public tracking page, which merchants link to with the waybill as `id`.
|
|
9
|
+
export const APC_OVERNIGHT_ENDPOINT = 'https://apcchoice.apc-overnight.com/track-parcel';
|
|
10
|
+
const REDIRECTS = [301, 302, 303, 307, 308];
|
|
11
|
+
// A missing route is not a missing consignment: the tracker answers unknown waybills with a notice.
|
|
12
|
+
const GONE = [404, 410];
|
|
13
|
+
export class ApcOvernightTracker {
|
|
14
|
+
options;
|
|
15
|
+
constructor(options = {}) {
|
|
16
|
+
this.options = options;
|
|
17
|
+
}
|
|
18
|
+
async fetch(raw, context = {}) {
|
|
19
|
+
const number = normalizeApcOvernightNumber(raw);
|
|
20
|
+
const url = `${APC_OVERNIGHT_ENDPOINT}?${new URLSearchParams({ id: number })}`;
|
|
21
|
+
const read = async (signal, timeoutMs) => {
|
|
22
|
+
const { response, bytes } = await fetchBounded(url, { method: 'GET', signal, headers: {
|
|
23
|
+
Accept: 'text/html,application/xhtml+xml',
|
|
24
|
+
'User-Agent': userAgentOf(this.options.userAgent),
|
|
25
|
+
} }, { provider: PROVIDER, timeoutMs: Math.max(1, Math.floor(timeoutMs)), maxBytes: APC_OVERNIGHT_MAX_BYTES,
|
|
26
|
+
redirect: 'manual', allowHttpStatuses: [...REDIRECTS, ...GONE], fetcher: this.options.fetcher });
|
|
27
|
+
// The site sends its errors to the search page with a message in the address.
|
|
28
|
+
if (REDIRECTS.includes(response.status))
|
|
29
|
+
throw new IndeterminateError(PROVIDER, 'APC Overnight sent the lookup to another page');
|
|
30
|
+
if (GONE.includes(response.status))
|
|
31
|
+
throw new TransportError(PROVIDER, 'APC Overnight tracking page is unavailable');
|
|
32
|
+
const html = decodeText(bytes);
|
|
33
|
+
if (!html.trim())
|
|
34
|
+
throw new IndeterminateError(PROVIDER, 'APC Overnight returned an empty page');
|
|
35
|
+
return parseApcOvernight(html, number);
|
|
36
|
+
};
|
|
37
|
+
// A request that fails to reach APC, or hangs, gets one more try: the
|
|
38
|
+
// first gets half of the budget, so the retry fits in the rest.
|
|
39
|
+
return runSteps({ carrier: 'apc-overnight', budgetMs: context.budgetMs ?? 15_000, signal: context.signal,
|
|
40
|
+
recorder: this.options.recorder ?? NOOP_RECORDER }, [
|
|
41
|
+
{ id: 'direct', run: ({ signal, remainingMs }) => read(signal, firstAttemptMs(remainingMs)) },
|
|
42
|
+
networkRetryStep(({ signal, remainingMs }) => read(signal, remainingMs)),
|
|
43
|
+
]);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
export const adapter = (environment) => {
|
|
47
|
+
const tracker = new ApcOvernightTracker({ fetcher: environment.fetcher, recorder: environment.recorder, userAgent: environment.userAgent });
|
|
48
|
+
return {
|
|
49
|
+
id: 'apc-overnight', recordsSteps: true, steps: ['direct', 'retry'],
|
|
50
|
+
track: (input, context) => tracker.fetch(input.number, context),
|
|
51
|
+
recognize: (number, context) => recognizeFromLookup(() => tracker.fetch(number, context), () => accepted(() => normalizeApcOvernightNumber(number))),
|
|
52
|
+
};
|
|
53
|
+
};
|
|
@@ -17,19 +17,66 @@
|
|
|
17
17
|
"timezone": "Europe/London",
|
|
18
18
|
"tracking": {
|
|
19
19
|
"mode": "automatic",
|
|
20
|
-
"adapter": "
|
|
21
|
-
"steps": [
|
|
20
|
+
"adapter": "apc-overnight",
|
|
21
|
+
"steps": [
|
|
22
|
+
"direct",
|
|
23
|
+
"retry"
|
|
24
|
+
],
|
|
25
|
+
"recognition": {
|
|
26
|
+
"rank": 870
|
|
27
|
+
},
|
|
28
|
+
"localClocks": true
|
|
22
29
|
},
|
|
23
|
-
"capabilities": [
|
|
30
|
+
"capabilities": [
|
|
31
|
+
"history",
|
|
32
|
+
"weight",
|
|
33
|
+
"service_name"
|
|
34
|
+
],
|
|
24
35
|
"portal": {
|
|
36
|
+
"url": "https://apcchoice.apc-overnight.com/track-parcel?id={trackingNumber}",
|
|
25
37
|
"searchUrl": "https://apc.co.uk/",
|
|
26
38
|
"canaryUrl": "https://apc.co.uk/",
|
|
27
|
-
"shows": [
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
39
|
+
"shows": [
|
|
40
|
+
"status",
|
|
41
|
+
"history",
|
|
42
|
+
"weight",
|
|
43
|
+
"service_name",
|
|
44
|
+
"parcel_count",
|
|
45
|
+
"customer_reference",
|
|
46
|
+
"office_contact_details",
|
|
47
|
+
"proof_of_delivery"
|
|
48
|
+
],
|
|
49
|
+
"scraped": [
|
|
50
|
+
"status",
|
|
51
|
+
"history",
|
|
52
|
+
"weight",
|
|
53
|
+
"service_name"
|
|
54
|
+
],
|
|
55
|
+
"discarded": [
|
|
56
|
+
"parcel_count",
|
|
57
|
+
"customer_reference",
|
|
58
|
+
"office_contact_details",
|
|
59
|
+
"proof_of_delivery"
|
|
60
|
+
],
|
|
61
|
+
"unavailable": [
|
|
62
|
+
"location",
|
|
63
|
+
"eta",
|
|
64
|
+
"sender_name",
|
|
65
|
+
"recipient_name",
|
|
66
|
+
"offset_timestamps"
|
|
67
|
+
]
|
|
31
68
|
},
|
|
32
|
-
"links": [
|
|
69
|
+
"links": [
|
|
70
|
+
{
|
|
71
|
+
"domains": [
|
|
72
|
+
"apcchoice.apc-overnight.com"
|
|
73
|
+
],
|
|
74
|
+
"pathPattern": "^/track-parcel/?$",
|
|
75
|
+
"params": [
|
|
76
|
+
"id"
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
],
|
|
33
80
|
"detection": [
|
|
34
81
|
{
|
|
35
82
|
"id": "apc-overnight-1",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"access": "full_page"
|
|
11
11
|
},
|
|
12
12
|
"context": {
|
|
13
|
-
"assessment": "
|
|
13
|
+
"assessment": "confirmed"
|
|
14
14
|
},
|
|
15
15
|
"expect": {
|
|
16
16
|
"carrier": "unknown",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"estafeta"
|
|
23
23
|
]
|
|
24
24
|
},
|
|
25
|
-
"note": "A seller on Amazon's seller forum gives it as an APC Overnight consignment number."
|
|
25
|
+
"note": "A seller on Amazon's seller forum gives it as an APC Overnight consignment number. APC's tracker returns its history."
|
|
26
26
|
},
|
|
27
27
|
{
|
|
28
28
|
"number": "2026100902014380018924",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"access": "full_page"
|
|
36
36
|
},
|
|
37
37
|
"context": {
|
|
38
|
-
"assessment": "
|
|
38
|
+
"assessment": "confirmed"
|
|
39
39
|
},
|
|
40
40
|
"expect": {
|
|
41
41
|
"carrier": "unknown",
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"estafeta"
|
|
48
48
|
]
|
|
49
49
|
},
|
|
50
|
-
"note": "ParcelPanel's APC Overnight page offered it as a sample to try on 11 Oct 2026
|
|
50
|
+
"note": "ParcelPanel's APC Overnight page offered it as a sample to try on 11 Oct 2026. APC's tracker returns its history."
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
53
|
"number": "2026090302014380017949",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"access": "full_page"
|
|
61
61
|
},
|
|
62
62
|
"context": {
|
|
63
|
-
"assessment": "
|
|
63
|
+
"assessment": "confirmed"
|
|
64
64
|
},
|
|
65
65
|
"expect": {
|
|
66
66
|
"carrier": "unknown",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"estafeta"
|
|
73
73
|
]
|
|
74
74
|
},
|
|
75
|
-
"note": "ParcelPanel's APC Overnight page offered it as a sample to try on 11 Oct 2026
|
|
75
|
+
"note": "ParcelPanel's APC Overnight page offered it as a sample to try on 11 Oct 2026. APC's tracker returns its history."
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
78
|
"number": "2018041910099660000599",
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"estafeta"
|
|
96
96
|
]
|
|
97
97
|
},
|
|
98
|
-
"note": "The Glama listing of an open-source MCP server for APC Overnight's booking API uses it as the waybill in an example prompt; it is not described as a live shipment."
|
|
98
|
+
"note": "The Glama listing of an open-source MCP server for APC Overnight's booking API uses it as the waybill in an example prompt; it is not described as a live shipment. APC's tracker no longer finds it."
|
|
99
99
|
}
|
|
100
100
|
]
|
|
101
101
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { CarrierResult } from '../../core/result/index.js';
|
|
2
|
+
export declare const PROVIDER = "APC Overnight";
|
|
3
|
+
export declare const APC_OVERNIGHT_MAX_BYTES: number;
|
|
4
|
+
/**
|
|
5
|
+
* An APC waybill: twenty-two digits that start with the consignment's booking
|
|
6
|
+
* date, as 20YYMMDD, and end with its seven-digit consignment number. The
|
|
7
|
+
* tracker looks a consignment up only by the whole waybill.
|
|
8
|
+
*/
|
|
9
|
+
export declare function normalizeApcOvernightNumber(raw: string): string;
|
|
10
|
+
/**
|
|
11
|
+
* The tracking page for one waybill: a consignment summary, then each item's
|
|
12
|
+
* journey through the network and its delivery summary, each row a wording
|
|
13
|
+
* with its day and minute. The page names the consignment by its seven-digit
|
|
14
|
+
* number, the end of the waybill it was asked for. A waybill the tracker does
|
|
15
|
+
* not have, or of another shape, comes back on the search page with a notice.
|
|
16
|
+
*/
|
|
17
|
+
export declare function parseApcOvernight(html: string, rawNumber: string): CarrierResult;
|