All constructor parameters for configuration are optional. If no configuration is provided, the SDK will use environment variables to configure itself.
Optional
options: { Optional
config?: Camunda8ClientConfigurationOptional
oPrivate
configPrivate
oPrivate
prefixPrivate
restPrivate
Optional
tenantPrivate
userIterate through all known partitions and activate jobs up to the requested maximum.
The parameter inputVariablesDto
is a Dto to decode the job payload. The customHeadersDto
parameter is a Dto to decode the custom headers.
Pass in a Dto class that extends LosslessDto to provide both type information in your code,
and safe interoperability with applications that use the int64
type in variables.
8.6.0
Private
addPrivate
addHelper method to add the default job methods to a job
The job to add the methods to
The job with the added methods
Assign a user task with the given key to the given assignee.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/assign-user-task/
8.6.0
use assignUserTask
Assign a user task with the given key to the given assignee.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/assign-user-task/
8.6.0
Broadcast a signal.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/broadcast-signal/
8.6.0
This is a generic method to call an API endpoint. Use this method to call any REST API endpoint in the Camunda 8 cluster. TODO: This does not currently support multipart form-data, but it will.
Complete a job with the given payload, which allows completing the associated service task.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/complete-job/
8.6.0
Complete a user task with the given key. The method either completes the task or throws 400, 404, or 409.
Documentation: https://docs.camunda.io/docs/apis-tools/zeebe-api-rest/specifications/complete-a-user-task/
Optional
action?: stringOptional
variables?: Record<string, unknown>8.6.0
Publish a Message and correlates it to a subscription. If correlation is successful it will return the first process instance key the message correlated with.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/correlate-a-message/
8.6.0
Create document link
Create a link to a document in the Camunda 8 cluster. Note that this is currently supported for document stores of type: AWS, GCP
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/create-document-link/
8.7.0
Create a new polling Job Worker.
You can pass in an optional winston.Logger instance as logger
. This enables you to have distinct logging levels for different workers.
Polling: The worker polls periodically. If no jobs are available, the poll stays open for 10 seconds. If no jobs become available in that time, the poll is closed, and the worker polls again. When jobs are available, they are returned, and the worker polls again for more jobs as soon as it has capacity for more jobs.
8.6.0
Create and start a process instance. This method does not await the outcome of the process. For that, use createProcessInstanceWithResult
.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/create-process-instance/
8.6.0
Create and start a process instance. This method awaits the outcome of the process.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/create-process-instance/
8.6.0
Create a user.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/create-user/
8.6.0
Delete a document from the Camunda 8 cluster.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/delete-document/
Optional
store8.7.0
Deletes a deployed resource. This can be a process definition, decision requirements definition, or form definition deployed using the deploy resources endpoint. Specify the resource you want to delete in the resourceKey parameter.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/delete-resource/
Optional
operation8.6.0
Deploy resources to the broker.
An array of binary data strings representing the resources to deploy.
Optional
tenantId: stringOptional tenant ID to deploy the resources to. If not provided, the default tenant ID is used.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/deploy-resources/
8.6.0
Deploy resources to Camunda 8 from files
an array of file paths
Optional
tenant8.6.0
Download a document from the Camunda 8 cluster.
Note that this is currently supported for document stores of type: AWS, GCP, in-memory, local Documentation: https://docs.camunda.io/docs/8.7/apis-tools/camunda-api-rest/specifications/get-document/
8.7.0
Report a business error (i.e. non-technical) that occurs while processing a job.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/report-error-for-job/
8.6.0
Evaluate decision
Evaluates a decision. You specify the decision to evaluate either by using its unique key (as returned by DeployResource), or using the decision ID. When using the decision ID, the latest deployed version of the decision is used.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/evaluate-decision/
8.6.0
Fails a job using the provided job key. This method sends a POST request to the endpoint '/jobs/{jobKey}/fail' with the failure reason and other details specified in the failJobRequest object.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/fail-job/
8.6.0
Private
getObtains the status of the current Camunda license.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/get-status-of-camunda-license/
8.6.0
Get the user task by the user task key.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/get-user-task/
8.8.0
Migrates a process instance to a new process definition. This request can contain multiple mapping instructions to define mapping between the active process instance's elements and target process definition elements. Use this to upgrade a process instance to a new version of a process or to a different process definition, e.g. to keep your running instances up-to-date with the latest process improvements.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/migrate-process-instance/
8.6.0
Manage the permissions assigned to authorization.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/patch-authorization/
8.6.0
Modify process instance
Modifies a running process instance. This request can contain multiple instructions to activate an element of the process or to terminate an active instance of an element. Use this to repair a process instance that is stuck on an element or took an unintended path. For example, because an external system is not available or doesn't respond as expected.
Documentation https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/modify-process-instance/
8.6.0
Set a precise, static time for the Zeebe engine's internal clock. When the clock is pinned, it remains at the specified time and does not advance. To change the time, the clock must be pinned again with a new timestamp, or reset.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/pin-internal-clock/
8.6.0
Publish a single message. Messages are published to specific partitions computed from their correlation keys. This method does not wait for a correlation result. Use correlateMessage
for such use cases.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/publish-a-message/
8.6.0
Resets the Zeebe engine's internal clock to the current system time, enabling it to tick in real-time. This operation is useful for returning the clock to normal behavior after it has been pinned to a specific time.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/reset-internal-clock/
8.6.0
Marks the incident as resolved; most likely a call to Update job will be necessary to reset the job's retries, followed by this call.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/resolve-incident/
8.6.0
Query process instances
Documentation: https://docs.camunda.io/docs/8.7/apis-tools/camunda-api-rest/specifications/query-process-instances-alpha/
8.8.0
Search for user task variables based on given criteria.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/find-user-task-variables/
8.8.0
Search for user tasks based on given criteria.
Documentation: https://docs.camunda.io/docs/8.7/apis-tools/camunda-api-rest/specifications/find-user-tasks/
8.8.0 - alpha status in 8.6 and 8.7
Search for process and local variables based on given criteria.
Documentation: https://docs.camunda.io/docs/next/apis-tools/camunda-api-rest/specifications/find-variables/
8.8.0
Remove the assignee of a task with the given key.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/unassign-user-task/
8.6.0
use unassignUserTask
Remove the assignee of a task with the given key.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/unassign-user-task/
8.6.0
Updates all the variables of a particular scope (for example, process instance, flow element instance) with the given variable data. Specify the element instance in the elementInstanceKey parameter.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/update-element-instance-variables/
8.6.0
Update a job with the given key.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/update-a-job/
8.6.0
Update a user task with the given key.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/update-user-task/
8.6.0
use updateUserTask
Update a user task with the given key.
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/update-user-task/
8.6.0
Upload a document to the Camunda 8 cluster. Note that this is currently supported for document stores of type: AWS, GCP, in-memory, local
Documentation: https://docs.camunda.io/docs/8.7/apis-tools/camunda-api-rest/specifications/create-document/
8.7.0
Upload multiple documents to the Camunda 8 cluster. The caller must provide a file name for each document, which will be used in case of a multi-status response to identify which documents failed to upload. The file name can be provided in the Content-Disposition header of the file part or in the fileName field of the metadata part. If both are provided, the fileName field takes precedence.
In case of a multi-status response, the response body will contain a list of DocumentBatchProblemDetail objects, each of which contains the file name of the document that failed to upload and the reason for the failure. The client can choose to retry the whole batch or individual documents based on the response.
Note that this is currently supported for document stores of type: AWS, GCP, in-memory (non-production), local (non-production)
Documentation: https://docs.camunda.io/docs/apis-tools/camunda-api-rest/specifications/create-documents/
Optional
storeThe ID of the document store to upload the documents to. Currently, only a single document store is supported per cluster. However, this attribute is included to allow for potential future support of multiple document stores.
8.7.0
Generated using TypeDoc
The client for the unified Camunda 8 REST API.
Logging: to enable debug tracing during development, you can set
DEBUG=camunda:zeebe-rest
.For production, you can pass in an instance of winston.Logger to the constructor as
logger
.CAMUNDA_LOG_LEVEL
in the environment or the constructor options can be used to set the log level to one of 'error', 'warn', 'info', 'http', 'verbose', 'debug', or 'silly'.Since
8.6.0