VB.NET / DocuSign eSignature REST API / Gets status changes for one or more envelopes.
Back to Collection Items
' This example assumes the Chilkat API to have been previously unlocked.
' See Global Unlock Sample for sample code.
Dim http As New Chilkat.Http
Dim success As Boolean
Dim queryParams As New Chilkat.JsonObject
queryParams.UpdateString("ac_status","{{ac_status}}")
queryParams.UpdateString("block","{{block}}")
queryParams.UpdateString("cdse_mode","{{cdse_mode}}")
queryParams.UpdateString("continuation_token","{{continuation_token}}")
queryParams.UpdateString("count","{{count}}")
queryParams.UpdateString("custom_field","{{custom_field}}")
queryParams.UpdateString("email","{{email}}")
queryParams.UpdateString("envelope_ids","{{envelope_ids}}")
queryParams.UpdateString("exclude","{{exclude}}")
queryParams.UpdateString("folder_ids","{{folder_ids}}")
queryParams.UpdateString("folder_types","{{folder_types}}")
queryParams.UpdateString("from_date","{{from_date}}")
queryParams.UpdateString("from_to_status","{{from_to_status}}")
queryParams.UpdateString("include","{{include}}")
queryParams.UpdateString("include_purge_information","{{include_purge_information}}")
queryParams.UpdateString("intersecting_folder_ids","{{intersecting_folder_ids}}")
queryParams.UpdateString("last_queried_date","{{last_queried_date}}")
queryParams.UpdateString("order","{{order}}")
queryParams.UpdateString("order_by","{{order_by}}")
queryParams.UpdateString("powerformids","{{powerformids}}")
queryParams.UpdateString("query_budget","{{query_budget}}")
queryParams.UpdateString("requester_date_format","{{requester_date_format}}")
queryParams.UpdateString("search_text","{{search_text}}")
queryParams.UpdateString("start_position","{{start_position}}")
queryParams.UpdateString("status","{{status}}")
queryParams.UpdateString("to_date","{{to_date}}")
queryParams.UpdateString("transaction_ids","{{transaction_ids}}")
queryParams.UpdateString("user_filter","{{user_filter}}")
queryParams.UpdateString("user_id","{{user_id}}")
queryParams.UpdateString("user_name","{{user_name}}")
' Adds the "Authorization: Bearer {{accessToken}}" header.
http.AuthToken = "{{accessToken}}"
http.SetRequestHeader("Accept","application/json")
Dim resp As Chilkat.HttpResponse = http.QuickRequestParams("GET","https://domain.com/v2.1/accounts/{{accountId}}/envelopes",queryParams)
If (http.LastMethodSuccess = False) Then
Debug.WriteLine(http.LastErrorText)
Exit Sub
End If
Debug.WriteLine(resp.StatusCode)
Debug.WriteLine(resp.BodyStr)
Curl Command
curl -G -d "ac_status=%7B%7Bac_status%7D%7D"
-d "block=%7B%7Bblock%7D%7D"
-d "cdse_mode=%7B%7Bcdse_mode%7D%7D"
-d "continuation_token=%7B%7Bcontinuation_token%7D%7D"
-d "count=%7B%7Bcount%7D%7D"
-d "custom_field=%7B%7Bcustom_field%7D%7D"
-d "email=%7B%7Bemail%7D%7D"
-d "envelope_ids=%7B%7Benvelope_ids%7D%7D"
-d "exclude=%7B%7Bexclude%7D%7D"
-d "folder_ids=%7B%7Bfolder_ids%7D%7D"
-d "folder_types=%7B%7Bfolder_types%7D%7D"
-d "from_date=%7B%7Bfrom_date%7D%7D"
-d "from_to_status=%7B%7Bfrom_to_status%7D%7D"
-d "include=%7B%7Binclude%7D%7D"
-d "include_purge_information=%7B%7Binclude_purge_information%7D%7D"
-d "intersecting_folder_ids=%7B%7Bintersecting_folder_ids%7D%7D"
-d "last_queried_date=%7B%7Blast_queried_date%7D%7D"
-d "order=%7B%7Border%7D%7D"
-d "order_by=%7B%7Border_by%7D%7D"
-d "powerformids=%7B%7Bpowerformids%7D%7D"
-d "query_budget=%7B%7Bquery_budget%7D%7D"
-d "requester_date_format=%7B%7Brequester_date_format%7D%7D"
-d "search_text=%7B%7Bsearch_text%7D%7D"
-d "start_position=%7B%7Bstart_position%7D%7D"
-d "status=%7B%7Bstatus%7D%7D"
-d "to_date=%7B%7Bto_date%7D%7D"
-d "transaction_ids=%7B%7Btransaction_ids%7D%7D"
-d "user_filter=%7B%7Buser_filter%7D%7D"
-d "user_id=%7B%7Buser_id%7D%7D"
-d "user_name=%7B%7Buser_name%7D%7D"
-H "Accept: application/json"
-H "Authorization: Bearer {{accessToken}}"
https://domain.com/v2.1/accounts/{{accountId}}/envelopes
Postman Collection Item JSON
{
"name": "Gets status changes for one or more envelopes.",
"request": {
"method": "GET",
"header": [
{
"key": "Accept",
"value": "application/json"
},
{
"key": "Authorization",
"value": "Bearer {{accessToken}}"
}
],
"url": {
"raw": "{{baseUrl}}/v2.1/accounts/{{accountId}}/envelopes?ac_status={{ac_status}}&block={{block}}&cdse_mode={{cdse_mode}}&continuation_token={{continuation_token}}&count={{count}}&custom_field={{custom_field}}&email={{email}}&envelope_ids={{envelope_ids}}&exclude={{exclude}}&folder_ids={{folder_ids}}&folder_types={{folder_types}}&from_date={{from_date}}&from_to_status={{from_to_status}}&include={{include}}&include_purge_information={{include_purge_information}}&intersecting_folder_ids={{intersecting_folder_ids}}&last_queried_date={{last_queried_date}}&order={{order}}&order_by={{order_by}}&powerformids={{powerformids}}&query_budget={{query_budget}}&requester_date_format={{requester_date_format}}&search_text={{search_text}}&start_position={{start_position}}&status={{status}}&to_date={{to_date}}&transaction_ids={{transaction_ids}}&user_filter={{user_filter}}&user_id={{user_id}}&user_name={{user_name}}",
"host": [
"{{baseUrl}}"
],
"path": [
"v2.1",
"accounts",
"{{accountId}}",
"envelopes"
],
"query": [
{
"key": "ac_status",
"value": "{{ac_status}}"
},
{
"key": "block",
"value": "{{block}}"
},
{
"key": "cdse_mode",
"value": "{{cdse_mode}}"
},
{
"key": "continuation_token",
"value": "{{continuation_token}}"
},
{
"key": "count",
"value": "{{count}}"
},
{
"key": "custom_field",
"value": "{{custom_field}}"
},
{
"key": "email",
"value": "{{email}}"
},
{
"key": "envelope_ids",
"value": "{{envelope_ids}}"
},
{
"key": "exclude",
"value": "{{exclude}}"
},
{
"key": "folder_ids",
"value": "{{folder_ids}}"
},
{
"key": "folder_types",
"value": "{{folder_types}}"
},
{
"key": "from_date",
"value": "{{from_date}}"
},
{
"key": "from_to_status",
"value": "{{from_to_status}}"
},
{
"key": "include",
"value": "{{include}}"
},
{
"key": "include_purge_information",
"value": "{{include_purge_information}}"
},
{
"key": "intersecting_folder_ids",
"value": "{{intersecting_folder_ids}}"
},
{
"key": "last_queried_date",
"value": "{{last_queried_date}}"
},
{
"key": "order",
"value": "{{order}}"
},
{
"key": "order_by",
"value": "{{order_by}}"
},
{
"key": "powerformids",
"value": "{{powerformids}}"
},
{
"key": "query_budget",
"value": "{{query_budget}}"
},
{
"key": "requester_date_format",
"value": "{{requester_date_format}}"
},
{
"key": "search_text",
"value": "{{search_text}}"
},
{
"key": "start_position",
"value": "{{start_position}}"
},
{
"key": "status",
"value": "{{status}}"
},
{
"key": "to_date",
"value": "{{to_date}}"
},
{
"key": "transaction_ids",
"value": "{{transaction_ids}}"
},
{
"key": "user_filter",
"value": "{{user_filter}}"
},
{
"key": "user_id",
"value": "{{user_id}}"
},
{
"key": "user_name",
"value": "{{user_name}}"
}
],
"variable": [
{
"key": "accountId",
"value": "{{accountId}}",
"type": "string"
}
]
},
"description": "Retrieves envelope status changes for all envelopes. You can modify the information returned by adding query strings to limit the request to check between certain dates and times, or for certain envelopes, or for certain status codes. It is recommended that you use one or more of the query strings in order to limit the size of the response.\n\n### Important: Unless you are requesting the status for specific envelopes (using the `envelopeIds` or `transactionIds` properties), you must add a set the `from_date` property in the request.\n\nGetting envelope status using `transactionIds` is useful for offline signing situations where it can be used determine if an envelope was created or not, for the cases where a network connection was lost, before the envelope status could be returned.\n\n### Request Envelope Status Notes ###\n\nThe REST API GET /envelopes call uses certain filters to find results. In some cases requests are check for \"any status change\" instead of the just the single status requested. In these cases, more envelopes might be returned by the request than otherwise would be. For example, for a request with the begin date is set to Jan 1st, an end date set to Jan 7th and the status qualifier (`from_to_status`) set to `Delivered` — the response set might contain envelopes that were created during that time period, but not delivered during the time period.\n\nTo avoid unnecessary database queries, the DocuSign system checks requests to ensure that the added filters will not result in a zero-size response before acting on the request. The following table shows the valid envelope statuses (in the Valid Current Statuses column) for the status qualifiers in the request. If the status and status qualifiers in the API request do not contain any of the values shown in the valid current statuses column, then an empty list is returned.\n\nFor example, a request with a status qualifier (from_to_status) of `Delivered` and a status of \"`Created`,`Sent`\", DocuSign will always return an empty list. This is because the request essentially translates to: find the envelopes that were delivered between the begin and end dates that have a current status of `Created` or `Sent`, and since an envelope that has been delivered can never have a status of `Created` or `Sent`, a zero-size response would be generated. In this case, DocuSign does not run the request, but just returns the empty list.\n\nClient applications should check that the statuses they are requesting make sense for a given status qualifier."
},
"response": [
]
}