Before you use this tool

The user the connection acts as needs a CloudFiles Document Generation license. See Who the Agent Acts As.

Inputs

InputRequiredDescription
documentIdYesThe documentId that generate-document returned.

Document status fields

get-document-status returns these fields. Fields without a value are left out of the result.

FieldDescription
documentIdThe document's ID, used with get-document-status and send-for-signing.
statusgenerating, ready or failed. See Status values below.
recordIdThe Salesforce record the document was filled from.
fileNameThe document's file name.
savedFileIdThe saved file's ID in its library. On a Salesforce record, the ContentDocument ID.
savedLibraryWhere the document was saved: salesforce for the record's Salesforce Files, otherwise the folder's library.
savedDriveIdThe drive the document was saved in, for libraries with drives.
previewUrlOpens the document in the CloudFiles viewer. Stops working after a few minutes.
downloadUrlDownloads the document. The link expires after a short time.
errorWhy the document or its signing failed, written to be passed on to the user as it is.
signingStatusHow signing stands, once the document is generated. See Status values below.
signersWho the template sends the document to, in signing order, with the signer fields below.
signedPreviewUrlOpens the signed copy once signing is completed. Stops working after a few minutes.
signedDownloadUrlDownloads the signed copy once signing is completed. The link expires after a short time.

Signer fields

FieldDescription
nameThe signer's name.
emailThe signer's email address.
orderSigning order. Recipients with the same order receive the document together.
rolesigner signs the document, and copy receives the signed copy.
statusWhere this signer stands. See Signer status below.
changedAtWhen the status last changed, in ISO 8601 format.
declineReasonWhy the signer declined, when they did.

Status values

Document status

ValueMeaning
generatingThe document is not saved yet. Check again with get-document-status.
readyThe document is saved where savedLibrary says.
failedThe document could not be generated. error says why.

Signing status

ValueMeaning
noneThe template names no signers.
pendingThe document is about to be held for approval or sent.
waitingHeld until send-for-signing is called or someone clicks Approve on the record page.
sendingBeing sent through DocuSign.
sentSent to the signers.
completedEvery signer has signed.
declinedA signer declined to sign.
voidedThe signing request was voided.
failedThe signing request could not be sent.

Signer status

ValueMeaning
not_sentNot sent to this signer yet.
sentSent to this signer.
openedThe signer opened the document.
signedThe signer signed.
declinedThe signer declined to sign.
auto_repliedDocuSign received an automatic reply from the signer's email address, such as an out-of-office message.

Example requests

You askWhat the agent does
Is the quote ready?Calls get-document-status and, once the status is ready, shares the preview and download links.
Send me a fresh link to the proposal.Calls get-document-status again, which returns new preview and download links.
Has the customer signed yet? Who is still outstanding?Calls get-document-status and reports the signing status and each signer's progress.