Skip to content

Create envelope

POST
/envelope/create
curl --request POST \
--url https://app.legaldoc.com/api/v2/envelope/create \
--header 'Authorization: <Authorization>' \
--header 'Content-Type: multipart/form-data' \
--form 'payload={ "title": "example", "type": "DOCUMENT", "delegatedDocumentOwner": "example", "externalId": "example", "visibility": "EVERYONE", "globalAccessAuth": [ "ACCOUNT" ], "globalActionAuth": [ "ACCOUNT" ], "formValues": { "additionalProperty": "example" }, "folderId": "example", "recipients": [ { "email": "", "name": "example", "role": "CC", "signingOrder": 1, "accessAuth": [], "actionAuth": [], "fields": [ { "type": "SIGNATURE", "fieldMeta": { "type": "signature", "fontSize": 18, "overflow": "auto" }, "identifier": "example", "page": 1, "positionX": 1, "positionY": 1, "width": 1, "height": 1 } ] } ], "meta": { "subject": "example", "message": "example", "timezone": "example", "dateFormat": "yyyy-MM-dd hh:mm a", "distributionMethod": "EMAIL", "signingOrder": "PARALLEL", "allowDictateNextSigner": true, "redirectUrl": "example", "language": "de", "typedSignatureEnabled": true, "uploadSignatureEnabled": true, "drawSignatureEnabled": true, "emailId": "example", "emailReplyTo": "example", "emailSettings": { "recipientSigningRequest": true, "recipientRemoved": true, "recipientSigned": true, "documentPending": true, "documentCompleted": true, "documentDeleted": true, "ownerDocumentCompleted": true, "ownerRecipientExpired": true, "ownerDocumentCreated": true }, "envelopeExpirationPeriod": { "unit": "day", "amount": 1 }, "reminderSettings": { "sendAfter": { "unit": "day", "amount": 1 }, "repeatEvery": { "unit": "day", "amount": 1 } } }, "attachments": [ { "label": "example", "data": "https://example.com", "type": "link" } ] }' \
--form files=example

Create an envelope using form data.

