Question

Create and Send envelope on behalf of another user

  • 27 April 2024
  • 2 replies
  • 24 views

Badge +1

How do you create and send an envelope on behalf of another user using the REST API?

 


2 replies

Userlevel 2
Badge +7

To create and send a DocuSign envelope on behalf of another user using the REST API, you can utilize the "Send On Behalf Of" (SOBO) functionality. This allows a user (agent) to send envelopes as if they were another user (principal). Here’s a general overview of how to do it:

  1. Authentication: The agent needs to authenticate using OAuth. Once authenticated, you can include the principal user's userId in the API request. 

Badge

Hi,

As Justin has mentioned, this is part of the authentication process.

When building your JWT, you can specify the userId you wish to impersonate. Listed in Step 2. Create a JWT of the link below

https://developers.docusign.com/platform/auth/jwt/jwt-get-token/

The user you are impersonating will need to provide consent to your application which can be done many ways:

Administrative consent. This is the best option for customer developers, because it requires nothing from your users. But this consent pattern generally can’t be used by ISVs, requires more work by the DocuSign administrator, and requires a product feature that is only included with some pricing plans.


Individual consent. This option has no prerequisites and can be used by customer developers and ISVs’ customers. But it requires specific steps by each user who will be impersonated via a JWT grant (discussed in the link below). Because it has no prerequisites, this consent pattern is also often used by developers while they’re developing or testing their applications.


Administrative consent for third-party (ISV) applications. The administrative consent pattern can only be used by third-party applications if the ISV implements an additional API protocol. (And the other prerequisites for administrative consent still apply.) Because of the prerequisites, this consent pattern does not have much usage.

more information here: https://www.docusign.com/blog/developers/oauth-jwt-granting-consent

Reply