Administration/Materials

Replaces a material: name is required, and every other field left out is cleared (category, description, the image and the units to null, isRecycled/isSynthetic to 0) — except translations (en/es/de/fr), whose sent languages are merged over the stored ones. Also renames the material's raw-material product category, publishes a newly attached image, and re-syncs the category into the style types. Responds with the record as GET /:id returns it. 404 material_not_found for an unknown id.

put/api/admin/materials/{id}

Request

  • Base URL
    https://api.retraced.com (the document declares no server; this is the origin it was published from)
  • URL
    https://api.retraced.com/api/admin/materials/{id}
  • Auth
    none declared

Path parameters

idstring required

Request body

namestring required
descriptionstring nullable
imageFileIdstring nullable
isRecyclednumber nullable
isSyntheticnumber nullable
category'NATURAL_FIBER' | 'SYNTHETIC_FIBER' | 'LEATHER' | 'NATURAL_MATERIAL' | 'SYNTHETIC_MATERIAL' | 'METAL'
quantityUnitsstring[]
weightUnitsstring[]

Response

Default Response

Changes