Swagger v3 Background Job API Changes
This topic explains the Swagger v3 background job API changes.
Create a Background Job to Update a Working-Set 
Since Codebeamer release 22.04-SP1, a new endpoint is available to start a job that merges changes from the source working-set into the target working-set. This endpoint replaces the content of the specified target trackers.
URL
POST /v3/jobs/working-set-update
Request Body Example
{
"projectBaselineId": 0,
"source": {
"id": 0,
"name": "string",
"type": "string"
},
"target": {
"id": 0,
"name": "string",
"type": "string"
},
"trackers": [
{
"baselineId": 0,
"cbql": "string",
"tracker": {
"id": 0,
"name": "string",
"type": "string"
}
}
]
}
Input Parameters
Parameter
Description
name
The name is not a required field.
type
The type is not a required field.
projectBaselineId
The projectBaselineId is a mandatory field. If undefined, HEAD is considered.
trackers
The trackers field must be specified if all the items are not to be updated.
baselineId
The ID of the baseline. Use the baselineId in trackers if the projectBaselineId or HEAD are not the required baseline for the specified tracker.
cbql
The cbql field is used to filter items. If not set, all items are updated.
source
The parent working set
target
The child working set
Examples
Consider the following scenario:
A default working-set with tracker ID 1234.
A custom working-set with working-set ID 5678.
Merge all items from the default working-set into a custom working-set as follows.
{
"target": {
"id": 5678
}
}
Merge only item1 and item2 from the default working-set into a custom working-set as follows.
{
"target": {
"id": 5678
},
"trackers": [
{
"cbql": "(summary = 'item1' OR summary = 'item2') AND tracker.id IN (1234) AND project.id IN (101)",
"tracker": {
"id": 1234
}
}
]
}
Merge all items from a custom working-set into the default working-set as follows.
{
"source": {
"id": 5678
}
}
Was this helpful?