DocuSign signs users in with their DocuSign account, which is the usual identity for products that send or track envelopes on the user's behalf.

## Copy the redirect URI

In the [Authdog console](https://console.authdog.com), select the project and environment, open **Authentication > Providers**, find **DocuSign**, and click **Enable**. Copy the redirect URI shown in the form:

```url
https://identity.authdog.com/api/v1/callback/<connectionId>
```

## Create the application

1. Open the [DocuSign Developer Center apps page](https://developers.docusign.com/) and add an app in your account under **Apps and Keys**.
2. Choose an **Authorization Code Grant** app.
3. Under **Redirect URIs**, paste the redirect URI from Authdog.
4. Generate a secret key and copy it, along with the **Integration Key**.
5. Grant consent for the app in your account before the first sign-in.

## Configure Authdog

| Field | Value |
| --- | --- |
| **Client ID** | The DocuSign **Integration Key** |
| **Client Secret** | The generated **Secret Key** |

Save, then toggle the connection **active**.

## What DocuSign returns

Authdog requests the `signature openid` scopes and reads the profile from `https://account.docusign.com/oauth/userinfo`.

The userinfo endpoint returns the user id, name, email, and the accounts the user belongs to, including which is the default.

The `signature` scope is part of the request because DocuSign issues it alongside identity. Consent is required once per user or granted organization-wide by an administrator.

## Test it

1. Open your environment's hosted sign-in page, or link to `https://identity.authdog.com/api/v1/signin/<connectionId>`.
2. Select the DocuSign button and complete the flow.
3. Confirm the user appears under **Users** in the console with a DocuSign identity linked.

## Troubleshooting

| Symptom | Cause |
| --- | --- |
| `consent_required` | The user or an admin has not granted consent for the integration key |
| `invalid_client` | Demo credentials used against the production host |
| Redirect or callback URL error | The URI registered with the provider does not match Authdog's exactly |
| Works in one environment only | Each environment has its own `connectionId`, and so its own redirect URI to register |

## Related

| Read | To learn how to |
| --- | --- |
| [Connectors](/docs/connectors) | Set up any other social provider |
