Create an empty Workflow
Author:
Fluent Commerce
Changed on:
1 Aug 2024
Key Points
- A new Workflow creation requires the correct permissions for the user, and a valid workflow JSON file (schema,
`entityType`
and statuses/rulesets).
Steps
Create an empty Workflow
Create an empty Workflow
Before you can create a you must have a valid JSON file.
A requires the following:
- a valid schema
- a valid
`entityType`
- a "Create" Ruleset and "CREATED" Status for the Rulesets each
`entityType`
in the Workflow.
Workflow schema
JSON Key | Value Type | Mandatory | Description |
retailerId | String | YES | Id of the Retailer this applies to. |
version | String | YES | The current version of this . The initial version is "1.0". Every time you successfully commit an update to a , the minor version will increment. Major versions can be updated manually. |
entityType | String | YES | This field accepts the following inputs: |
entitySubtype | String | YES | A type used to differentiate between multiple Workflows with the same |
description | String | NO | Cannot be more than 300 characters. |
versionComment | String | NO | Cannot be more than 2000 characters. |
createdBy | String | NO | The name of the last user who changed the . |
createdOn | String | NO | The date and time the was last changed. |
id | String | NO | |
name | String | NO | The name of the . If you leave this field blank, the system will generate a name based on the following format: entityType::entitySubtype. |
settings | Object | NO | An object of key-value pairs that can enhance the performance and functionality of your . See available Workflow settings or how to add Settings to a Workflow. |
rulesets | Array | YES | The array of Rulesets in the . |
statuses | Array | YES | The array of Statuses in the . |
Workflow sample
1{
2 "retailerId": "{{retailerID}}",
3 "version": "1",
4 "entityType": "{{entityType}}",
5 "entitySubtype": "{{entitySubtype}}",
6 "description": "",
7 "versionComment": null,
8 "createdBy": "",
9 "createdOn": "",
10 "id": null,
11 "name": "{{workflowName}}",
12 "settings": {},
13 "rulesets": [
14 {
15 "name": "CREATE",
16 "description": "",
17 "type": "{{entityType}}",
18 "eventType": "NORMAL",
19 "rules": [],
20 "triggers": [
21 {
22 "status": "CREATED"
23 }
24 ],
25 "userActions": []
26 }
27 ],
28 "statuses": [
29 {
30 "name": "CREATED",
31 "entityType": "{{entityType}}",
32 "category": "{{category}}"
33 }
34 ]
35}