Shell HTTP JavaScript Node.JS Ruby Python Java Go

Workflow v0.13.0

Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

The workflow API allows definition and execution of workflows. A workflow is a set of tasks in a dependency graph, with state and business rules which connect and constrain the execution of the workflow tasks. Each workflow maintains some state. Each task in the workflow has entry criteria, input variables, and output variables. Workflow tasks are connected in a graph. A task may be a composite task, built from another workflow. (This allowing for reuse of such subflows.)

Each task and workflow has the following data:

Tasks in a workflow which have no predecessor tasks and whose entry criteria rule evaluate to true may be run immediately.

A workflow is done when the state of all its tasks are done, or if the workflow has one or more terminal tasks that are done. If a terminal task causes the workflow to complete, any remaining tasks are canceled. This allows business rules and flow to define the completion criteria, for example, three of four tasks completed instead all four.

Workflow definitions may have cycles. That is, some tasks may be entered again, effectively restarting those tasks.

Workflows are static: once a workflow has been created, tasks cannot be added or removed from the workflow and the task dependency graph may not be changed.

Workflow definitions are workflows with a state of definition; the tasks in a workflow definition are also tasks with state equal to definition. Definitions act as workflow templates: one creates new workflow instances by specifying an existing workflow definition. This also creates new task instances from each task definition. The workflow and all tasks' state is set to blocked with the exception of tasks that do not have dependent tasks (initial is true).

Workflow definitions and task definitions also retain a revision history, available in the definition's revisions collection. New revisions are created via a POST operation to a definition's revisions collection. Revisions are immutable copies of the resource which preserve or record the definition's data at the point in time that the revision was created. This allows preserving specific behavior of a workflow when after changing the definition. For example, a specific revision of a workflow definition (using the revision URI, /workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}) may be attached to other resources (such as banking products) so that the specific revision can be instantiated as a new workflow, rather than instantiating the currently active, revisionless definition found at /workflowDefinitions/{workflowDefinitionId}. Revisions also support auditing: the immutable revision is a record of which workflow was used and its initial state. A workflow definition may reference either a specific revision of the embedded task definitions, or revisionless task definitions; this determines which task definition (a specific revision or the most recent revision) is used for all the tasks in that workflow when that definition is used to create a new workflow instance. A reference to a revisionless task definition URL matches the URL pattern /workflow/taskDefinitions/{taskDefinitionId}; a task definition revision instance has a URL pattern /workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId} where revisionId is an RFC 3339 format timestamp: YYYY-MM-DDThh:mm:ss.sssZ.

Download OpenAPI Definition (YAML)

Base URLs:

Terms of service

Email: Apiture Web: Apiture

Authentication

Scope Scope Description
data/read Read access to non-account, non-profile data.
data/write Write (update) access to non-account, non-profile data.
data/delete Delete access to non-account, non-profile data.
data/full Full access to non-account, non-profile data.

API

Endpoints which describe this API.

getApi

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/ \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY'

GET https://api.devbank.apiture.com/workflow/ HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY'

};

fetch('https://api.devbank.apiture.com/workflow/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY'
}

r = requests.get('https://api.devbank.apiture.com/workflow/', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Top-level resources and operations in this API

GET /

Return links to the top-level resources and operations in this API. Links included in this response include:

Example responses

OK

null

200 Response

{
  "id": "apiName",
  "name": "API name",
  "apiVersion": "0.0.1-SNAPSHOT",
  "_profile": "https://api.apiture.com/schemas/common/root/v1.0.0/profile.json",
  "_links": {}
}

OK

Responses

StatusDescription
200 OK
OK
Schema: root

getApiDoc

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/apiDoc \
  -H 'Accept: application/json' \
  -H 'API-Key: API_KEY'

GET https://api.devbank.apiture.com/workflow/apiDoc HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'API-Key':'API_KEY'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/apiDoc',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/json',
  'API-Key':'API_KEY'

};

fetch('https://api.devbank.apiture.com/workflow/apiDoc',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'API-Key' => 'API_KEY'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/apiDoc',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'API-Key': 'API_KEY'
}

