Skip to main content

Hello,

I’m trying to get the status of the envelope to send the envelope to second signatory once the first signatory has signed on Power Automate.

This is OK

  • I have got the envelope working so far either by sending to all signatories the same time or keeping a delay of window to send one after the other

This is Required

  • I need to send the envelope to signatories only after the signature, for this I’m trying to get the status of the envelope from HTTP operation that requires Access Token.
  • I’m following the below process to set this up
  1. Added app and integration key
  2. Redirect URL is set to “https://global.consent.azure-apim.net/redirect” for power automate
  3. Using this URL on browser to get the code “https://account-d.docusign.com/oauth/auth?response_type=code&scope=signature&client_id=<Integration Key>&redirect_uri=https://global.consent.azure-apim.net/redirect”
  4. Getting the authorization code with error “did not receive an expected state query parameter from the authorization service”
  5. Added HTTP operation with POST method, URI = “https://account-d.docusign.com/oauth/token”, Header content-type = “application/x-www-form-urlencoded”, grant_type=authorization_code&code=<YOUR_AUTHORIZATION_CODE>, &client_id=<integration key>&client_secret=<secret key>&redirect_uri=https://global.consent.azure-apim.net/redirect

But I get an error everytime HTTP operation runs “{"error":"invalid_grant","error_description":"expired_client_token"}”

 

Please let me know where I’m going wrong.

Thanks

I am seriously interested in this. I need to update tabs using external data that changes. I need to use the API, so how to silently get tokens for a power automate HTTP Connector

Ole


@OBEROLE @mohammed.qhuddus Power Automate does not support getting the grant token directly from the URL. (Does not matter if you provide the redirect URI also over there). 

 

The best way to perform programmatic actions is either use the DocuSign connector and authenticate with your account. In case the actions in the DocuSign connector do not support your use case, you can create a custom connector. You can follow my video tutorial here to setup a custom connector: https://www.youtube.com/watch?t=855&v=rR2kTM8bqMg&feature=youtu.be

 

Note that the video tutorial shows steps to add an action for requesting signatures. You will have to add action for getting the status by referencing the DocuSign api. 

 

Hope this Helps!


Thanks for your answer.

After following the video, I’m getting the below error.

I keep the redirect URI to this “https://login.microsoftonline.com/common/oauth2/nativeclient”, is it not correct?

 

 


@yashag2255

I would like to ask you in a simple way.

I made an envelope “DOCU1” and sent across to A,B and C. My envelope is getting signed up including some extra required data by all the three individuals whether inside or outside the organization. This works perfectly fine and there are no issues here.

The problem is, the envelope is sent to all the receivers the same time and whoever makes the sign first, that signature appears on the document first. I want it to be orderly fashioned and so I need to get the status whether A has already signed and only then send it to B and so on.

What can I do in the SAME FLOW to get the status of DOCU1 where based on the status the flow can be made.

For Example: I have a flow where I send an email with user response, through which based on the response I send another email.

Thank you

 


@mohammed.qhuddus The redirect error can be resolved by following the steps: 

  1. Create the custom connector. In the screenshot you have for the custom connector you can go to the security tab and then at the end you will see the redirect URI. 
  2. Grab that URI and then paste it in the redirect URLS on the DocuSign integration key settings. 

This will resolve your issue. 

Regarding the scenario you mentioned, you will have to add additional setup where you can use SharePoint lists or Dataverse tables to store information on who all the signature request was sent to and then use the DocuSign trigger in Power Automate to filter the source where you are storing the information and update that with status. To send an envelope to users in a sequential order, you need to add each recipient separately and also add routing order for the recipients in which they need to sign. 

 

Hope this Helps!


Reply