Skip to content

Commit

Permalink
fix(providers): update Descope docs, tweak default config (#11377)
Browse files Browse the repository at this point in the history
* Updated Descope Docs

* Update descope.mdx

* Update descope.mdx

* Update descope.mdx

* Update descope.ts

* Update descope.ts

---------

Co-authored-by: Nico Domino <[email protected]>
Co-authored-by: Balázs Orbán <[email protected]>
  • Loading branch information
3 people authored Aug 9, 2024
1 parent bffb308 commit 0d73205
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
5 changes: 2 additions & 3 deletions docs/pages/getting-started/providers/descope.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Code } from "@/components/Code"

## Resources

- [Descope OIDC](https://docs.descope.com/customize/auth/oidc)
- [Descope OIDC](https://docs.descope.com/manage/idpapplications/oidc/)
- [Descope Flows](https://docs.descope.com/customize/flows)

## Setup
Expand Down Expand Up @@ -43,15 +43,14 @@ https://example.com/auth/callback/descope
```
AUTH_DESCOPE_ID
AUTH_DESCOPE_SECRET
AUTH_DESCOPE_ISSUER
```

### Configuration

Follow these steps:

1. Log into the [Descope console](https://app.descope.com)
2. Follow the [OIDC instructions](https://docs.descope.com/customize/auth/oidc)
2. Follow the [OIDC instructions](https://docs.descope.com/manage/idpapplications/oidc/)

Add the required environment variables from above to your `.env.local` file.

Expand Down
14 changes: 4 additions & 10 deletions packages/core/src/providers/descope.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,7 @@ export interface DescopeProfile {
* import Descope from "@auth/core/providers/descope"
*
* const request = new Request(origin)
* const response = await Auth(request, {
* providers: [
* Descope({
* clientId: DESCOPE_ID,
* clientSecret: DESCOPE_SECRET,
* }),
* ],
* })
* const response = await Auth(request, { providers: [Descope] })
* ```
*
* ### Configuring Descope
Expand All @@ -71,8 +64,8 @@ export interface DescopeProfile {
*
* Get the following from the Descope's console:
* ```
* DESCOPE_ID="<Descope Issuer's last url segment>" # Descope's Issuer can be found in "Authentication Methods > SSO > Identity Provider" (Can also be taken from "Project > Project ID")
* DESCOPE_SECRET="<Descope Access Key>" # Manage > Access Keys
* AUTH_DESCOPE_ID="<Descope Issuer's last url segment>" # Descope's Issuer can be found in "Authentication Methods > SSO > Identity Provider" (Can also be taken from "Project > Project ID")
* AUTH_DESCOPE_SECRET="<Descope Access Key>" # Manage > Access Keys
* ```
*
* ### Resources
Expand Down Expand Up @@ -108,6 +101,7 @@ export default function Descope(
bg: "#1C1C23",
text: "#ffffff",
},
checks: ["pkce", "state"],
options: config,
}
}

0 comments on commit 0d73205

Please sign in to comment.