On behalf of

In BoldSign, you can perform several operations on behalf of another user. For this, you should add that user as your sender identity, and that user should approve your request. Once this is done, you can perform the actions like sending documents, download audit log, revoke, remind, change access code etc. The documents you sent on behalf of another user will be displayed under the Behalf Documents section in the BoldSign application.

Please refer to the Sender Identities article to know more details.

Send document on-behalf

post /v1/document/send

You can send documents to the signer on behalf of another user. When you send a document on behalf of another person, you will need to provide their email address in onBehalfOf property.

Code snippet

curl -X 'POST' \ 'https://api.boldsign.com/v1/document/send' \
     -H 'accept: application/json' \
     -H 'X-API-KEY: {your API key}' \
     -H 'Content-Type: multipart/form-data' \
     -F 'DisableExpiryAlert=false' \
     -F 'ReminderSettings.ReminderDays=3' \
     -F 'BrandId=' \
     -F 'ReminderSettings.ReminderCount=5' \
     -F 'EnableReassign=true' \
     -F 'Message=Please sign this.' \
     -F 'Signers={
          "name": "David",
          "emailAddress": "david@cubeflakes.com",
          "formFields": [
            {
              "fieldType": "Signature",
              "pageNumber": 1,
              "bounds": {
                "x": 100,
                "y": 100,
                "width": 100,
                "height": 50
              },
              "isRequired": true
            }
          ]
        }' \
      -F 'ExpiryDays=10' \
      -F 'EnablePrintAndSign=false' \
      -F 'AutoDetectFields=false' \
      -F 'OnBehalfOf=luthercooper@cubeflakes.com' \
      -F 'EnableSigningOrder=false' \
      -F 'UseTextTags=false' \
      -F 'SendLinkValidTill=' \
      -F 'Files=@agreement.pdf;type=application/pdf' \
      -F 'Title=Agreement' \
      -F 'HideDocumentId=false' \
      -F 'EnableEmbeddedSigning=false' \
      -F 'ExpiryDateType=Days' \
      -F 'ReminderSettings.EnableAutoReminder=false' \
      -F 'ExpiryValue=60' \
      -F 'DisableEmails=false'
var apiClient = new ApiClient("https://api.boldsign.com", "{your API key}");
var documentClient = new DocumentClient(apiClient);

var documentFilePath = new DocumentFilePath
{
    ContentType = "application/pdf",
    FilePath = "agreement.pdf", 
};

var filesToUpload = new List<IDocumentFile>
{
    documentFilePath,
};

var signatureField = new FormField(
  id: "sign",
  isRequired: true,
  type:FieldType.Signature,
  pageNumber: 1,
  bounds: new Rectangle(x: 100, y: 100, width: 100, height: 50));

var formFieldCollections = new List<FormField>()
{
    signatureField
};

var signer = new DocumentSigner(
  name: "David",
  emailAddress: "david@cubeflakes.com",
  formFields: formFieldCollections);

var documentSigners = new List<DocumentSigner>()
{
     signer
};

var sendForSign = new SendForSign()
{
    Message = "please sign this",
    Title = "Agreement",
    HideDocumentId = false,
    Signers = documentSigners,
    Files = filesToUpload,
    OnBehalfOf = "luthercooper@cubeflakes.com"
    };
var documentCreated = documentClient.SendDocument(sendForSign);
import requests

url = "https://api.boldsign.com/v1/document/send"

payload={'DisableExpiryAlert': 'false',
'ReminderSettings.ReminderDays': '3',
'BrandId': '',
'ReminderSettings.ReminderCount': '5',
'EnableReassign': 'true',
'Message': 'Please sign this.',
'Signers': '{
          "name": "David",
          "emailAddress": "david@cubeflakes.com",
          "formFields": [
            {
              "fieldType": "Signature",
              "pageNumber": 1,
              "bounds": {
                "x": 100,
                "y": 100,
                "width": 100,
                "height": 50
              },
              "isRequired": true
            }
          ]
        }',
