---
title: Archive a passport (irreversible)
description: Irreversibly archive a passport. Public viewer 404s, GS1 Digital Link stops resolving. Fires passport.archived webhook. Only for unshipped products.
canonical: "https://www.tracepass.eu/docs/archive-passport"
locale: en
source: "https://www.tracepass.eu/docs/archive-passport"
---

# Archive a passport (irreversible)

> Irreversibly archive a passport. Public viewer 404s, GS1 Digital Link stops resolving. Fires passport.archived webhook. Only for unshipped products.

```http
POST /api/v1/passports/{id}/archive
```

**Irreversible.** Public viewer returns 404, the GS1 Digital Link URL stops resolving, the QR code dies for good. Use ONLY for products that never shipped — archiving a passport for a product already in customers' hands breaks every QR scan they'll ever make of it.

There's no DELETE verb on purpose: too easy to misfire as a destructive action via curl typo or a misconfigured client. The HTTP method is POST and the path includes the literal `archive` segment — both intentional friction. Counts as one v1 write. Honours `Idempotency-Key`. Fires the `passport.archived` webhook.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Authorization` | header | string | yes | `Bearer <token>` — either a `tp_` API key (Developer → API Keys; simplest, for server-to-server) or an OAuth 2.0 access token (Developer → OAuth Apps; for user-authorized apps, scoped + revocable). The Authentication page has the full OAuth flow and scope list. |
| `Idempotency-Key` | header | string | no | UUID v4. |
| `id` | path | ObjectId | yes | Passport ID. |

## Examples

```bash
curl -sS -X POST \
  https://app.tracepass.eu/api/v1/passports/6650b2c3d4e5f6a7b8c9d0e1/archive \
  -H "Authorization: Bearer tp_REDACTED_xxxxxxxxxxxx"
```

```typescript
await fetch(
  `https://app.tracepass.eu/api/v1/passports/${id}/archive`,
  {
    method: "POST",
    headers: { Authorization: `Bearer ${process.env.TRACEPASS_API_KEY}` },
  },
);
```

```python
import os, requests
res = requests.post(
    f"https://app.tracepass.eu/api/v1/passports/{passport_id}/archive",
    headers={"Authorization": f"Bearer {os.environ['TRACEPASS_API_KEY']}"},
)
res.raise_for_status()
```

## Responses

### 200 — Archived

```json
{
  "_id": "6650b2c3d4e5f6a7b8c9d0e1",
  "status": "archived",
  "archivedAt": "2026-05-09T17:00:00.000Z"
}
```

### 422 — Already archived

```json
{ "error": "Passport already archived" }
```

### 404 — Not found

```json
{ "error": "Passport not found" }
```

## Related

- [Suspend a passport (reversible)](https://www.tracepass.eu/docs/suspend-passport.md)
- [Get passport](https://www.tracepass.eu/docs/get-passport.md)
