Docusign list of unsigned envelopes - docusignapi

When an admin user logs in to my app, I need a list of unsigned envelopes. What is the recommended way to get this list? I am using rest api v2.

You may want to clarify what falls under the category of 'unsigned'. Per below, you can run a query that returns any envelope that has been sent (unopened), and delivered (opened, but still not finished). This does not include envelopes that may have been declined by the signer for example, though you can modify your search query to include this status. Example query
GET: https://demo.docusign.net/restapi/v2/accounts/<removed>/envelopes?from_date=9-15-2015+12:00:00+AM&status=sent,delivered
Sample documentation:
https://docs.docusign.com/esign/restapi/Envelopes/Envelopes/listStatusChanges/

Related

Are there any APIs that list Envelope IDs as a Signer?

I'm looking for an API call that would effectively allow a Signer account to poll for Envelope IDs. Ideally I would like to get the envelopes id's of documents that fall under the "Action Needed" criteria.
I have looked into using the listStatusChanges GET Request, but it only returns envelope ID's that have been sent from other Docusign accounts.
Here is an example. For you to use this, you would need to replace your account and user Ids
GET <serverURI>/restapi/v2.1/accounts/ae232f1f-xxxx-xxxx-xxxx-626847fad8bb/envelopes?from_date=2020-01-26T08:00:00.000Z&to_date=2020-03-29T06:59:58.000Z&user_id=ee76c29e-xxxx-xxxx-xxxx-a0f95cd8e225&start_position=0&count=39&order=desc&order_by=last_modified&folder_ids=awaiting_my_signature&folder_types=normal,inbox,sentitems&include=recipients,powerform,folders&include_purge_information=true&query_budget=3
This is probably more than you need, but that's how the web app does it.

Grabbing docusign envelope status and recipients in a single API call

I'm using the docusign api and am having some trouble with a query string param. Basically I'm trying to grab the recipient information of an envelope along with the status of the envelope in a single call.
I am able to grab each of information individually with the following api calls and they both work
1.) Envelope endpoint (has a status field with overall envelope status such as Signed, Voided, Declined, etc...):
https://na2.docusign.net/restapi/v2/accounts/:accountId/envelopes/:docusignEnvelopeId/
2.) Envelope/recipients endpoint (has information regarding recipients)
https://na2.docusign.net/restapi/v2/accounts/:accountId/envelopes/:docusignEnvelopeId/recipients
However, I'm trying to see if I can grab these information all within one API call. According to the docs here for the general envelope endpoint, I think I should be able to with a query param
https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/get#request.
Under the include Optional Query Parameters section, there's a param for "include" which says I can grab recipients from the 1st endpoint. "Specifies additional information about the envelope to return. Enter a comma-separated list, such as tabs,recipients. Valid values are..."
I've been trying to modify the first endpoint with this include param to look something like this...
https://na2.docusign.net/restapi/v2/accounts/:accountId/envelopes/:docusignEnvelopeId?include=recipients
But I have been unable to have recipients show up as well. Was wondering if I'm just typing in the param wrong or if this is not available anymore. Any help would be appreciated!
Thanks :)
The include parameters were added in v2.1 of the eSignature API, so they don't work in v2. Changing your URL to https://na2.docusign.net/restapi/v2.1/accounts/:accountId/envelopes/:docusignEnvelopeId?include=recipients should return the recipient info.

How can I pull a list of all the envelopes sent/received by all the users (like in report tab) through Docusign REST API?

