[GET] /process-definitions

[GET] /process-definitions

/api/bpm/process-definitions

Description

To retrieve process definitions, which have running, suspended, completed or aborted processes.

If the withProcesses parameter is set to completed, only process definitions with completed or aborted processes are returned.

If withProcesses is set to active, only process definitions with running or suspended processes are returned. Historical process definitions include an additional property version.

If withProcesses is not set (enaio version greater than 12.0), all process definitions will be retuned. In this case returned object contains additional properties: version, description, parentId, userId, createTime, state, iconId and if available, information about locking. State in this case can be one of the folowing:

  • ACTIVE - The model is in use; i.e. new processes can be started with it.

  • EDIT_LOCKED - The model is locked for editing.

  • EDIT_UNLOCKED - The model is still being edited but is not locked.

  • TESTING - The model is available for testing.

  • DELETED - The model has been deleted but is still contained in the database.

  • RELEASED - The model is available but is not yet in use. New processes cannot be started with this model, active ones are being terminated.

Optionally, an organizationId could be sent if process definitions for the nonactive organization should be retrieved. By default, the active organization will be used.

Required Systemrole

R_WFADM_START (ID = 20)

Request
Method

GET

Request Optional Query Parameter

  • organizationId (String): The Id of the organization for which the active process definitions should be retrieved.

  • withProcesses (Enum): If completed, only historical process definitions are returned. If active, only active ones. If null or unspecified, all process definitions are returned.

Response
Format

JSON

Minimum Version

1.0.0

Request
Example

/api/bpm/process-definitions

/api/bpm/process-definitions?withProcesses=active&organizationId=914FC91A55D542F79D8ED1BADDE1AFE6

/api/bpm/process-definitions?withProcesses=completed&organizationId=914FC91A55D542F79D8ED1BADDE1AFE6

Result
Example when withProcesses is not specified

{     "objects": [{ "id": "1D3F4694BF1B4056B8A9DF75CE36006C", "parentId": "AFCE50FAD74A40D29E06A7AA7EC569C7", "name": "ExtremAdhoc", "userId": "B01F6B1429BD4E2B894A065E5C7888F1", "createTime": "2016-12-16T13:54:18+01:00", "version": 1, "state": "ACTIVE" }, { "id": "207A55B4165F46D5BCAF96A812F6F331", "parentId": "217CEC5775234EFEAC1158D137C7FFE1", "name": "Rechnungslauf v. 1.90", "description": "Rechnungslauf für E+S / MaWi", "userId": "DB1EF746DB2C4F42A9234F77939FB335", "createTime": "2019-03-15T13:54:29+01:00", "version": 3, "state": "EDIT_LOCKED", "iconId": 1073742370, "lock": { "userId": "BF894230A0324FB887CDD732FCDDD61D", "userName": "ROOT", "createTime": "2026-04-07T12:22:12+02:00" } }] }

Result
Example when withProcesses=active

{     "objects": [{         "id": "62AFC01A55B555F70DAED1DAADE1EF00",         "name": "Test-Workflow"     },{         "id": "914FC91A55D542F79D8ED1BADDE1AFE6",         "name": "Mail-Workflow"     }] }

Result
Example when withProcesses=completed

{ "objects": [{ "id": "146B2B9F2E334E6EA97FF566E6E8EDBA", "name": "Ad-hoc Version 1.6.2 german", "version": 2 },{ "id": "20852BCD50D0400AA907E420E5E9C18C", "name": "EndlessWF", "version": 13 }] }