Media typemultipart/form-data
object
payload
required
object
title
required
string
>= 1 characters <= 255 characters
type
required
string
Allowed values: DOCUMENT TEMPLATE
delegatedDocumentOwner
string
/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~\u{0080}-\u{FFFF}-]+@[a-zA-Z0-9\u{0080}-\u{FFFF}](?:[a-zA-Z0-9\u{0080}-\u{FFFF}-]{0,61}[a-zA-Z0-9\u{0080}-\u{FFFF}])?(?:\.[a-zA-Z0-9\u{0080}-\u{FFFF}](?:[a-zA-Z0-9\u{0080}-\u{FFFF}-]{0,61}[a-zA-Z0-9\u{0080}-\u{FFFF}])?)*$/
externalId
string
<= 255 characters
visibility
string
Allowed values: EVERYONE MANAGER_AND_ABOVE ADMIN
globalAccessAuth
Array<string>
Allowed values: ACCOUNT TWO_FACTOR_AUTH
globalActionAuth
Array<string>
Allowed values: ACCOUNT PASSKEY TWO_FACTOR_AUTH PASSWORD
formValues
object
key
additional properties
Any of:
string
folderId
string
recipients
Array<object>
object
email
required
Any of:
string
Allowed values: ""
name
required
string
<= 255 characters
role
required
string
Allowed values: CC SIGNER VIEWER APPROVER ASSISTANT
signingOrder
number
accessAuth
Array<string>
default:
Allowed values: ACCOUNT TWO_FACTOR_AUTH
actionAuth
Array<string>
default:
Allowed values: ACCOUNT PASSKEY TWO_FACTOR_AUTH PASSWORD EXPLICIT_NONE
fields
Array
object
One of:
object
type
required
string
Allowed values: SIGNATURE
fieldMeta
object
label
string
placeholder
string
required
boolean
readOnly
boolean
fontSize
number
default: 12 >= 8 <= 96
overflow
string
default: auto
Allowed values: auto horizontal vertical crop
type
required
string
Allowed values: signature
identifier
Any of:
string
page
required
number
>= 1
positionX
required
number
<= 100
positionY
required
number
<= 100
width
required
number
<= 100
height
required
number
<= 100
meta
object
subject
string
<= 254 characters
message
string
<= 5000 characters
timezone
string
dateFormat
string
Allowed values: yyyy-MM-dd hh:mm a yyyy-MM-dd dd/MM/yyyy dd-MM-yyyy MM/dd/yyyy yy-MM-dd MMMM dd, yyyy EEEE, MMMM dd, yyyy dd/MM/yyyy hh:mm a dd/MM/yyyy HH:mm dd-MM-yyyy hh:mm a dd-MM-yyyy HH:mm MM/dd/yyyy hh:mm a MM/dd/yyyy HH:mm dd.MM.yyyy dd.MM.yyyy HH:mm yyyy-MM-dd HH:mm yy-MM-dd hh:mm a yy-MM-dd HH:mm yyyy-MM-dd HH:mm:ss MMMM dd, yyyy hh:mm a MMMM dd, yyyy HH:mm EEEE, MMMM dd, yyyy hh:mm a EEEE, MMMM dd, yyyy HH:mm yyyy-MM-dd'T'HH:mm:ss.SSSXXX
distributionMethod
string
Allowed values: EMAIL NONE
signingOrder
string
Allowed values: PARALLEL SEQUENTIAL
allowDictateNextSigner
boolean
redirectUrl
string
language
string
Allowed values: de en fr es it nl pl pt-BR ja ko zh
typedSignatureEnabled
boolean
uploadSignatureEnabled
boolean
drawSignatureEnabled
boolean
emailId
string | null
emailReplyTo
string | null
/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~\u{0080}-\u{FFFF}-]+@[a-zA-Z0-9\u{0080}-\u{FFFF}](?:[a-zA-Z0-9\u{0080}-\u{FFFF}-]{0,61}[a-zA-Z0-9\u{0080}-\u{FFFF}])?(?:\.[a-zA-Z0-9\u{0080}-\u{FFFF}](?:[a-zA-Z0-9\u{0080}-\u{FFFF}-]{0,61}[a-zA-Z0-9\u{0080}-\u{FFFF}])?)*$/
emailSettings
object
recipientSigningRequest
boolean
default: true
recipientRemoved
boolean
default: true
recipientSigned
boolean
default: true
documentPending
boolean
default: true
documentCompleted
boolean
default: true
documentDeleted
boolean
default: true
ownerDocumentCompleted
boolean
default: true
ownerRecipientExpired
boolean
default: true
ownerDocumentCreated
boolean
default: true
envelopeExpirationPeriod
Any of:
object
unit
required
string
Allowed values: day week month year
amount
required
integer
>= 1
reminderSettings
object
sendAfter
required
Any of:
object
unit
required
string
Allowed values: day week month
amount
required
integer
>= 1
repeatEvery
required
Any of:
object
unit
required
string
Allowed values: day week month
amount
required
integer
>= 1
attachments
Array<object>
object
label
required
string
>= 1 characters
data
required
string format: uri
type
string
default: link
Allowed values: link
files
Array<string>

Successful response

Media typeapplication/json
object
id
required
string
Examplegenerated
{
"id": "example"
}

Invalid input data

Media typeapplication/json
object
message
required
string
code
required
string
issues
Array<object>
object
message
required
string
Examplegenerated
{
"message": "example",
"code": "example",
"issues": [
{
"message": "example"
}
]
}

Authorization not provided

Media typeapplication/json
object
message
required
string
code
required
string
issues
Array<object>
object
message
required
string
Examplegenerated
{
"message": "example",
"code": "example",
"issues": [
{
"message": "example"
}
]
}

Insufficient access

Media typeapplication/json
object
message
required
string
code
required
string
issues
Array<object>
object
message
required
string
Examplegenerated
{
"message": "example",
"code": "example",
"issues": [
{
"message": "example"
}
]
}

Internal server error

Media typeapplication/json
object
message
required
string
code
required
string
issues
Array<object>
object
message
required
string
Examplegenerated
{
"message": "example",
"code": "example",
"issues": [
{
"message": "example"
}
]
}