Update Lifecycle State
POST/agreements/:agreement_id/lifecycle
Update the lifecycle status of an agreement: pending
, open
or cancelled
.
Pending: When an agreement is switched to Pending, it is finalized for signing by validating all inputs and, if communication is enabled, sends out all or the first batch of invitations. A Pending agreement can be either cancelled or opened.
Open: If the agreement is opened, the signing process is paused and reset to allow making any changes you would like to do.
Cancelled: If you cancel the agreement, it is moved into an end state where no more changes are allowed. If communication is enabled and the agreement is cancelled, notifications will be sent to all participants.
Request
Path Parameters
POST /agreements/:agreement_id/lifecycle parameter
- application/json
Body
POST /agreements/:agreement_id/lifecycle request body
- MOD1
- MOD2
- MOD3
- MOD1
- MOD2
lifecycle_state object required
The lifecycle state of the agreement
Possible values: [cancelled
]
input object required
Possible values: [invalid_document
, invalid_participant
, invalid_email
]
Possible values: [custom
]
Possible values: >= 10 characters
and <= 255 characters
Possible values: [open
]
Possible values: [pending
]
Responses
- 200
- 400
POST /agreements/:agreement_id/lifecycle Successful response
- application/json
- Schema
- Example (from schema)
Schema
- MOD1
- MOD2
- MOD3
- MOD1
- MOD2
- MOD3
- Array [
- ]
- MOD1
- MOD2
- MOD3
- Array [
- ]
- Array [
- MOD1
- 118cb3b11b8a1f3b6b1e60a89f96a8be9da32a0f
- MOD3
- Array [
- ]
- MOD1
- MOD3
- Array [
- ]
- ]
- MOD1
- MOD2
- MOD3
- MOD1
- MOD2
- MOD3
- Array [
- ]
- Array [
- MOD1
- MOD2
- ]
- MOD1
- MOD2
- MOD3
- MOD1
- MOD2
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the agreement resource.
Possible values: [agreement
]
Data contains the agreement resource.
data objectrequired
The resource data.
The unique identifier of the agreement
Possible values: [agreement
]
Indicates if the agreement is created using a development client
Possible values: [draft
, pending
, fulfilled
, cancelled
, generating
, failed_to_generate
, open
]
The status of the agreement
Possible values: [SES
, AES
, QES
]
The minimum trust level for the signatures.
If the agreement is in a cancelled state, this will be a short description on the reason why, otherwise it will be null.
theme object required
string
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the theme resource.
Possible values: [theme
]
Data contains the theme resource.
data objectrequired
The resource data.
The unique identifier of the theme
Possible values: [theme
]
logo objectrequired
The logo of the theme. This is displayed to the user in all communication and touch points.
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the file resource.
Possible values: [file
]
Data contains the file resource.
data objectrequired
The resource data.
The unique identifier of the file
Possible values: [file
]
Possible values: non-empty
The complete filename including the file extension
Possible values: non-empty
The mime type of the file
The signed read url of the file
metadata object
A provided lookup key provided by you to help you identify the file.
UTC datetime ISO string
UTC datetime ISO string
icon objectrequired
The icon of the theme. This is used for the favicon.
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the file resource.
Possible values: [file
]
Data contains the file resource.
data objectrequired
The resource data.
The unique identifier of the file
Possible values: [file
]
Possible values: non-empty
The complete filename including the file extension
Possible values: non-empty
The mime type of the file
The signed read url of the file
metadata object
A provided lookup key provided by you to help you identify the file.
UTC datetime ISO string
UTC datetime ISO string
Default value: #000000
The primary color used to create the color palette in the signing room.
metadata object
A provided lookup key provided by you to help you identify the theme.
UTC datetime ISO string
UTC datetime ISO string
string
issuer objectrequired
The issuer of the agreement
The name of the issuer. Required if no email is provided.
The email of the issuer. Required if agreemnt is configured to send emails.
Possible values: [signer
, approver
, observer
]
The role of the issuer in the agreement process.
If the issuer is a signer or approver this is the ID of the related participant.
The URL to the signing room for the issuer. Only available after the agreement has been finalized for signing.
participants object required
string
Possible values: [1.0
]
The version of the response schema
Possible values: [list
]
A non-paginated list of the participant resource.
Possible values: [participant
]
Data contains the participant resource.
string
signing_groups object
string
Possible values: [1.0
]
The version of the response schema
Possible values: [list
]
A non-paginated list of the signing group resource.
Possible values: [signing_group
]
Data contains the signing group resource.
data object[]required
The unique identifier of the signing group
Possible values: [signing_group
]
The name of the signing group
Possible values: [draft
, pending
, fulfilled
]
The status of the signing group
Possible values: >= 5e-324
and <= 1.7976931348623157e+308
The queue number of the signing group
participants object required
string
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the signing_group resource.
Possible values: [signing_group
]
Data contains the signing_group resource.
data objectrequired
The resource data.
The unique identifier of the signing group
Possible values: [signing_group
]
The name of the signing group
Possible values: [draft
, pending
, fulfilled
]
The status of the signing group
Possible values: >= 5e-324
and <= 1.7976931348623157e+308
The queue number of the signing group
participants object required
string
string
The unique identifier of the agreement this signing group belongs to
UTC datetime ISO string
UTC datetime ISO string
string
The unique identifier of the agreement this signing group belongs to
UTC datetime ISO string
UTC datetime ISO string
string
documents object
original_documents objectrequired
main object required
The main document which will be signed.
string
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the file resource.
Possible values: [file
]
Data contains the file resource.
data objectrequired
The resource data.
The unique identifier of the file
Possible values: [file
]
Possible values: non-empty
The complete filename including the file extension
Possible values: non-empty
The mime type of the file
The signed read url of the file
metadata object
A provided lookup key provided by you to help you identify the file.
UTC datetime ISO string
UTC datetime ISO string
string
attachments object
string
Possible values: [1.0
]
The version of the response schema
Possible values: [list
]
A non-paginated list of the attachment resource.
Possible values: [attachment
]
Data contains the attachment resource.
data object[]required
The unique identifier of the attachment
Possible values: [attachment
]
The unique identifier of the agreement which this attachment belongs to
Possible values: <= 9007199254740991
The order of this attachment relative to the other attachments
file object required
string
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the file resource.
Possible values: [file
]
Data contains the file resource.
data objectrequired
The resource data.
The unique identifier of the file
Possible values: [file
]
Possible values: non-empty
The complete filename including the file extension
Possible values: non-empty
The mime type of the file
The signed read url of the file
metadata object
A provided lookup key provided by you to help you identify the file.
UTC datetime ISO string
UTC datetime ISO string
UTC datetime ISO string
UTC datetime ISO string
string
signed_document object required
The finalized and signed document.
string
Possible values: [1.0
]
The version of the response schema
Possible values: [single
]
A single object of the file resource.
Possible values: [file
]
Data contains the file resource.
data objectrequired
The resource data.
The unique identifier of the file
Possible values: [file
]
Possible values: non-empty
The complete filename including the file extension
Possible values: non-empty
The mime type of the file
The signed read url of the file
metadata object
A provided lookup key provided by you to help you identify the file.
UTC datetime ISO string
UTC datetime ISO string
string
signing_order objectrequired
communication objectrequired
default_locale object
string
string
metadata object
A provided lookup key provided by you to help you identify the agreement.
A provided callback url to refer the participants back to post successful action.
UTC datetime ISO string
UTC datetime ISO string
{
"version": "1.0",
"result_type": "single",
"resource_type": "agreement",
"data": {
"id": "c4y1fah0gtlwm42gbuyexample",
"resource_type": "agreement",
"test_mode": true,
"status": "draft",
"trust_level": "SES",
"cancellation_reason": null,
"theme": "cceciv9dj6gv4xjdkohexample",
"issuer": {
"name": "John Doe",
"email": "example@example.com",
"role": "signer",
"participant_id": "c0we2fkh6u4okalpjifexample",
"signing_room_url": "https://www.zigned.se/sign/cqxfd5wjc9gdgwul3cdexample/cchz66ltlex1jjudwrbexample"
},
"participants": [
"cbe1nayfmye0qndiapaexample",
"c21htxwpjaybwlqzljcexample",
"c0jysx87bd3o7ikfbjgexample"
],
"signing_groups": [
"cbe1nayfmye0qndiapaexample",
"c21htxwpjaybwlqzljcexample",
"c0jysx87bd3o7ikfbjgexample"
],
"documents": {
"original_documents": {
"main": "c9tv7aw3wqlhje6xle6example",
"attachments": [
"cbe1nayfmye0qndiapaexample",
"c21htxwpjaybwlqzljcexample",
"c0jysx87bd3o7ikfbjgexample"
]
},
"signed_document": "cm7wscybpkdc1lsuv1lexample"
},
"signing_order": {
"enabled": true,
"grouped": true
},
"communication": {
"send_emails": true,
"default_locale": "sv-SE"
},
"metadata": {
"lookup_key": "your_internal_customer_id",
"success_callback_url": "https://yourdomain.com/sign-complete"
},
"updated_at": "2024-01-01T00:00:00.000Z",
"created_at": "2024-01-01T00:00:00.000Z"
}
}
POST /agreements/:agreement_id/lifecycle Error response
- application/json
- Schema
- Example (from schema)
Schema
Possible values: [error
]
error objectrequired
Possible values: >= 400
and <= 599
{
"status": "error",
"error": {
"code": 0,
"message": "string",
"request_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}