Skip to main content
POST
Create product instance

Authorizations

X-API-Key
string
header
required

Per-manufacturer API key in the X-API-Key header, format emidat-{key_id}-{secret} where key_id is a random public handle. Issued by an owner in the Emidat dashboard; carries its own permission scopes, optional plant restrictions, and optional expiry. A revoked, expired, or unknown key returns 401. See the Authentication guide for details.

Headers

Idempotency-Key
string

Optional client-generated key of 1–255 characters (e.g. a UUID) that makes a create idempotent — the only mechanism that does so. A replay carrying the same key returns the original response unchanged (200); reusing a key with a different request body (compared byte for byte) or create endpoint is rejected with 409 err_idempotency_key_reused. Concurrent requests with the same key receive 409 err_idempotency_in_progress. Keys are scoped to your manufacturer; successful responses are retained for 6h without extending that window on replay. Current permissions are required on every retry; product-instance replays also require the original production-data scopes. Deduplication is best effort: Redis data loss can end the window early, and Redis unavailability, timeouts, or unreadable cache entries can allow creation without replay protection. Successful creates still return 201 if caching fails. Redis waits share a two-second budget excluding creation time. Incompatible replay-format upgrades reset replay protection, so retries across that boundary can create again. An interrupted create can reserve the key for up to 6h. See External IDs for recovery guidance.

Required string length: 1 - 255

Body

application/json
external_id
string | null
required

Your own code for this product instance. Required; pass null if unset. A non-null code must be unique among your active product instances; a duplicate returns 409 (see External IDs).

Example:

"CEM-42.5R-25KG-MUNICH"

plant_id
string<uuid>
required

The plant's Emidat UUID.

name
string
required
Example:

"CEM 42.5 R, 25 kg bag (Munich)"

elementary_id
string<uuid>
required

Emidat material-type UUID — determines the product type.

unit
enum<string>
required
Available options:
M,
M2,
M3,
UG,
KG,
T,
L,
KWH,
MJ,
UNIT,
METRIC TON*KM
Example:

"KG"

produced_from
integer
required

First year this instance is valid.

Required range: 2020 <= x <= 2100
Example:

2025

production_process_id
string<uuid> | null

The production process's Emidat UUID. Optional.

produced_to
integer | null

Last valid year, or null if open-ended.

Required range: 2020 <= x <= 2100
tech_specs
object | null

Technical specifications as key/value pairs. Which keys apply depends on the instance's elementary_id — cement, for example, takes compressive_strength and density.

Example:
annual_data
object[] | null

Production output and economic value per year. Include both values for each year, using null when one is unknown. Each year must fall inside the instance's production period.

Response

Returned unchanged — an Idempotency-Key replay.

id
string<uuid>
required
external_id
string | null
required

Your own code for this instance, as provided on creation.

plant_id
string<uuid>
required

The plant's Emidat UUID. Always present — set at creation and immutable.

name
string
required
elementary_id
string<uuid>
required

Emidat material-type UUID — determines the product type.

production_process_id
string<uuid> | null
required

The production process's Emidat UUID, or null if none.

unit
enum<string>
required
Available options:
M,
M2,
M3,
UG,
KG,
T,
L,
KWH,
MJ,
UNIT,
METRIC TON*KM
Example:

"KG"

produced_from
integer
required

First year this instance is valid.

Example:

2025

produced_to
integer | null
required

Last valid year, or null if open-ended.

tech_specs
object | null
required

Technical specifications as key/value pairs. Which keys apply depends on the instance's elementary_id — cement, for example, takes compressive_strength and density.

Example:
annual_data
object[]
required

Production output and economic value per year.

status
enum<string>
required

Whether the instance is modelled far enough to run an LCA. Derived on every read, never set directly.

incomplete — something structural is still missing: tech_specs is empty, production_process_id is null, or the material type needs a BOM (PUT …/bom) and none is set. draft — all of that is present. A by-product of its production process needs no recipe.

draft is about structure only. It does not mean any year is computable: per-year gaps such as missing production data surface as blocked_by entries on the LCA results, not here.

Available options:
incomplete,
draft
Example:

"draft"

created_at
string<date-time>
required