curl --request PUT \
--url https://sandbox.circularo.com/api/v1/share/draft \
--header 'Content-Type: application/json' \
--data '
{
"body": {
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"cancelled": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": true,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": true,
"kycFactors": [
"idVerification",
"livenessDetection"
],
"kycProvider": "identomat",
"mailProtection": true,
"message": "<string>",
"metadata": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"usersWithKycData": [
{
"kycDocumentTypes": [
"passport",
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [],
"user": "john.doe@example.com"
}
]
},
"signEntities": [
{
"inGroup": true,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"kycFactors": [],
"kycProvider": "<string>",
"language": "en",
"mailProtection": true,
"message": "Please countersign before Friday.",
"metadata": true,
"nafathId": "1012345678",
"nafathProtection": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"phone": "+420777123456",
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
]
}
}
'import requests
url = "https://sandbox.circularo.com/api/v1/share/draft"
payload = { "body": {
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": True,
"isConvertible": True,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": True,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": True,
"cancelled": True,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": True,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": True,
"maxCharacters": 123,
"multipage": True,
"numberOfLines": 123,
"order": 123,
"pages": [1, 2],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": True,
"readOnly": True,
"required": True,
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"subtype": "annotation_generic",
"text": "<string>",
"time": True,
"timestamp": True,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": ["john.doe+member@example.com"],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": ["Yes", "No"],
"zIndex": 123
}
],
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": True,
"delegate": True,
"expirationEnabled": True,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": True,
"kycFactors": ["idVerification", "livenessDetection"],
"kycProvider": "identomat",
"mailProtection": True,
"message": "<string>",
"metadata": True,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": True,
"password": "<string>",
"passwordProtection": True,
"print": True,
"rejectWithoutComment": True,
"remindersEnabled": True,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": True,
"uploadFiles": True,
"usersWithKycData": [
{
"kycDocumentTypes": ["passport", "idCard"],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [],
"user": "john.doe@example.com"
}
]
},
"signEntities": [
{
"inGroup": True,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": True,
"delegate": True,
"expirationEnabled": True,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"kycFactors": [],
"kycProvider": "<string>",
"language": "en",
"mailProtection": True,
"message": "Please countersign before Friday.",
"metadata": True,
"nafathId": "1012345678",
"nafathProtection": True,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": True,
"password": "<string>",
"passwordProtection": True,
"phone": "+420777123456",
"print": True,
"rejectWithoutComment": True,
"remindersEnabled": True,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": True,
"uploadFiles": True,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": True,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": True,
"maxCharacters": 123,
"multipage": True,
"numberOfLines": 123,
"order": 123,
"pages": [1, 2],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": True,
"readOnly": True,
"required": True,
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"subtype": "annotation_generic",
"text": "<string>",
"time": True,
"timestamp": True,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": ["john.doe+member@example.com"],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": ["Yes", "No"],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": True,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": True,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
]
} }
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
body: JSON.stringify({
customFields: [
{
key: 'internalReference',
type: 'string',
value: 'ACME-2026-001',
displayName: 'Internal reference'
}
],
file: [
{
additionalInfo: '<string>',
content: 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
fileExtension: 'docx',
fileType: 'word',
hasPassword: true,
isConvertible: true,
mimetype: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
name: 'LegalNotes.docx',
pages: 8,
public: true,
size: 522481,
timestamp: '2023-11-07T05:31:56Z',
user: 'john.doe@example.com'
}
],
originalSignFields: [
{
align: 'center',
backgroundColor: '#FFFF00',
bold: true,
cancelled: true,
color: '#000000',
config: '{"multipageType":"all","multiPageCustom":"1"}',
fieldGroupId: 123,
fileName: 'evidence.pdf',
filled: true,
font: 'default',
fontSize: 123,
groupId: 123,
id: '1LTn5IimzXh68bOv',
link: 'https://example.com',
lockRatio: true,
maxCharacters: 123,
multipage: true,
numberOfLines: 123,
order: 123,
pages: [1, 2],
position: {
percentHeight: 0.03176305676305678,
percentWidth: 0.43921568627450985,
percentX: 0.49892906639788337,
percentY: 0.2465883269647186
},
public: true,
readOnly: true,
required: true,
shareId: ['sd0oAvfpB4k0yDf787x4'],
subtype: 'annotation_generic',
text: '<string>',
time: true,
timestamp: true,
tooltip: 'Sign here',
type: 'signature',
usage: 'manual',
user: ['john.doe+member@example.com'],
userRoleId: 123,
userRoleName: 'Recipient 1',
values: ['Yes', 'No'],
zIndex: 123
}
],
shareSettings: {
allowedOAuth: '<string>',
canAnnotateOnReject: true,
delegate: true,
expirationEnabled: true,
expirationTime: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
isPublicComment: true,
kycFactors: ['idVerification', 'livenessDetection'],
kycProvider: 'identomat',
mailProtection: true,
message: '<string>',
metadata: true,
oauthFactors: [{type: 'email', value: 'john.doe@example.com'}],
oauthFactorTypes: [],
oAuthProtection: true,
password: '<string>',
passwordProtection: true,
print: true,
rejectWithoutComment: true,
remindersEnabled: true,
remindersIntervalDays: 123,
remindersStartDays: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
smsProtection: true,
uploadFiles: true,
usersWithKycData: [
{
kycDocumentTypes: ['passport', 'idCard'],
kycExpectedData: {
dateOfBirth: '1988-11-13T00:00:00.000Z',
documentNumber: 'X1234567',
nationality: 'CZE'
},
kycExpectedDataFields: [],
user: 'john.doe@example.com'
}
],
usersWithOAuthFactors: [
{
oauthFactors: [{type: 'phoneNumber', value: '+420777123456'}],
oauthFactorTypes: [],
user: 'john.doe@example.com'
}
]
},
signEntities: [
{
inGroup: true,
order: 123,
quorum: 123,
shareData: [
{
allowedOAuth: 'uaePass',
canAnnotateOnReject: true,
delegate: true,
expirationEnabled: true,
expirationTime: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
kycDocumentTypes: [],
kycExpectedData: {
dateOfBirth: '1988-11-13T00:00:00.000Z',
documentNumber: 'X1234567',
nationality: 'CZE'
},
kycExpectedDataFields: [],
kycFactors: [],
kycProvider: '<string>',
language: 'en',
mailProtection: true,
message: 'Please countersign before Friday.',
metadata: true,
nafathId: '1012345678',
nafathProtection: true,
oauthFactors: [{type: 'email', value: 'john.doe@example.com'}],
oauthFactorTypes: [],
oAuthProtection: true,
password: '<string>',
passwordProtection: true,
phone: '+420777123456',
print: true,
rejectWithoutComment: true,
remindersEnabled: true,
remindersIntervalDays: 3,
remindersStartDays: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
smsProtection: true,
uploadFiles: true,
user: {
contactType: '<string>',
fullname: 'John Doe',
language: 'en',
mail: 'john.doe@example.com',
name: 'john.doe@example.com',
type: 'internal'
}
}
],
shareId: ['sd0oAvfpB4k0yDf787x4'],
shareType: 'sign',
type: 'user',
usage: 'manual',
userRoleId: 123,
userRoleName: 'Recipient 1'
}
],
signFields: [
{
align: 'center',
backgroundColor: '#FFFF00',
bold: true,
color: '#000000',
config: '{"multipageType":"all","multiPageCustom":"1"}',
fieldGroupId: 123,
fileName: 'evidence.pdf',
font: 'default',
fontSize: 123,
groupId: 123,
id: '1LTn5IimzXh68bOv',
link: 'https://example.com',
lockRatio: true,
maxCharacters: 123,
multipage: true,
numberOfLines: 123,
order: 123,
pages: [1, 2],
position: {
percentHeight: 0.03176305676305678,
percentWidth: 0.43921568627450985,
percentX: 0.49892906639788337,
percentY: 0.2465883269647186
},
public: true,
readOnly: true,
required: true,
shareId: ['sd0oAvfpB4k0yDf787x4'],
subtype: 'annotation_generic',
text: '<string>',
time: true,
timestamp: true,
tooltip: 'Sign here',
type: 'signature',
usage: 'manual',
user: ['john.doe+member@example.com'],
userRoleId: 123,
userRoleName: 'Recipient 1',
values: ['Yes', 'No'],
zIndex: 123
}
],
submittedFiles: [
{
additionalInfo: '<string>',
content: 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
fileExtension: 'pdf',
fileType: 'pdf',
hasPassword: true,
mimetype: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
name: 'IDCardFront.pdf',
pages: 8,
public: true,
size: 522481,
timestamp: '2023-11-07T05:31:56Z',
user: 'john.doe@example.com'
}
]
})
})
};
fetch('https://sandbox.circularo.com/api/v1/share/draft', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.circularo.com/api/v1/share/draft",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'body' => [
'customFields' => [
[
'key' => 'internalReference',
'type' => 'string',
'value' => 'ACME-2026-001',
'displayName' => 'Internal reference'
]
],
'file' => [
[
'additionalInfo' => '<string>',
'content' => 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
'fileExtension' => 'docx',
'fileType' => 'word',
'hasPassword' => true,
'isConvertible' => true,
'mimetype' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'name' => 'LegalNotes.docx',
'pages' => 8,
'public' => true,
'size' => 522481,
'timestamp' => '2023-11-07T05:31:56Z',
'user' => 'john.doe@example.com'
]
],
'originalSignFields' => [
[
'align' => 'center',
'backgroundColor' => '#FFFF00',
'bold' => true,
'cancelled' => true,
'color' => '#000000',
'config' => '{"multipageType":"all","multiPageCustom":"1"}',
'fieldGroupId' => 123,
'fileName' => 'evidence.pdf',
'filled' => true,
'font' => 'default',
'fontSize' => 123,
'groupId' => 123,
'id' => '1LTn5IimzXh68bOv',
'link' => 'https://example.com',
'lockRatio' => true,
'maxCharacters' => 123,
'multipage' => true,
'numberOfLines' => 123,
'order' => 123,
'pages' => [
1,
2
],
'position' => [
'percentHeight' => 0.03176305676305678,
'percentWidth' => 0.43921568627450985,
'percentX' => 0.49892906639788337,
'percentY' => 0.2465883269647186
],
'public' => true,
'readOnly' => true,
'required' => true,
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'subtype' => 'annotation_generic',
'text' => '<string>',
'time' => true,
'timestamp' => true,
'tooltip' => 'Sign here',
'type' => 'signature',
'usage' => 'manual',
'user' => [
'john.doe+member@example.com'
],
'userRoleId' => 123,
'userRoleName' => 'Recipient 1',
'values' => [
'Yes',
'No'
],
'zIndex' => 123
]
],
'shareSettings' => [
'allowedOAuth' => '<string>',
'canAnnotateOnReject' => true,
'delegate' => true,
'expirationEnabled' => true,
'expirationTime' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'isPublicComment' => true,
'kycFactors' => [
'idVerification',
'livenessDetection'
],
'kycProvider' => 'identomat',
'mailProtection' => true,
'message' => '<string>',
'metadata' => true,
'oauthFactors' => [
[
'type' => 'email',
'value' => 'john.doe@example.com'
]
],
'oauthFactorTypes' => [
],
'oAuthProtection' => true,
'password' => '<string>',
'passwordProtection' => true,
'print' => true,
'rejectWithoutComment' => true,
'remindersEnabled' => true,
'remindersIntervalDays' => 123,
'remindersStartDays' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'smsProtection' => true,
'uploadFiles' => true,
'usersWithKycData' => [
[
'kycDocumentTypes' => [
'passport',
'idCard'
],
'kycExpectedData' => [
'dateOfBirth' => '1988-11-13T00:00:00.000Z',
'documentNumber' => 'X1234567',
'nationality' => 'CZE'
],
'kycExpectedDataFields' => [
],
'user' => 'john.doe@example.com'
]
],
'usersWithOAuthFactors' => [
[
'oauthFactors' => [
[
'type' => 'phoneNumber',
'value' => '+420777123456'
]
],
'oauthFactorTypes' => [
],
'user' => 'john.doe@example.com'
]
]
],
'signEntities' => [
[
'inGroup' => true,
'order' => 123,
'quorum' => 123,
'shareData' => [
[
'allowedOAuth' => 'uaePass',
'canAnnotateOnReject' => true,
'delegate' => true,
'expirationEnabled' => true,
'expirationTime' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'kycDocumentTypes' => [
],
'kycExpectedData' => [
'dateOfBirth' => '1988-11-13T00:00:00.000Z',
'documentNumber' => 'X1234567',
'nationality' => 'CZE'
],
'kycExpectedDataFields' => [
],
'kycFactors' => [
],
'kycProvider' => '<string>',
'language' => 'en',
'mailProtection' => true,
'message' => 'Please countersign before Friday.',
'metadata' => true,
'nafathId' => '1012345678',
'nafathProtection' => true,
'oauthFactors' => [
[
'type' => 'email',
'value' => 'john.doe@example.com'
]
],
'oauthFactorTypes' => [
],
'oAuthProtection' => true,
'password' => '<string>',
'passwordProtection' => true,
'phone' => '+420777123456',
'print' => true,
'rejectWithoutComment' => true,
'remindersEnabled' => true,
'remindersIntervalDays' => 3,
'remindersStartDays' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'smsProtection' => true,
'uploadFiles' => true,
'user' => [
'contactType' => '<string>',
'fullname' => 'John Doe',
'language' => 'en',
'mail' => 'john.doe@example.com',
'name' => 'john.doe@example.com',
'type' => 'internal'
]
]
],
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'shareType' => 'sign',
'type' => 'user',
'usage' => 'manual',
'userRoleId' => 123,
'userRoleName' => 'Recipient 1'
]
],
'signFields' => [
[
'align' => 'center',
'backgroundColor' => '#FFFF00',
'bold' => true,
'color' => '#000000',
'config' => '{"multipageType":"all","multiPageCustom":"1"}',
'fieldGroupId' => 123,
'fileName' => 'evidence.pdf',
'font' => 'default',
'fontSize' => 123,
'groupId' => 123,
'id' => '1LTn5IimzXh68bOv',
'link' => 'https://example.com',
'lockRatio' => true,
'maxCharacters' => 123,
'multipage' => true,
'numberOfLines' => 123,
'order' => 123,
'pages' => [
1,
2
],
'position' => [
'percentHeight' => 0.03176305676305678,
'percentWidth' => 0.43921568627450985,
'percentX' => 0.49892906639788337,
'percentY' => 0.2465883269647186
],
'public' => true,
'readOnly' => true,
'required' => true,
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'subtype' => 'annotation_generic',
'text' => '<string>',
'time' => true,
'timestamp' => true,
'tooltip' => 'Sign here',
'type' => 'signature',
'usage' => 'manual',
'user' => [
'john.doe+member@example.com'
],
'userRoleId' => 123,
'userRoleName' => 'Recipient 1',
'values' => [
'Yes',
'No'
],
'zIndex' => 123
]
],
'submittedFiles' => [
[
'additionalInfo' => '<string>',
'content' => 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
'fileExtension' => 'pdf',
'fileType' => 'pdf',
'hasPassword' => true,
'mimetype' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'name' => 'IDCardFront.pdf',
'pages' => 8,
'public' => true,
'size' => 522481,
'timestamp' => '2023-11-07T05:31:56Z',
'user' => 'john.doe@example.com'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.circularo.com/api/v1/share/draft"
payload := strings.NewReader("{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://sandbox.circularo.com/api/v1/share/draft")
.header("Content-Type", "application/json")
.body("{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v1/share/draft")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"alerts": [
{
"alertTo": "john.doe@example.com",
"message": "The contract expires next week.",
"sent": true,
"triggerOn": "2023-11-07T05:31:56Z"
}
],
"barcode": "g153bn7qeo63b5kzec7q9cvnxnd03n34d4zkfyjy8m728eqdznf3htxm8mh14d48",
"counterId": "TEF_2016_aa_001",
"createDate": "2023-11-07T05:31:56Z",
"createName": {
"name": "john.doe@example.com",
"type": "internal"
},
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"definitionLanguage": "en",
"definitionType": "edoc",
"documentCategory": "Contract",
"documentId": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"documentTitle": "Contract Agreement",
"draftType": "create",
"expiresOn": "2026-12-31T00:00:00.000Z",
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"folder": {
"global": {
"level": 123,
"parentFolderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"path": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"level": 123
}
],
"username": "john.doe@example.com"
},
"user": {
"level": 123,
"parentFolderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"path": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"level": 123
}
],
"username": "john.doe@example.com"
}
},
"html": "<string>",
"isFolder": true,
"isSigned": true,
"lastModified": "2023-11-07T05:31:56Z",
"lastUpdated": "2023-11-07T05:31:56Z",
"organization": "d0a72e51-728e-4a1d-9a5c-13796122b6f8",
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"cancelled": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": true,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"pdfFile": {
"additionalInfo": "<string>",
"content": "a219a47b4f5b1xv726cfm36l8k1hkxzwmj5mszvfq6szoambdvc44v6i8hrhntv0",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/pdf",
"name": "Contract.pdf",
"pages": 21,
"size": 724158
},
"readBy": [
"<string>"
],
"revision": 3,
"rights": {
"editGroups": [
"<string>"
],
"editUsers": [
"<string>"
],
"private": true,
"readGroups": [
"<string>"
],
"readUsers": [
"<string>"
]
},
"sequential": true,
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": true,
"kycFactors": [
"idVerification",
"livenessDetection"
],
"kycProvider": "identomat",
"mailProtection": true,
"message": "<string>",
"metadata": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [
"email"
],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"usersWithKycData": [
{
"kycDocumentTypes": [
"passport",
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [
"dateOfBirth"
],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [
"email"
],
"user": "john.doe@example.com"
}
]
},
"showBarcode": true,
"signEntities": [
{
"inGroup": true,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [
"dateOfBirth"
],
"kycFactors": [
"idVerification"
],
"kycProvider": "<string>",
"language": "en",
"mailProtection": true,
"message": "Please countersign before Friday.",
"metadata": true,
"nafathId": "1012345678",
"nafathProtection": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [
"email"
],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"phone": "+420777123456",
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"tags": {
"global": [
"Contract",
"2026"
],
"user": [
"To review"
]
},
"term": {
"nextNotificationOn": "2026-11-30T08:00:00.000Z",
"nextRenewalOn": "2027-01-01T00:00:00.000Z",
"nonFixedTerm": {
"noticePeriod": "3M",
"terminationStartDate": "2026-10-01T00:00:00.000Z"
},
"reminders": [
{
"nextReminderOn": "2026-11-30T08:00:00.000Z",
"notifyOwner": true,
"period": "30d",
"recipients": [
"jane.doe@example.com"
],
"sentOn": "2026-11-30T08:00:07.412Z",
"skipped": true,
"time": "09:00",
"timeZone": "Europe/Prague"
}
],
"renewal": {
"finalDate": "2030-12-31T00:00:00.000Z",
"lastRenewedOn": "2027-01-01T00:15:03.118Z",
"maxRenewals": 50,
"noticeDueOn": "2026-09-30T00:00:00.000Z",
"noticePeriod": "3M",
"period": "1y",
"renewedCount": 1,
"type": "auto"
},
"timeZone": "Europe/Prague"
},
"termType": "fixed_term",
"thumbnails": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"tika": {
"content_ocr": "<string>",
"content_text": "<string>",
"language": "<string>"
},
"tikaStatus": "<string>",
"usePdfA": true,
"workflow": [
{
"archived": true,
"group": [
"<string>"
],
"history": [
{
"action": 123,
"comment": "<string>",
"date": "2023-11-07T05:31:56Z",
"fileChanged": true,
"fileName": "contract.pdf",
"groupReceiver": [
"<string>"
],
"mentionedDocuments": [
"<string>"
],
"mentionedUsers": [
"jane.doe@example.com"
],
"mimetype": "application/pdf",
"name": "document_signed",
"newRevision": 123,
"newTitle": "<string>",
"originalFileName": "contract.docx",
"originalMimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"originalRevision": 123,
"originalTitle": "<string>",
"sent": true,
"shareEmail": "<string>",
"shareFinal": true,
"shareGroup": "<string>",
"shareType": "<string>",
"shareUser": "<string>",
"signatureComponents": "<string>",
"state": 123,
"tags": [
"<string>"
],
"titleChanged": true,
"type": "document_signed",
"user": {
"name": "john.doe@example.com",
"type": "internal"
},
"userReceiver": [
{
"name": "john.doe@example.com",
"type": "internal"
}
]
}
],
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc590",
"lastAction": {
"archive": true,
"commentRequired": true,
"following": "<string>",
"id": 5,
"isInitial": true,
"multipleReceivers": true,
"name": "create",
"nextState": 1,
"predefinedReceiver": true,
"receiver": "john.doe@example.com",
"recipient": true,
"rights": "<string>",
"send": true,
"stateId": 0
},
"lastRequest": {
"commentRequired": true,
"id": 5,
"isInitial": true,
"multipleReceivers": true,
"name": "request_approval",
"nextState": 1,
"predefinedReceiver": true,
"receiver": "john.doe@example.com",
"recipient": true,
"resolvedBy": 5,
"rework": true,
"rights": "<string>",
"sign": true,
"stateId": 0
},
"receivedDate": "2023-11-07T05:31:56Z",
"state": 1,
"stateName": "created",
"timeOfDuration": 86400000,
"user": [
{
"name": "john.doe@example.com",
"type": "internal"
}
],
"workflowType": "wf_archive"
}
]
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 428,
"type": "AUTH:MFA_REQUIRED",
"message": "MFA activation required",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 498,
"type": "SHARE_AUTH:TOKEN_INVALID",
"message": "Invalid share token",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}Save the recipient's draft of a share
PUT /share/draft
Saves what the recipient has filled in on this share without submitting it, so that they can break off and take the work up again later, on another device if need be.
There is one draft per recipient and share. Each call replaces it whole rather than merging into what was there, and carrying the action out clears it, as does calling the share off or handing it to somebody else. Only a recipient from outside the workspace keeps a draft; a share assigned to a user of this workspace is refused, that user working on the document itself instead.
Share authorization: Authorize using a share token and a one-time password (if required) to call this endpoint.
Allowed share object types: document
Allowed share purposes: sign or accept or approve or review
curl --request PUT \
--url https://sandbox.circularo.com/api/v1/share/draft \
--header 'Content-Type: application/json' \
--data '
{
"body": {
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"cancelled": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": true,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": true,
"kycFactors": [
"idVerification",
"livenessDetection"
],
"kycProvider": "identomat",
"mailProtection": true,
"message": "<string>",
"metadata": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"usersWithKycData": [
{
"kycDocumentTypes": [
"passport",
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [],
"user": "john.doe@example.com"
}
]
},
"signEntities": [
{
"inGroup": true,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"kycFactors": [],
"kycProvider": "<string>",
"language": "en",
"mailProtection": true,
"message": "Please countersign before Friday.",
"metadata": true,
"nafathId": "1012345678",
"nafathProtection": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"phone": "+420777123456",
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
]
}
}
'import requests
url = "https://sandbox.circularo.com/api/v1/share/draft"
payload = { "body": {
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": True,
"isConvertible": True,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": True,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": True,
"cancelled": True,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": True,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": True,
"maxCharacters": 123,
"multipage": True,
"numberOfLines": 123,
"order": 123,
"pages": [1, 2],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": True,
"readOnly": True,
"required": True,
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"subtype": "annotation_generic",
"text": "<string>",
"time": True,
"timestamp": True,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": ["john.doe+member@example.com"],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": ["Yes", "No"],
"zIndex": 123
}
],
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": True,
"delegate": True,
"expirationEnabled": True,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": True,
"kycFactors": ["idVerification", "livenessDetection"],
"kycProvider": "identomat",
"mailProtection": True,
"message": "<string>",
"metadata": True,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": True,
"password": "<string>",
"passwordProtection": True,
"print": True,
"rejectWithoutComment": True,
"remindersEnabled": True,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": True,
"uploadFiles": True,
"usersWithKycData": [
{
"kycDocumentTypes": ["passport", "idCard"],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [],
"user": "john.doe@example.com"
}
]
},
"signEntities": [
{
"inGroup": True,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": True,
"delegate": True,
"expirationEnabled": True,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [],
"kycFactors": [],
"kycProvider": "<string>",
"language": "en",
"mailProtection": True,
"message": "Please countersign before Friday.",
"metadata": True,
"nafathId": "1012345678",
"nafathProtection": True,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [],
"oAuthProtection": True,
"password": "<string>",
"passwordProtection": True,
"phone": "+420777123456",
"print": True,
"rejectWithoutComment": True,
"remindersEnabled": True,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": True,
"uploadFiles": True,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": True,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": True,
"maxCharacters": 123,
"multipage": True,
"numberOfLines": 123,
"order": 123,
"pages": [1, 2],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": True,
"readOnly": True,
"required": True,
"shareId": ["sd0oAvfpB4k0yDf787x4"],
"subtype": "annotation_generic",
"text": "<string>",
"time": True,
"timestamp": True,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": ["john.doe+member@example.com"],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": ["Yes", "No"],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": True,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": True,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
]
} }
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
body: JSON.stringify({
customFields: [
{
key: 'internalReference',
type: 'string',
value: 'ACME-2026-001',
displayName: 'Internal reference'
}
],
file: [
{
additionalInfo: '<string>',
content: 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
fileExtension: 'docx',
fileType: 'word',
hasPassword: true,
isConvertible: true,
mimetype: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
name: 'LegalNotes.docx',
pages: 8,
public: true,
size: 522481,
timestamp: '2023-11-07T05:31:56Z',
user: 'john.doe@example.com'
}
],
originalSignFields: [
{
align: 'center',
backgroundColor: '#FFFF00',
bold: true,
cancelled: true,
color: '#000000',
config: '{"multipageType":"all","multiPageCustom":"1"}',
fieldGroupId: 123,
fileName: 'evidence.pdf',
filled: true,
font: 'default',
fontSize: 123,
groupId: 123,
id: '1LTn5IimzXh68bOv',
link: 'https://example.com',
lockRatio: true,
maxCharacters: 123,
multipage: true,
numberOfLines: 123,
order: 123,
pages: [1, 2],
position: {
percentHeight: 0.03176305676305678,
percentWidth: 0.43921568627450985,
percentX: 0.49892906639788337,
percentY: 0.2465883269647186
},
public: true,
readOnly: true,
required: true,
shareId: ['sd0oAvfpB4k0yDf787x4'],
subtype: 'annotation_generic',
text: '<string>',
time: true,
timestamp: true,
tooltip: 'Sign here',
type: 'signature',
usage: 'manual',
user: ['john.doe+member@example.com'],
userRoleId: 123,
userRoleName: 'Recipient 1',
values: ['Yes', 'No'],
zIndex: 123
}
],
shareSettings: {
allowedOAuth: '<string>',
canAnnotateOnReject: true,
delegate: true,
expirationEnabled: true,
expirationTime: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
isPublicComment: true,
kycFactors: ['idVerification', 'livenessDetection'],
kycProvider: 'identomat',
mailProtection: true,
message: '<string>',
metadata: true,
oauthFactors: [{type: 'email', value: 'john.doe@example.com'}],
oauthFactorTypes: [],
oAuthProtection: true,
password: '<string>',
passwordProtection: true,
print: true,
rejectWithoutComment: true,
remindersEnabled: true,
remindersIntervalDays: 123,
remindersStartDays: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
smsProtection: true,
uploadFiles: true,
usersWithKycData: [
{
kycDocumentTypes: ['passport', 'idCard'],
kycExpectedData: {
dateOfBirth: '1988-11-13T00:00:00.000Z',
documentNumber: 'X1234567',
nationality: 'CZE'
},
kycExpectedDataFields: [],
user: 'john.doe@example.com'
}
],
usersWithOAuthFactors: [
{
oauthFactors: [{type: 'phoneNumber', value: '+420777123456'}],
oauthFactorTypes: [],
user: 'john.doe@example.com'
}
]
},
signEntities: [
{
inGroup: true,
order: 123,
quorum: 123,
shareData: [
{
allowedOAuth: 'uaePass',
canAnnotateOnReject: true,
delegate: true,
expirationEnabled: true,
expirationTime: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
kycDocumentTypes: [],
kycExpectedData: {
dateOfBirth: '1988-11-13T00:00:00.000Z',
documentNumber: 'X1234567',
nationality: 'CZE'
},
kycExpectedDataFields: [],
kycFactors: [],
kycProvider: '<string>',
language: 'en',
mailProtection: true,
message: 'Please countersign before Friday.',
metadata: true,
nafathId: '1012345678',
nafathProtection: true,
oauthFactors: [{type: 'email', value: 'john.doe@example.com'}],
oauthFactorTypes: [],
oAuthProtection: true,
password: '<string>',
passwordProtection: true,
phone: '+420777123456',
print: true,
rejectWithoutComment: true,
remindersEnabled: true,
remindersIntervalDays: 3,
remindersStartDays: {
exactTime: '2026-03-01T12:00:00.000Z',
timeSize: {size: 'day', span: 3},
type: 'time_span_span'
},
smsProtection: true,
uploadFiles: true,
user: {
contactType: '<string>',
fullname: 'John Doe',
language: 'en',
mail: 'john.doe@example.com',
name: 'john.doe@example.com',
type: 'internal'
}
}
],
shareId: ['sd0oAvfpB4k0yDf787x4'],
shareType: 'sign',
type: 'user',
usage: 'manual',
userRoleId: 123,
userRoleName: 'Recipient 1'
}
],
signFields: [
{
align: 'center',
backgroundColor: '#FFFF00',
bold: true,
color: '#000000',
config: '{"multipageType":"all","multiPageCustom":"1"}',
fieldGroupId: 123,
fileName: 'evidence.pdf',
font: 'default',
fontSize: 123,
groupId: 123,
id: '1LTn5IimzXh68bOv',
link: 'https://example.com',
lockRatio: true,
maxCharacters: 123,
multipage: true,
numberOfLines: 123,
order: 123,
pages: [1, 2],
position: {
percentHeight: 0.03176305676305678,
percentWidth: 0.43921568627450985,
percentX: 0.49892906639788337,
percentY: 0.2465883269647186
},
public: true,
readOnly: true,
required: true,
shareId: ['sd0oAvfpB4k0yDf787x4'],
subtype: 'annotation_generic',
text: '<string>',
time: true,
timestamp: true,
tooltip: 'Sign here',
type: 'signature',
usage: 'manual',
user: ['john.doe+member@example.com'],
userRoleId: 123,
userRoleName: 'Recipient 1',
values: ['Yes', 'No'],
zIndex: 123
}
],
submittedFiles: [
{
additionalInfo: '<string>',
content: 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
fileExtension: 'pdf',
fileType: 'pdf',
hasPassword: true,
mimetype: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
name: 'IDCardFront.pdf',
pages: 8,
public: true,
size: 522481,
timestamp: '2023-11-07T05:31:56Z',
user: 'john.doe@example.com'
}
]
})
})
};
fetch('https://sandbox.circularo.com/api/v1/share/draft', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.circularo.com/api/v1/share/draft",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'body' => [
'customFields' => [
[
'key' => 'internalReference',
'type' => 'string',
'value' => 'ACME-2026-001',
'displayName' => 'Internal reference'
]
],
'file' => [
[
'additionalInfo' => '<string>',
'content' => 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
'fileExtension' => 'docx',
'fileType' => 'word',
'hasPassword' => true,
'isConvertible' => true,
'mimetype' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'name' => 'LegalNotes.docx',
'pages' => 8,
'public' => true,
'size' => 522481,
'timestamp' => '2023-11-07T05:31:56Z',
'user' => 'john.doe@example.com'
]
],
'originalSignFields' => [
[
'align' => 'center',
'backgroundColor' => '#FFFF00',
'bold' => true,
'cancelled' => true,
'color' => '#000000',
'config' => '{"multipageType":"all","multiPageCustom":"1"}',
'fieldGroupId' => 123,
'fileName' => 'evidence.pdf',
'filled' => true,
'font' => 'default',
'fontSize' => 123,
'groupId' => 123,
'id' => '1LTn5IimzXh68bOv',
'link' => 'https://example.com',
'lockRatio' => true,
'maxCharacters' => 123,
'multipage' => true,
'numberOfLines' => 123,
'order' => 123,
'pages' => [
1,
2
],
'position' => [
'percentHeight' => 0.03176305676305678,
'percentWidth' => 0.43921568627450985,
'percentX' => 0.49892906639788337,
'percentY' => 0.2465883269647186
],
'public' => true,
'readOnly' => true,
'required' => true,
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'subtype' => 'annotation_generic',
'text' => '<string>',
'time' => true,
'timestamp' => true,
'tooltip' => 'Sign here',
'type' => 'signature',
'usage' => 'manual',
'user' => [
'john.doe+member@example.com'
],
'userRoleId' => 123,
'userRoleName' => 'Recipient 1',
'values' => [
'Yes',
'No'
],
'zIndex' => 123
]
],
'shareSettings' => [
'allowedOAuth' => '<string>',
'canAnnotateOnReject' => true,
'delegate' => true,
'expirationEnabled' => true,
'expirationTime' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'isPublicComment' => true,
'kycFactors' => [
'idVerification',
'livenessDetection'
],
'kycProvider' => 'identomat',
'mailProtection' => true,
'message' => '<string>',
'metadata' => true,
'oauthFactors' => [
[
'type' => 'email',
'value' => 'john.doe@example.com'
]
],
'oauthFactorTypes' => [
],
'oAuthProtection' => true,
'password' => '<string>',
'passwordProtection' => true,
'print' => true,
'rejectWithoutComment' => true,
'remindersEnabled' => true,
'remindersIntervalDays' => 123,
'remindersStartDays' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'smsProtection' => true,
'uploadFiles' => true,
'usersWithKycData' => [
[
'kycDocumentTypes' => [
'passport',
'idCard'
],
'kycExpectedData' => [
'dateOfBirth' => '1988-11-13T00:00:00.000Z',
'documentNumber' => 'X1234567',
'nationality' => 'CZE'
],
'kycExpectedDataFields' => [
],
'user' => 'john.doe@example.com'
]
],
'usersWithOAuthFactors' => [
[
'oauthFactors' => [
[
'type' => 'phoneNumber',
'value' => '+420777123456'
]
],
'oauthFactorTypes' => [
],
'user' => 'john.doe@example.com'
]
]
],
'signEntities' => [
[
'inGroup' => true,
'order' => 123,
'quorum' => 123,
'shareData' => [
[
'allowedOAuth' => 'uaePass',
'canAnnotateOnReject' => true,
'delegate' => true,
'expirationEnabled' => true,
'expirationTime' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'kycDocumentTypes' => [
],
'kycExpectedData' => [
'dateOfBirth' => '1988-11-13T00:00:00.000Z',
'documentNumber' => 'X1234567',
'nationality' => 'CZE'
],
'kycExpectedDataFields' => [
],
'kycFactors' => [
],
'kycProvider' => '<string>',
'language' => 'en',
'mailProtection' => true,
'message' => 'Please countersign before Friday.',
'metadata' => true,
'nafathId' => '1012345678',
'nafathProtection' => true,
'oauthFactors' => [
[
'type' => 'email',
'value' => 'john.doe@example.com'
]
],
'oauthFactorTypes' => [
],
'oAuthProtection' => true,
'password' => '<string>',
'passwordProtection' => true,
'phone' => '+420777123456',
'print' => true,
'rejectWithoutComment' => true,
'remindersEnabled' => true,
'remindersIntervalDays' => 3,
'remindersStartDays' => [
'exactTime' => '2026-03-01T12:00:00.000Z',
'timeSize' => [
'size' => 'day',
'span' => 3
],
'type' => 'time_span_span'
],
'smsProtection' => true,
'uploadFiles' => true,
'user' => [
'contactType' => '<string>',
'fullname' => 'John Doe',
'language' => 'en',
'mail' => 'john.doe@example.com',
'name' => 'john.doe@example.com',
'type' => 'internal'
]
]
],
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'shareType' => 'sign',
'type' => 'user',
'usage' => 'manual',
'userRoleId' => 123,
'userRoleName' => 'Recipient 1'
]
],
'signFields' => [
[
'align' => 'center',
'backgroundColor' => '#FFFF00',
'bold' => true,
'color' => '#000000',
'config' => '{"multipageType":"all","multiPageCustom":"1"}',
'fieldGroupId' => 123,
'fileName' => 'evidence.pdf',
'font' => 'default',
'fontSize' => 123,
'groupId' => 123,
'id' => '1LTn5IimzXh68bOv',
'link' => 'https://example.com',
'lockRatio' => true,
'maxCharacters' => 123,
'multipage' => true,
'numberOfLines' => 123,
'order' => 123,
'pages' => [
1,
2
],
'position' => [
'percentHeight' => 0.03176305676305678,
'percentWidth' => 0.43921568627450985,
'percentX' => 0.49892906639788337,
'percentY' => 0.2465883269647186
],
'public' => true,
'readOnly' => true,
'required' => true,
'shareId' => [
'sd0oAvfpB4k0yDf787x4'
],
'subtype' => 'annotation_generic',
'text' => '<string>',
'time' => true,
'timestamp' => true,
'tooltip' => 'Sign here',
'type' => 'signature',
'usage' => 'manual',
'user' => [
'john.doe+member@example.com'
],
'userRoleId' => 123,
'userRoleName' => 'Recipient 1',
'values' => [
'Yes',
'No'
],
'zIndex' => 123
]
],
'submittedFiles' => [
[
'additionalInfo' => '<string>',
'content' => 'as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth',
'fileExtension' => 'pdf',
'fileType' => 'pdf',
'hasPassword' => true,
'mimetype' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'name' => 'IDCardFront.pdf',
'pages' => 8,
'public' => true,
'size' => 522481,
'timestamp' => '2023-11-07T05:31:56Z',
'user' => 'john.doe@example.com'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.circularo.com/api/v1/share/draft"
payload := strings.NewReader("{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://sandbox.circularo.com/api/v1/share/draft")
.header("Content-Type", "application/json")
.body("{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.circularo.com/api/v1/share/draft")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"body\": {\n \"customFields\": [\n {\n \"key\": \"internalReference\",\n \"type\": \"string\",\n \"value\": \"ACME-2026-001\",\n \"displayName\": \"Internal reference\"\n }\n ],\n \"file\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"docx\",\n \"fileType\": \"word\",\n \"hasPassword\": true,\n \"isConvertible\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"LegalNotes.docx\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"originalSignFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"cancelled\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"filled\": true,\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"shareSettings\": {\n \"allowedOAuth\": \"<string>\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"isPublicComment\": true,\n \"kycFactors\": [\n \"idVerification\",\n \"livenessDetection\"\n ],\n \"kycProvider\": \"identomat\",\n \"mailProtection\": true,\n \"message\": \"<string>\",\n \"metadata\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 123,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"usersWithKycData\": [\n {\n \"kycDocumentTypes\": [\n \"passport\",\n \"idCard\"\n ],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"user\": \"john.doe@example.com\"\n }\n ],\n \"usersWithOAuthFactors\": [\n {\n \"oauthFactors\": [\n {\n \"type\": \"phoneNumber\",\n \"value\": \"+420777123456\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"user\": \"john.doe@example.com\"\n }\n ]\n },\n \"signEntities\": [\n {\n \"inGroup\": true,\n \"order\": 123,\n \"quorum\": 123,\n \"shareData\": [\n {\n \"allowedOAuth\": \"uaePass\",\n \"canAnnotateOnReject\": true,\n \"delegate\": true,\n \"expirationEnabled\": true,\n \"expirationTime\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"kycDocumentTypes\": [],\n \"kycExpectedData\": {\n \"dateOfBirth\": \"1988-11-13T00:00:00.000Z\",\n \"documentNumber\": \"X1234567\",\n \"nationality\": \"CZE\"\n },\n \"kycExpectedDataFields\": [],\n \"kycFactors\": [],\n \"kycProvider\": \"<string>\",\n \"language\": \"en\",\n \"mailProtection\": true,\n \"message\": \"Please countersign before Friday.\",\n \"metadata\": true,\n \"nafathId\": \"1012345678\",\n \"nafathProtection\": true,\n \"oauthFactors\": [\n {\n \"type\": \"email\",\n \"value\": \"john.doe@example.com\"\n }\n ],\n \"oauthFactorTypes\": [],\n \"oAuthProtection\": true,\n \"password\": \"<string>\",\n \"passwordProtection\": true,\n \"phone\": \"+420777123456\",\n \"print\": true,\n \"rejectWithoutComment\": true,\n \"remindersEnabled\": true,\n \"remindersIntervalDays\": 3,\n \"remindersStartDays\": {\n \"exactTime\": \"2026-03-01T12:00:00.000Z\",\n \"timeSize\": {\n \"size\": \"day\",\n \"span\": 3\n },\n \"type\": \"time_span_span\"\n },\n \"smsProtection\": true,\n \"uploadFiles\": true,\n \"user\": {\n \"contactType\": \"<string>\",\n \"fullname\": \"John Doe\",\n \"language\": \"en\",\n \"mail\": \"john.doe@example.com\",\n \"name\": \"john.doe@example.com\",\n \"type\": \"internal\"\n }\n }\n ],\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"shareType\": \"sign\",\n \"type\": \"user\",\n \"usage\": \"manual\",\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\"\n }\n ],\n \"signFields\": [\n {\n \"align\": \"center\",\n \"backgroundColor\": \"#FFFF00\",\n \"bold\": true,\n \"color\": \"#000000\",\n \"config\": \"{\\\"multipageType\\\":\\\"all\\\",\\\"multiPageCustom\\\":\\\"1\\\"}\",\n \"fieldGroupId\": 123,\n \"fileName\": \"evidence.pdf\",\n \"font\": \"default\",\n \"fontSize\": 123,\n \"groupId\": 123,\n \"id\": \"1LTn5IimzXh68bOv\",\n \"link\": \"https://example.com\",\n \"lockRatio\": true,\n \"maxCharacters\": 123,\n \"multipage\": true,\n \"numberOfLines\": 123,\n \"order\": 123,\n \"pages\": [\n 1,\n 2\n ],\n \"position\": {\n \"percentHeight\": 0.03176305676305678,\n \"percentWidth\": 0.43921568627450985,\n \"percentX\": 0.49892906639788337,\n \"percentY\": 0.2465883269647186\n },\n \"public\": true,\n \"readOnly\": true,\n \"required\": true,\n \"shareId\": [\n \"sd0oAvfpB4k0yDf787x4\"\n ],\n \"subtype\": \"annotation_generic\",\n \"text\": \"<string>\",\n \"time\": true,\n \"timestamp\": true,\n \"tooltip\": \"Sign here\",\n \"type\": \"signature\",\n \"usage\": \"manual\",\n \"user\": [\n \"john.doe+member@example.com\"\n ],\n \"userRoleId\": 123,\n \"userRoleName\": \"Recipient 1\",\n \"values\": [\n \"Yes\",\n \"No\"\n ],\n \"zIndex\": 123\n }\n ],\n \"submittedFiles\": [\n {\n \"additionalInfo\": \"<string>\",\n \"content\": \"as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth\",\n \"fileExtension\": \"pdf\",\n \"fileType\": \"pdf\",\n \"hasPassword\": true,\n \"mimetype\": \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\",\n \"name\": \"IDCardFront.pdf\",\n \"pages\": 8,\n \"public\": true,\n \"size\": 522481,\n \"timestamp\": \"2023-11-07T05:31:56Z\",\n \"user\": \"john.doe@example.com\"\n }\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"alerts": [
{
"alertTo": "john.doe@example.com",
"message": "The contract expires next week.",
"sent": true,
"triggerOn": "2023-11-07T05:31:56Z"
}
],
"barcode": "g153bn7qeo63b5kzec7q9cvnxnd03n34d4zkfyjy8m728eqdznf3htxm8mh14d48",
"counterId": "TEF_2016_aa_001",
"createDate": "2023-11-07T05:31:56Z",
"createName": {
"name": "john.doe@example.com",
"type": "internal"
},
"customFields": [
{
"key": "internalReference",
"type": "string",
"value": "ACME-2026-001",
"displayName": "Internal reference"
}
],
"definitionLanguage": "en",
"definitionType": "edoc",
"documentCategory": "Contract",
"documentId": "a0d01c9d-f72f-4c57-af11-e26bda19cc59",
"documentTitle": "Contract Agreement",
"draftType": "create",
"expiresOn": "2026-12-31T00:00:00.000Z",
"file": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "docx",
"fileType": "word",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "LegalNotes.docx",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"folder": {
"global": {
"level": 123,
"parentFolderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"path": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"level": 123
}
],
"username": "john.doe@example.com"
},
"user": {
"level": 123,
"parentFolderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"path": [
{
"folderId": "97cfb9de-92dd-413a-b5e7-175eff7506d6",
"level": 123
}
],
"username": "john.doe@example.com"
}
},
"html": "<string>",
"isFolder": true,
"isSigned": true,
"lastModified": "2023-11-07T05:31:56Z",
"lastUpdated": "2023-11-07T05:31:56Z",
"organization": "d0a72e51-728e-4a1d-9a5c-13796122b6f8",
"originalSignFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"cancelled": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"filled": true,
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"pdfFile": {
"additionalInfo": "<string>",
"content": "a219a47b4f5b1xv726cfm36l8k1hkxzwmj5mszvfq6szoambdvc44v6i8hrhntv0",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"isConvertible": true,
"mimetype": "application/pdf",
"name": "Contract.pdf",
"pages": 21,
"size": 724158
},
"readBy": [
"<string>"
],
"revision": 3,
"rights": {
"editGroups": [
"<string>"
],
"editUsers": [
"<string>"
],
"private": true,
"readGroups": [
"<string>"
],
"readUsers": [
"<string>"
]
},
"sequential": true,
"shareSettings": {
"allowedOAuth": "<string>",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"isPublicComment": true,
"kycFactors": [
"idVerification",
"livenessDetection"
],
"kycProvider": "identomat",
"mailProtection": true,
"message": "<string>",
"metadata": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [
"email"
],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 123,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"usersWithKycData": [
{
"kycDocumentTypes": [
"passport",
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [
"dateOfBirth"
],
"user": "john.doe@example.com"
}
],
"usersWithOAuthFactors": [
{
"oauthFactors": [
{
"type": "phoneNumber",
"value": "+420777123456"
}
],
"oauthFactorTypes": [
"email"
],
"user": "john.doe@example.com"
}
]
},
"showBarcode": true,
"signEntities": [
{
"inGroup": true,
"order": 123,
"quorum": 123,
"shareData": [
{
"allowedOAuth": "uaePass",
"canAnnotateOnReject": true,
"delegate": true,
"expirationEnabled": true,
"expirationTime": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"kycDocumentTypes": [
"idCard"
],
"kycExpectedData": {
"dateOfBirth": "1988-11-13T00:00:00.000Z",
"documentNumber": "X1234567",
"nationality": "CZE"
},
"kycExpectedDataFields": [
"dateOfBirth"
],
"kycFactors": [
"idVerification"
],
"kycProvider": "<string>",
"language": "en",
"mailProtection": true,
"message": "Please countersign before Friday.",
"metadata": true,
"nafathId": "1012345678",
"nafathProtection": true,
"oauthFactors": [
{
"type": "email",
"value": "john.doe@example.com"
}
],
"oauthFactorTypes": [
"email"
],
"oAuthProtection": true,
"password": "<string>",
"passwordProtection": true,
"phone": "+420777123456",
"print": true,
"rejectWithoutComment": true,
"remindersEnabled": true,
"remindersIntervalDays": 3,
"remindersStartDays": {
"exactTime": "2026-03-01T12:00:00.000Z",
"timeSize": {
"size": "day",
"span": 3
},
"type": "time_span_span"
},
"smsProtection": true,
"uploadFiles": true,
"user": {
"contactType": "<string>",
"fullname": "John Doe",
"language": "en",
"mail": "john.doe@example.com",
"name": "john.doe@example.com",
"type": "internal"
}
}
],
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"shareType": "sign",
"type": "user",
"usage": "manual",
"userRoleId": 123,
"userRoleName": "Recipient 1"
}
],
"signFields": [
{
"align": "center",
"backgroundColor": "#FFFF00",
"bold": true,
"color": "#000000",
"config": "{\"multipageType\":\"all\",\"multiPageCustom\":\"1\"}",
"fieldGroupId": 123,
"fileName": "evidence.pdf",
"font": "default",
"fontSize": 123,
"groupId": 123,
"id": "1LTn5IimzXh68bOv",
"link": "https://example.com",
"lockRatio": true,
"maxCharacters": 123,
"multipage": true,
"numberOfLines": 123,
"order": 123,
"pages": [
1,
2
],
"position": {
"percentHeight": 0.03176305676305678,
"percentWidth": 0.43921568627450985,
"percentX": 0.49892906639788337,
"percentY": 0.2465883269647186
},
"public": true,
"readOnly": true,
"required": true,
"shareId": [
"sd0oAvfpB4k0yDf787x4"
],
"subtype": "annotation_generic",
"text": "<string>",
"time": true,
"timestamp": true,
"tooltip": "Sign here",
"type": "signature",
"usage": "manual",
"user": [
"john.doe+member@example.com"
],
"userRoleId": 123,
"userRoleName": "Recipient 1",
"values": [
"Yes",
"No"
],
"zIndex": 123
}
],
"submittedFiles": [
{
"additionalInfo": "<string>",
"content": "as0ia4jdqecwq0u5s1omd9krs4u244ic2n2545kyhyat9imkwyg1bgec16r94tth",
"fileExtension": "pdf",
"fileType": "pdf",
"hasPassword": true,
"mimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"name": "IDCardFront.pdf",
"pages": 8,
"public": true,
"size": 522481,
"timestamp": "2023-11-07T05:31:56Z",
"user": "john.doe@example.com"
}
],
"tags": {
"global": [
"Contract",
"2026"
],
"user": [
"To review"
]
},
"term": {
"nextNotificationOn": "2026-11-30T08:00:00.000Z",
"nextRenewalOn": "2027-01-01T00:00:00.000Z",
"nonFixedTerm": {
"noticePeriod": "3M",
"terminationStartDate": "2026-10-01T00:00:00.000Z"
},
"reminders": [
{
"nextReminderOn": "2026-11-30T08:00:00.000Z",
"notifyOwner": true,
"period": "30d",
"recipients": [
"jane.doe@example.com"
],
"sentOn": "2026-11-30T08:00:07.412Z",
"skipped": true,
"time": "09:00",
"timeZone": "Europe/Prague"
}
],
"renewal": {
"finalDate": "2030-12-31T00:00:00.000Z",
"lastRenewedOn": "2027-01-01T00:15:03.118Z",
"maxRenewals": 50,
"noticeDueOn": "2026-09-30T00:00:00.000Z",
"noticePeriod": "3M",
"period": "1y",
"renewedCount": 1,
"type": "auto"
},
"timeZone": "Europe/Prague"
},
"termType": "fixed_term",
"thumbnails": "s1pss1atbzli272pinbt48n2ssy96ax2pwgqrz5qyzklwxg1kl0tq6anvz1p97xj",
"tika": {
"content_ocr": "<string>",
"content_text": "<string>",
"language": "<string>"
},
"tikaStatus": "<string>",
"usePdfA": true,
"workflow": [
{
"archived": true,
"group": [
"<string>"
],
"history": [
{
"action": 123,
"comment": "<string>",
"date": "2023-11-07T05:31:56Z",
"fileChanged": true,
"fileName": "contract.pdf",
"groupReceiver": [
"<string>"
],
"mentionedDocuments": [
"<string>"
],
"mentionedUsers": [
"jane.doe@example.com"
],
"mimetype": "application/pdf",
"name": "document_signed",
"newRevision": 123,
"newTitle": "<string>",
"originalFileName": "contract.docx",
"originalMimetype": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"originalRevision": 123,
"originalTitle": "<string>",
"sent": true,
"shareEmail": "<string>",
"shareFinal": true,
"shareGroup": "<string>",
"shareType": "<string>",
"shareUser": "<string>",
"signatureComponents": "<string>",
"state": 123,
"tags": [
"<string>"
],
"titleChanged": true,
"type": "document_signed",
"user": {
"name": "john.doe@example.com",
"type": "internal"
},
"userReceiver": [
{
"name": "john.doe@example.com",
"type": "internal"
}
]
}
],
"id": "a0d01c9d-f72f-4c57-af11-e26bda19cc590",
"lastAction": {
"archive": true,
"commentRequired": true,
"following": "<string>",
"id": 5,
"isInitial": true,
"multipleReceivers": true,
"name": "create",
"nextState": 1,
"predefinedReceiver": true,
"receiver": "john.doe@example.com",
"recipient": true,
"rights": "<string>",
"send": true,
"stateId": 0
},
"lastRequest": {
"commentRequired": true,
"id": 5,
"isInitial": true,
"multipleReceivers": true,
"name": "request_approval",
"nextState": 1,
"predefinedReceiver": true,
"receiver": "john.doe@example.com",
"recipient": true,
"resolvedBy": 5,
"rework": true,
"rights": "<string>",
"sign": true,
"stateId": 0
},
"receivedDate": "2023-11-07T05:31:56Z",
"state": 1,
"stateName": "created",
"timeOfDuration": 86400000,
"user": [
{
"name": "john.doe@example.com",
"type": "internal"
}
],
"workflowType": "wf_archive"
}
]
}{
"status": 400,
"type": "VALIDATION:INPUT_INVALID",
"message": "Invalid input",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 401,
"type": "AUTH:UNAUTHORIZED",
"message": "Authentication failed",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 403,
"type": "AUTH:ACCESS_DENIED",
"message": "Access denied",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 428,
"type": "AUTH:MFA_REQUIRED",
"message": "MFA activation required",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}{
"status": 498,
"type": "SHARE_AUTH:TOKEN_INVALID",
"message": "Invalid share token",
"requestId": "3fa85f6457174562b3fc2c963f66afa6"
}Query Parameters
Body
Response
Returns the draft as it was saved.
Kind of term of the document the draft was set up from. Only a draft the platform sets up from an existing document carries it; a draft saved by a client never does.
fixed_term: The document expires on a set date and its contract is renewed, automatically or by hand.expiry_only: The document expires on a set date and nothing renews it.non_fixed_term: The contract runs until it is terminated. The document expires only once a termination has started, the notice period after it.
fixed_term, expiry_only, non_fixed_term, null