I am an admin account user and to get insights from data I need to pull the details of all the envelopes from all accounts. The similar thing is what a report provides in Docusign dashboard but I need the list of recipients as well. Can anyone please help me. Thanks.
Listing envelopes sent by your users: Envelopes::listStatusChanges
I think that call may cover envelopes sent by anyone in your account (if the accessToken represents a user with admin privileges). But I'm not sure.
If it doesn't then you can loop through the account's users.
Tracking who has received an envelope through their DocuSign account is done with the Folders::listItems API call. You may need to list both the Inbox and Deleted folders. You also need to check that the person signed the specific envelope vs receiving it for some other reason (cc, certified copy, etc).
Finally, an alternative if you have higher volumes is to purchase the DocuSign Report Feed product (see note below). It will send you DB table dumps about your account activity on a regular basis so you can do your own reporting on DocuSign activity. It is the best way to have full access to report data. Ask your DocuSign contact for more info.
Note: I'm not sure of the exact name for the reporting product.
This can be done if you install DocuSign for Salesforce managed package and use Connect feature in DocuSign. Configure your webhooks to create DocuSign Status and DocuSign Recipient Status records for each send. Any DocuSign objects or custom object can be used in the Connect configuration, after selecting objects, select which events you want the results to be pushed back to Salesforce.
Use a parent object to store envelope details and child object for the recipient data. Use Envelope Id to relate the child records to the parent. Eventually, you will be able to build various reports on Salesforce.
More info here: https://support.docusign.com/guides/dfs-admin-guide-ds-connect-for-salesforce

Searching Shared Envelopes in Docusign

I'm currently using the docusign api to make a request that searches the user's folders in order to bring back all the envelopes that are out for signature. This works but it doesn't seem to bring back envelopes from shared folders.
Having executed the 'list' api action I can see that my user has access to another user's folders and having logged in as that user I can see that some signing requests have been sent. I'm just wondering if this is a limitation of the API search function or whether I'll have to perform a list then iterate through each folder requesting envelopes, the search API function has been quite useful as it allows me to return recipient information as a part of the request whereas it seems that listitems doesn't allow that.
Edit: I'm looking to perform a lookup that will bring back all of the envelopes that have been sent by user A and user B that are out for signature.
The situation is that we have multiple company accounts that can send docusign documents to customers. What we need to be able to do is to view all documents that are out for signature across all accounts in one single list.
Any help would be much appreciated.
Per, https://docs.docusign.com/esign/restapi/Folders/Folders/list/
call GET /v2/accounts/{accountId}/folders this will return list of folders which userA has access to, this will also include the list of userB folders. Once you get folderId from previous call then use below call to get the list of envelopes in the folder
GET /v2/accounts/{accountId}/folders/{folderId}

Possible values for "Action" value in DOCUSIGN API audit_event

There is a documentation about possible envelop status value from docusign for a given envelope.
Howver i am trying to understand if there are any documentation which lists out the possible "Action" value from docusign in the "Audit_event" REST API method.
The reaosn is I am storing the audit events locally to avoid multiple API calls and i wanted to account for all the possible action values.
Thanks for reading
Since there were any documentation provided, i am including the staus i have seen based on my reverse engg
Registered
Sent Invitations
Printable Copy Delivered
Printable Copy Attached to Email
AccessCode Passed
AccessCode Failed
Viewed
Signed
Approved
Resent
Voided
Declined
Correction Initiated
Correction Cancelled
Viewed In-Session
Corrected
I've never seen any documentation for possible values of the action property within a GET Envelope Audit Events response -- to the best of my knowledge, none exists. You might be stuck having to 'reverse engineer' to determine possible values. i.e., create envelopes via the DocuSign web console, act on them in a variety of ways (both as Sender and as Recipient) -- for example: Send Envelope, Void Envelope, Decline Envelope, Sign Envelope, View Envelope, Pass Signer Authentication, Fail Signer Authentication, etc. etc. etc. -- and then examine the corresponding action values that appear in the GET Envelope Audit Events response for those Envelopes.
Obviously this approach is not ideal, since someone fairly new to DocuSign won't necessarily know all of things that can be done with an Envelope, in order to trigger the various action values in the API response. Perhaps someone from DocuSign will see this post and chime in with a list of all possible values...or better yet, add this info to the API Guide one day soon.

Resources