universal-parcel-scraper 0.3.1-main.313 → 0.3.2-main.314

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/data/catalog.json CHANGED
@@ -998,6 +998,10 @@
998
998
  "pattern": "^[68][A-Z]\\d{11}$",
999
999
  "confidence": "high"
1000
1000
  },
1001
+ {
1002
+ "pattern": "^870\\d{11,12}$",
1003
+ "confidence": "high"
1004
+ },
1001
1005
  {
1002
1006
  "pattern": "^[A-Z0-9]{2}\\d{11}$",
1003
1007
  "confidence": "low"
@@ -2677,40 +2677,26 @@
2677
2677
  },
2678
2678
  {
2679
2679
  "input": "87000918244878",
2680
- "carrier": "unknown",
2681
- "confidence": "low",
2680
+ "carrier": "la-poste",
2681
+ "confidence": "high",
2682
2682
  "candidates": [
2683
- "dpd",
2684
- "ciblex",
2685
- "hermes-de",
2686
- "seur",
2687
- "brt",
2688
- "delhivery"
2689
- ],
2690
- "asked": [
2691
- "dpd",
2692
- "seur",
2693
- "brt",
2694
- "hermes-de",
2695
- "ciblex"
2683
+ "la-poste"
2696
2684
  ]
2697
2685
  },
2698
2686
  {
2699
2687
  "input": "87000918635108",
2700
- "carrier": "unknown",
2701
- "confidence": "low",
2688
+ "carrier": "la-poste",
2689
+ "confidence": "high",
2702
2690
  "candidates": [
2703
- "dpd",
2704
- "ciblex",
2705
- "seur",
2706
- "brt",
2707
- "delhivery"
2708
- ],
2709
- "asked": [
2710
- "dpd",
2711
- "seur",
2712
- "brt",
2713
- "ciblex"
2691
+ "la-poste"
2692
+ ]
2693
+ },
2694
+ {
2695
+ "input": "870012345678901",
2696
+ "carrier": "la-poste",
2697
+ "confidence": "high",
2698
+ "candidates": [
2699
+ "la-poste"
2714
2700
  ]
2715
2701
  },
2716
2702
  {
@@ -832,6 +832,10 @@ var ue = {
832
832
  pattern: "^[68][A-Z]\\d{11}$",
833
833
  confidence: "high"
834
834
  },
835
+ {
836
+ pattern: "^870\\d{11,12}$",
837
+ confidence: "high"
838
+ },
835
839
  {
836
840
  pattern: "^[A-Z0-9]{2}\\d{11}$",
837
841
  confidence: "low"
@@ -70,9 +70,10 @@ export function normalizeLaPosteTrackingNumber(raw) {
70
70
  const value = raw.toLocaleUpperCase('en-US').replace(/[\s.-]/g, '');
71
71
  const domestic = /^[A-Z0-9]{2}\d{11}$/.test(value);
72
72
  const international = /^[A-Z]{2}\d{9}[A-Z]{2}$/.test(value);
73
+ const numericMail = /^\d{14,15}$/.test(value);
73
74
  const foreignExpress = /^\d{14}[A-Z]$/.test(value);
74
- if (!domestic && !international && !foreignExpress) {
75
- throw new InvalidInputError('La Poste', 'La Poste tracking numbers must use a supported 13- or 15-character format');
75
+ if (!domestic && !international && !numericMail && !foreignExpress) {
76
+ throw new InvalidInputError('La Poste', 'La Poste tracking numbers must use a supported 13-, 14- or 15-character format');
76
77
  }
77
78
  return value;
78
79
  }
@@ -72,6 +72,11 @@
72
72
  "pattern": "^[68][A-Z]\\d{11}$",
73
73
  "confidence": "high"
74
74
  },
75
+ {
76
+ "id": "la-poste-4",
77
+ "pattern": "^870\\d{11,12}$",
78
+ "confidence": "high"
79
+ },
75
80
  {
76
81
  "id": "la-poste-2",
77
82
  "pattern": "^[A-Z0-9]{2}\\d{11}$",
@@ -35,18 +35,10 @@
35
35
  "url": "https://marketplace.fnacdarty.com/s/article/Dois-je-obligatoirement-renseigner-un-num%C3%A9ro-de-suivi-tracking-pour-ma-commande?language=fr_BE"
36
36
  },
37
37
  "expect": {
38
- "carrier": "unknown",
39
- "confidence": "low",
40
- "candidates": [
41
- "dpd",
42
- "ciblex",
43
- "hermes-de",
44
- "seur",
45
- "brt",
46
- "delhivery"
47
- ]
38
+ "carrier": "la-poste",
39
+ "confidence": "high"
48
40
  },
49
- "note": "Published integration example, not a real shipment. The source attributes it to La Poste / Colissimo, which no rule claims."
41
+ "note": "Published integration example, not a real shipment."
50
42
  },
51
43
  {
52
44
  "number": "87000918635108",
@@ -56,17 +48,10 @@
56
48
  "url": "https://marketplace.fnacdarty.com/s/article/Dois-je-obligatoirement-renseigner-un-num%C3%A9ro-de-suivi-tracking-pour-ma-commande?language=fr_BE"
57
49
  },
58
50
  "expect": {
59
- "carrier": "unknown",
60
- "confidence": "low",
61
- "candidates": [
62
- "dpd",
63
- "ciblex",
64
- "seur",
65
- "brt",
66
- "delhivery"
67
- ]
51
+ "carrier": "la-poste",
52
+ "confidence": "high"
68
53
  },
69
- "note": "Published integration example, not a real shipment. The source attributes it to La Poste / Colissimo, which no rule claims."
54
+ "note": "Published integration example, not a real shipment."
70
55
  },
