Optional endpoint. Calling this endpoint is optional. If you use it, create a manufactured material and optionally define processing steps; you must include either the owner (ownerKind, ownerId) or the processing step address, but not both.
rawMaterialName and rawMaterialAttribute are optional. When you send them, provide both as a single taxonomy pair at the root of the object (not a list). Use the Fairly Made Material Selector to pick the allowed attribute for that name (Step 1 = material, Step 2 = attributes).
Traceability collection: to link purchased inputs for Fairly Made supplier data collection, reference them via purchasedItems (each purchased item must include a purchaseOrder on POST /purchased-items). Links made only through usedMaterials are not taken into account for that analysis.
This identifier will make each material unique in our systems.
System UUID of the material supplier. Provide exactly one of ownerId or ownerUniqueIdentifier (with ownerKind = SUPPLIER), or use address instead — not both owner and address.
Client uniqueIdentifier of the material supplier. Requires ownerKind = SUPPLIER. Mutually exclusive with ownerId and with address.
Raw material name taxonomy (from official material–attribute pairs; each name must be combined with a valid attribute for that material). Use the Fairly Made Material Selector spreadsheet to see which attributes are allowed for each name (Step 1 = material, Step 2 = allowed attributes), then align with the enums here. Fairly Made Material Selector.
Raw material attribute taxonomy. Values are only valid in combination with a given raw material name; each material name accepts only the attributes defined in the official material–attribute pairs. To choose the correct attribute for a given material name, use the Fairly Made Material Selector (Google Sheets): Step 1 — select the material; Step 2 — lists the attributes you may use with that name. Then send the exact enum value from this schema. Fairly Made Material Selector.
Purchased material inputs to produce this material. Each item represents a purchased material and its contribution percentage. Only applicable when the entity is linked with an owner (ownerKind with ownerId or ownerUniqueIdentifier); not used when providing a processing step address. Sum of purchased items and used items usagePercentage must equal 100. For Fairly Made traceability / supplier data collection, use purchasedItems (each related purchased item must have a purchaseOrder). Links made only through usedMaterials are not taken into account for that analysis.
- Mock serverhttps://doc.api.fairlymade.com/_mock/swagger-fairlymadeapi-v3/manufactured-materials
- Productionhttps://api.fairlymade.com/v3/manufactured-materials
- Sandboxhttps://api.sandbox.fairlymade.com/v3/manufactured-materials
Creation of a material with a single supplier (owner). Owner is specified via ownerKind and ownerId; no processing step address.
curl -i -X POST \
https://doc.api.fairlymade.com/_mock/swagger-fairlymadeapi-v3/manufactured-materials \
-H 'Content-Type: application/json' \
-d '{
"uniqueIdentifier": "FM-MATERIAL-COTTON-0001",
"ownerKind": "SUPPLIER",
"ownerId": "a5765369-b42c-4e6f-849b-0c3873e8deb5",
"rawMaterialName": "COTTON",
"rawMaterialAttribute": "CONVENTIONAL"
}'{ "materialId": "30cdab3c-3e2b-44f4-8415-c6dd88ed4261" }