'ExpiryDays': '10',
'EnablePrintAndSign': 'false',
'AutoDetectFields': 'false',
'OnBehalfOf': 'luthercooper@cubeflakes.com',
'EnableSigningOrder': 'false',
'UseTextTags': 'false',
'SendLinkValidTill': '',
'Title': 'Agreement',
'HideDocumentId': 'false',
'EnableEmbeddedSigning': 'false',
'ExpiryDateType': 'Days',
'ReminderSettings.EnableAutoReminder': 'false',
'ExpiryValue': '60',
'DisableEmails': 'false'}
files=[
  ('Files',('file',open('{file path}','rb'),'application/octet-stream'))
]
headers = {
  'accept': 'application/json',
  'X-API-KEY': '{your API key}'
}

response = requests.request("POST", url, headers=headers, data=payload, files=files)

print(response.text)
const axios = require('axios');
const FormData = require('form-data');
const fs = require('fs');

const form = new FormData();
form.append('DisableExpiryAlert', 'false');
form.append('ReminderSettings.ReminderDays', '3');
form.append('BrandId', '');
form.append('ReminderSettings.ReminderCount', '5');
form.append('EnableReassign', 'true');
form.append('Message', 'Please sign this.');
form.append('Signers', '{\n  "name": "David",\n  "emailAddress": "david@cubeflakes.com",\n  "formFields": [\n    {\n      "fieldType": "Signature",\n      "pageNumber": 1,\n      "bounds": {\n        "x": 100,\n        "y": 100,\n        "width": 100,\n        "height": 50\n      },\n      "isRequired": true\n    }\n  ]\n}');
form.append('ExpiryDays', '10');
form.append('EnablePrintAndSign', 'false');
form.append('AutoDetectFields', 'false');
form.append('OnBehalfOf', 'luthercooper@cubeflakes.com');
form.append('EnableSigningOrder', 'false');
form.append('UseTextTags', 'false');
form.append('SendLinkValidTill', '');
form.append('Files', fs.readFileSync('agreement.pdf;type=application/pdf'), 'agreement.pdf;type=application/pdf');
form.append('Title', 'Agreement');
form.append('HideDocumentId', 'false');
form.append('EnableEmbeddedSigning', 'false');
form.append('ExpiryDateType', 'Days');
form.append('ReminderSettings.EnableAutoReminder', 'false');
form.append('ExpiryValue', '60');
form.append('DisableEmails', 'false');

const response = await axios.post(
'https://api.boldsign.com/v1/document/send',
form,
{
  headers: {
    ...form.getHeaders(),
    'accept': 'application/json',
    'X-API-KEY': '{your API key}',
    'Content-Type': 'multipart/form-data'
  }
}
);

Request body

