products/{productId}/operations:batch-create
Adds one or more operations to the specified Product. Each request body may contain at most 100 operations; larger payloads must be split across multiple requests.
Resource Information
| Method and URI | POST https://api.aps.autodesk.com/fusion-operations/v2/products/{productId}/operations:batch-create |
| Authentication Context | No security required |
| Required OAuth Scopes | data:read data:write |
| Data Format | JSON |
Request
Headers
| Authorization* string | JWT Access Token |
| Content-Type* string | Must be application/json |
Request
URI Parameters
| productId int | The unique identifier of the Product to which the operation belongs. |
Request
Body Structure
Array of operation objects to be added to the Product. At most 100 items are accepted per request.
| code* string | Max length: 255 |
| name string | Max length: 255 |
| notes string | Max length: 5000 |
| wasteCodes array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| leadTime number | |
| timesPerProduct number | |
| parameters array: object | |
| name string | |
| checklists array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| machines array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| section | |
| id int | Unique identifier of the referenced entity. |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| labels array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| maxWasteAllowed number | |
| workInstructions array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| unitOfMeasurement | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| teamOperation boolean | |
| allowInputLot boolean | |
| allowInputRecoverySerialNumber boolean | |
| multi boolean | |
| noQuantityRecord boolean | |
| noTimeRecord boolean | |
| optional boolean | |
| prepareBatchOrder boolean | |
| enableBarcodePrint boolean | |
| quantityOnCheckIn boolean | |
| disabled boolean | |
| recovery boolean |
Response
HTTP Status Code Summary
| 201 Created | Operations successfully created. |
| 207 | Partial success. The request was processed but one or more operations were not created. |
| 400 Bad Request | Bad request due to invalid data. |
| 401 Unauthorized | The access token is invalid. It may have either expired or may not be a three-legged access token. Please verify the token and retry the request. |
| 403 Forbidden | The request was successfully validated but lacked required permission. Please verify your token permissions and retry the request. |
| 404 Not Found | The resource in the path does not exist. |
| 429 Too Many Requests | Rate limit exceeded; wait some time before retrying. |
| 500 Internal Server Error | An unknown server-side error occurred. Please try again later. If the problem persists, please contact support. |
Response
Header (429)
| Retry-After integer | The number of seconds to wait before retrying the request. |
Response
Body Structure (201)
| id int | Unique identifier of the Operation. |
| code string | Max length: 255 |
| name string | Max length: 255 |
| notes string | Max length: 5000 |
| wasteCodes array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| taskDuration object | Current active Task Duration. Considering the validSince date. |
| id int | Unique identifier of the Task Duration. |
| validSince string | Valid Since date (e.g. 2017-06-21) |
| cycleTime string | Cycle Time (ISO 8601 duration, e.g. PT3H15M30S) |
| customerTime string | Customer Time (ISO 8601 duration, e.g. PT3H15M30S) |
| quantityRatio number | Quantity Ratio |
| leadTime number | |
| timesPerProduct number | |
| productionFlowOrder int | |
| parameters array: object | |
| id int | Unique identifier of the variable parameter. |
| name string | |
| type object | Possible values: NUMERIC, TEXT, SINGLE_SELECT, SIGNATURE, IMAGE |
| checklists array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| machines array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| section | |
| id int | Unique identifier of the referenced entity. |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| labels array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| maxWasteAllowed number | |
| workInstructions array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| unitOfMeasurement | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| teamOperation boolean | |
| allowInputLot boolean | |
| allowInputRecoverySerialNumber boolean | |
| multi boolean | |
| noQuantityRecord boolean | |
| noTimeRecord boolean | |
| optional boolean | |
| prepareBatchOrder boolean | |
| enableBarcodePrint boolean | |
| quantityOnCheckIn boolean | |
| disabled boolean | |
| recovery boolean |
Response
Body Structure (207)
| results array: object | |
| id int | Unique identifier of the Operation. |
| code string | Max length: 255 |
| name string | Max length: 255 |
| notes string | Max length: 5000 |
| wasteCodes array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| taskDuration object | Current active Task Duration. Considering the validSince date. |
| id int | Unique identifier of the Task Duration. |
| validSince string | Valid Since date (e.g. 2017-06-21) |
| cycleTime string | Cycle Time (ISO 8601 duration, e.g. PT3H15M30S) |
| customerTime string | Customer Time (ISO 8601 duration, e.g. PT3H15M30S) |
| quantityRatio number | Quantity Ratio |
| leadTime number | |
| timesPerProduct number | |
| productionFlowOrder int | |
| parameters array: object | |
| id int | Unique identifier of the variable parameter. |
| name string | |
| type object | Possible values: NUMERIC, TEXT, SINGLE_SELECT, SIGNATURE, IMAGE |
| checklists array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| machines array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| section | |
| id int | Unique identifier of the referenced entity. |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| labels array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| maxWasteAllowed number | |
| workInstructions array: object | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| unitOfMeasurement | |
| id int | Unique identifier of the referenced entity. |
| code string | Code of the referenced entity.
Max length: 255 |
| name string | Name of the referenced entity.
Max length: 255 |
| anyOf | |
| 0 | |
| 1 | |
| teamOperation boolean | |
| allowInputLot boolean | |
| allowInputRecoverySerialNumber boolean | |
| multi boolean | |
| noQuantityRecord boolean | |
| noTimeRecord boolean | |
| optional boolean | |
| prepareBatchOrder boolean | |
| enableBarcodePrint boolean | |
| quantityOnCheckIn boolean | |
| disabled boolean | |
| recovery boolean | |
| errors array: object | |
| title string | |
| detail string | |
| field string |
Example
Operations successfully created.
Operations to be added to the Product with codes
Request
curl -v 'https://developer.api.autodesk.com/fusion-operations/v2/products/:productId/operations:batch-create' \
-X 'POST' \
-H 'Authorization: ' \
-H 'Content-Type: application/json' \
-d '[
{
"code": "Setup",
"name": "Setup",
"notes": "Setup operation notes",
"wasteCodes": [
{
"code": "SetupWaste"
}
],
"taskDuration": {
"id": 8,
"validSince": "2025-01-25",
"cycleTime": "PT1H13M30S",
"customerTime": "PT2H15M30S",
"quantityRatio": 2
},
"leadTime": 12,
"timesPerProduct": 1,
"productionFlowOrder": 1,
"parameters": [
{
"name": "Voltage",
"type": "NUMERIC"
}
],
"checklists": [
{
"code": "SetupChecklist",
"name": "First checklist to follow"
}
],
"machines": [
{
"code": "Machine A",
"name": "Machine A"
}
],
"section": {
"name": "Assembly"
},
"labels": [
{
"code": "Critical"
}
],
"maxWasteAllowed": 2.0,
"workInstructions": [
{
"code": "SetupInstructions"
}
],
"unitOfMeasurement": {
"code": "Each",
"name": "Each"
},
"teamOperation": false,
"allowInputLot": true,
"allowInputRecoverySerialNumber": false,
"multi": false,
"noQuantityRecord": false,
"noTimeRecord": false,
"optional": false,
"prepareBatchOrder": false,
"enableBarcodePrint": false,
"quantityOnCheckIn": false,
"disabled": false,
"recovery": false
}
]'
Operations to be added to the Product with ids
Request
curl -v 'https://developer.api.autodesk.com/fusion-operations/v2/products/:productId/operations:batch-create' \
-X 'POST' \
-H 'Authorization: ' \
-H 'Content-Type: application/json' \
-d '[
{
"code": "Setup",
"name": "Setup",
"notes": "Setup operation notes",
"wasteCodes": [
{
"id": 5
}
],
"taskDuration": {
"id": 8,
"validSince": "2025-01-25",
"cycleTime": "PT1H13M30S",
"customerTime": "PT2H15M30S",
"quantityRatio": 2
},
"leadTime": 12,
"timesPerProduct": 1,
"productionFlowOrder": 1,
"parameters": [
{
"name": "Voltage"
}
],
"checklists": [
{
"id": 22
}
],
"machines": [
{
"id": 7
}
],
"section": {
"id": 4
},
"labels": [
{
"id": 6
}
],
"maxWasteAllowed": 2.0,
"workInstructions": [
{
"id": 9
}
],
"unitOfMeasurement": {
"id": 3
},
"teamOperation": false,
"allowInputLot": true,
"allowInputRecoverySerialNumber": false,
"multi": false,
"noQuantityRecord": false,
"noTimeRecord": false,
"optional": false,
"prepareBatchOrder": false,
"enableBarcodePrint": false,
"quantityOnCheckIn": false,
"disabled": false,
"recovery": false
}
]'
Response
[
{
"id": 2,
"code": "Setup",
"name": "Setup",
"notes": "Setup operation notes",
"wasteCodes": [
{
"id": 5,
"code": "SetupWaste"
}
],
"taskDuration": {
"id": 8,
"validSince": "2025-01-25",
"cycleTime": "PT1H13M30S",
"customerTime": "PT2H15M30S",
"quantityRatio": 2
},
"leadTime": 12,
"timesPerProduct": 1,
"productionFlowOrder": 1,
"parameters": [
{
"name": "Voltage",
"type": "NUMERIC"
}
],
"checklists": [
{
"id": 22,
"code": "SetupChecklist",
"name": "First checklist to follow"
}
],
"machines": [
{
"id": 7,
"code": "Machine A",
"name": "Machine A"
}
],
"section": {
"id": 4,
"name": "Assembly"
},
"labels": [
{
"id": 6,
"code": "Critical"
}
],
"maxWasteAllowed": 2.0,
"workInstructions": [
{
"id": 9,
"code": "SetupInstructions"
}
],
"unitOfMeasurement": {
"id": 3,
"code": "Each",
"name": "Each"
},
"teamOperation": false,
"allowInputLot": true,
"allowInputRecoverySerialNumber": false,
"multi": false,
"noQuantityRecord": false,
"noTimeRecord": false,
"optional": false,
"prepareBatchOrder": false,
"enableBarcodePrint": false,
"quantityOnCheckIn": false,
"disabled": false,
"recovery": false
}
]