Extend document expiry
patch/v1/document/extendExpiryThe sender and its admin can only extend the expiration date of a document. Additionally, you can also notify the recipient one day prior to the expiry date.
You cannot perform this action to reduce the expiry date of a document, and this action can only be performed on documents that have not been signed yet.
Code snippet
curl -X PATCH "https://api.boldsign.com/v1/document/extendExpiry?documentId={documentId}" -H 'X-API-KEY: {your API key}' -H "Content-Type: application/json" -d "{\"newExpiryValue\": \"2022-12-15\", \"warnPrior\": true}"
var apiClient = new ApiClient("https://api.boldsign.com", "{apikey}"); var documentclient = new DocumentClient(apiClient); await documentclient.ExtendExpiryAsync("{documentId}", "2022-12-15", true).ConfigureAwait(false);
import requests import json url = "https://api.boldsign.com/v1/document/extendExpiry?documentId={documentId}" payload = json.dumps({ "newExpiryValue": "2022-12-15", "warnPrior": true }) headers = { 'X-API-KEY': '{your API key}', 'Content-Type': 'application/json' } response = requests.request("PATCH", url, headers=headers, data=payload) print(response.text)
const axios = require('axios'); await axios.patch( 'https://api.boldsign.com/v1/document/extendExpiry', { newExpiryValue: '2022-12-15', warnPrior: true }, { params: { documentId: '{documentId}' }, headers: { 'X-API-KEY': '{Your API key}', 'Content-Type': 'application/json' } } );
Query parameters
documentIdstringRequired | ID of the requested document |
Request body
newExpiryValuestring($date)Required | New expiry date of the document. The expiration date must not exceed 180 days from the document creation date. If the document’s default expiry date type is specified as Days, set the new extended expiry value in yyyy-MM-dd format (‘2022-12-15’). If the document’s default expiry date type is specified as Hours, set the new extended expiry value in integer format (‘12’). If the document’s default expiry date type is specified as Specific Date and Time, set the new extended expiry value in ISO date time format (‘2022-12-15T10:58:04.863Z’). |
onBehalfOfstring | If the document is created on behalf of the sender, the sender's identity email address must be specified. |
warnPriorBoolean | If the value is null, the existing document configuration will be used. If the value is true, a signing notification mail will be sent one day before the expiration date. If the value is false, one day before signing notification mail will not be sent. |
Example response
200 Success