71
56
  {
72
57
  "number": "88000019255788Y",
@@ -135,6 +120,18 @@
135
120
  "confidence": "high"
136
121
  },
137
122
  "note": "Made-up number that follows the published format."
123
+ },
124
+ {
125
+ "number": "870012345678901",
126
+ "role": "shipment",
127
+ "evidence": "synthetic",
128
+ "derivedFrom": "official_shape",
129
+ "shapeConfirmed": "2026-10-04",
130
+ "expect": {
131
+ "carrier": "la-poste",
132
+ "confidence": "high"
133
+ },
134
+ "note": "Made-up numeric tracked-mail identifier; La Poste documents fifteen-character tracked mail."
138
135
  }
139
136
  ]
140
137
  }
@@ -998,6 +998,10 @@
998
998
  "pattern": "^[68][A-Z]\\d{11}$",
999
999
  "confidence": "high"
1000
1000
  },
1001
+ {
1002
+ "pattern": "^870\\d{11,12}$",
1003
+ "confidence": "high"
1004
+ },
1001
1005
  {
1002
1006
  "pattern": "^[A-Z0-9]{2}\\d{11}$",
1003
1007
  "confidence": "low"
@@ -611,6 +611,9 @@ export declare const CARRIER_CATALOG: {
611
611
  readonly detectionRules: readonly [{
612
612
  readonly pattern: "^[68][A-Z]\\d{11}$";
613
613
  readonly confidence: "high";
614
+ }, {
615
+ readonly pattern: "^870\\d{11,12}$";
616
+ readonly confidence: "high";
614
617
  }, {
615
618
  readonly pattern: "^[A-Z0-9]{2}\\d{11}$";
616
619
  readonly confidence: "low";
@@ -999,6 +999,10 @@ export const CARRIER_CATALOG = {
999
999
  "pattern": "^[68][A-Z]\\d{11}$",
1000
1000
  "confidence": "high"
1001
1001
  },
1002
+ {
1003
+ "pattern": "^870\\d{11,12}$",
1004
+ "confidence": "high"
1005
+ },
1002
1006
  {
1003
1007
  "pattern": "^[A-Z0-9]{2}\\d{11}$",
1004
1008
  "confidence": "low"
@@ -2,7 +2,7 @@
2
2
  "openapi": "3.1.0",
3
3
  "info": {
4
4
  "title": "Universal Parcel Scraper",
5
- "version": "0.3.1"
5
+ "version": "0.3.2"
6
6
  },
7
7
  "paths": {
8
8
  "/health": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "universal-parcel-scraper",
3
- "version": "0.3.1-main.313",
3
+ "version": "0.3.2-main.314",
4
4
  "description": "Self-hosted parcel tracking: carrier detection, dedicated scrapers and optional universal providers.",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",