Required Format for JSON Payloads
When a REST operation requires that a payload be passed in the request body, you can pass either XML or JSON.
However, if JSON is passed in the request body, all attributes must be prefixed with an @ character. This is required because the ActiveMatrix BPM REST operations use the Badgerfish standard.
The following are some examples of using this standard in ActiveMatrix BPM:
Example 1
The following is an example of a JSON request body for the createWorkListView REST operation:
{
"WorkListViewEdit": {
"@description": "Pending orders",
"@public": "true",
"entityID": {
"@entity-type": "RESOURCE",
"@guid": "9178DD52-C6AE-468E-AF31-10EA78CC500B"
},
"orderFilterCriteria": {
"@order": "id ASC , startDate DESC",
},
"users": {
"@entity-type": "RESOURCE",
"@guid": "32B63222-5B76-4EF9-8BEA-A8E538A3BB17"
}
}
}
Example 2
The following is an example of a JSON request body for the pendWorkItem REST operation:
{
"workItemID":[{"@id":"83"}],
"hiddenPeriod":[{"hiddenDuration":{"@days":1,"@hours":0,"@minutes":0,"@months":0,"@weeks":0,"@years":0}}]
}
Copyright © Cloud Software Group, Inc. All rights reserved.
