简体   繁体   中英

DocuSign API Explorer - Creating a draft envelope with a document and recipient

I am trying to create aa draft envelope with a document and a recipient through DocuSign API Explorer using my DocuSign Developer Sandbox account.

Despite a SUCCESS response, the actual envelope contains neither the document or the recipient I included in the Request. Where am I going wrong?

Here is the Request XML:

<envelopeDefinition 
    xmlns:i="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns="http://www.docusign.com/restapi">
    <documents>
        <documentBase64>&lt;Base64BytesHere&gt;</documentBase64>
    </documents>
    <emailSubject>Test from API Explorer</emailSubject>
    <recipients>
        <signers>
            <email>nobody@nobody.com</email>
            <name>John Smith</name>
        </signers>
    </recipients>
    <status>created</status>
</envelopeDefinition>

Here is the empty envelope screenshot

You're missing some parameters for the document and recipient objects, for instance you need to add a documentId and documentName for the document in addition to the document bytes.

Here's what a full XML request should look like:

<envelopeDefinition xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.docusign.com/restapi">
    <emailSubject>Test Subject</emailSubject>
    <documents>
      <document>
        <name>document.pdf</name>
        <documentId>1</documentId>
        <documentBase64>&lt;Base64BytesHere&gt;</documentBase64>
      </document>
    </documents>
    <recipients>
        <signers>
            <tabs>
                <signHereTabs>
                  <signHereTab>
                    <pageNumber>1</pageNumber>
                    <documentId>1</documentId>
                    <xPosition>100</xPosition>
                    <yPosition>100</yPosition>
                  </signHereTab>
                </signHereTabs>
            </tabs>
            <routingOrder>1</routingOrder>
            <recipientId>1</recipientId>
            <name>My Name</name>
            <email>email@email.com</email>
        </signers>
    </recipients>
    <status>created</status>
</envelopeDefinition>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM