Endpoints
| Method | Path | Description |
|---|---|---|
GET | /api/v1/textile/fabrics | List fabrics, optionally filtered by supplierId |
GET | /api/v1/textile/fabrics/{id} | Get a single fabric |
POST | /api/v1/textile/fabrics | Create a fabric product |
PATCH | /api/v1/textile/fabrics/{id} | Partially update a fabric |
DELETE | /api/v1/textile/fabrics/{id} | Delete a fabric |
GET /api/v1/textile/fabrics
| Query parameter | Type | Required |
|---|---|---|
supplierId | uuid | — |
Shell
curl "{{BASE_URL}}/api/v1/textile/fabrics?supplierId=3f2b9a1c-…"
Response 200 OK — JSON array of FabricProductDto.
POST /api/v1/textile/fabrics
Common textile fields
See the Textile concept page for the shared core (identity, origin, certifications, sustainability, commerce, logistics).
Fabric-specific fields
| Field | Type | Description |
|---|---|---|
widthCm | number | Fabric width on the roll (cm) |
arealMassGsm | number | Weight per square meter (g/m²) |
weaveType | string | e.g. PLAIN, TWILL, SATIN |
finish | string | e.g. MERCERIZED, DYED, RAW |
Example
Shell
curl -X POST {{BASE_URL}}/api/v1/textile/fabrics \-H "Content-Type: application/json" \-d '{"name": "Organic Cotton Poplin 140gsm","code": "FAB-OCP-140","supplierId": "3f2b9a1c-…","composition": "100% organic cotton","productOriginCountry": "IT","rawMaterialOriginCountry": "IN","gotsCertified": true,"grsCertified": false,"oekoTexCertified": true,"recycledContentPct": 0,"organicContentPct": 100,"unitOfMeasure": "M","widthCm": 150,"arealMassGsm": 140,"weaveType": "PLAIN","finish": "DYED","available": true,"minimumOrder": 200,"pricePerUnit": "6.90","currency": "EUR","leadTimeDays": 21}'
Response 201 Created — FabricProductDto.
GET /api/v1/textile/fabrics/{id}
200 OK—FabricProductDto.404 Not Found— fabric does not exist in your tenant.
PATCH /api/v1/textile/fabrics/{id}
Partial update over any of the fields documented above.
DELETE /api/v1/textile/fabrics/{id}
204 No Content— deleted.404 Not Found— fabric does not exist in your tenant.
Fabric schema
FabricProductDto has textileCategory fixed to FABRIC.
JSON
{"id": "fab-uuid…","supplierId": "3f2b9a1c-…","companyId": null,"userId": null,"name": "Organic Cotton Poplin 140gsm","code": "FAB-OCP-140","textileCategory": "FABRIC","description": null,"technicalSpecs": null,"composition": "100% organic cotton","productOriginCountry": "IT","rawMaterialOriginCountry": "IN","gotsCertified": true,"grsCertified": false,"oekoTexCertified": true,"cradleToCradle": false,"betterCotton": false,"otherCertifications": null,"recycledContentPct": 0,"organicContentPct": 100,"sustainabilityNotes": null,"available": true,"minimumOrder": 200,"pricePerUnit": "6.90","currency": "EUR","productWeightKg": null,"quantityAvailable": null,"leadTimeDays": 21,"unitOfMeasure": "M","metadata": null,"widthCm": 150,"arealMassGsm": 140,"weaveType": "PLAIN","finish": "DYED","createdAt": "2026-04-21T10:00:00.000Z","updatedAt": "2026-04-21T10:00:00.000Z"}