Developers · Core concepts

Requests and responses

Base URL, JSON conventions, identifiers, dates, request IDs and the headers every request and response carries.

Version
v1.0.0
Base URL
https://dppapi-production.up.railway.app/v1
Format
JSON · OpenAPI 3.1
FeedbackLast updated

Este artículo aún no está disponible en español; se muestra a continuación en inglés.

On this pageBase URL and transport

Base URL and transport

All endpoints are under https://dppapi-production.up.railway.app/v1, over HTTPS only. The public resolver lives at https://dppapi-production.up.railway.app/p/…, outside /v1, because it is the address printed in QR codes. Cross-origin requests are allowed on /v1 from any origin — keys travel in a header, never a cookie — but keys are secrets: call the API from your servers.

JSON in, JSON out

  • Request bodies are JSON with Content-Type: application/json, except document uploads (multipart/form-data).
  • Send Content-Type: application/json only when there is a body. A write without a body (publish, test webhook) that declares JSON is rejected with 400.
  • Responses are JSON (application/json; charset=utf-8), except QR images, documents, the export archive and JSON-LD (application/ld+json).
  • Property names are camelCase on resources; list envelopes, error fields and query parameters use snake_case (has_more, request_id, updated_since).

Identifiers

KindExampleNotes
Record idcm1q8y0bq0006l70fx9y8z7w6Opaque string. Store it as text; do not parse it.
Battery unique identifierC-7KQ2M9XHT4RC- + 11 characters, no ambiguous letters. Immutable, printed on the label, resolvable at /p/{uniqueIdentifier}.
Serial numberC48-2027-0001Yours. Searchable, not unique across models.
Request id3f1c2a9e-8d4b-4c6f-9e2a-7b5d1c0e8f34Per request; see below.

Dates and times

Timestamps are ISO 8601 in UTC (2027-01-15T10:02:11.000Z). Date inputs accept a date (2027-01-15) or a full timestamp. Filters such as updated_since accept a date or a date-time with an offset.

Request IDs

Every response carries an X-Request-Id header, and every /v1 error body repeats it as request_id. Log it with every failure: quoting it is the fastest way for us to find exactly what happened. You may also send your own X-Request-Id (for example your trace id) and it is used for the request.

404 · a mistyped path
{"error": "route_not_found","message": "GET /v1/pasports is not part of the API. See /v1/openapi.json.","request_id": "3f1c2a9e-8d4b-4c6f-9e2a-7b5d1c0e8f34"}

Headers at a glance

HeaderDirectionPurpose
Authorization: Bearer dpp_…RequestYour API key. Required on /v1 except /openapi.json.
Content-Type: application/jsonRequestOnly with a JSON body.
Idempotency-KeyRequestMakes a POST or PATCH safe to retry. Details.
X-DPP-Dry-Run: trueRequestLive key: validate without storing. Details.
X-Request-IdBothCorrelates a request with our logs.
X-DPP-ModeResponselive or test.
X-DPP-Dry-Run: trueResponseThis answer is a dry run; nothing was stored.
X-DPP-Api-VersionResponseThe API version that answered, e.g. 1.0.0.
Idempotent-Replayed: trueResponseThis is a stored response being replayed.
x-ratelimit-limit / -remaining / -resetResponseYour rate-limit budget. Details.
retry-afterResponseOn 429: seconds to wait.

Success codes

StatusMeaning
200 OKRead, update, or a dry run that would have succeeded.
201 CreatedA record was created (model, battery, document, event, linked passport).
207 Multi-StatusA bulk request where at least one row failed; read results.

Every failure is described in Errors.

Preferencias de cookies

Tú decides qué cookies se usan. Puedes cambiar tu elección en cualquier momento desde «Configuración de cookies» en el pie de página. Política de privacidad

Necesarias

Siempre activas

Imprescindibles para que el sitio funcione: tu tema claro/oscuro y esta elección de cookies se guardan en tu navegador. No sirven para rastrearte.

Analítica

Google Analytics 4 mide cómo se usan las páginas mediante estadísticas, lo que nos ayuda a mejorar el sitio. Si aceptas, instala cookies y mide tu visita por completo. Si rechazas, no instala cookies, pero Google aún puede recibir datos técnicos como la página vista, el tipo de navegador y la dirección IP.

_ga, _ga_* · hasta 2 años · Google