BoldSign AI Assistant
Chat with the BoldSign AI AssistantChange the Recipient of a Document
In the event that you've sent a document to an incorrect signer and the document remains unsigned, there's no need to worry. BoldSign provides a straightforward option to change the recipient. This guide outlines the steps to effectively modify the recipient of a document.
BoldSign provides an API that allows you to programmatically change the recipient of a document. The following are the code examples in different programming languages to assist you in achieving this task:
Code snippet
curl -X 'PATCH' \ 'https://api.boldsign.com/v1/document/changeRecipient?documentId={Your document Id}' \
-H 'X-API-KEY: {your API key}' \
-H 'Content-Type: application/json' \
-d '{
"newSignerName": "{New signer name}",
"reason": "{Reason to change signer}",
"newSignerEmail": "{Old signer email}",
"oldSignerEmail": "{New signer email}"
}'
var apiClient = new ApiClient("https://api.boldsign.com", "{your API key}");
var documentClient = new DocumentClient(apiClient);
documentClient.ChangeRecipient("{Your document Id}",
"{Old signer email}", "{Reason to change signer}", "{New signer name}", "{New signer email}");
import boldsign
configuration = boldsign.Configuration(host = "https://api.boldsign.com", api_key = "YOUR_API_KEY")
with boldsign.ApiClient(configuration) as api_client:
document_api = boldsign.DocumentApi(api_client)
document_id = "YOUR_DOCUMENT_ID"
change_recipient = boldsign.ChangeRecipient(
newSignerName = "{New signer name}",
newSignerEmail = "{New signer email}",
oldSignerEmail = "{Old signer email}",
reason = "{Reason to change signer}"
)
change_recipient_response = document_api.change_recipient(
document_id = document_id,
change_recipient = change_recipient
)
<?php require_once "vendor/autoload.php";
use BoldSign\Configuration;
use BoldSign\Api\DocumentApi;
use BoldSign\Model\ChangeRecipient;
$config = new Configuration();
$config->setHost("https://api.boldsign.com");
$config->setApiKey('YOUR_API_KEY');
$document_api = new DocumentApi($config);
$change_recipient = new ChangeRecipient();
$change_recipient->setNewSignerName('{New signer name}');
$change_recipient->setNewSignerEmail('{New signer email');
$change_recipient->setOldSignerEmail('{Old signer email}');
$change_recipient->setReason('{Reason to change signer}');
$change_recipient_response = $document_api->changeRecipient($document_id = 'YOUR_DOCUMENT_ID', $change_recipient);
ApiClient client = Configuration.getDefaultApiClient();
client.setBasePath("https://api.boldsign.com");
client.setApiKey("YOUR_API_KEY");
DocumentApi documentApi = new DocumentApi(client);
ChangeRecipient changeRecipient = new ChangeRecipient();
changeRecipient.setNewSignerName("{New signer name}");
changeRecipient.setNewSignerEmail("{New signer email}");
changeRecipient.setOldSignerEmail("{Old signer email}");
changeRecipient.setReason("{Reason to change signer}");
ErrorResult changeRecipientResponse = documentApi.changeRecipient("YOUR_DOCUMENT_ID", changeRecipient);
import { DocumentApi, ChangeRecipient } from "boldsign";
const documentApi = new DocumentApi("https://api.boldsign.com");
documentApi.setApiKey("YOUR_API_KEY");
const changeRecipient = new ChangeRecipient();
changeRecipient.newSignerName = "{New signer name}";
changeRecipient.newSignerEmail = "{New signer email}";
changeRecipient.oldSignerEmail = "{Old signer email}";
changeRecipient.reason = "{Reason to change signer}";
const changeRecipientResponse = documentApi.changeRecipient("YOUR_DOCUMENT_ID", changeRecipient);
In the above example, replace the documentId with the ID of the document you created earlier. Then, update the newSignerName, newSignerEmail, oldSignerEmail, and reason properties with the appropriate values.
By using these code snippets, the recipient of the document will be updated, and an email will be sent to the new signer containing the signing link for the document.