Skip to content

Commit 63457b0

Browse files
author
Austin McBee
authored
Merge pull request #501 from FormidableLabs/task/azure_ad_b2c_example
add azure ad b2c example config
2 parents ea0b9f9 + 4ec09d1 commit 63457b0

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
## Azure Active Directory B2C
2+
3+
Detailed documentation [here](https://docs.microsoft.com/en-us/azure/active-directory-b2c/openid-connect).
4+
5+
```js
6+
const config = {
7+
issuer: 'https://<TENANT_NAME>.b2clogin.com/<TENANT_NAME>.onmicrosoft.com/<USER_FLOW_NAME>/v2.0',
8+
clientId: '<APPLICATION_ID>',
9+
redirectUrl: 'com.myapp://redirect/url',
10+
scopes: ['openid', 'offline_access']
11+
};
12+
13+
// Log in to get an authentication token
14+
const authState = await authorize(config);
15+
16+
// Refresh token
17+
const refreshedState = await refresh(config, {
18+
refreshToken: authState.refreshToken,
19+
});
20+
```

0 commit comments

Comments
 (0)