Finished document

This commit is contained in:
Dewi Roberts
2025-06-17 14:49:41 +03:00
parent e63545458c
commit 50cfec98f9

View File

@ -33,8 +33,8 @@ To support the integration of Papra with authentik, you need to create an applic
- **Application**: provide a descriptive name, an optional group for the type of application, the policy engine mode, and optional UI settings.
- **Choose a Provider type**: select **OAuth2/OpenID Connect** as the provider type.
- **Configure the Provider**: provide a name (or accept the auto-provided name), the authorization flow to use for this provider, and the following required configurations.
- Note the **Client ID** and **Client Secret** values because they will be required later.
- Set a `Strict` redirect URI to `https://papra.company/api/auth/oauth2/callback/:authentik`.
- Note the **Client ID**, **Client Secret**, and **Slug** values because they will be required later.
- Set a `Strict` redirect URI to `https://papra.company/api/auth/oauth2/callback/authentik`.
- Select any available signing key.
- **Configure Bindings** _(optional)_: you can create a [binding](/docs/add-secure-apps/flows-stages/bindings/) (policy, group, or user) to manage the listing and access to applications on a user's **My applications** page.
@ -42,27 +42,20 @@ To support the integration of Papra with authentik, you need to create an applic
## Papra configuration
Add the following to your Papra environment variables:
Add the following environment variable to your Papra deployment and ensure that you update the client ID, client secret, and application slug:
```yaml
AUTH_PROVIDERS_CUSTOMS='[
{
"providerId": "custom-oauth2",
"providerName": "Custom OAuth2",
"providerIconUrl": "https://api.iconify.design/tabler:login-2.svg",
"clientId": "your-client-id",
"clientSecret": "your-client-secret",
"type": "oidc",
"discoveryUrl": "https://your-provider.tld/.well-known/openid-configuration",
"scopes": ["openid", "profile", "email"]
}
]'
AUTH_PROVIDERS_CUSTOMS=[{"providerId": "authentik","providerName": "authentik","providerIconUrl": "https://api.iconify.design/tabler:login-2.svg","clientId": "client id from authentik","clientSecret": "client secret from authentik","type": "oidc","discoveryUrl": "https://authentik.company/application/o/<application_slug>/.well-known/openid-configuration","scopes": ["openid", "profile", "email"]}]
```
:::note
The JSON needs to be inline because various `.env` parsers, such as the one used by docker compose, do not support multiline environment variables.
:::
## Configuration verification
To verify the integration with Papra, log out and attempt to log back in using..
To verify the integration with Papra, log out and attempt to log back in using the **Log in with authentik** button. You should be redirected to the authenik login page. Once authenticated you should be redirected to the Papra dashboard.
## Resources
- [Papra - Setup Custom OAuth2 Providers Documentation](https://docs.papra.app/guides/setup-custom-oauth2-providers/)
- [Papra Docs - Setup Custom OAuth2 Providers](https://docs.papra.app/guides/setup-custom-oauth2-providers/)