【问题标题】:to attach a pdf/other file at time of envelope creation / draft envelope in Docusign在 Docusign 中创建信封/草稿信封时附加 pdf/其他文件
【发布时间】:2020-11-01 11:27:27
【问题描述】:

目标是在创建信封/草稿信封时附加一个 pdf/其他文件。我正在使用 PHP5 Docusign。

请在此处找到随附的“create_proposal.php”作为“create_proposal.txt”以供参考。

// instantiate a new envelope attachment
$content_bytes = file_get_contents("test.pdf");
$doc1_b64 = base64_encode($content_bytes);

$document1 = new \DocuSign\eSign\Model\Document([ # create the DocuSign document object
'document_base64' => $doc1_b64,
'name' => 'Order acknowledgement', # can be different from actual file name
'file_extension' => 'pdf', # many different document types are accepted
'document_id' => '1' # a label used to reference the doc
]);

$envelop_definition->setDocuments([$document1]);

回复是:

<pre>DocuSign\eSign\Client\ApiException Object
(
[responseBody:protected] => O:8:"stdClass":2:{s:9:"errorCode";s:33:"TAB_PAGENUMBER_IS_NOT_IN_DOCUMENT";s:7:"message";s:134:"The pagenumber specified in the tab element is not in the document that the tab refers to. Tab on Page 4 of Document 1 for Recipient 1";}
[responseHeaders:protected] => Array
(
[0] => HTTP/1.1 400 Bad Request
[Cache-Control] => no-cache
[Content-Length] => 196
[Content-Type] => application/json; charset=utf-8
[X-RateLimit-Reset] => 1604228400
[X-RateLimit-Remaining] => 992
[X-RateLimit-Limit] => 1000
[X-BurstLimit-Remaining] => 499
[X-BurstLimit-Limit] => 500
[X-DocuSign-TraceToken] => 943befbf-c776-4d03-a091-be5202acede7
[X-DocuSign-Node] => DA4FE36
[Date] => Sun, 01 Nov 2020 10:10:54 GMT
[Vary] => Accept-Encoding
)

请提供解决方案。谢谢。

【问题讨论】:

    标签: docusignapi attachment envelope


    【解决方案1】:

    Manish,看看错误,它看起来与为用户分配标签有关。您能否提供更多代码,因为不清楚您是否使用模板,如何设置选项卡等。您是否尝试从here 下载并运行 PHP 代码示例。您也可以从here 下载快速入门

    【讨论】:

      猜你喜欢
      • 2022-08-24
      • 1970-01-01
      • 2013-10-13
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-09-04
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多