Skip to content
Scott Kirkland edited this page Jun 23, 2022 · 9 revisions

Welcome to the Peaks wiki!

DocuSign Setup Information (General)

Get DocuSign working in the demo environment https://admindemo.docusign.com/ using the following steps. Once everything works you'll need to submit the application for review, pass, and then promote to production, where you'll have to redo the following steps with production keys and accounts.

  1. Go to "API and Keys" and create an application. We are using JWT Authentication so follow those guidelines and create an RSA Key Pair. For "RedirectURIs" you can put any valid URL you want.

  2. Make sure your sender/service account is in DocuSign, and if not then add them.

  3. Get consent from the sender account. This only needs to be done once. Login as the sender account and craft a url as described in step1 of the JWT instructions document, then click Accept on the consent screen.

  4. Get user and account info. This is a bit tricky but just follow the instructions at https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant. From the userinfo endpoint response at the end, you'll need to grab the accountID (our docusign account), baseURL (For api calls) and your user's SUB (the userID of the sender account).

  5. Now you are ready to send! Using JWT auth and your private key, along with the info you grabbed above, you can make all the calls your heart desires.

Adding new DocuSign Accounts

  1. Have someone add the [email protected] user to their account/instance with Bulk Sender rights.

  2. Login to https://outlook.office365.com/ with the [email protected] and approve the invitation to the new account.

  3. (optional) Create a sample template as the peaks account for testing.

  4. This is all you need to do. If you'd like to use the use the API to verify the accounts that are available under our parent sub, continue:

  5. Now we need to call the DocuSign API and ultimately get the user's account id and baseURL for the new account/instance. To do that, follow the instructions at https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant, all info you need is in 1pass.

  6. Ensure when you called the user-info endpoint above you see the newly created account. Now you should be ready to send. PEAKS may need a restart to ensure it sees the new docusign user.

Notes on using docusign API in above steps Get auth code

https://account.docusign.com/oauth/auth?response_type=code&scope=signature&client_id=<integration key from 1pass>&state=a39fh23hnf23&redirect_uri=https://peaks.ucdavis.edu/ds/callback

Get token

curl --location --request POST 'https://account.docusign.com/oauth/token' \
--header 'Authorization: Basic <Integration+Secret BtoA from 1pass>' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=authorization_code' \
--data-urlencode 'code=<previous step code, good for 2 minutes>'

Spaces

File share: \yonder.ucdavis.edu\GFS_SATA_LUSIDEPOT_CIFS\prod\get\keas

Clone this wiki locally