Developers · API endpoints

Facilities

List and register the manufacturing plants your passports name as their place of manufacture.

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

Manufacturing plants. A battery’s placeOfManufacture (data point 8) is required before its passport can be published; keeping the plants here gives every integration the same spelling, and each plant shows how many batteries name it.

Personalise the samples. Paste a test key and every snippet uses it — and your own model and passport ids.

GET/v1/plants
read scope

List facilities

Your plants, alphabetically, each with usedBy: the number of batteries whose placeOfManufacture is the plant’s name.

Responses

  • 200OK — The facilities.

Errors1

GET /v1/plants
curl "https://dppapi-production.up.railway.app/v1/plants" \-H "Authorization: Bearer $DPP_API_KEY"
200 OK · The facilities.
[{"id": "cm1qh7k8l0080l70fs9d0f1g2","name": "Stuttgart, Germany","location": "Musterstraße 1, 70173 Stuttgart, DE","esprFacilityId": "FAC-STR-01","createdAt": "2027-01-05T08:00:00.000Z","usedBy": 100}]
POST/v1/plants
write scope

Add a facility

Registers a plant. Use its name as placeOfManufacture when you create batteries.

Request body3

  • namestring, 1–200required

    How passports name the plant.

  • locationstring, 1–300required

    Address or city and country.

  • esprFacilityIdstring, ≤ 120optional

    Your ESPR facility identifier, if you have one.

Headers2

  • Idempotency-Keystringheaderoptional

    Optional. A unique string per logical operation (a UUID is ideal). The first response is stored for 24 hours and replayed for retries; see Idempotency.

  • X-DPP-Dry-Run"true"headeroptional

    Optional, live keys. Validate the write in full and store nothing. Test keys always dry-run; see Test keys.

Responses

  • 201Created — The facility.

Errors3

POST /v1/plants
curl -X POST "https://dppapi-production.up.railway.app/v1/plants" \-H "Authorization: Bearer $DPP_API_KEY" \-H "Content-Type: application/json" \-d '{"name": "Stuttgart, Germany","location": "Musterstraße 1, 70173 Stuttgart, DE","esprFacilityId": "FAC-STR-01"}'
201The facility.

Cookie preferences

You choose which cookies are used. You can change your choice at any time with “Cookie settings” in the footer. Privacy policy

Necessary

Always on

Needed for the site to work: your light/dark theme and this cookie choice are stored in your browser. They do not track you.

Analytics

Google Analytics 4 measures how pages are used through statistics, which helps us improve the site. If you accept, it sets cookies and measures your visit in full. If you decline, it sets no cookies, but Google may still receive technical data such as the page viewed, your browser type and IP address.

_ga, _ga_* · up to 2 years · Google