Worksteps
Overview
A workstep is a prototype of one stepwise state transition contained in a Workflow
. A Workstep
contains a Prover
that ingests data passed to the Workstep
and outputs a zero-knowledge proof that can be used to verify synchronization of data amongst Workgroup
participants.
Application
Worksteps are useful for defining the real-world activities or operations to be used as synchronization check-points in a Workflow
. They provide context for the data required to instantiate, populate and execute a zero-knowledge Prover
as it relates to a corresponding business process.
When used in series, a verified claim from a previously derived proof
can be used as input for a subsequent Workstep
to ensure that a Workflow
cannot be completed if all participants are not in sync. As additional worksteps are completed and a Workflow
is completed, the proof
derived from the exit-workstep provides verifiable proof of synchronization amongst all participants.
Fundamentals
Prover
A Prover
is a zero knowledge circuit that generates a method by which one party (the prover) can prove to another party (the verifier) that a given statement is true while the prover avoids conveying any additional information apart from the fact that the statement is indeed true. To learn more about provers, see Provide Privacy.
Prime Workstep
The prime-workstep is the leading workstep in a workflow. The trigger defined in the prime Workstep
instantiates a WorkflowInstance
and all subsequent WorkstepInstance
objects.
Exit Workstep
The exit-workstep is the final Workstep
included in a Workflow
. Once executed as a WorkstepInstance
, it outputs a recursive proof
encompassing all previous WorkstepInstanc
proofs. The proof
resulting from the execution exit-workstep must always be published to a network
.
A WorkstepInstance
is a run-time execution of a deployed Workstep
. All WorkstepInstance
executions included in a WorkflowInstance
are spawned when the conditions specified in the prime-workstep are met. A WorkstepInstance
shares the same schema as a Workstep
and is distinguishable by the presence of a value in the workstep_id
field.
Workstep Lifecycle
Status | Definition |
| undeployed |
|
|
|
|
|
|
Using Worksteps
Prerequisites
The Workstep API is intended to function within the context of an Organization
acting as a Participant
in a Workgroup
.
Within this context, it is assumed that:
an
Organization
scoped JWT is available for useOrganization
is a participant in aWorkgroup
destination system of record data structure is known
originating system of record data structure is known
a
Workflow
has been created
Workstep Schema
Field | Type | Description |
---|---|---|
| int | position within sequence of worksteps in parent workflow |
| date/time | timestamp of |
| date/time | timestamp of |
| string | brief descriptor of |
| uuid |
|
| object | arbitrary data pertaining to |
| array | list of |
| uuid |
|
| boolean | when |
| string | address of target shield contract |
| string | current workstep status |
| uuid |
|
| uuid |
|
API Requests
List Worksteps
Returns a list of all Workstep
objects in the authorized scope
List Worksteps
GET
https://baseline.provide.services/api/v1/workflow
Returns a list of all Workstep
objects in the authorized scope
Query Parameters
Name | Type | Description |
---|---|---|
filter_prototypes | boolean | when |
filter_instances | boolean | when |
Headers
Name | Type | Description |
---|---|---|
authorization* | string | bearer <JWT> scoped for an |
Create Workstep
Creates a Workstep
. The cardinality
of a Workstep
is calculated by the service, as determined by the order of creation.
Create a Workstep
POST
https://baseline.provide.services/api/v1/workflow/:id/
Creates a Workstep
within a specified Workflow
. Workflow must be in draft
status in order to accept new worksteps
Path Parameters
Name | Type | Description |
---|---|---|
id* | uuid |
|
Headers
Name | Type | Description |
---|---|---|
authorization* | string | bearer <JWT> scoped for |
Request Body
Name | Type | Description |
---|---|---|
name* | string | name of |
desciption | string | description of |
status | string | current status of |
require_finality | boolean | when The terminal |
metadata* | object | arbitrary data containing a |
Get Workstep Details
Retrieves detailed information for a specified Workstep
Get Workstep Details
GET
https://baseline.provide.services/api/v1/workflows/:id/worksteps/:workstep_id
Retrieves details for a specified Workstep
Path Parameters
Name | Type | Description |
---|---|---|
id* | string |
|
workstep_id* | string |
|
Headers
Name | Type | Description |
---|---|---|
authorization* | string | bearer <JWT> scoped for an |
Update Workstep
Updates a specified Workstep
Update a Workstep
PUT
https://baseline.provide.services/api/v1/workflows/:id/worksteps/:workstep_id
Creates a Workstep
within a specified Workflow
. Workflow
must be in draft
status in order to update included worksteps=
Path Parameters
Name | Type | Description |
---|---|---|
id* | uuid |
|
workstep_id* | uuid |
|
Headers
Name | Type | Description |
---|---|---|
authorization* | string | bearer <JWT> scoped for |
Request Body
Name | Type | Description |
---|---|---|
name* | string | name of |
desciption | string | brief description of |
status | string | current status of |
require_finality | boolean | when All exit-steps in a |
metadata[]* | object | arbitrary data containing a |
Delete Workstep
Deletes a specified Workstep
Delete a Workstep
PUT
https://baseline.provide.services/api/v1/workflows/:id/worksteps/:workstep_id
Deletes a Workstep
within a specified Workflow
. Workflow
must be in draft
status in order to delete included Workstep
Path Parameters
Name | Type | Description |
---|---|---|
id* | uuid |
|
workstep_id* | uuid |
|
Headers
Name | Type | Description |
---|---|---|
authorization* | string | bearer <JWT> scoped for |
Last updated