Add Repair Unit
POST/api/repairs/:repair/lines
Add Repair Unit.
repairs:writeGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Request fields:
product_id(required): integer, exists:products,idcomponent_product_id(optional): integer, exists:products,idcustomer_product_text(optional): string, max:255needs_product_match(optional): booleanrequested_service(optional): Enum:in:"repair","replate","replace"quantity(optional): integer, min:1, max:100000sales_order_line_id(optional): integer, exists:sales_order_lines,idrma_line_id(optional): integer, exists:rma_lines,idserial_number_id(optional): integer, exists:serial_numbers,idlot_number(optional): string, max:100warranty_registration_id(optional): integer, exists:warranty_registrations,idownership(optional): Enum:in:"customer","brand"issue_type_ids(optional): arrayissue_type_ids.*(optional): integer, exists:repair_issue_types,idcustomer_description(optional): string, max:5000technician_user_id(optional): integerroot_cause(optional): Enum:in:"manufacturing_defect","wear_and_tear","accidental_damage","misuse","shipping_damage","no_fault_found","unknown"purchase_date(optional): dateattachment_ids(optional): array, max:20attachment_ids.*(optional): integer, exists:repair_attachments,idcustody_warehouse_location_id(optional): integer, exists:warehouse_locations,id
Permission: repairs.update|repairs.create.
Authentication: Bearer token with the repairs:read / write scope.
Request
Responses
- 200
- 401
- 403
- 404
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not found — no record with the given identifier (or the route does not exist). Verify the ID before retrying.
Unprocessable Content
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.