Add a rework action
POST
/rework-orders/{id}/actions
const url = 'https://app.buildtrace.eu/api/rework-orders/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/actions';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"actionType":"example","removedSerialId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","addedSerialId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","childRevisionId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","lotNumber":"example","quantity":"example","notes":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://app.buildtrace.eu/api/rework-orders/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/actions \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "actionType": "example", "removedSerialId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "addedSerialId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "childRevisionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "lotNumber": "example", "quantity": "example", "notes": "example" }'Required scope: service:write.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string format: uuid
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
actionType
required
string
removedSerialId
string format: uuid
addedSerialId
string format: uuid
childRevisionId
string format: uuid
lotNumber
string
quantity
string
notes
string
Example generated
{ "actionType": "example", "removedSerialId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "addedSerialId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "childRevisionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "lotNumber": "example", "quantity": "example", "notes": "example"}Responses
Section titled “Responses”OK
Media typeapplication/json
object
id
required
string format: uuid
orderNumber
required
The order’s number within the organization, e.g. RW-0001
string
serialId
required
string format: uuid
reason
required
string
ecoId
string format: uuid
status
required
string
serialNumber
Human-readable serial number of the unit being reworked (read-only).
string
ecoNumber
ECO number, when the order is ECO-linked (read-only).
string
ecoTitle
ECO title, when the order is ECO-linked (read-only).
string
Example generated
{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "orderNumber": "example", "serialId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "reason": "example", "ecoId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "status": "example", "serialNumber": "example", "ecoNumber": "example", "ecoTitle": "example"}Bad request
Media typeapplication/json
object
error
required
string
Example generated
{ "error": "example"}Unauthorized
Not found
The order is not in progress, the reworked unit is reserved for a build order, the unit named is not fitted in this unit or is not in a state to be fitted, the reworked unit is not an assembly, or the fit would put a unit inside itself or nest units more than 64 deep
Media typeapplication/json
object
error
required
string
Example generated
{ "error": "example"}