Regarding Docusign envelope API - docusignapi

I am getting the below response using Docusign envelope API
{
""envelopeId"": ""0aac02c3-ccdc-4bfe-88af-eefa2438d696"",
""uri"": ""/envelopes/0aac02c3-ccdc-4bfe-88af-eefa2438d696"",
""statusDateTime"": ""2016-10-14T10:39:02.4900000Z"",
""status"": ""created""
}
I am unable to open the envelope, even though I have logged into the Docusign site in the web. Let me know the URL to open the envelope. The response doesn't give the exact URL.

Created status means you will find it in your draft folder and that it has not been sent. If you want a POST sender view then you will need to make the correct call and use the URL returned by DocuSign to access the view and send the envelope.

Related

Apex toolkit Envelope change sender, subject and message in Docusign Envelope

I have two problems with Docusign, first, always it sent the envelope with the same account, no matter who is logged always is sending using the same account, i don't know why.
Second, i want to change the subject and message, i am using the example for apex toolkit and i am using the template, but always it show the same subject Documents for your DocuSign signature.
https://www.docusign.com/blog/dsdev-sending-template-apex-toolkit
To change the subject of a message you can use the withEmail method and edit the emailSubject property. See the API reference for more details: https://developers.docusign.com/docs/salesforce/apex-toolkit-reference/envelope.html
Do your salesforce users have the DocuSign Sender permission? I'm thinking that could be the reason that envelopes aren't being sent from their account.

How to handle ACTIVATION_FAILED

I am creating an embedded signing experience within our web app, so have turned off the sending of emails by DocuSign. Our app will send any emails required itself.
The DocuSign envelope has a single recipient with an access code defined.
I use the createRecipient envelope view in order to get the DocuSign URL at which the recipient can sign the document.
When accessing this URL, the recipient is prompted to enter their access code. If instead of entering the access code, they click the I NEVER RECEIVED AN ACCESS CODE button, they get taken to the return URL with the event parameter set to XXX.
This is all working as I would expect.
However, if I then try to call the createRecipient function again for the envelope, I get an error response from the API:
{
"errorCode": "ACTIVATION_FAILED",
"message": "The token for a recipient that has failed activation cannot be generated."
}
If I login to the DocuSign site and look at the envelope, it shows an error message:
Authentication Failed: Resend to give recipient another chance to pass authentication, or correct to remove or change authentication details.
The envelope appears to be in a locked state.
I can click RESEND in the DocuSign site, or do a PUT request to the envelope via the API with ?resend_envelope=true and this results in the envelope "unlocking" and allows the call to the createRecipient envelope view to succeed.
However, this results in an email being sent by DocuSign to the user, which I don't want.
Can anyone advise how to unlock an envelope/recipient in an ACTIVATION_FAILED state without sending emails?
I tried the same flow and it works fine for me and I am not getting an email when clicking RESEND in the DocuSign site, or do a PUT request to the envelope via the API with ?resend_envelope=true. Please find the below steps which I took to replicate the issue:
Created an envelope with recipient with clientUserId as not null
Generated RecipientView Url using clientUserId
User was presented with AccessCode, then I clicked "Never
Received an Access Code"
Again tried to created RecipientView Url using clientUserId and
got ACTIVATION_FAILED error
Then I tried below call
PUT /restapi/v2/accounts/<accountId>/envelopes/<envelopeId>?resend_envelope=true
with blank body as
{
}
Instead of Put call, I even tried using Resend button from Webconsole and it also worked fine without triggering any email.
I did not receive any email
Now again tried to created RecipientView Url using clientUserId,
this time I could generate the URL and on opening that URL, I
could again get a screen to enter the Access Code

getting "Expected Stream" error while sending envelope from docusign console

We are opening draft envelope using DocuSign REST API in DocuSign web console from our website, so our user can add/edit tags in document and send envelope directly from docusign site. But while sending envelope we are getting "Expected Stream" error. Can anyone have an idea why this error can come?
This recipe shows how to use the SenderView method to open the Sender's view on DocuSign for an envelope that you've created in draft mode.
Your user can then tag the document(s) and send off the envelope.

Not receiving emails from DocuSIgn SandBox when envelope created through the API

When I upload a document using the Docusign API on the Sandbox and then send the document I do not receive any emails.
I've also logged on to the sandbox and tried to sign the document but don't have the option - status seems to be waiting for others (even though the document is only sent to my email).
When I create the envelope through the web site and send, I do get the email.
This has only started to happen in the last day or two. Had been working fine for us.
Is there a problem with Sandbox?
The issue was that we were passing the ClientUserId property for the Signer in the API call when creating the envelope.
I wasn't aware but this actually stops the notification emails being sent.
You can check Docusign system status at
https://trust.docusign.com/en-us/system-status/
When I wasn't received emails in the develop environment, it was because I hadn't set:
{ "status": "sent" }
...in the envelope definition. This is the documented way of indicating that you would like this envelope to be sent rather than just "created", which sets it as a draft.

Can I get the url for managing an envelope from the Docusign API?

I'm able to create an envelope with the API which returns the envelopeId which looks like:
13f23354-7eee-41d3-897a-c1353a1e465c
When I navigate to docusign in my browser and open the envelope the url is:
https://na2.docusign.net/MEMBER/EnvelopeSetup.aspx?ti=ad05458248c54654a16a54195bf72ffe
I don't see what that "ad05458248c54654a16a54195bf72ffe" id is. I've tried every envelope API in the documentation (many don't make sense, but I tried them anyways):
/accounts/{accountId}/envelopes/{envelopeId}
/accounts/{accountId}/envelopes/{envelopeId}/audit_events
/accounts/{accountId}/envelopes/{envelopeId}/custom_fields
/accounts/{accountId}/envelopes/{envelopeId}/email_settings
/accounts/{accountId}/envelopes/{envelopeId}/notification
/accounts/{accountId}/envelopes/{envelopeId}/templates
But that id isn't anywhere.
Is there a way to retrieve that URL id? and/or is there another way I can get the url for the envelope?
The ID that appears as part of any URL when you're using the DocuSign web console is an internal ID -- you cannot use it with the API in any way. The Envelope ID value that DocuSign returns in response to the "Create Envelope" API request is the ID that you'll want to use with any API request that requires an Envelope ID.
It's not exactly clear to me what you mean by "[url for] managing an envelope" -- but I'd suggest you explore the following operations in the DocuSign REST API Guide:
Post Envelope Correction (page 146)
Modify or Correct and Resend Recipient Information (page 137)
Post Sender View (page 149)
(I'd guess that "Post Envelope Correction" is likely what you're after.)

Resources