Field, Data TypeDescription
filesarrayThe files to be uploaded for sending signature request. .pdf, .png, .jpg, and .docx are supported file formats. The preferred file format is .pdf. You can upload up to 25 files. Each document may have a maximum of 1000 pages and must be no larger than 25 MB in size.
titlestringThis is the title of the document that will be displayed in the BoldSign user interface as well as in the signature request email.
messagestringA message for all the recipients. You can include the instructions that the signer should know before signing the document.
signersarrayDetails of the signers. One or more signers can be specified. DocumentSigner properties are available here.
ccarrayMail ID of the CC recipients. One or more CC recipients can be specified. DocumentCC properties are available here.
enableSigningOrderboolean Enables or disables the signing order. If this is enabled, then the signers can sign the document in the specified order and will not be able to sign parallel. The default value is false.
expiryDaysintegerThe number of days after which the document expires. The default value is 60 days.
ReminderSettings.EnableAutoReminderbooleanEnables or disables the auto reminder.
ReminderSettings.ReminderDaysintegerThe number of days between each automatic reminder.
ReminderSettings.ReminderCountintegerThe number of times the auto reminder should be sent.
disableEmailsbooleanDisables the sending of document related emails to all the recipients. The default value is false.
brandIdstringYou can customize the logo, colors and other elements of the signature request emails and document signing pages to match your company branding. The ID of the existing brand can be obtained from the branding API and from the web app.
hideDocumentIdbooleanDecides whether the document ID should be hidden or not.
labelsarrayLabels(tags) are added to the document to categorize and filter the documents. One or more labels can be added.
fileUrlsarrayThe URL of the files to be uploaded for sending signature request. .pdf, .png, .jpg, and .docx are supported file formats. The preferred file format is .pdf. You can upload up to 25 files. Each document may have a maximum of 1000 pages and must be no larger than 25 MB in size.
sendLinkValidTillstringConfigures the expiration for the generated URL. A maximum of 180 days can be assigned. The string should be in date-time format.
useTextTagsBooleanWhen enabled, it will convert all the tags defined in the document to BoldSign form fields. The default value is false.
textTagDefinitionarrayThis can be used for long text tag handling. TextTagDefinition properties are available here.
enablePrintAndSignbooleanAllows the signer to reassign the signature request to another person. The default value is true.
disableExpiryAlertarrayDisables the alert, which was shown one day before the expiry of the document.
documentInfoarrayOptions to customize the information, like the title and description of the document for a particular signer. DocumentInfo properties are available here.
onBehalfOfstringMail ID of the user to send the document on behalf of them.

DocumentSigner properties

Field, Data TypeDescription
namestringName of the signer. This name will appear on all the emails, notifications, and on the audit file.
emailAddressstringMail ID of the signer. This ID will appear on all the emails, notifications, and on the audit file.
privateMessagestringWhen the specified signer proceeds to sign the document, a message appears. You can include the instructions that the signer should know before signing the document.
authenticationCodestringThe authentication access code that must be entered by the signer to access the document. This should be shared with the signer.
signerOrderintegerSigning order of the signer. This is applicable when the signing order option is enabled.
enableEmailOTPbooleanEnables email OTP authentication. If this is enabled, the signer must enter the OTP that was received in the email to access the document.
signerTypestringType of the signer. The values are Signer, Reviewer and InPersonSigner.
hostEmailstringMail ID of the host. It is applicable when the signerType is set to InPersonSigner.
signerRolestringThe role of the signer.
formFieldsarrayList of form fields associated with the signer. FormField properties are available here.
languageintegerIndex of the language in which the document signing pages and emails for the signer should render. The supported languages are 1-English, 2-Spanish, 3-German, 4-French, and 5-Romanian.

FormField properties

Field, DataTypeDescription
idstringThe ID of the form field.
namestringName of the form field.
fieldTypestringType of the form field. The available values are Signature, Initial, CheckBox, TextBox, Label, DateSigned, RadioButton, Image, Attachment, EditableDate, Hyperlink, and Dropdown.
pageNumberintegerPage number in the document in which the form field has to be placed.
boundsRectanglePosition and size values of the form field to be placed. Bounds properties are available here.
isRequiredbooleanDecides whether this form field is required to be filled or not.
valuestringValue to be displayed on the label form field.
fontSizefloatSize of the font.
font stringFont family. The values are Courier, Helvetica, and TimesNewRoman.
fontHexColorstringColor of the font. The value should be hex color code. Example - #035efc.
isBoldFontbooleanDecides whether the font should be in bold or not.
isItalicFontbooleanDecides whether the font should be in italic or not.
isUnderLineFontbooleanDecides whether the font should be underlined or not.
lineHeightintegerHeight of a line in the text.
characterLimitintegerLimits the number of characters in the text.
groupNamestringThe group name of the form field. This field is required when the fieldType is set to RadioButton.
placeHolderstringA hint text to be displayed on the text form field by default.
validationTypestringType of validation for the text box form field. The values are Only Numbers, Regex, Currency, Email, and None.
validationCustomRegexstringValue for regex validation. This is applicable when the validationType is set to Regex.
validationCustomRegexMessagestringDescription for regex validation. This message is displayed when the signer enters an invalid regex format value in the text box form field.
dateFormatstringFormat of the date to be displayed on the date signed form field. The default value is MM/dd/yyyy.
imageInfoobjectOptions to customize the image form field. ImageInfo properties are available here.
attachmentInfoobjectOptions to customize the attachment form field. AttachmentInfo properties are available here.
editableDateFieldSettingsobjectOptions to customize the editable date form field. EditableDateFieldSettings properties are available here.
hyperLinkTextstringText to be displayed for the hyperlink.
dataSyncTagstringThe value that can be specified on two or more textbox form fields to sync them.
dropDownOptionsarrayThe values that have to be displayed on the dropdown form field. One or more values can be specified.

Bound properties

Field, DataTypeDescription
xfloatX coordinate value to place the form field.
yfloatY coordinate value to place the form field.
widthfloatWidth of the form field.
heightfloatHeight of the form field.

ImageInfo properties

Field, DataTypeDescription
titlestringTitle of the image form field.
descriptionstringDescription of the image form field.
allowedFileExtensionsstringControls the image formats that are allowed to upload on the image form field. The values are .jpg or .jpeg, .svg, .png, and .bmp.

AttachmentInfo properties

Field, DataTypeDescription
titlestringTitle of the attachment form field.
descriptionstringDescription of the image form field.
allowedFileTypesstringControls the file formats that are allowed to upload on the attachment form field. The values are PDF, Document, and Image.

EditableDateFieldSettings properties

Field, DataTypeDescription
dateFomatstringFormat of the date to be displayed on the date signed form field. The default value is MM/dd/yyyy.
minDatestringThe minimum date that can be selected. The string should be in date-time format.
maxDate stringThe maximum date that can be selected. The string should be in date-time format.

DocumentCC properties

Field, DataTypeDescription
emailAddressstringMail ID of the CC recipients.

TextTagDefinition properties

Field, DataTypeDescription
definitionIdstringThe definition id of the text tag.
typeFieldTypeThe type of the form field.
signerIndexintegerThe signer index of the form field.
isRequiredbooleanWhen disabled, the signer is not required to fill out the specific form field. The default value is true.
placeHolderstringThe placeholder of the form field.
fieldIdstringThe field id of the form field.
fontobjectThe font of the form field. Font properties are available here.
validationobjectWhen we select the type as TextBox, the validation of the form field is required. Validation properties are available here.
sizeobjectThis can be used to specify the form field's height and width. Size properties are available here.
dateFormatstringThe date format of the form field.
radioGroupNamestringThe form field's group name, which is required when we set the type as RadioButton.
valuestringThe value of the form field.
dropDownOptionsarrayThe options of the dropdown form field.

Font properties

Field, DataTypeDescription
nameFontFamilyFont family. The values are Courier, Helvetica, and TimesNewRoman.
colorstringColor of the font.
sizefloatSize of the font.
styleFontStyleStyle of the font. The values are Regular, Bold, Italic, and Underline.
lineHeightintegerHeight of a line in the text.

Validation properties

Field, DataTypeDescription
typestringThe validation type of the text box form field. The available values are None, NumbersOnly, EmailAddress, Currency, and CustomRegex. The default value is None.
regexstringThe custom regex of the text box form filed. When we set the ValidationType to CustomRegex, it will be required.

Size properties

Field, DataTypeDescription
widthfloatThe width of the form field.
heightfloatThe height of the form field.

DocumentInfo properties

Field, DataTypeDescription
languageintegerLanguage in which the document signing pages and emails for the signer should be rendered. The supported languages are 1-English, 2-Spanish, 3-German, 4-French, and 5-Romanian.
titlestringTitle of the document.
descriptionstringA message for the singer. You can include the instructions that the signer should know before signing the document.

Example response

201 Created

{
  "documentId": "8f59295d-xxxx-xxxx-xxxx-e7dc88cfff2c"
}