eSign Automation
This skill provides automation capabilities for the eSignGlobal electronic signature platform.
It enables AI agents to automate document signing workflows and integrate with eSignGlobal APIs.
This skill is maintained by the eSignGlobal team and is intended for safe automation of contract signing workflows.
Best For
Use this skill when the user wants to:
- - send a contract, agreement, or approval form for signature
- launch a new e-sign workflow from a local file
- send one document to one or more recipients for signing
- create a draft envelope and get an interactive sender view URL to configure and send it
- open an envelope preparation page in the browser to add files and signers interactively
- query the status and details of an envelope
- send a reminder to signers who have not yet signed
- cancel an in-progress envelope
- download signed documents or certificates after an envelope is completed
- check what files are available for a completed envelope
- verify or validate signatures in a signed PDF file
- check whether a PDF has been tampered with after signing
- inspect signer identity, signing time, or certificate details in a PDF
- look up a template and its fields
- render a template with filled-in field values to produce a document
- send a rendered template document for signature using its file key
- compare two versions of a contract to identify differences
- compare a draft contract against a standard baseline document
- check what changed between two PDF files
- add attachments (reference files) to a draft envelope
- delete attachments from a draft envelope before it is sent
- add CC (carbon copy) recipients to a draft or in-progress envelope
- remove CC recipients from a draft envelope
- add signers to a draft envelope
- remove signers from a draft envelope
Example requests:
- - "Send this contract to John for signature"
- "Start a signing workflow for this PDF"
- "Send this agreement to Alice and Bob"
- "Create a draft envelope called Offer Letter"
- "Get me a sender view link for envelope abc123"
- "Open the envelope preparation page so I can add files and signers"
- "What is the status of envelope abc123?"
- "Who has signed and who is still pending for this envelope?"
- "Remind the signers of envelope abc123 to sign"
- "Cancel envelope abc123, the signer info was wrong"
- "Download the signed files for envelope abc123"
- "Get me the signed PDF and certificate for this envelope"
- "Verify the signatures in this PDF"
- "Check if this signed PDF has been tampered with"
- "Who signed this document and when?"
- "What fields does template abc123 have?"
- "Render template abc123 with these values and send it to Alice for signing"
- "Use template abc123 to generate a contract and send it to Bob"
- "Compare these two contract PDFs and show me the differences"
- "Check what changed between contractv1.pdf and contractv2.pdf"
- "Compare this draft against our standard template"
- "I need to review the changes between the old and new version of this agreement"
- "Add this file as an attachment to envelope abc123"
- "Remove the attachment fileKey1 from envelope abc123"
- "Add alice@example.com as a CC recipient to envelope abc123"
- "Remove bob@example.com from the CC list of envelope abc123"
- "Add Bob Smith as a signer to envelope abc123"
- "Remove alice@example.com from the signer list of envelope abc123"
Installation
Use the external CLI through npx:
CODEBLOCK0
Setup
Before calling any send action, set ESIGNGLOBAL_APIKEY in the shell environment.
If the user does not already have an api key, direct them to:
- 1. Sign in at INLINECODE2
- Open INLINECODE3
- Create an application and copy the generated api key
CODEBLOCK1
Credential handling rules:
- - The CLI reads credentials only from INLINECODE4
- Do not implement local credential storage inside this skill
- Do not print or persist secrets
External CLI Pattern
Use the external command-line tool instead of bundled scripts:
CODEBLOCK2
CODEBLOCK3
CODEBLOCK4
CODEBLOCK5
CODEBLOCK6
CODEBLOCK7
CODEBLOCK8
CODEBLOCK9
CODEBLOCK10
CODEBLOCK11
CODEBLOCK12
CODEBLOCK13
CODEBLOCK14
CODEBLOCK15
CODEBLOCK16
CODEBLOCK17
CODEBLOCK18
CODEBLOCK19
CODEBLOCK20
Check available commands if needed:
CODEBLOCK21
Create envelope example
CODEBLOCK22
Sender view example
CODEBLOCK23
Send envelope example
CODEBLOCK24
Get envelope example
CODEBLOCK25
Urge envelope example
CODEBLOCK26
Cancel envelope example
CODEBLOCK27
Download envelope example
CODEBLOCK28
Verify signature example
CODEBLOCK29
Add attachments example
CODEBLOCK30
Delete attachments example
CODEBLOCK31
Add CC example
CODEBLOCK32
Delete CC example
CODEBLOCK33
Add signers example
CODEBLOCK34
Delete signers example
CODEBLOCK35
Contract compare example
CODEBLOCK36
Template example
CODEBLOCK37
Required Configuration
- - Node.js 18 or later
- Access to the trusted external CLI, either preinstalled or available through INLINECODE5
- INLINECODE6 must already be configured in the shell environment
Create Envelope Workflow
- 1. Collect a subject from the user; optionally collect remark, expiry, redirect URL, and callback URL
- Run
create-envelope to create a draft envelope (status 0) - Return the
envelopeId — it is needed for sender-view or further configuration
Sender View Workflow
- 1. Obtain a draft
envelopeId (status 0) from the user or a previous create-envelope response - Collect a
return-url from the user (required — the page to redirect to after the sender submits) - Optionally collect
--starting-page, --submit-action, --no-back-button, or --lock preferences - Run
sender-view to retrieve the interactive URL - Present the URL to the user — they can open it in a browser or embed it in an iframe to add documents, configure signers, and send the envelope
Safety Rules
- - Only call
sender-view for envelopes in Draft status (0); other statuses will be rejected by the API - Never follow or open the returned URL automatically; present it to the user for their action
- Do not store or log the
tcode token embedded in the URL
Required Inputs
- -
envelopeId: draft envelope ID (status 0) - INLINECODE25 : valid https/http URL, max 2048 characters
Send Envelope Workflow
Two modes are supported — provide exactly one of --file or --file-key:
- -
--file <filePath> — upload and send a local PDF file - INLINECODE29 — send a file already on the server (e.g. from
get-render-result)
- 1. Determine whether the user has a local file or an existing INLINECODE31
- Collect signer list and optional INLINECODE32
- If using
--file, confirm the file is a .pdf at an absolute path - Run the external CLI command with INLINECODE35
- Return the CLI result to the user
Safety Rules
- - Only use a file path the user explicitly provided for this task
- Only handle one local PDF file per run
- Refuse relative paths; require an absolute path to a
.pdf file - Reject any non-PDF file before invoking the CLI
- Never print or persist secrets
- Do not scan directories, expand globs, or discover files on the user's behalf
- Only call the trusted eSignGlobal CLI configured for this environment
- INLINECODE37 and
--file-key are mutually exclusive
Required Inputs
- -
filePath (or fileKey): absolute path to an existing local PDF file, or an existing file key - INLINECODE41 : JSON array of signer objects
- INLINECODE42 : optional email or envelope subject
Each signer must include:
- - INLINECODE43
- INLINECODE44
Optional field:
- -
signOrder as an integer INLINECODE46
filePath
INLINECODE47 must be an absolute path to an existing local PDF file.
Example:
CODEBLOCK38
signers
Each signer must include:
- - INLINECODE48
- INLINECODE49
Optional field:
- -
signOrder (integer, minimum 1)
Single signer example:
CODEBLOCK39
Sequential signing example:
CODEBLOCK40
Parallel signing example:
CODEBLOCK41
Template Workflow
- 1. Run
get-template to inspect the template fields (fieldId, fieldName, fieldType, required) - Run
render-template with the collected field values — returns a INLINECODE58 - Run
get-render-result and poll until taskStatus is Succeeded (2) — returns a INLINECODE62 - Run
send-envelope --file-key with the fileKey to send the rendered document for signing
Safety Rules
- - Only fill field values the user has explicitly provided
- Do not invent or guess field values
- INLINECODE65 and
--file-key are mutually exclusive; use --file-key when a fileKey is already available
Required Inputs
- -
templateId: template ID provided by the user - INLINECODE69 : array of
{ fieldId, fieldValue } for required fields - INLINECODE71 : signer list (same format as Send Envelope Workflow)
Get Envelope Workflow
- 1. Obtain the
envelopeId from the user or a previous send-envelope response - Run
get-envelope to retrieve full envelope details - Present the status, signer progress, and document list to the user using the Get Envelope Output Format below
Envelope status codes: 0=Draft, 1=In Progress, 2=Completed, 3=Expired, 4=Declined, INLINECODE80
Signer status codes: 0=Pending, 1=Signing, INLINECODE83
Get Envelope Output Format
Always present get-envelope results using this exact template:
CODEBLOCK42
Envelope status icon and label mapping:
⏳ | Waiting for Others |
| 2 | ✅ | Completed |
| 3 | ❌ | Expired |
| 4 | ❌ | Declined |
| 5 | ❌ | Canceled |
Initiator: always show as INLINECODE85
Signer status icon and label mapping:
⏳ | Signing |
| 2 | ✅ | Signed |
Bottleneck marker: append <- Current Bottleneck to the first signer whose status is 0 (Pending) or 1 (Signing) when the envelope is In Progress.
CC status: always show as ⚪ Pending Sync if envelope is not yet Completed, ✅ Synced if Completed.
Rules:
- - Omit the CC row if
ccInfos is empty - Number signers sequentially: Signer 1, Signer 2, …
- Use
[subject] from the envelope response as the file name - Always use this format — never use a table or other layout for
get-envelope output
Urge Envelope Workflow
- 1. Confirm the envelope is in progress (status
1) before sending a reminder - Run
urge-envelope to notify all pending signers - Inform the user that reminders are rate-limited to once every 30 minutes per envelope
Cancel Envelope Workflow
- 1. Confirm the reason for cancellation with the user before proceeding
- Run
cancel-envelope with --confirm — cancellation is irreversible - After cancellation the envelope is suspended and all signatures within it are invalid
Download Envelope Workflow
- 1. Obtain the
envelopeId from a previous send-envelope response or from the user - Run
--type list to check envelope status and retrieve individual file download URLs - If
envelopeStatus is 2 (Completed), share the downloadUrl for each file with the user - If the envelope is not yet completed, inform the user and wait
Envelope status codes: 0=Draft, 1=Signing, 2=Completed, 3=Expired, 4=Rejected, INLINECODE109
File types in the list response:
- -
CONTRACT — the signed document - INLINECODE111 — the signing audit certificate
- INLINECODE112 — any attachments
- INLINECODE113 — merged PDF (if enabled on the account)
Individual file download URLs are valid for 60 minutes. Download can only proceed when the envelope is Completed.
Verify Signature Workflow
- 1. Obtain an absolute path to a local PDF file from the user
- Run
verify-signature — no API key required, verification runs entirely offline - Parse and present the JSON result to the user
The command outputs:
- -
integrity — true (unmodified) / false (tampered) / null (unknown) - INLINECODE119 — number of signatures found
- Per-signature fields:
-
isValid —
true /
false /
null
-
signer — common name from the signing certificate
-
declaredTime — signing time (trusted timestamp preferred over local clock), UTC+08:00
-
signatureAlgorithm — e.g.
RSA / SHA-256
-
timestampIssuer — TSA certificate issuer, or
"Local time" when no trusted timestamp is present
-
certificate.serialNumber,
certificate.validFrom, INLINECODE132
INLINECODE133 works fully offline and does not require ESIGNGLOBAL_APIKEY.
Contract Compare Workflow
- 1. Determine whether the user has local PDF files or existing file keys for both the standard (baseline) and comparative documents
- Optionally collect
--filter-header-footer preference and any punctuation to ignore via INLINECODE136 - Run
contract-compare — if local paths are provided, the CLI uploads them automatically before comparing - Return the
contractCompareUrl to the user so they can open it in a browser to review highlighted differences
Safety Rules
- - Only use file paths the user explicitly provided for this task
- Require absolute paths to
.pdf files when local files are given - INLINECODE140 and
--standard-file-key are mutually exclusive; same for the comparative pair - Never follow or open the returned URL automatically; present it to the user for their action
- Supports PDF files up to 30 MB each
Required Inputs
- -
standardFile (or standardFileKey): absolute path to the baseline PDF, or an existing file key - INLINECODE144 (or
comparativeFileKey): absolute path to the PDF to compare against, or an existing file key
Optional Inputs
- -
--filter-header-footer: exclude headers and footers from comparison - INLINECODE147 : comma-separated punctuation marks to ignore (e.g.
".,。、")
Contract Compare Output Format
Present the result using this exact template:
CODEBLOCK43
Rules:
- - Always display the full URL on its own line so the user can click or copy it
- Always show the
contractCompareBizId for reference - Do not attempt to parse or summarize the differences — the comparison page handles that visually
Add Attachments Workflow
- 1. Obtain a draft
envelopeId (status 0) from the user or a previous create-envelope response - Collect the list of
fileKey strings to attach (upload files first via the Upload Documents API if needed) - Run
add-attachments with the envelope ID and file keys JSON array - Return the result to the user
Safety Rules
- - Only add attachments when the envelope is in Draft status (
0) - Do not upload or discover files on the user's behalf; require explicit file keys from the user
- Attachments are reference-only and are not signed
Delete Attachments Workflow
- 1. Obtain the
envelopeId and the fileKey values to remove from the user - Confirm the deletion with the user before proceeding — it cannot be undone once the envelope is sent
- Run
delete-attachments with INLINECODE159 - Return the result to the user
Safety Rules
- - Attachments can only be deleted before the envelope is initiated
- Always require
--confirm before proceeding - Never delete attachments the user has not explicitly listed
Add CC Workflow
- 1. Obtain the
envelopeId from the user or a previous create-envelope / send-envelope response - Collect the list of CC recipients — each must have
userEmail and INLINECODE165 - Run
add-cc — supported for envelopes in Draft (0) or In Progress (1) status - Return the updated CC list to the user
Safety Rules
- - The same email address cannot be added as CC more than once; the API will reject duplicates
- CC recipients can only view the envelope — they cannot sign
- INLINECODE169 must not contain these special characters:
/ \ : * " < > | ? or emoji
Required Inputs
- -
envelopeId: envelope ID (Draft or In Progress) - INLINECODE172 : JSON array of
{ userEmail, userName } objects
Delete CC Workflow
- 1. Obtain the
envelopeId and the email addresses of CC recipients to remove from the user - Confirm the deletion with the user before proceeding
- Run
delete-cc with --confirm — only supported for envelopes in Draft status (0) - Return the remaining CC list to the user
Safety Rules
- - CC recipients can only be deleted from envelopes in Draft status (
0) - Always require
--confirm before proceeding - Never remove CC recipients the user has not explicitly listed
Required Inputs
- -
envelopeId: draft envelope ID (status 0) - INLINECODE182 : JSON array of
{ userEmail } objects to remove
Add Signers Workflow
- 1. Obtain a draft
envelopeId (status 0) from the user or a previous create-envelope response - Collect the list of signers — each must have
userName, userEmail, and INLINECODE189 - Run
add-signers — new signers can only be appended after existing ones; inserting before a current or completed signer is rejected by the API - Return the updated signer list to the user
Safety Rules
- - Only add signers when the envelope is in Draft status (
0) - The same email address cannot be added twice (use delete then re-add to update)
- Maximum 10 signers per envelope
- INLINECODE192 must not contain these special characters:
/ \ : * " < > | ? or emoji
Required Inputs
- -
envelopeId: draft envelope ID (status 0) - INLINECODE196 : JSON array of
{ userName, userEmail, signOrder } objects
Optional Signer Fields
- -
businessId: developer-defined business number - INLINECODE199 :
auto (default), none, email, sms, INLINECODE204 - INLINECODE205 :
true to allow free stamp/signature placement - INLINECODE207 :
noAuth (default), accessCode, sms, emailAuth, etc.
Delete Signers Workflow
- 1. Obtain the
envelopeId and the email addresses of signers to remove from the user - Confirm the deletion with the user before proceeding
- Run
delete-signers with --confirm — only supported for envelopes in Draft status (0) - Return the remaining signer list to the user
Safety Rules
- - Signers can only be deleted from envelopes in Draft status (
0) - Always require
--confirm before proceeding - Never remove signers the user has not explicitly listed
Required Inputs
- -
envelopeId: draft envelope ID (status 0) - INLINECODE220 : JSON array of
{ userEmail } objects to remove
Output
Return the external CLI result. Do not bundle or implement upload logic inside this skill.
Verify Signature Output Format
Present each signature using this exact template:
CODEBLOCK44
Rules:
- - Use no emoji for
isValid === true or isValid === false;
- Repeat the block for each signature if signatureCount > 1
- If signatureCount === 0`, output: "No signatures found in this PDF"
Support
If you encounter any issues during invocation, visit the official website at https://www.esignglobal.com?source=agent to submit a support ticket.
电子签名自动化
该技能为eSignGlobal电子签名平台提供自动化能力。
它使AI代理能够自动化文档签署工作流程,并与eSignGlobal API集成。
该技能由eSignGlobal团队维护,旨在安全地自动化合同签署工作流程。
最佳用途
当用户希望执行以下操作时使用此技能:
- - 发送合同、协议或审批表以供签署
- 从本地文件启动新的电子签名工作流程
- 将一份文档发送给一个或多个收件人签署
- 创建草稿信封并获取交互式发送者视图URL以配置和发送
- 在浏览器中打开信封准备页面,以交互方式添加文件和签署人
- 查询信封的状态和详细信息
- 向尚未签署的签署人发送提醒
- 取消进行中的信封
- 信封完成后下载已签署的文档或证书
- 检查已完成信封可用的文件
- 验证或校验已签署PDF文件中的签名
- 检查PDF签署后是否被篡改
- 检查PDF中的签署人身份、签署时间或证书详情
- 查找模板及其字段
- 使用填充的字段值渲染模板以生成文档
- 使用文件密钥发送渲染后的模板文档以供签署
- 比较两个版本的合同以识别差异
- 将草稿合同与标准基线文档进行比较
- 检查两个PDF文件之间的变化
- 向草稿信封添加附件(参考文件)
- 在发送前从草稿信封删除附件
- 向草稿或进行中的信封添加抄送(CC)收件人
- 从草稿信封移除抄送收件人
- 向草稿信封添加签署人
- 从草稿信封移除签署人
示例请求:
- - 将此合同发送给John签署
- 为此PDF启动签署工作流程
- 将此协议发送给Alice和Bob
- 创建名为Offer Letter的草稿信封
- 给我信封abc123的发件人视图链接
- 打开信封准备页面,以便我添加文件和签署人
- 信封abc123的状态是什么?
- 谁已签署,谁仍在等待此信封?
- 提醒信封abc123的签署人签署
- 取消信封abc123,签署人信息有误
- 下载信封abc123的已签署文件
- 获取此信封的已签署PDF和证书
- 验证此PDF中的签名
- 检查此已签署PDF是否被篡改
- 谁签署了此文档,何时签署的?
- 模板abc123有哪些字段?
- 使用这些值渲染模板abc123并发送给Alice签署
- 使用模板abc123生成合同并发送给Bob
- 比较这两个合同PDF并显示差异
- 检查contractv1.pdf和contractv2.pdf之间的变化
- 将此草稿与我们的标准模板进行比较
- 我需要查看此协议新旧版本之间的变化
- 将此文件作为附件添加到信封abc123
- 从信封abc123移除附件fileKey1
- 将alice@example.com添加为信封abc123的抄送收件人
- 从信封abc123的抄送列表中移除bob@example.com
- 将Bob Smith添加为信封abc123的签署人
- 从信封abc123的签署人列表中移除alice@example.com
安装
通过npx使用外部CLI:
bash
npx @esignglobal/envelope-cli
设置
在调用任何发送操作之前,在shell环境中设置ESIGNGLOBAL_APIKEY。
如果用户尚未拥有API密钥,请引导他们:
- 1. 登录https://www.esignglobal.com?source=agent
- 打开设置 -> 集成 -> 应用
- 创建应用并复制生成的API密钥
bash
Windows PowerShell
$env:ESIGNGLOBAL
APIKEY=yourapi_key
macOS / Linux
export ESIGNGLOBAL
APIKEY=yourapi_key
验证连接
npx @esignglobal/envelope-cli config health
凭据处理规则:
- - CLI仅从ESIGNGLOBAL_APIKEY读取凭据
- 不要在此技能内实现本地凭据存储
- 不要打印或持久化密钥
外部CLI模式
使用外部命令行工具而非捆绑脚本:
bash
npx @esignglobal/envelope-cli create-envelope --subject [--remark ] [--expire ] [--redirect-url ] [--callback-url ]
bash
npx @esignglobal/envelope-cli sender-view --envelope-id --return-url [--starting-page ] [--submit-action ] [--no-back-button] [--lock ]
bash
npx @esignglobal/envelope-cli send-envelope --file --signers [--subject ] --confirm
bash
npx @esignglobal/envelope-cli send-envelope --file-key --signers [--subject ] --confirm
bash
npx @esignglobal/envelope-cli get-template --template-id
bash
npx @esignglobal/envelope-cli render-template --template-id [--file-name ] [--fields ] [--callback-url ]
bash
npx @esignglobal/envelope-cli get-render-result --task-id
bash
npx @esignglobal/envelope-cli get-envelope --envelope-id
bash
npx @esignglobal/envelope-cli urge-envelope --envelope-id
bash
npx @esignglobal/envelope-cli cancel-envelope --envelope-id --reason --confirm
bash
npx @esignglobal/envelope-cli download-envelope --envelope-id --type list
bash
npx @esignglobal/envelope-cli verify-signature --file
bash
npx @esignglobal/envelope-cli contract-compare (--standard-file | --standard-file-key ) (--comparative-file | --comparative-file-key ) [--filter-header-footer] [--filter-symbols ]
bash
npx @esignglobal/envelope-cli add-attachments --envelope-id --file-keys
bash
npx @esignglobal/envelope-cli delete-attachments --envelope-id --file-keys --confirm
bash
npx @esignglobal/envelope-cli add-cc --envelope-id --cc-infos [{userEmail:...,userName:...}]
bash
npx @esignglobal/envelope-cli delete-cc --envelope-id --cc-infos [{userEmail:...}] --confirm
bash
npx @esignglobal/envelope-cli add-signers --envelope-id --signers [{userName:...,userEmail:...,signOrder:1}]
bash
npx @esignglobal/envelope-cli delete-signers --envelope-id --signers [{userEmail:...}] --confirm
如果需要,检查可用命令:
bash
npx @esignglobal/envelope-cli help
创建信封示例
bash
npx @esignglobal/envelope-cli create-envelope --subject 服务协议 --remark 请审核并发送 --expire 604800
发件人视图示例
bash
步骤1:创建草稿信封
npx @esignglobal/envelope-cli create-envelope --subject 录用通知书
步骤2:获取交互式发件人视图URL
npx @esignglobal/envelope-cli sender-view --envelope-id
--return-url https://app.example.com/done
发送信封示例
bash
npx @esignglobal/envelope-cli send-envelope --file C:\\docs\\contract.pdf --signers [{userName:Bob Smith,userEmail:bob@example.com}] --subject 请签署此合同 --confirm
获取信封示例
bash
npx @esignglobal/envelope-cli get-envelope --envelope-id abc123
催促信封示例
bash
向待签署人发送提醒(速率限制:每个信封每30分钟一次)
npx @esignglobal/envelope-cli urge-envelope --envelope-id abc123
取消信封示例
bash
npx @esignglobal/envelope-cli cancel-envelope --envelope-id abc123 --reason 签署人信息不正确。 --confirm
###