# Grupo ampm Tracking API & MCP

URL: https://docs.lastscanned.com/carriers/ampm

Query live **Grupo ampm** (`ampm`) package status and scan history in a single synchronous `GET` request or MCP tool call.

## Overview & Quick Facts

| Property | Value |
|---|---|
| **Carrier slug (`?carrier=`)** | `ampm` |
| **Brand aliases** | Grupo ampm, ampm, AMPM Mexico, grupoampm.com |
| **Category** | Mexican parcel delivery and Cainiao last mile |
| **Single-package REST endpoint** | `GET https://api.lastscanned.com/v1/track/{trackingNumber}` |
| **Batch REST endpoint** | `GET https://api.lastscanned.com/v1/track?numbers=CNA000001234567,CNA000001234567` |
| **MCP server (`https://mcp.lastscanned.com`)** | `track_package`, `track_packages`, `list_carriers` |
| **Authentication & pricing** | `Authorization: Bearer lsk_live_...` · 1 free keyless lookup/day per IP |

## Tracking Number Formats & Auto-Detection

| Pass | Rule / Regex | Check Digit | Examples |
|---|---|---|---|
| **Pass 1 (`matches`)** | none | none | none |
| **Pass 2 (`mayMatch`)** | `/^(CNA\d{12}|IDTS\d{14})$/` | none | `CNA000001234567` |

ampm numbers are 10-30 letters and digits in no fixed pattern. The `CNA…` and `IDTS…` forms are only a loose fallback; otherwise pass `?carrier=ampm`.

## Synchronous `GET` Request & Normalized JSON Response

```bash
curl -s "https://api.lastscanned.com/v1/track/CNA000002663047?carrier=ampm" \
  -H "Authorization: Bearer $LASTSCANNED_API_KEY"
```

```json
{
  "carrier": "ampm",
  "trackingNumber": "CNA000002663047",
  "status": "delivered",
  "statusDescription": "ENTREGADO",
  "service": null,
  "deliveredAt": null,
  "deliveredAtLocal": "2026-04-09T13:22:10",
  "signedBy": null,
  "destination": {
    "city": "Guadalajara",
    "state": "Jalisco",
    "country": "MX"
  },
  "estimatedDelivery": "2026-04-10T23:59:00",
  "events": [
    {
      "timestamp": null,
      "localTime": "2026-04-09T13:22:10",
      "status": "delivered",
      "description": "ENTREGADO",
      "location": "HUB MEXICO",
      "code": "EN"
    },
    {
      "timestamp": null,
      "localTime": "2026-04-09T08:40:31",
      "status": "out_for_delivery",
      "description": "CON MENSAJERO DE ENTREGA",
      "location": "HUB MEXICO",
      "code": "CM"
    },
    {
      "timestamp": null,
      "localTime": "2026-04-08T17:05:12",
      "status": "in_transit",
      "description": "PROCESADO EN INSTALACIONES",
      "location": "HUB MEXICO",
      "code": "PI"
    },
    {
      "timestamp": null,
      "localTime": "2026-04-07T16:42:43",
      "status": "in_transit",
      "description": "ENTRADA A CENTRO OPERATIVO",
      "location": "HUB MEXICO",
      "code": "AE"
    }
  ]
}
```

## Notes

- **Route**: the `grupoampm.com/rastreador/` page is server-rendered; its MOVIMIENTOS table (date, code, movement, office) is read. No account.
- **Time zone**: the page gives no zone, so only `localTime` is set.
- **Status**: the carrier's codes are not obvious (`EN` reads `DEVUELTO`, returned), so the Spanish wording drives the status: `ENTREGADO` delivered, `CON MENSAJERO` out for delivery, `DEVUELTO`/`DEVOLUCION`/`RETORNO` returned, `DESTRUIDO` exception.
- **ETA**: `estimatedDelivery` is the page's "Fecha Compromiso de Entrega" while the parcel is undelivered.

## Related Resources

- **Regex & check digits**: [Tracking number formats & auto-detection](/formats)