# Latest active version (minimal)
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}'
# Pinned to a specific version number
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"workflowVersionNumber": 3,
"title": "Q4 Report Processing"
}'
import requests
url = "https://operator.opus.com/api/v1/case"
headers = {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}"
}
payload = {
"workflowId": "{YOUR_WORKFLOW_ID}",
# Pin a specific workflow version (omit both to use the latest active version):
# "workflowVersionNumber": 3,
# "workflowVersionId": "{WORKFLOW_VERSION_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
const response = await fetch("https://operator.opus.com/api/v1/case", {
method: "POST",
headers: {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}",
},
body: JSON.stringify({
workflowId: "{YOUR_WORKFLOW_ID}",
// Pin a specific workflow version (omit both to use the latest active version):
// workflowVersionNumber: 3,
// workflowVersionId: "{WORKFLOW_VERSION_ID}",
title: "Q4 Report Processing",
description: "Processing quarterly financial reports",
}),
});
const data = await response.json();
console.log(data);
{
"caseId": "{CASE_ID}"
}
Cases
Initiate Case
Create a new case for a workflow and receive a caseId
POST
/
api
/
v1
/
case
# Latest active version (minimal)
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}'
# Pinned to a specific version number
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"workflowVersionNumber": 3,
"title": "Q4 Report Processing"
}'
import requests
url = "https://operator.opus.com/api/v1/case"
headers = {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}"
}
payload = {
"workflowId": "{YOUR_WORKFLOW_ID}",
# Pin a specific workflow version (omit both to use the latest active version):
# "workflowVersionNumber": 3,
# "workflowVersionId": "{WORKFLOW_VERSION_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
const response = await fetch("https://operator.opus.com/api/v1/case", {
method: "POST",
headers: {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}",
},
body: JSON.stringify({
workflowId: "{YOUR_WORKFLOW_ID}",
// Pin a specific workflow version (omit both to use the latest active version):
// workflowVersionNumber: 3,
// workflowVersionId: "{WORKFLOW_VERSION_ID}",
title: "Q4 Report Processing",
description: "Processing quarterly financial reports",
}),
});
const data = await response.json();
console.log(data);
{
"caseId": "{CASE_ID}"
}
This step creates a case for a workflow and returns the unique
caseId required for execution and monitoring. A case is a single run of a workflow.
Identify the workflow with the workflowId returned by the workflow endpoints. The case runs against the latest active version of the workflow unless you pin one with workflowVersionId or workflowVersionNumber.
You must save the
caseId returned by this endpoint for all subsequent steps.Headers
string
required
Your API authentication key
Body Parameters
string
required
The workflow to run — the
workflowId UUID returned by the workflow endpoints.string
Pin the case to a specific workflow version by UUID. Omit to run the latest active version.
number
Pin the case to a specific workflow version by version number. Omit to run the latest active version.
string
Case title shown in the Opus UI
string
Case description shown in the Opus UI
Response
string
required
The unique identifier for this case. Use this ID in all subsequent API calls.
Errors
Unauthorized
Missing, invalid, or expired API key.
Not Found
The workflow does not exist.
# Latest active version (minimal)
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}'
# Pinned to a specific version number
curl --request POST \
--url https://operator.opus.com/api/v1/case \
--header 'Content-Type: application/json' \
--header 'x-service-key: {YOUR_SERVICE_KEY}' \
--data '{
"workflowId": "{YOUR_WORKFLOW_ID}",
"workflowVersionNumber": 3,
"title": "Q4 Report Processing"
}'
import requests
url = "https://operator.opus.com/api/v1/case"
headers = {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}"
}
payload = {
"workflowId": "{YOUR_WORKFLOW_ID}",
# Pin a specific workflow version (omit both to use the latest active version):
# "workflowVersionNumber": 3,
# "workflowVersionId": "{WORKFLOW_VERSION_ID}",
"title": "Q4 Report Processing",
"description": "Processing quarterly financial reports"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
const response = await fetch("https://operator.opus.com/api/v1/case", {
method: "POST",
headers: {
"Content-Type": "application/json",
"x-service-key": "{YOUR_SERVICE_KEY}",
},
body: JSON.stringify({
workflowId: "{YOUR_WORKFLOW_ID}",
// Pin a specific workflow version (omit both to use the latest active version):
// workflowVersionNumber: 3,
// workflowVersionId: "{WORKFLOW_VERSION_ID}",
title: "Q4 Report Processing",
description: "Processing quarterly financial reports",
}),
});
const data = await response.json();
console.log(data);
{
"caseId": "{CASE_ID}"
}
Was this page helpful?