r = requests.get('https://api.devbank.apiture.com/workflow/apiDoc', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/apiDoc");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "API-Key": []string{"API_KEY"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/apiDoc", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return API definition document

GET /apiDoc

Return the OpenAPI document that describes this API.

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline

Response Schema

Workflow Definition

Workflow Definitions

getWorkflowDefinitions

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflowDefinitions \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflowDefinitions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflowDefinitions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflowDefinitions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflowDefinitions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of workflow definitions

GET /workflowDefinitions

Return a paginated sortable filterable searchable collection of workflow definitions. The links in the response include pagination links.

Parameters

Parameter Description
start
(query)
integer(int64)
The zero-based index of the first workflow definition item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of workflow definition representations to return in this page.
sortBy
(query)
string
Optional sort criteria. See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.
state
(query)
string
Subset the accounts or external accounts collection to those whose state matches this value. Use | to separate multiple values. For example, ?state=pending will match only items whose state is pending; ?state=removed|inactive will match items whose state is removed or inactive. This is combined with an implicit and with other filters if they are used. See filtering.
Enumerated values:
pending
definition
blocked
removed
running
paused
completed
failed
canceled
name
(query)
string
Subset the accounts or external accounts collection to those with this name value. Use
domain
(query)
string
Subset the accounts or external accounts collection to those with this domain value. Use
type
(query)
string
Subset the accounts or external accounts collection to those with this exact type value. Use
label
(query)
string
Subset the accounts or external accounts collection to those with this label value. Use

Example responses

OK

{
  "_profile": "https://api.apiture.com/schemas/workflow/workflows/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "workflows",
  "_links": {
    "self": {
      "href": "/workflow/workflows?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/workflows?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/workflows?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/workflows"
    }
  },
  "_embedded": {
    "items": [
      {
        "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
        "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
        "_links": {
          "self": {
            "href": "/workflow/workflowDefinitions/0399abed-fd3d-4830-a88b-30f38b8a365c"
          }
        },
        "name": "newAccountSelector",
        "domain": "https://api.apiture.com/acctApps",
        "label": "New Account Selector",
        "type": "somethingElse",
        "visibility": "hidden",
        "state": "definition",
        "values": {
          "category": "personal",
          "ownership": "joint",
          "minimumBalanceGoal": 1000
        },
        "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
        "_embedded": {}
      }
    ]
  }
}

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/workflows/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "workflows",
  "_links": {
    "self": {
      "href": "/workflow/workflows?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/workflows?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/workflows?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/workflows"
    }
  },
  "_embedded": {
    "items": [
      {
        "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
        "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
        "_links": {
          "self": {
            "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
          }
        },
        "name": "newAccountSelector",
        "domain": "https://api.apiture.com/acctApps",
        "label": "New Account Selector",
        "type": "somethingElse",
        "visibility": "hidden",
        "state": "pending",
        "values": {
          "category": "personal",
          "ownership": "joint",
          "minimumBalanceGoal": 1000
        },
        "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
        "_embedded": {}
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: workflows
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createWorkflowDefinition

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/workflowDefinitions \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/workflowDefinitions HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "apiture:application": {
      "href": "/accountApplications/applications/2f23b9fe-532f-4e82-943e-b079ea55aebc"
    }
  },
  "name": "newAccountSelector",
  "label": "New Account Selector",
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/workflowDefinitions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/workflowDefinitions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/workflowDefinitions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new workflow definition

POST /workflowDefinitions

Create a new workflow definition in the workflow definitions collection.

Body parameter

{
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "apiture:application": {
      "href": "/accountApplications/applications/2f23b9fe-532f-4e82-943e-b079ea55aebc"
    }
  },
  "name": "newAccountSelector",
  "label": "New Account Selector",
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Parameters

Parameter Description
body
(body)
createWorkflow (required)
A workflow definition. The state must be definition.

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
201 Created
Created
Schema: workflow
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
201 Location string uri
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update the resource.

getWorkflowDefinition

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of this workflow definition

GET /workflowDefinitions/{workflowDefinitionId}

Return a HAL representation of this workflow definition resource. This resource is referred to as the revisionless workflow definition, in contrast to the explicit revision at /workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}.

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such workflow definition resource at the specified {workflowDefinitionId}. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow definition resource.

updateWorkflowDefinition

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this workflow definition

PUT /workflowDefinitions/{workflowDefinitionId}

Perform a complete replacement of this workflow definition.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateWorkflow (required)

Example responses

OK

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "name": "personalCheckingApplicationWorkflow",
  "label": "Personal Checking Application Workflow",
  "description": "Personal Checking Application Workflow",
  "state": "definition",
  "schema": {
    "applicatant": {
      "type": "object",
      "required": [
        "firstName",
        "lastName"
      ],
      "properties": {
        "firstName": {
          "type": "string"
        },
        "middleName": {
          "type": "string"
        },
        "lastName": {
          "type": "string"
        }
      }
    }
  },
  "tasks": {
    "personalInfoForm1": {
      "domain": "http:/api.apiture.com/domains/tasks/forms",
      "name": "userForm",
      "label": "Personal Information",
      "type": "form",
      "_links": {
        "self": {
          "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
        }
      }
    },
    "accountOwnershipChoice": {
      "domain": "http:/api.apiture.com/domains/tasks/prompts",
      "name": "accountOwnershipChoice",
      "type": "binaryChoice",
      "label": "Select Account Ownership Type",
      "_links": {
        "self": {
          "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
        }
      }
    },
    "jointOwnerInfoForm1": {
      "domain": "http:/api.apiture.com/domains/tasks/forms",
      "name": "userForm",
      "type": "form",
      "label": "Joint Owner Personal Information",
      "_links": {
        "self": {
          "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ],
  "_links": {
    "self": {
      "href": "/workflow/workflowDefinitions/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "_embedded": {}
}

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such workflow definition resource at the specified {workflowDefinitionId}. The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow definition resource.

patchWorkflowDefinition

Code samples

# You can also use wget
curl -X PATCH https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this workflow definition

PATCH /workflowDefinitions/{workflowDefinitionId}

Perform a partial update of this workflow definition. Fields which are omitted are not updated. Nested _embedded and _links are ignored if included.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateWorkflow (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such workflow definition resource at the specified {workflowDefinitionId}. The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow definition resource.

deleteWorkflowDefinition

Code samples

# You can also use wget
curl -X DELETE https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

DELETE https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.delete 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.delete('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Delete this workflow definition resource

DELETE /workflowDefinitions/{workflowDefinitionId}

Delete this workflow definition resource. The workflow definition may not be deleted if it or any of its revisions are in use by any tasks. Deleting a workflow defintion also deletes all of its revisions.

Parameters

Parameter Description
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.

Example responses

400 Response

{
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": {},
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  }
}

Responses

StatusDescription
204 No Content
No Content. The resource was deleted successfully.
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

getWorkflowDefinitionRevisions

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of workflow definition revisions

GET /workflowDefinitions/{workflowDefinitionId}/revisions

Return a paginated sortable filterable searchable collection of workflow definition revisions. The links in the response include pagination links.

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
start
(query)
integer(int64)
The zero-based index of the first workflow definition revision item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of workflow definition representations to return in this page.
sortBy
(query)
string
Optional sort criteria. Revision collections are sorted by default in reverse chronological order (most recent revision first). See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/workflows/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "workflows",
  "_links": {
    "self": {
      "href": "/workflow/workflows?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/workflows?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/workflows?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/workflows"
    }
  },
  "_embedded": {
    "items": [
      {
        "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
        "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
        "_links": {
          "self": {
            "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
          }
        },
        "name": "newAccountSelector",
        "domain": "https://api.apiture.com/acctApps",
        "label": "New Account Selector",
        "type": "somethingElse",
        "visibility": "hidden",
        "state": "pending",
        "values": {
          "category": "personal",
          "ownership": "joint",
          "minimumBalanceGoal": 1000
        },
        "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
        "_embedded": {}
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: workflows
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createWorkflowDefinitionRevision

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new workflow definition revision

POST /workflowDefinitions/{workflowDefinitionId}/revisions

Create a new immutable revision of this workflow definition. The revision is a snapshot of the content of the definition. This operation has no request body. The response body is the representation of the new revision. It is recommended to update the workflow definition's revisionLabel before calling this operation. This operation is ignored (it returns 204 No Content) if the workflow definition has not changed since the last time the revision was created. Creating a revision does not alter the entity tag of the workflow definition.

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
revisionPolicy
(query)
string
The revisionPolicy property determines how task definitions reference by this workflow definition are processed when creating a workflow definition revision.

If revisionPolicy is none, then the task definitions referenced by this workflow definition are copied directly to the new workflow definition revision. With this policy, when instantiating a new workflow W from the new workflow definitions revision, W will use the revisionless task definitions, unless the workflow definition already specifies an explict task definition revisionless.

If revisionPolicy is taskRevisions (the default), then the new revision will explicitly link to (and optionally create) the latest revisions of any task definitions embedded within this workflow definition, even if the workflow definition refers to revisionless task definitions. This effectively "snapshots" both the workflow definition and the task definitions in one operation. For example, if the workflow embeds task definitions A and B and C such that:

then creating new workflow definition revision with ?taskRevisions=true will first create a task definition revision for C (2018-10-30T13:30:30.300Z) and the new workflow definition revision will embed the existing revision 2018-10-10T10:10:10.10Z of A, the existing revision 2018-10-20T20:20:20.000Z of B, and the new revision 2018-10-30T13:30:30.300Z of C.
Enumerated values:
none
taskRevisions|

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
201 Created
OK. A new revision was created.
Schema: workflow
204 No Content
No Content. The resource has not changed since the last revision was created, and a new revision has not been created.

Response Headers

StatusDescription
201 Location string uri
The URI of the new revision. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag for the revision. This entity tag may be passed as the If-Not-Match on a GET request for the revision location. (This is not the entity tag of the mutable definition resource.)

getWorkflowDefinitionRevision

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of an immutable revision of this workflow definition

GET /workflowDefinitions/{workflowDefinitionId}/revisions/{revisionId}

Return an immutable HAL representation of this revision of this workflow definition resource. The revision may also have prev and next links to previous and/or next revisions, if they exist.

Parameters

Parameter Description
workflowDefinitionId
(path)
string (required)
The unique identifier of this workflow definition. This is an opaque string.
revisionId
(path)
string (required)
The identifier for a revision of this resource. Revision identifiers use RFC 3339 format: YYYY-MM-DDThh:mm:ss.sssZ.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow definition resource.

Workflow

Workflows

getWorkflows

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflows \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflows HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflows',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflows', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of workflows

GET /workflows

Return a paginated sortable filterable searchable collection of workflows. The links in the response include pagination links.

Parameters

Parameter Description
start
(query)
integer(int64)
The zero-based index of the first workflow item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of workflow representations to return in this page.
sortBy
(query)
string
Optional sort criteria. See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.
state
(query)
string
Subset the accounts or external accounts collection to those whose state matches this value. Use | to separate multiple values. For example, ?state=pending will match only items whose state is pending; ?state=removed|inactive will match items whose state is removed or inactive. This is combined with an implicit and with other filters if they are used. See filtering.
Enumerated values:
pending
definition
blocked
removed
running
paused
completed
failed
canceled
name
(query)
string
Subset the accounts or external accounts collection to those with this name value. Use
domain
(query)
string
Subset the accounts or external accounts collection to those with this domain value. Use
type
(query)
string
Subset the accounts or external accounts collection to those with this exact type value. Use
label
(query)
string
Subset the accounts or external accounts collection to those with this label value. Use

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/workflows/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "workflows",
  "_links": {
    "self": {
      "href": "/workflow/workflows?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/workflows?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/workflows?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/workflows"
    }
  },
  "_embedded": {
    "items": [
      {
        "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
        "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
        "_links": {
          "self": {
            "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
          }
        },
        "name": "newAccountSelector",
        "domain": "https://api.apiture.com/acctApps",
        "label": "New Account Selector",
        "type": "somethingElse",
        "visibility": "hidden",
        "state": "pending",
        "values": {
          "category": "personal",
          "ownership": "joint",
          "minimumBalanceGoal": 1000
        },
        "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
        "_embedded": {}
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: workflows
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createWorkflow

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/workflows \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/workflows HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "apiture:application": {
      "href": "/accountApplications/applications/2f23b9fe-532f-4e82-943e-b079ea55aebc"
    }
  },
  "name": "newAccountSelector",
  "label": "New Account Selector",
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/workflows',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/workflows', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/workflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new workflow

POST /workflows

Create a new workflow instance from a workflow definition.

The workflow is started automatically upon creation; and initial tasks (those with no input dependencies) will be started. Thus, the state of the new workflow may be running or blocked depending on the initial tasks.

Body parameter

{
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "apiture:application": {
      "href": "/accountApplications/applications/2f23b9fe-532f-4e82-943e-b079ea55aebc"
    }
  },
  "name": "newAccountSelector",
  "label": "New Account Selector",
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Parameters

Parameter Description
definition
(query)
string
A server-supplied value which identifies the workflow definition instance from which this new workflow will be created. The request body is ignored when this parameter is used.
body
(body)
createWorkflow (required)
The data necessary to create a new workflow.

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
201 Created
Created
Schema: workflow
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such workflow definition resource at the specified URL. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
201 Location string uri
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update the resource.

getWorkflow

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflows/{workflowId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflows/{workflowId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflows/{workflowId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of this workflow

GET /workflows/{workflowId}

Return a HAL representation of this workflow resource.

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.
embed
(query)
string
The resources to embed within the _embedded object. This is a comma separated list which can include any of the following options:

tasks will be embedded by default even if no embed query parameters are specified. |

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

patchWorkflow

Code samples

# You can also use wget
curl -X PATCH https://api.devbank.apiture.com/workflow/workflows/{workflowId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.devbank.apiture.com/workflow/workflows/{workflowId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this workflow

PATCH /workflows/{workflowId}

Perform a partial update of this workflow. Fields which are omitted are not updated. Nested _embedded and _links are ignored if included. This operation may not change the workflow's set of tasks or the task dependencies.

NOTE This operation is deprecated. Most fields of a workflow instance are immutable or derived. Use the updateWorkflowValues (PUT /workflows/{workflowId}/values) operation to update the values in a workflow.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateWorkflow (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

deleteWorkflow

Code samples

# You can also use wget
curl -X DELETE https://api.devbank.apiture.com/workflow/workflows/{workflowId} \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

DELETE https://api.devbank.apiture.com/workflow/workflows/{workflowId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.delete 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.delete('https://api.devbank.apiture.com/workflow/workflows/{workflowId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Delete this workflow resource

DELETE /workflows/{workflowId}

Delete this workflow resource and any resources that are owned by it.

Parameters

Parameter Description
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.

Example responses

412 Response

{
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": {},
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  }
}

Responses

StatusDescription
204 No Content
No Content. The resource was deleted successfully.
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

getVisibleTasks

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}/visibleTasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch an ordered representation of the visible tasks within this workflow

GET /workflows/{workflowId}/visibleTasks

Return a collection of visible tasks for the given workflow. The result reflects the nested structure of the workflow and any tasks that are embedded inside nested workflows.

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "name": "visibleTasks",
  "_embedded": {
    "items": [
      {
        "_id": "4c44d065-1f4c-4bf8-b76d-d0514cd2acff",
        "domain": "http:/api.apiture.com/domains/accountApplication",
        "name": "userInfoForm",
        "description": "User Info Form",
        "label": "User Profile Information",
        "state": "completed",
        "done": true,
        "type": "form",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": true,
        "_links": {
          "self": {
            "href": "/workflow/tasks/4c44d065-1f4c-4bf8-b76d-d0514cd2acff"
          }
        }
      },
      {
        "_id": "32e4a075-bd33-43ee-a50a-ca499bbf3c6e",
        "domain": "http:/api.apiture.com/domains/identityVerification",
        "name": "idVerification",
        "description": "Identity Verification",
        "label": "Identity Verification",
        "state": "running",
        "done": false,
        "type": "workflow",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": false,
        "_links": {
          "self": {
            "href": "/workflow/tasks/32e4a075-bd33-43ee-a50a-ca499bbf3c6e"
          }
        },
        "subTasks": [
          {
            "_id": "5ce72b5c-361f-4ba2-b0a5-92f7e18764bd",
            "domain": "http:/api.apiture.com/domains/identityVerification",
            "name": "idQuiz",
            "label": "Identity Quiz",
            "description": "Identity Quiz",
            "state": "pending",
            "done": false,
            "type": "rest",
            "initial": false,
            "terminal": false,
            "visibility": "visible",
            "mode": "interactive",
            "restartable": false,
            "_links": {
              "self": {
                "href": "/workflow/tasks/5ce72b5c-361f-4ba2-b0a5-92f7e18764bd"
              }
            }
          }
        ]
      },
      {
        "_id": "4386bdee-ffe4-47ac-b313-87fd735be9ea",
        "domain": "http:/api.apiture.com/domains/accountApplication",
        "name": "selectFundingAccount",
        "label": "Select Funding Account",
        "description": "Select Funding Account",
        "state": "blocked",
        "done": false,
        "type": "form",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": true,
        "_links": {
          "self": {
            "href": "/workflow/tasks/4386bdee-ffe4-47ac-b313-87fd735be9ea"
          }
        }
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: visibleTasks
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

getWorkflowValues

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch the runtime values associated with this workflow

GET /workflows/{workflowId}/values

Fetch the runtime values associated with this workflow. This provides convenient access to the map of values of the workflow, including the inputs and outputs. This map does not include the tasks and their values, or values from nested workflows; it only contains values defined in the workflow's schema.

Use the PUT /workflows/{workflowId}/values operation to update the values, or to update a specific value, use PUT /workflows/{workflowId}/values/{valueName}.

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

updateWorkflowValues

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update the runtime values associated with this workflow

PUT /workflows/{workflowId}/values

Update the runtime values associated with this workflow. This provides convenient access to the map of values of the workflow, inlcuding the inputs and outputs. This map does not include the tasks and their values, or values from nested workflows; it only contains values defined in the workflow's schema. This operation is idempotent. The request body must include all values obtained from the GET operation, and the values must conform to the workflow's schema.

To update a specific value, use PUT /workflows/{workflowId}/values/{valueName}.

Body parameter

{}

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
body
(body)
attributes (required)

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

getWorkflowValue

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName} \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a single runtime value associated with this workflow

GET /workflows/{workflowId}/values/{valueName}

Fetch a single runtime value associated with this workflow. This provides convenient access to the map of values of the workflow, including the inputs and outputs. This map does not include the tasks and their values, or values from nested workflows; it only contains values defined in the workflow's schema.

To update a specific value, use PUT /workflows/{workflowId}/values/{valueName} (operation updateWorkflowValue).

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
valueName
(path)
string (required)
The unique identifier of a value in a workflow item. This is the name of the value in the schema. A {valueName} must be a simple identifier following the pattern letter [letter | digit | '-' | '_']*

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
404 Not Found
Not Found. There is no such workflow resource at the specified {workflowId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

updateWorkflowValue

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/workflows/{workflowId}/values/{valueName}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update a single runtime value associated with this workflow

PUT /workflows/{workflowId}/values/{valueName}

Update a single runtime value associated with this workflow. This provides convenient access to individual values of the workflow as defined in the workflow's schema. The request body must conform to the workflow's schema for the named {valueName}. This operation is idempotent.

Body parameter

{}

Parameters

Parameter Description
workflowId
(path)
string (required)
The unique identifier of this workflow. This is an opaque string.
valueName
(path)
string (required)
The unique identifier of a value in a workflow item. This is the name of the value in the schema. A {valueName} must be a simple identifier following the pattern letter [letter | digit | '-' | '_']*
body
(body)
attributes (required)

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow resource.

startWorkflow

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/runningWorkflows?workflow=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/runningWorkflows?workflow=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/runningWorkflows',
  method: 'post',
  data: '?workflow=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/runningWorkflows?workflow=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/runningWorkflows',
  params: {
  'workflow' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/runningWorkflows', params={
  'workflow': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/runningWorkflows?workflow=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/runningWorkflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Start, restart, or resume a workflow

POST /runningWorkflows

Change the state of a workflow to running. This is allowed if the state is paused. If the workflow is restartable, this is also allowed if the state is failed, completed, or canceled. There is no request body on this operation; the task is passed as a query parameter, ?workflow=. This operation is invoked from the apiture:start link on a workflow; the link is present if the operation is allowed. This operation is not allowed on a workflow definition.

Parameters

Parameter Description
workflow
(query)
string (required)
A server-supplied value which identifies the workflow instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow

pauseWorkflow

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/pausedWorkflows?workflow=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/pausedWorkflows?workflow=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/pausedWorkflows',
  method: 'post',
  data: '?workflow=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/pausedWorkflows?workflow=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/pausedWorkflows',
  params: {
  'workflow' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/pausedWorkflows', params={
  'workflow': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/pausedWorkflows?workflow=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/pausedWorkflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Pause a workflow

POST /pausedWorkflows

Change the state of a workflow to paused. This is allowed if the state is running. There is no request body on this operation; the task is passed as a query parameter, ?workflow=. This operation is invoked from the apiture:pause link on a workflow; the link is present if the operation is allowed. This operation will also pause all running tasks in the workflow. This operation is not allowed on a workflow definition.

Parameters

Parameter Description
workflow
(query)
string (required)
A server-supplied value which identifies the workflow instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow

cancelWorkflow

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/canceledWorkflows?workflow=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/canceledWorkflows?workflow=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/canceledWorkflows',
  method: 'post',
  data: '?workflow=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/canceledWorkflows?workflow=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/canceledWorkflows',
  params: {
  'workflow' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/canceledWorkflows', params={
  'workflow': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/canceledWorkflows?workflow=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/canceledWorkflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Cancel a workflow

POST /canceledWorkflows

Change the state of a workflow to canceled. This is allowed if the state is running or paused. There is no request body on this operation; the task is passed as a query parameter, ?workflow=. This operation is invoked from the apiture:cancel link on a workflow; the link is present if the operation is allowed. This operation will also cancel all running or paused tasks in the workflow. This operation is not allowed on a workflow definition.

Parameters

Parameter Description
workflow
(query)
string (required)
A server-supplied value which identifies the workflow instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow

failWorkflow

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/failedWorkflows?workflow=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/failedWorkflows?workflow=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/failedWorkflows',
  method: 'post',
  data: '?workflow=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/failedWorkflows?workflow=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/failedWorkflows',
  params: {
  'workflow' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/failedWorkflows', params={
  'workflow': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/failedWorkflows?workflow=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/failedWorkflows", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Stop a workflow and mark it as failed

POST /failedWorkflows

Change the state of a workflow to failed. This is allowed if the state is running or paused. There is no request body on this operation; the task is passed as a query parameter, ?workflow=. This operation is invoked from the apiture:fail link on a workflow; the link is present if the operation is allowed. This operation may also affect the state of the workflow in which the task instance resides.

This operation is not allowed on a workflow definition.

Parameters

Parameter Description
workflow
(query)
string (required)
A server-supplied value which identifies the workflow instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Responses

StatusDescription
200 OK
OK
Schema: workflow

Task Definition

Workflow Task Definitions

getTaskDefinitions

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/taskDefinitions \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/taskDefinitions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/taskDefinitions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/taskDefinitions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/taskDefinitions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of task definitions

GET /taskDefinitions

Return a paginated sortable filterable searchable collection of task definitions. The links in the response include pagination links.

Parameters

Parameter Description
start
(query)
integer(int64)
The zero-based index of the first task definition item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of task definition representations to return in this page.
sortBy
(query)
string
Optional sort criteria. See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.
state
(query)
string
Subset the accounts or external accounts collection to those whose state matches this value. Use | to separate multiple values. For example, ?state=pending will match only items whose state is pending; ?state=removed|inactive will match items whose state is removed or inactive. This is combined with an implicit and with other filters if they are used. See filtering.
Enumerated values:
pending
definition
blocked
removed
running
paused
completed
failed
canceled
name
(query)
string
Subset the accounts or external accounts collection to those with this name value. Use
domain
(query)
string
Subset the accounts or external accounts collection to those with this domain value. Use
type
(query)
string
Subset the accounts or external accounts collection to those with this exact type value. Use
label
(query)
string
Subset the accounts or external accounts collection to those with this label value. Use

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "tasks",
  "_links": {
    "self": {
      "href": "/workflow/tasks?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/tasks?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/tasks?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/tasks"
    }
  },
  "_embedded": {
    "items": [
      {
        "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountCategoryChoice",
        "label": "Account Category Choice",
        "type": "staticChoice",
        "state": "blocked",
        "done": false,
        "mode": "interactive",
        "restartable": true,
        "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)"
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: tasks
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createTaskDefinition

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/taskDefinitions \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/taskDefinitions HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
  "name": "accountCategoryChoice",
  "label": "Account Category Choice",
  "type": "staticChoice",
  "state": "blocked",
  "mode": "interactive",
  "restartable": true,
  "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "imageUri": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choices": {
      "value": [
        {
          "id": "savings",
          "label": "Savings",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/savings.png"
        },
        {
          "id": "checking",
          "label": "Checking",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/checking.png"
        }
      ]
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/taskDefinitions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/taskDefinitions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/taskDefinitions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new task definition

POST /taskDefinitions

Create a new task definition in the task definitions collection. The state of the new task will be set to definition.

Body parameter

{
  "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
  "name": "accountCategoryChoice",
  "label": "Account Category Choice",
  "type": "staticChoice",
  "state": "blocked",
  "mode": "interactive",
  "restartable": true,
  "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "imageUri": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choices": {
      "value": [
        {
          "id": "savings",
          "label": "Savings",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/savings.png"
        },
        {
          "id": "checking",
          "label": "Checking",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/checking.png"
        }
      ]
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  }
}

Parameters

Parameter Description
body
(body)
createTask (required)
The data necessary to create a new task definition.

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
201 Created
Created
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
201 Location string uri
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update the resource.

getTaskDefinition

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of this task definition

GET /taskDefinitions/{taskDefinitionId}

Return a HAL representation of this task definition resource. This resource is referred to as the revisionless task definition, in contrast to the explicit revision at /taskDefinitions/{taskDefinitionId}/revisions/{revisionId}.

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such task definition resource at the specified {taskDefinitionId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task definition resource.

updateTaskDefinition

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this task definition

PUT /taskDefinitions/{taskDefinitionId}

Perform a complete replacement of this task definition.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateTask (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such task definition resource at the specified {taskDefinitionId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task definition resource.

patchTaskDefinition

Code samples

# You can also use wget
curl -X PATCH https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this task definition

PATCH /taskDefinitions/{taskDefinitionId}

Perform a partial update of this task definition. Fields which are omitted are not updated. Nested _embedded and _links are ignored if included.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateTask (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such task definition resource at the specified {taskDefinitionId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task definition resource.

deleteTaskDefinition

Code samples

# You can also use wget
curl -X DELETE https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

DELETE https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.delete 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.delete('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Delete this task definition resource

DELETE /taskDefinitions/{taskDefinitionId}

Delete this task definition resource and any resources that are owned by it. The task definition may not be deleted if it or any of its revisions are in use by any tasks or workflows. Deleting a task definition also deletes all revisions.

Parameters

Parameter Description
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.

Example responses

400 Response

{
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": {},
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  }
}

Responses

StatusDescription
204 No Content
No Content. The resource was deleted successfully.
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

getTaskDefinitionRevisions

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of workflow task definition revisions

GET /taskDefinitions/{taskDefinitionId}/revisions

Return a paginated sortable filterable searchable collection of workflow task revisions. The links in the response include pagination links. The revisions collection shows the modification history of the workflow task defintion. Revisions are immutable.

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
start
(query)
integer(int64)
The zero-based index of the first workflow task revision item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of workflow task representations to return in this page.
sortBy
(query)
string
Optional sort criteria. Revision collections are sorted by default in reverse chronological order (most recent revision first). See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "tasks",
  "_links": {
    "self": {
      "href": "/workflow/tasks?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/tasks?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/tasks?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/tasks"
    }
  },
  "_embedded": {
    "items": [
      {
        "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountCategoryChoice",
        "label": "Account Category Choice",
        "type": "staticChoice",
        "state": "blocked",
        "done": false,
        "mode": "interactive",
        "restartable": true,
        "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)"
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: tasks
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createTaskDefinitionRevision

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new task definition revision

POST /taskDefinitions/{taskDefinitionId}/revisions

Create a new immutable revision of this workflow task definition. The revision is a snapshot of the content of the definition. This operation has no request body. The response body is the representation of the new revision. This operation is ignored if the task definition has not changed since the last time the revision was created. Creating a revision does not alter the entity tag of the task definition.

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
201 Created
OK. A new revision was created.
Schema: task
204 No Content
No Content. The resource has not changed since the last revision was created, and a new revision has not been created.

Response Headers

StatusDescription
201 Location string uri
The URI of the new revision. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag for the revision. This entity tag may be passed as the If-Not-Match on a GET request for the revision location. (This is not the entity tag of the mutable definition resource.)

getTaskDefinitionRevision

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/taskDefinitions/{taskDefinitionId}/revisions/{revisionId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of an immutable revision of this workflow task

GET /taskDefinitions/{taskDefinitionId}/revisions/{revisionId}

Return an immutable HAL representation of this revision of this workflow task resource. The revision may also have prev and next links to previous and/or next revisions, if they exist.

Parameters

Parameter Description
taskDefinitionId
(path)
string (required)
The unique identifier of this task definition. This is an opaque string.
revisionId
(path)
string (required)
The identifier for a revision of this resource. Revision identifiers use RFC 3339 format: YYYY-MM-DDThh:mm:ss.sssZ.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this workflow task resource.

Task

Workflow Tasks

getTasks

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/tasks \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/tasks HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/tasks',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/tasks', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/tasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of tasks

GET /tasks

Return a paginated sortable filterable searchable collection of tasks. The links in the response include pagination links.

Parameters

Parameter Description
start
(query)
integer(int64)
The zero-based index of the first task item to include in this page. The default 0 denotes the beginning of the collection.
limit
(query)
integer(int32)
The maximum number of task representations to return in this page.
sortBy
(query)
string
Optional sort criteria. See sort criteria format, such as ?sortBy=field1,-field2.
filter
(query)
string
Optional filter criteria. See filtering.
q
(query)
string
Optional search string. See searching.
state
(query)
string
Subset the accounts or external accounts collection to those whose state matches this value. Use | to separate multiple values. For example, ?state=pending will match only items whose state is pending; ?state=removed|inactive will match items whose state is removed or inactive. This is combined with an implicit and with other filters if they are used. See filtering.
Enumerated values:
pending
definition
blocked
removed
running
paused
completed
failed
canceled
name
(query)
string
Subset the accounts or external accounts collection to those with this name value. Use
domain
(query)
string
Subset the accounts or external accounts collection to those with this domain value. Use
type
(query)
string
Subset the accounts or external accounts collection to those with this exact type value. Use
label
(query)
string
Subset the accounts or external accounts collection to those with this label value. Use

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "tasks",
  "_links": {
    "self": {
      "href": "/workflow/tasks?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/tasks?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/tasks?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/tasks"
    }
  },
  "_embedded": {
    "items": [
      {
        "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountCategoryChoice",
        "label": "Account Category Choice",
        "type": "staticChoice",
        "state": "blocked",
        "done": false,
        "mode": "interactive",
        "restartable": true,
        "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)"
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: tasks
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

createTask

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/tasks \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/tasks HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
  "name": "accountCategoryChoice",
  "label": "Account Category Choice",
  "type": "staticChoice",
  "state": "blocked",
  "mode": "interactive",
  "restartable": true,
  "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "imageUri": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choices": {
      "value": [
        {
          "id": "savings",
          "label": "Savings",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/savings.png"
        },
        {
          "id": "checking",
          "label": "Checking",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/checking.png"
        }
      ]
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/tasks',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/tasks', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/tasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Create a new task

POST /tasks

Create a new task in the tasks collection.

Body parameter

{
  "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
  "name": "accountCategoryChoice",
  "label": "Account Category Choice",
  "type": "staticChoice",
  "state": "blocked",
  "mode": "interactive",
  "restartable": true,
  "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "imageUri": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choices": {
      "value": [
        {
          "id": "savings",
          "label": "Savings",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/savings.png"
        },
        {
          "id": "checking",
          "label": "Checking",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/checking.png"
        }
      ]
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  }
}

Parameters

Parameter Description
definition
(query)
string
A server-supplied value which identifies the task definition instance from which this new task will be created. The request body is ignored when this parameter is used.
body
(body)
createTask (required)
The data necessary to create a new task.

Example responses

201 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
201 Created
Created
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
201 Location string uri
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme://host
201 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update the resource.

getTask

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/tasks/{taskId} \
  -H 'Accept: application/hal+json' \
  -H 'If-None-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/tasks/{taskId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-None-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-None-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-None-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-None-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/tasks/{taskId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-None-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/tasks/{taskId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a representation of this task

GET /tasks/{taskId}

Return a HAL representation of this task resource.

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
If-None-Match
(header)
string
The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET will return 304 (Not Modified) and no response body, else the resource representation will be returned.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
304 Not Modified
Not Modified. The resource has not been modified since it was last fetched.
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

updateTask

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/tasks/{taskId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/tasks/{taskId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/tasks/{taskId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/tasks/{taskId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this task

PUT /tasks/{taskId}

Perform a complete replacement of this task.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateTask (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

patchTask

Code samples

# You can also use wget
curl -X PATCH https://api.devbank.apiture.com/workflow/tasks/{taskId} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.devbank.apiture.com/workflow/tasks/{taskId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json
If-Match: string

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.devbank.apiture.com/workflow/tasks/{taskId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.devbank.apiture.com/workflow/tasks/{taskId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update this task

PATCH /tasks/{taskId}

Perform a partial update of this task. Fields which are omitted are not updated. Nested _embedded and _links are ignored if included.

NOTE This operation is deprecated. Most fields of a task instance are immutable or derived. Use the updateTaskValues (PUT /tasks/{taskId}/values) operation to update the values in a task.

Body parameter

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
body
(body)
updateTask (required)

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

deleteTask

Code samples

# You can also use wget
curl -X DELETE https://api.devbank.apiture.com/workflow/tasks/{taskId} \
  -H 'Accept: application/hal+json' \
  -H 'If-Match: string' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

DELETE https://api.devbank.apiture.com/workflow/tasks/{taskId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
If-Match: string

var headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'If-Match':'string',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'If-Match' => 'string',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.delete 'https://api.devbank.apiture.com/workflow/tasks/{taskId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'If-Match': 'string',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.delete('https://api.devbank.apiture.com/workflow/tasks/{taskId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "If-Match": []string{"string"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://api.devbank.apiture.com/workflow/tasks/{taskId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Delete this task resource

DELETE /tasks/{taskId}

Delete this task resource and any resources that are owned by it.

Parameters

Parameter Description
If-Match
(header)
string
The entity tag that was returned in the ETag response. This must match the current entity tag of the resource.
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.

Example responses

412 Response

{
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": {},
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  }
}

Responses

StatusDescription
204 No Content
No Content. The resource was deleted successfully.
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

getTaskValues

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/tasks/{taskId}/values \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/tasks/{taskId}/values HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}/values");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/tasks/{taskId}/values", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch the runtime values associated with this task

GET /tasks/{taskId}/values

Fetch the runtime values associated with this task. This provides convenient access to the map of values of the task, including the inputs and outputs.

Use the PUT /tasks/{taskId}/values operation to update the values, or to update a specific value, use PUT /tasks/{taskId}/values/{valueName}.

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

updateTaskValues

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/tasks/{taskId}/values \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/tasks/{taskId}/values HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}/values");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/tasks/{taskId}/values", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update the runtime values associated with this task

PUT /tasks/{taskId}/values

Update the runtime values associated with this task. This provides convenient access to the map of values of the task, inlcuding the inputs and outputs. This map only contains values defined in the tasks's schema. The request body must include all values obtained from the GET operation, and the values must conform to the tasks's schema. This operation is idempotent.

To update a specific value, use PUT /tasks/{taskId}/values/{valueName} (operation updateTaskValue).

Body parameter

{}

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
body
(body)
attributes (required)

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse
412 Precondition Failed
Precondition Failed. The supplied if-Match header value does not match the most recent ETag response header value. The resource has changed in the interim.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

getTaskValue

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName} \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Fetch a single runtime value associated with this task

GET /tasks/{taskId}/values/{valueName}

Fetch a single runtime value associated with this task. This provides convenient access to the map of values of the task, including the inputs and outputs. This map does not include the tasks and their values, or values from nested workflows; it only contains values defined in the tasks's schema.

To update a specific value, use PUT /tasks/{taskId}/values/{valueName} (operation updateTaskValue).

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
valueName
(path)
string (required)
The unique identifier of a value in a workflow item. This is the name of the value in the schema. A {valueName} must be a simple identifier following the pattern letter [letter | digit | '-' | '_']*

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline
404 Not Found
Not Found. There is no such task resource at the specified {taskId} The _error field in the response will contain details about the request error.
Schema: errorResponse

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

updateTaskValue

Code samples

# You can also use wget
curl -X PUT https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName} \
  -H 'Content-Type: application/hal+json' \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/hal+json
Accept: application/hal+json

var headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');
const inputBody = '{}';
const headers = {
  'Content-Type':'application/hal+json',
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/hal+json',
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/hal+json',
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/hal+json"},
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/workflow/tasks/{taskId}/values/{valueName}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Update the runtime values associated with this task

PUT /tasks/{taskId}/values/{valueName}

Update a single runtime value associated with this task. This provides convenient access to individual values of the task as defined in the tasks's schema. The request body must conform to the tasks's schema for the named {valueName}. This operation is idempotent.

To update a specific value, use PUT /workflows/{workflowId}/values/{valueName}.

Body parameter

{}

Parameters

Parameter Description
taskId
(path)
string (required)
The unique identifier of this task. This is an opaque string.
valueName
(path)
string (required)
The unique identifier of a value in a workflow item. This is the name of the value in the schema. A {valueName} must be a simple identifier following the pattern letter [letter | digit | '-' | '_']*
body
(body)
attributes (required)

Example responses

200 Response

{}

Responses

StatusDescription
200 OK
OK
Schema: Inline

Response Schema

Response Headers

StatusDescription
200 ETag string
The ETag response header specifies an entity tag which must be provided in an If-Match request header for PUT or PATCH operations which update this task resource.

startTask

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/runningTasks?task=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/runningTasks?task=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/runningTasks',
  method: 'post',
  data: '?task=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/runningTasks?task=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/runningTasks',
  params: {
  'task' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/runningTasks', params={
  'task': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/runningTasks?task=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/runningTasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Start, restart, or resume a workflow task

POST /runningTasks

Change the state of a workflow to running. This is allowed if the state is paused. If the task is restartable, this is also allowed if the state is failed, completed, or canceled. There is no request body on this operation; the task is passed as a query parameter, ?task=. This operation is invoked from the apiture:start link on a task; the link is present if the operation is allowed. This operation may also affect the state of the workflow in which the task instance resides. This operation is not allowed on a task definition.

Parameters

Parameter Description
task
(query)
string (required)
A server-supplied value which identifies the task instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task

pauseTask

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/pausedTasks?task=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/pausedTasks?task=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/pausedTasks',
  method: 'post',
  data: '?task=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/pausedTasks?task=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/pausedTasks',
  params: {
  'task' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/pausedTasks', params={
  'task': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/pausedTasks?task=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/pausedTasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Pause a workflow task

POST /pausedTasks

Change the state of a workflow to paused. This is allowed if the state is running. There is no request body on this operation; the task is passed as a query parameter, ?task=. This operation is invoked from the apiture:pause link on a task; the link is present if the operation is allowed. This operation may also affect the state of the workflow in which the task instance resides.

This operation is not allowed on a task definition.

Parameters

Parameter Description
task
(query)
string (required)
A server-supplied value which identifies the task instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task

cancelTask

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/canceledTasks?task=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/canceledTasks?task=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/canceledTasks',
  method: 'post',
  data: '?task=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/canceledTasks?task=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/canceledTasks',
  params: {
  'task' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/canceledTasks', params={
  'task': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/canceledTasks?task=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/canceledTasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Cancel a workflow task

POST /canceledTasks

Change the state of a workflow to canceled. This is allowed if the state is running or paused. There is no request body on this operation; the task is passed as a query parameter, ?task=. This operation is invoked from the apiture:cancel link on a task; the link is present if the operation is allowed. This operation may also affect the state of the workflow in which the task instance resides.

This operation is not allowed on a task definition.

Parameters

Parameter Description
task
(query)
string (required)
A server-supplied value which identifies the task instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task

failTask

Code samples

# You can also use wget
curl -X POST https://api.devbank.apiture.com/workflow/failedTasks?task=string \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.devbank.apiture.com/workflow/failedTasks?task=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/failedTasks',
  method: 'post',
  data: '?task=string',
  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/failedTasks?task=string',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.devbank.apiture.com/workflow/failedTasks',
  params: {
  'task' => 'string'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.devbank.apiture.com/workflow/failedTasks', params={
  'task': 'string'
}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/failedTasks?task=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/workflow/failedTasks", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Stop a workflow task and mark it as failed

POST /failedTasks

Change the state of a workflow to failed. This is allowed if the state is running or paused. There is no request body on this operation; the task is passed as a query parameter, ?task=. This operation is invoked from the apiture:fail link on a task; the link is present if the operation is allowed. This operation may also affect the state of the workflow in which the task instance resides.

This operation is not allowed on a task definition.

Parameters

Parameter Description
task
(query)
string (required)
A server-supplied value which identifies the task instance.

Example responses

200 Response

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Responses

StatusDescription
200 OK
OK
Schema: task

Task Type

Workflow Task Types

getTaskTypes

Code samples

# You can also use wget
curl -X GET https://api.devbank.apiture.com/workflow/taskTypes \
  -H 'Accept: application/hal+json' \
  -H 'API-Key: API_KEY' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.devbank.apiture.com/workflow/taskTypes HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.devbank.apiture.com/workflow/taskTypes',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const fetch = require('node-fetch');

const headers = {
  'Accept':'application/hal+json',
  'API-Key':'API_KEY',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.devbank.apiture.com/workflow/taskTypes',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/hal+json',
  'API-Key' => 'API_KEY',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.devbank.apiture.com/workflow/taskTypes',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'API-Key': 'API_KEY',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.devbank.apiture.com/workflow/taskTypes', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.devbank.apiture.com/workflow/taskTypes");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/hal+json"},
        "API-Key": []string{"API_KEY"},
        "Authorization": []string{"Bearer {access-token}"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/workflow/taskTypes", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Return a collection of task types

GET /taskTypes

Return a collection of task types. This collection does not support pagination, sorting, or filtering.

Note: This operation is deprecated and will be removed before this service is released. The operation will become part of the service configuration, which is pending design and implementation.

Example responses

200 Response

{
  "_profile": "https://api.apiture.com/schemas/workflow/taskTypes/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "taskTypes",
  "_embedded": {
    "items": [
      {
        "name": "choice",
        "label": "Choice",
        "description": "The Choice task type represents tasks which present a static choice to to the end user.",
        "_links": {
          "self": {
            "href": "/workflow/taskTypes/choice"
          }
        }
      }
    ]
  }
}

Responses

StatusDescription
200 OK
OK
Schema: taskTypes
400 Bad Request
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response will contain details about the request error.
Schema: errorResponse
422 Unprocessable Entity
Unprocessable Entity. One or more of the query parameters was well formed but otherwise invalid. The _error field in the response will contain details about the request error.
Schema: errorResponse

Schemas

flowItemSummary

{
  "_links": {
    "property1": {
      "href": "http://example.com",
      "type": "string",
      "templated": true,
      "title": "string",
      "deprecation": "http://example.com",
      "profile": "http://example.com"
    },
    "property2": {
      "href": "http://example.com",
      "type": "string",
      "templated": true,
      "title": "string",
      "deprecation": "http://example.com",
      "profile": "http://example.com"
    }
  },
  "_embedded": {},
  "_profile": "http://example.com",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": "2018-01-25T05:50:52.375Z",
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  },
  "effectiveStartAt": "2019-09-09T17:04:53Z",
  "effectiveEndAt": "2019-09-09T17:04:53Z",
  "name": "acceptTermsAndConditions",
  "domain": "https://api.apiture.com/acctApps",
  "label": "Accept Terms and Conditions",
  "description": "Present the _Terms and Conditions_ to the user; they must actively accept the content for this tsask to complete successfully.",
  "instructions": "Please read the _Terms and Conditions_ below and signifiy that you accept them by checking the box. You must accept the terms and conditions in order to continue.",
  "revisionLabel": "Use Terms and Conditions 1.0.4 as of 2018-09-25",
  "done": false,
  "restartable": false,
  "restartableRule": "start.state === 'completed' && end.state === 'blocked'",
  "maxRestartCount": 3,
  "restartCount": 3,
  "includeInTaskSequence": true,
  "state": "definition"
}

Flow Item

This schema defines core properties shared between workflow and task summary represenations. It is used to define other model schemas for this API and is not used on its own to describe request and response bodies.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

revisionEffectiveInterval

{
  "effectiveStartAt": "2019-09-09T17:04:53Z",
  "effectiveEndAt": "2019-09-09T17:04:53Z"
}

Revision Effective Time Interval

Time interval when a resource revision was active. This schema is used when composing other schemas.

Note: This schema should be moved to common-models.

Properties

NameDescription
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.

flowItem

{
  "_links": {
    "property1": {
      "href": "http://example.com",
      "type": "string",
      "templated": true,
      "title": "string",
      "deprecation": "http://example.com",
      "profile": "http://example.com"
    },
    "property2": {
      "href": "http://example.com",
      "type": "string",
      "templated": true,
      "title": "string",
      "deprecation": "http://example.com",
      "profile": "http://example.com"
    }
  },
  "_embedded": {},
  "_profile": "http://example.com",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": "2018-01-25T05:50:52.375Z",
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  },
  "effectiveStartAt": "2019-09-09T17:04:53Z",
  "effectiveEndAt": "2019-09-09T17:04:53Z",
  "name": "acceptTermsAndConditions",
  "domain": "https://api.apiture.com/acctApps",
  "label": "Accept Terms and Conditions",
  "description": "Present the _Terms and Conditions_ to the user; they must actively accept the content for this tsask to complete successfully.",
  "instructions": "Please read the _Terms and Conditions_ below and signifiy that you accept them by checking the box. You must accept the terms and conditions in order to continue.",
  "revisionLabel": "Use Terms and Conditions 1.0.4 as of 2018-09-25",
  "done": false,
  "restartable": false,
  "restartableRule": "start.state === 'completed' && end.state === 'blocked'",
  "maxRestartCount": 3,
  "restartCount": 3,
  "includeInTaskSequence": true,
  "state": "definition",
  "schema": {},
  "interface": {
    "property1": {
      "input": null,
      "output": null,
      "required": null
    },
    "property2": {
      "input": null,
      "output": null,
      "required": null
    }
  },
  "values": null
}

Flow Item

This schema defines core properties shared between workflows and tasks. It is used to define other model schemas for this API and is not used on its own to describe request and response bodies.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

interface

{
  "input": null,
  "output": null,
  "required": null
}

Interface

Defines the input and output interface (subset of values) for a task or workflow.

Properties

NameDescription
input any
true if the variable is an input to the task or workflow.
output any
true if the variable is an output of the task or workflow.
required any
true if the input variable is required. For a task, the workflow must bind the task's required inputs to a value, such as one of the variables in the workflow, or to an output variable of another task. (The schema types must match for such assignments.)

createTask

{
  "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
  "name": "accountCategoryChoice",
  "label": "Account Category Choice",
  "type": "staticChoice",
  "state": "blocked",
  "mode": "interactive",
  "restartable": true,
  "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "imageUri": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choices": {
      "value": [
        {
          "id": "savings",
          "label": "Savings",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/savings.png"
        },
        {
          "id": "checking",
          "label": "Checking",
          "imageUri": "https://api.apiture.com/static/images/accountTypes/checking.png"
        }
      ]
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  }
}

Create Task Definition

Representation used to create a new task definition.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

type string
Describes the type of this task. This determines the behavior when the task is activated. Example task types are form (fill out a form), choice (select a value from a fixed set of choices), select (select one or more values from a dynamic set of choices), rest (perform a REST call), compute (compute output values based on the input values), workflow (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
initial boolean
Indicates if a task is an initial task A initial task is one which has no task dependencies and thus can never be blocked. Initial tasks are started automatically when the workflow is started.

This is a derived property.
read-only

terminal boolean
Indicates if a task is a terminal task A terminal task is one which no other task depends on. If a terminal state is reached (its entry criteria are satisfied), the workflow containing the task is also marked as completed or failed.

This is a derived property.
read-only

visibility any

The visibility of the task.

  • hidden: Presentation clients (UI) should not show this task to the end user.
  • visible: Presentation clients (UI) may show this task to the end user.
mode any

Describes the mode of this task.

  • interactive The task requires interaction witht the user, such as selecting a choice or filling out a form.
    • automatic The task runs without interaction once it's prerequisites are satisfied.


Enumerated values:
interactive
automatic

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

nestableTask

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Nestable Task Definition Summary

Summary representation of a task definition resource that contains an optional array of subtasks. This representation normally does not contain any _embedded objects. If needed, call the GET operation on the item's self link to get _embedded objects.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

type string
Describes the type of this task. This determines the behavior when the task is activated. Example task types are form (fill out a form), choice (select a value from a fixed set of choices), select (select one or more values from a dynamic set of choices), rest (perform a REST call), compute (compute output values based on the input values), workflow (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
initial boolean
Indicates if a task is an initial task A initial task is one which has no task dependencies and thus can never be blocked. Initial tasks are started automatically when the workflow is started.

This is a derived property.
read-only

terminal boolean
Indicates if a task is a terminal task A terminal task is one which no other task depends on. If a terminal state is reached (its entry criteria are satisfied), the workflow containing the task is also marked as completed or failed.

This is a derived property.
read-only

visibility any

The visibility of the task.

  • hidden: Presentation clients (UI) should not show this task to the end user.
  • visible: Presentation clients (UI) may show this task to the end user.
mode any

Describes the mode of this task.

  • interactive The task requires interaction witht the user, such as selecting a choice or filling out a form.
    • automatic The task runs without interaction once it's prerequisites are satisfied.


Enumerated values:
interactive
automatic

_id string
The unique identifier for this task definition resource. This is an immutable opaque string.
subtasks [nestableTask]
An optional array of summary task definitions. Subtasks appear on nested workflows (tasks of type: workflow).

summaryTask

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Task Definition Summary

Summary representation of a task definition resource in task definitions collections. This representation normally does not contain any _embedded objects. If needed, call the GET operation on the item's self link to get _embedded objects.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

type string
Describes the type of this task. This determines the behavior when the task is activated. Example task types are form (fill out a form), choice (select a value from a fixed set of choices), select (select one or more values from a dynamic set of choices), rest (perform a REST call), compute (compute output values based on the input values), workflow (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
initial boolean
Indicates if a task is an initial task A initial task is one which has no task dependencies and thus can never be blocked. Initial tasks are started automatically when the workflow is started.

This is a derived property.
read-only

terminal boolean
Indicates if a task is a terminal task A terminal task is one which no other task depends on. If a terminal state is reached (its entry criteria are satisfied), the workflow containing the task is also marked as completed or failed.

This is a derived property.
read-only

visibility any

The visibility of the task.

  • hidden: Presentation clients (UI) should not show this task to the end user.
  • visible: Presentation clients (UI) may show this task to the end user.
mode any

Describes the mode of this task.

  • interactive The task requires interaction witht the user, such as selecting a choice or filling out a form.
    • automatic The task runs without interaction once it's prerequisites are satisfied.


Enumerated values:
interactive
automatic

_id string
The unique identifier for this task definition resource. This is an immutable opaque string.

updateTask

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Update Workflow Task

Representation used to update or patch a task definition. Updates do not change the derived state field.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

type string
Describes the type of this task. This determines the behavior when the task is activated. Example task types are form (fill out a form), choice (select a value from a fixed set of choices), select (select one or more values from a dynamic set of choices), rest (perform a REST call), compute (compute output values based on the input values), workflow (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
initial boolean
Indicates if a task is an initial task A initial task is one which has no task dependencies and thus can never be blocked. Initial tasks are started automatically when the workflow is started.

This is a derived property.
read-only

terminal boolean
Indicates if a task is a terminal task A terminal task is one which no other task depends on. If a terminal state is reached (its entry criteria are satisfied), the workflow containing the task is also marked as completed or failed.

This is a derived property.
read-only

visibility any

The visibility of the task.

  • hidden: Presentation clients (UI) should not show this task to the end user.
  • visible: Presentation clients (UI) may show this task to the end user.
mode any

Describes the mode of this task.

  • interactive The task requires interaction witht the user, such as selecting a choice or filling out a form.
    • automatic The task runs without interaction once it's prerequisites are satisfied.


Enumerated values:
interactive
automatic

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

_id string
The unique identifier for this task resource. This is an immutable opaque string.

task

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_links": {
    "self": {
      "href": "/workflow/tasks/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:defintion": {
      "href": "/workflow/taskDefiniitions/99ced512-9c19-4c5d-8859-9c42cd4bcc7b"
    },
    "up": {
      "href": "/workflow/workflows/64802afe-d0a4-4680-b6fb-a0de98f3d871"
    },
    "apiture:cancel": {
      "href": "/canceledTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedTasks?task=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  }
}

Workflow Task

Representation of a task definition resource. A definition (template) for creating new tasks in workflows. A task instance (not a task definition) may have the following links:

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

type string
Describes the type of this task. This determines the behavior when the task is activated. Example task types are form (fill out a form), choice (select a value from a fixed set of choices), select (select one or more values from a dynamic set of choices), rest (perform a REST call), compute (compute output values based on the input values), workflow (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
initial boolean
Indicates if a task is an initial task A initial task is one which has no task dependencies and thus can never be blocked. Initial tasks are started automatically when the workflow is started.

This is a derived property.
read-only

terminal boolean
Indicates if a task is a terminal task A terminal task is one which no other task depends on. If a terminal state is reached (its entry criteria are satisfied), the workflow containing the task is also marked as completed or failed.

This is a derived property.
read-only

visibility any

The visibility of the task.

  • hidden: Presentation clients (UI) should not show this task to the end user.
  • visible: Presentation clients (UI) may show this task to the end user.
mode any

Describes the mode of this task.

  • interactive The task requires interaction witht the user, such as selecting a choice or filling out a form.
    • automatic The task runs without interaction once it's prerequisites are satisfied.


Enumerated values:
interactive
automatic

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

_id string
The unique identifier for this task resource. This is an immutable opaque string.

visibleTasks

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "name": "visibleTasks",
  "_embedded": {
    "items": [
      {
        "_id": "4c44d065-1f4c-4bf8-b76d-d0514cd2acff",
        "domain": "http:/api.apiture.com/domains/accountApplication",
        "name": "userInfoForm",
        "description": "User Info Form",
        "label": "User Profile Information",
        "state": "completed",
        "done": true,
        "type": "form",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": true,
        "_links": {
          "self": {
            "href": "/workflow/tasks/4c44d065-1f4c-4bf8-b76d-d0514cd2acff"
          }
        }
      },
      {
        "_id": "32e4a075-bd33-43ee-a50a-ca499bbf3c6e",
        "domain": "http:/api.apiture.com/domains/identityVerification",
        "name": "idVerification",
        "description": "Identity Verification",
        "label": "Identity Verification",
        "state": "running",
        "done": false,
        "type": "workflow",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": false,
        "_links": {
          "self": {
            "href": "/workflow/tasks/32e4a075-bd33-43ee-a50a-ca499bbf3c6e"
          }
        },
        "subTasks": [
          {
            "_id": "5ce72b5c-361f-4ba2-b0a5-92f7e18764bd",
            "domain": "http:/api.apiture.com/domains/identityVerification",
            "name": "idQuiz",
            "label": "Identity Quiz",
            "description": "Identity Quiz",
            "state": "pending",
            "done": false,
            "type": "rest",
            "initial": false,
            "terminal": false,
            "visibility": "visible",
            "mode": "interactive",
            "restartable": false,
            "_links": {
              "self": {
                "href": "/workflow/tasks/5ce72b5c-361f-4ba2-b0a5-92f7e18764bd"
              }
            }
          }
        ]
      },
      {
        "_id": "4386bdee-ffe4-47ac-b313-87fd735be9ea",
        "domain": "http:/api.apiture.com/domains/accountApplication",
        "name": "selectFundingAccount",
        "label": "Select Funding Account",
        "description": "Select Funding Account",
        "state": "blocked",
        "done": false,
        "type": "form",
        "initial": false,
        "terminal": false,
        "visibility": "visible",
        "mode": "interactive",
        "restartable": true,
        "_links": {
          "self": {
            "href": "/workflow/tasks/4386bdee-ffe4-47ac-b313-87fd735be9ea"
          }
        }
      }
    ]
  }
}

Visible Task Collection

Collection of visible tasks. The visibility of each task under _embedded.items will be visible. If any of the tasks are of type workflow, their visible tasks will be included as well, nested inside that workflow task's subTasks.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Embedded task objects.
» items [nestableTask]
An array containing all visible task items.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
count integer
The number of items in the full collection..
start integer
The start index of this page of items.
limit integer
The maximum number of items per page.
name string
The name of the collection.

tasks

{
  "_profile": "https://api.apiture.com/schemas/workflow/tasks/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "tasks",
  "_links": {
    "self": {
      "href": "/workflow/tasks?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/tasks?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/tasks?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/tasks"
    }
  },
  "_embedded": {
    "items": [
      {
        "_profile": "https://api.apiture.com/schemas/workflow/task/v1.0.0/profile.json",
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountCategoryChoice",
        "label": "Account Category Choice",
        "type": "staticChoice",
        "state": "blocked",
        "done": false,
        "mode": "interactive",
        "restartable": true,
        "description": "This workflow task presents a user choices representing a set of account types. The user selects one. (For this example, we assume that `staticChoice` is a defined task type for making a choice from a static list of values.)"
      }
    ]
  }
}

Task Collection

Collection of tasks. The items in the collection are ordered in the _embedded object with name items. The top-level _links object may contain pagination links (self, next, prev, first, last, collection) as well as the following:

* *`apiture:createTaskDefinition`* a POST operation to create a task definition using the `createTask` schema for the request.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Embedded task summary objects.
» items [summaryTask]
An array containing a page of task items.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
count integer
The number of items in the full collection..
start integer
The start index of this page of items.
limit integer
The maximum number of items per page.
name string
The name of the collection.

createWorkflow

{
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "apiture:application": {
      "href": "/accountApplications/applications/2f23b9fe-532f-4e82-943e-b079ea55aebc"
    }
  },
  "name": "newAccountSelector",
  "label": "New Account Selector",
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Create Workflow

Representation used to create a new workflow definition. A workflow consists of one or more tasks, with dependencies and constraints. Each task can depend on one or more other tasks, with an optional constraint predicate which must evaluate to true when the dependent tasks have completed (their completed field is true). The default constraint is that each dependent task has completed (its completed field is true, indicating it completed normally, it failed, or it was canceled). The account application should be passed as the apiture:application link in _links in the request. The values of each task in the workflows _embedded.tasks will also be available within the values of the workflow via the names in the tasks object. For example, if a workflow has tasks { 'a' : { ... task type c ... }, 'b' : { ... task type c ... }, ... } where tasks a and b both have values named x, y an z, these tasks will be available within the workflow's values as a and b and each of the tasks' values available via a.x, a.y, a.z, b.x, b.y and b.z, respectively. Thus, the schema and values from the workflow definition should not define any values whose name conflicts with the names in tasks. Note: When creating workflow definition, the _embedded objects should be task definitions.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Nested objects within a workflow definition. When creating a workflow definition, the nested tasks should be task or task summary representations from /taskDefinitions (i.e. the task state must be definition). These may be either revisionless task definitions or specific revisions of task definitions.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

dependencies object
The task dependency graph. This defines which tasks are prerequisite tasks for other task in the workflow. dependencies is a map structure. The key is the name of the task which depends on the others; the value is an array of dependency objects which define what named task depends on and what conditions must be met.
» additionalProperties [dependency]
[A dependency captures a workflow task dependency: each task within a workflow can depend on 0 or more other dependent tasks, creating a (possibly cyclic) dependency graph. Associated with each dependency is a _rule_: an optional constraint predicate expression which must evaluate to true in order for the task to start. The default constraint is that the dependent tasks all be completed (normal completion). A dependency object is the value associated with a task's name within a workflow's depenencies object.]
bindings [binding]
bindings connects input and output interface variables of the workflow and the workflow tasks.

When the workflow starts, all workflow and task variables are first assigned to any default values as per their respective interface and schema defaults. Next, workflow interface inputs are assigned to the inputs of any tasks as per these bindings. When a task starts, any bindings for its inputs are assigned as per these bindings. Each binding defines a source and one or more targets.

binding

{
  "source": "_.userProfile",
  "targets": [
    "userForm1.user",
    "jointUserForm1.spouse"
  ]
}

Variable Binding

Associates or binds a source variable to one or more target destinations.

Each source or target is a compound name, either .fieldName to refer to an variable in the workflow's values, or taskName.fieldName to refer to a variable in a task's values. The fieldName may in turn be a compound name if the value is an object type, or may include an array index if the value is an arrays.

For example, the binding { 'source' : '.userProfile', 'targets' : [ 'userForm1.user', 'jointUserForm1.spouse' ] } will initialize the value user in the userForm1 task with the workflow's userProfile value, and initialize the value spouse field in the jointUserForm1 task with the same value.

Properties

NameDescription
source string
The name of a value within the workflow's values (such as _.fieldName) or within a task's values (such as taskName.fieldName).
minLength: 3
maxLength: 256
targets [string]
The names of one or more values within the workflow (named _.fieldName) or within a task (named taskName.fieldName) which will be bound to or assigned the value of the source.
externalTargets [object]
External targets bind source variables to an external resource. For example, the external target { 'source' : 'userInformation.firstName', 'externalTargets' : [ { 'uri': '_.applicationUri', 'target': 'applicants[0].firstName'} ] } will update the resource located at the uri at applicationUri in the workflow's values and map the source value from the userInformation task values to the external resource's body { 'applicants': [{ 'firstName': 'mySourceValue' }] }
» uri string
The names of one or more values within the workflow (named _.fieldName) or within a task (named taskName.fieldName) which contains the uri of the external resource to bind to.
minLength: 3
maxLength: 256
» target string
The name of one or more properties on the external resource which will be assigned the value of the source. This is used to map the source value to the proper object structure of the external resource.
minLength: 3
maxLength: 256

dependency

{
  "dependents": [
    "string"
  ],
  "rule": "task1.state == 'completed' && task2.values.targetBalance < 1000"
}

task Dependency

A dependency captures a workflow task dependency: each task within a workflow can depend on 0 or more other dependent tasks, creating a (possibly cyclic) dependency graph. Associated with each dependency is a rule: an optional constraint predicate expression which must evaluate to true in order for the task to start. The default constraint is that the dependent tasks all be completed (normal completion). A dependency object is the value associated with a task's name within a workflow's depenencies object.

Properties

NameDescription
dependents [string]
The names of the tasks which must be done before this task can be run.
rule string
A business rule expression which must evaluate to true for this dependency to succeed. If any dependency constraint evaluates to false, the node's state becomes failed, and the workflow state may also become failed.

summaryWorkflow

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {}
}

Workflow Summary

Summary representation of a workflow resource in workflows collections. This representation normally does not contain any _embedded objects. If needed, call the GET operation on the item's self link to get _embedded objects.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

_id string
The unique identifier for this workflow resource. This is an immutable opaque string.

updateWorkflow

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "running",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Update Workflow

Representation used to update or patch a workflow. Updates do not change the derived state field.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Nested objects within a workflow definition. When creating a workflow definition, the nested tasks should be task or task summary representations from /taskDefinitions (i.e. the task state must be definition). These may be either revisionless task definitions or specific revisions of task definitions.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

dependencies object
The task dependency graph. This defines which tasks are prerequisite tasks for other task in the workflow. dependencies is a map structure. The key is the name of the task which depends on the others; the value is an array of dependency objects which define what named task depends on and what conditions must be met.
» additionalProperties [dependency]
[A dependency captures a workflow task dependency: each task within a workflow can depend on 0 or more other dependent tasks, creating a (possibly cyclic) dependency graph. Associated with each dependency is a _rule_: an optional constraint predicate expression which must evaluate to true in order for the task to start. The default constraint is that the dependent tasks all be completed (normal completion). A dependency object is the value associated with a task's name within a workflow's depenencies object.]
bindings [binding]
bindings connects input and output interface variables of the workflow and the workflow tasks.

When the workflow starts, all workflow and task variables are first assigned to any default values as per their respective interface and schema defaults. Next, workflow interface inputs are assigned to the inputs of any tasks as per these bindings. When a task starts, any bindings for its inputs are assigned as per these bindings. Each binding defines a source and one or more targets.

_id string
The unique identifier for this workflow resource. This is an immutable opaque string.

workflow

{
  "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
  "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
  "_links": {
    "self": {
      "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:cancel": {
      "href": "/canceledWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:fail": {
      "href": "/failedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    },
    "apiture:pause": {
      "href": "/pausedWorkflows?workflow=0399abed-fd3d-4830-a88b-30f38b8a365c"
    }
  },
  "name": "newAccountSelector",
  "domain": "https://api.apiture.com/acctApps",
  "label": "New Account Selector",
  "type": "somethingElse",
  "visibility": "hidden",
  "state": "blocked",
  "schema": {
    "category": {
      "type": "string",
      "description": "An account category",
      "enum": [
        "personal",
        "business"
      ]
    },
    "ownership": {
      "type": "string",
      "description": "How account ownership is shared",
      "enum": [
        "joint",
        "individual"
      ]
    },
    "minimumBalanceGoal": {
      "description": "The applicant's target minimum balance.",
      "type": "number",
      "example": 1000
    }
  },
  "interface": {
    "category": {
      "input": true,
      "output": false,
      "required": true
    },
    "ownership": {
      "input": true,
      "output": false,
      "required": true
    },
    "minimumBalanceGoal": {
      "input": true,
      "output": false,
      "value": 10000
    }
  },
  "values": {
    "category": "personal",
    "ownership": "joint",
    "minimumBalanceGoal": 1000
  },
  "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
  "_embedded": {
    "tasks": {
      "personalInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "label": "Personal Information",
        "type": "form",
        "_links": {
          "self": {
            "href": "/workflow/tasks/46913e8b-fb7f-4f31-92bf-7b263907ed95"
          }
        }
      },
      "accountOwnershipChoice": {
        "domain": "http:/api.apiture.com/domains/tasks/prompts",
        "name": "accountOwnershipChoice",
        "type": "binaryChoice",
        "label": "Select Account Ownership Type",
        "_links": {
          "self": {
            "href": "/workflow/tasks/3768afc0-1070-4372-b965-44f01cba70cb"
          }
        }
      },
      "jointOwnerInfoForm1": {
        "domain": "http:/api.apiture.com/domains/tasks/forms",
        "name": "userForm",
        "type": "form",
        "label": "Joint Owner Personal Information",
        "_links": {
          "self": {
            "href": "/workflow/tasks/cb898688-05d1-4ecd-8684-d67da617eafa"
          }
        }
      }
    }
  },
  "dependencies": {
    "jointOwnerInfoForm1": [
      {
        "dependents": [
          "accountOwnershipChoice"
        ],
        "rule": "accountOwnershipChoice.choice == 'joint'"
      }
    ],
    "accountOwnershipChoice": [
      {
        "dependents": [
          "personalInfoForm1"
        ]
      }
    ]
  },
  "bindings": [
    {
      "source": "_.userProfile",
      "targets": [
        "userForm1.user",
        "jointUserForm1.spouse"
      ]
    }
  ]
}

Workflow

Representation of a workflow resource. A workflow instance based on a workflow definition. A workflow instance (not a workflow definition) may have the following links:

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Nested objects within a workflow definition. When creating a workflow definition, the nested tasks should be task or task summary representations from /taskDefinitions (i.e. the task state must be definition). These may be either revisionless task definitions or specific revisions of task definitions.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
effectiveStartAt string(date-time)
The date-time when this revision was created and become effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable.
effectiveEndAt string(date-time)
The date-time when the another revision became effective and this revision ceased being effective. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This field is immutable and is not present until the revision is no longer active. If present in a PUT or PATCH, this date (not the current date-time) will be used for the revision ID and the effectiveStartAt of the next revision, but the date must be between the revision's effectiveStartAt and the current date-time.
name string
The name of this resource. The combination of domain and name must be unique within the set of all resources of this type.
minLength: 1
maxLength: 48
pattern: [a-zA-Z][-\w_]*
domain string
A namespace for grouping related resources, to keep them separate from other resources. For example, a department or bank branch may define a _domain_, and all tasks or workflow instances they define will use that domain, so that they can avoid conflicting with task or workflow names in other domains. An API or service may define a domain for workflows and tasks that it defines. The combination of domain and name must be unique within the set of all resources of this type. It is a best practice to define domains with URIs.
minLength: 1
maxLength: 512
label string
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string(markdown)
The full description for this resource, suitable for presentation in the tools for building/navigating the workflow. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
instructions string(markdown)
End-user instructions for this workflow item. The content is processed as Github Flavored Markdown and thus supports rich text.
minLength: 1
maxLength: 4096
revisionLabel string
The text label for the revision of this resource, suitable for presentation to the client. This is used to differentiate between differend revisons of the item. Clients should change this via the PATCH or PUT before creating the revision, since revisions are immutable and there is no way to change this label after the revision is created.
minLength: 1
maxLength: 128
done boolean
Indicates if a task or workflow has completed. (With the current set of state values, this is true when the state is one of completed or failed or canceled, although the set of states may change when new states are added.)
read-only
restartable boolean
Indicates if the workflow or task is restartable.
restartableRule string
An optional expression used in determining if the given task is restartable
minLength: 1
maxLength: 128
maxRestartCount integer
An optional limit on the amount of times that the given task can be restarted
restartCount integer
A running count of the amount of times that a given task has been restarted
includeInTaskSequence boolean
Can be used to include tasks in an optional task sequence object on the workflow. This object contains an ordered list of tasks that have been completed during the workflow. The UI may use this object to traverse the completed tasks.
read-only
state string

The state of a workflow or task.

  • definition - The workflow or task is a definition used to instatiate runnable workflows or tasks. Definitions may not be run. Tasks with this value may only be added to /taskDefinitions; workflows with this value may only be added to /workflowDefinitions.
  • pending - The workflow or task is available to be started (it is not blocked) but has not been started. Note: This state is currently not used, but in a future release, an option to the createWorkflow operation will allow creating workflows in the pending state instead of automatically starting them.
  • blocked - The workflow or task is waiting for the entry criteria to be satisfied. This could be one or more predecessor tasks are not completed, or the global criteria expression is not satisfied.
  • running - The workflow or task has started.
  • paused - The workflow or task has been paused. It may be resumed by setting the state back to running (via a POST to /runningTasks or /runningWorkflows)
  • completed - The workflow or task has completed successfully.
  • canceled - The workflow or task was canceled before completing.
  • failed - The workflow or task has failed with an error or other non-success criteria. The state is a derived value, maintained by the Workflow service. It is updated by the service or by operations on workflow instances or task instances such as the apiture:cancelWorkflow link found on a workflow.


Enumerated values:
definition
pending
blocked
running
paused
completed
failed
canceled

schema object
The schema which defines the name and types of the variables that are part of this task definition. Property names must be simple identifiers consisting of alphanumeric characters, -, _ following the pattern letter [letter | digit | '-' | '_']* This is implicitly a schema for type: object and contains the properties.

The values in a task conform to the schema. The names and types are described with a subset of JSON Schema Core and JSON Schema Validation similar to that used to define schemas in OpenAPI Specification 2.0.

interface object
interface defines the input and output interface of the workflow or task. The interface maps a variable from the schema to an object which indicates if the variable is part of the inputs to the task or workflow or part of the outputs of the instance, or both. The value provides a default value which is used when creating the instance. The value must confirm to the schema for that variable.
» additionalProperties interface
Defines the input and output interface (subset of values) for a task or workflow.
values any
The data associated with this flow item: the item's variable names and values. These values must conform to this item's schema. When a workflow or task runs, it may read and/or update these values as part of its processing.

When used in a workflow definition or task definition, the values define the default values for the variable that the workflow or task will take if the corresponding value is not bound via a workflow's bindings. That is, a definition's values are copied into the new workflow item's values when the item is instantiated from the definition.

Note: the schema may also contain default values which, if present, are used if a value is not set in the definition's values. (For example, multiple task definitions may use the same schema which defines values a, b, and c, but each task definition may have their own unique values for a, b, and c which is separate from the schema.)

dependencies object
The task dependency graph. This defines which tasks are prerequisite tasks for other task in the workflow. dependencies is a map structure. The key is the name of the task which depends on the others; the value is an array of dependency objects which define what named task depends on and what conditions must be met.
» additionalProperties [dependency]
[A dependency captures a workflow task dependency: each task within a workflow can depend on 0 or more other dependent tasks, creating a (possibly cyclic) dependency graph. Associated with each dependency is a _rule_: an optional constraint predicate expression which must evaluate to true in order for the task to start. The default constraint is that the dependent tasks all be completed (normal completion). A dependency object is the value associated with a task's name within a workflow's depenencies object.]
bindings [binding]
bindings connects input and output interface variables of the workflow and the workflow tasks.

When the workflow starts, all workflow and task variables are first assigned to any default values as per their respective interface and schema defaults. Next, workflow interface inputs are assigned to the inputs of any tasks as per these bindings. When a task starts, any bindings for its inputs are assigned as per these bindings. Each binding defines a source and one or more targets.

_id string
The unique identifier for this workflow resource. This is an immutable opaque string.
createdAt string(date-time)
The date-time when the workflow was created. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This is a derived field and is immutable.
read-only
updatedAt string(date-time)
The date-time when the workflow was updated. This is an RFC 3369 formatted date-time string, YYYY-MM-DDThh:mm:ss.sssZ. This is a derived field and is immutable.
read-only

workflows

{
  "_profile": "https://api.apiture.com/schemas/workflow/workflows/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "workflows",
  "_links": {
    "self": {
      "href": "/workflow/workflows?start=10&limit=10"
    },
    "first": {
      "href": "/workflow/workflows?start=0&limit=10"
    },
    "next": {
      "href": "/workflow/workflows?start=20&limit=10"
    },
    "collection": {
      "href": "/workflow/workflows"
    }
  },
  "_embedded": {
    "items": [
      {
        "_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
        "_profile": "https://api.apiture.com/schemas/workflow/v1.0.0/profile.json",
        "_links": {
          "self": {
            "href": "/workflow/workflows/0399abed-fd3d-4830-a88b-30f38b8a365c"
          }
        },
        "name": "newAccountSelector",
        "domain": "https://api.apiture.com/acctApps",
        "label": "New Account Selector",
        "type": "somethingElse",
        "visibility": "hidden",
        "state": "pending",
        "values": {
          "category": "personal",
          "ownership": "joint",
          "minimumBalanceGoal": 1000
        },
        "description": "A flow for selecting a Banking Product. Once a product is selected, the application will run the workflow associated with that specific product.",
        "_embedded": {}
      }
    ]
  }
}

Workflow Collection

Collection of workflows. The items in the collection are ordered in the _embedded object with name items. The top-level _links object may contain pagination links (self, next, prev, first, last, collection) as well the following:

* *`apiture:createWorkflowDefinition`* - a POST operation to create a workflow definition using the `createWorkflow` schema for the request.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Embedded workflow summary objects.
» items [summaryWorkflow]
An array containing a page of workflow items.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
count integer
The number of items in the full collection..
start integer
The start index of this page of items.
limit integer
The maximum number of items per page.
name string
The name of the collection.

root

{
  "id": "apiName",
  "name": "API name",
  "apiVersion": "0.0.1-SNAPSHOT",
  "_profile": "https://api.apiture.com/schemas/common/root/v1.0.0/profile.json",
  "_links": {}
}

API Root

A HAL response, with hypermedia _links for the top-level resources and operations in API.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
_id string
This API's unique ID.
name string
This API's name.
apiVersion string
This API's version.

errorResponse

{
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "_error": {
    "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
    "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
    "message": "The value for deposit must be greater than 0.",
    "statusCode": 422,
    "type": "positiveNumberRequired",
    "attributes": {
      "value": -125.5
    },
    "remediation": "Provide a value which is greater than 0",
    "occurredAt": {},
    "_links": {
      "describedby": {
        "href": "http://doc.apiture.com/errors/positiveNumberRequired"
      }
    },
    "_embedded": {
      "errors": []
    }
  }
}

Error Response

Describes an error response, typically returned on 4xx or 5xx errors from API operations. The _error object contains the error details.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
An optional map of nested resources, mapping each nested resource name to a nested resource representation.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.

error

{
  "_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
  "_profile": "https://api.apiture.com/schemas/common/errorResponse/v1.0.0/profile.json",
  "message": "The value for deposit must be greater than 0.",
  "statusCode": 422,
  "type": "positiveNumberRequired",
  "attributes": {
    "value": -125.5
  },
  "remediation": "Provide a value which is greater than 0",
  "occurredAt": "2018-01-25T05:50:52.375Z",
  "_links": {
    "describedby": {
      "href": "http://doc.apiture.com/errors/positiveNumberRequired"
    }
  },
  "_embedded": {
    "errors": []
  }
}

Error

An error description. Nested source errors are contained in the _embedded object with the key "errors"; this is an array of nested error objects. For example, an API which validates its request body may find multiple errors in the request, which may be detailed here. The _links may contain a describedby link which refers to a web page with details about the error. The attributes field An optional map of name/value pairs which provide structured data about the error. For example, if the error is a value out of range, the attributes may specify the range values min and max. This allows clients to present error messages as they see fit (the API does not assume the client/presentation tier).

Properties

NameDescription
message string (required)
A localized message string describing the error condition.
_id string
A unique identifier for this error instance. This may be used as a correlation ID with the root cause error (i.e. this ID may be logged at the source of the error). This is is an opaque string.
statusCode integer
The HTTP status code associate with this error.
minimum: 100
maximum: 599
type string
An error identifier which indicates the category of error and associate it with API support documentation or which the UI tier can use to render an appropriate message or hint. This provides a finer level of granularity than the statusCode. For example, instead of just 400 Bad Request, the type may be much more specific. such as integerValueNotInAllowedRange or numericValueExceedsMaximum or stringValueNotInAllowedSet.
occurredAt string(date-time)
An ISO 8601 UTC time stamp indicating when the error occurred.
attributes attributes
Data attribute associated with the error, such as values or constraints.
remediation string
An optional localized string which provides hints for how the user or client can resolve the error.
_embedded object
Optional embedded array of errors. This field may not exist if the error does not have nested errors.
» items [errorResponse]
An array of error objects.

attributes

{}

Attributes

An optional map of name/value pairs which contains additional dynamic data about the resource.

Properties

{
  "property1": {
    "href": "http://example.com",
    "type": "string",
    "templated": true,
    "title": "string",
    "deprecation": "http://example.com",
    "profile": "http://example.com"
  },
  "property2": {
    "href": "http://example.com",
    "type": "string",
    "templated": true,
    "title": "string",
    "deprecation": "http://example.com",
    "profile": "http://example.com"
  }
}

Links

An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.

Properties

NameDescription
additionalProperties link
Describes a hypermedia link within a _links object in HAL representations. In Apiture APIs, links are HAL links, but Apiture APIs do not use the name or hreflang properties of HAL. Apiture links may include a method property.

{
  "href": "http://example.com",
  "type": "string",
  "templated": true,
  "title": "string",
  "deprecation": "http://example.com",
  "profile": "http://example.com"
}

Link

Describes a hypermedia link within a _links object in HAL representations. In Apiture APIs, links are HAL links, but Apiture APIs do not use the name or hreflang properties of HAL. Apiture links may include a method property.

Properties

NameDescription
href string(uri) (required)
The URI or URI template for the resource/operation this link refers to.
type string
The media type for the resource.
templated boolean
If true, the link's href is a URI template.
title string
An optional human-readable localized title for the link.
deprecation string(uri)
If present, the containing link is deprecated and the value is a URI which provides human-readable text information about the deprecation.
profile string(uri)
The URI of a profile document, a JSON document which describes the target resource/operation.

taskType

{
  "_profile": "https://api.apiture.com/schemas/taskType/v1.0.0/profile.json",
  "label": "Choice",
  "description": "The Choice task type represents tasks which present a static choice to to the end user.",
  "_links": {
    "self": {
      "href": "/workflow/taskTypes/choice"
    }
  },
  "name": "choice",
  "schema": {
    "type": "object",
    "properties": {
      "choice": {
        "description": "The `id` of the selected choice.",
        "type": "string"
      },
      "choiceLabel": {
        "description": "The `label` of the selected choice.",
        "type": "string"
      },
      "choices": {
        "description": "An array of choices which are presented to the user for selection.",
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "This selection's unique ID."
            },
            "label": {
              "type": "string",
              "description": "This selection's text label."
            },
            "image": {
              "type": "string",
              "description": "A URI of an image to present for this choice."
            }
          }
        }
      }
    }
  },
  "interface": {
    "choice": {
      "input": true,
      "output": true
    },
    "choiceLabel": {
      "input": false,
      "output": true
    },
    "choices": {
      "input": true
    },
    "label": "Choose an account type",
    "presentation": "iconAndLabel",
    "selection": "single",
    "defaultSelection": "savings"
  },
  "values": {
    "choice": "checking",
    "choiceLabel": "Checking",
    "choices": [
      {
        "id": "savings",
        "label": "Savings",
        "image": "https://api.apiture.com/static/images/accountTypes/savings.png"
      },
      {
        "id": "checking",
        "label": "Checking",
        "image": "https://api.apiture.com/static/images/accountTypes/checking.png"
      }
    ]
  },
  "_embedded": {}
}

Task Type

Representation of a task type resource. Workflow task types which define the schema and interface for all tasks of that type. This schema is used to create new task types with the PUT operation and is used as the representation on the GET operation.

Properties

NameDescription
name string (required)
The unique name of this task type. This also serves as the ID of the task type (the {taskName} path parameter). This value corresponds to thetypefield of task definitions and tasks. Example task type names areform(fill out a form),choice(select a value from a fixed set of choices),select(select one or more values from a dynamic set of choices),rest(perform a REST call),compute(compute output values based on the input values),workflow` (a reusable set of subtasks).
minLength: 3
maxLength: 64
pattern: [a-zA-Z][-\w_]*
label string (required)
The text label for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 128
description string (required)
The full description for this resource, suitable for presentation to the client.
minLength: 1
maxLength: 4096
schema object (required)
The JSON Schema that will be used for all task definitions and tasks that use this task type.

Note: OpenAPI Specification is not expressive enough to model all of JSON Schema, so the type is just object.

interface interface (required)
The interface that (inputs and outputs, based on the schema) for task definitions and tasks that use this task type.

taskTypes

{
  "_profile": "https://api.apiture.com/schemas/workflow/taskTypes/v1.0.0/profile.json",
  "start": 10,
  "limit": 10,
  "count": 67,
  "name": "taskTypes",
  "_embedded": {
    "items": [
      {
        "name": "choice",
        "label": "Choice",
        "description": "The Choice task type represents tasks which present a static choice to to the end user.",
        "_links": {
          "self": {
            "href": "/workflow/taskTypes/choice"
          }
        }
      }
    ]
  }
}

Task Type Collection

Collection of task types. The items in the collection are in the _embedded object with name items.

Properties

NameDescription
_links links
An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations.
_embedded object
Embedded task type objects.
» items [taskType]
An array containing a page of task type items.
_profile string(uri)
The URI of a resource profile which describes the representation.
_error error
An object which describes an error. This value is omitted if the operation succeeded without error.
count integer
The number of items in the full collection..
start integer
The start index of this page of items.
limit integer
The maximum number of items per page.
name string
The name of the collection.