Skip to content

Commit 53dc696

Browse files
committed
docs: update social auth docs
1 parent 6803e98 commit 53dc696

File tree

5 files changed

+127
-1
lines changed

5 files changed

+127
-1
lines changed

apps/portal/src/app/connect/sidebar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ export const sidebar: SideBar = {
126126
},
127127
{
128128
name: "Social Login",
129-
href: `${connectSlug}/methods/social-logins`,
129+
href: `${walletSlug}/sign-in-methods/socials`,
130130
},
131131
{
132132
name: "Email & Phone",
Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
import { ArticleIconCard, DocImage } from "@doc";
2+
import {
3+
ReactIcon,
4+
TypeScriptIcon,
5+
UnityIcon,
6+
DotNetIcon,
7+
ExternalLinkIcon,
8+
UnrealEngineIcon
9+
} from "@/icons"
10+
import EcosystemSocialConfig from './social-config.png'
11+
12+
# Social Logins
13+
14+
thirdweb uses the [OAuth 2.0 Protocol](https://oauth.net/2/) to enable social login.
15+
16+
For all social login methods, thirdweb generates a non-custodial [wallet](/connect/wallet/security) behind the scenes. Thirdweb wallets enable your users to interact with your application, as well as store tokens and assets they receive while interacting with your application.
17+
18+
## Add Social Login options
19+
20+
### In-App Wallets
21+
22+
To add social logins to your in-app wallet, refer to the following guides:
23+
24+
<div className="my-4 grid gap-2 md:grid-cols-2 lg:grid-cols-3">
25+
<ArticleIconCard
26+
title="TypeScript"
27+
icon={TypeScriptIcon}
28+
description="Implement in-app wallets in TypeScript"
29+
href="/typescript/v5/inAppWallet#example"
30+
/>
31+
<ArticleIconCard
32+
title="React"
33+
icon={ReactIcon}
34+
description="Implement in-app wallets in React"
35+
href="/react/v5/in-app-wallet/get-started#choose-authentication-methods"
36+
/>
37+
{/* TODO: Link to react native getting started for in appw allet */}
38+
<ArticleIconCard
39+
title="React Native"
40+
icon={ReactIcon}
41+
description="Implement in-app wallets in React Native"
42+
href="/react/v5/in-app-wallet/get-started#choose-authentication-methods"
43+
/>
44+
<ArticleIconCard
45+
title=".NET"
46+
icon={DotNetIcon}
47+
description="Connect in-app wallets in .NET"
48+
href="/dotnet/wallets/providers/in-app-wallet#oauth-authentication-flow"
49+
/>
50+
<ArticleIconCard
51+
title="Unity"
52+
icon={UnityIcon}
53+
description="Implement in-app wallets in Unity"
54+
href="/unity/v5/wallets/in-app-wallet#login-with-socials-google-apple-facebook-etc"
55+
/>
56+
<ArticleIconCard
57+
title="Unreal Engine"
58+
icon={UnrealEngineIcon}
59+
description="Implement in-app wallets in Unreal Engine"
60+
href="/unreal-engine/blueprints/in-app-wallet#oauth"
61+
/>
62+
</div>
63+
64+
### Ecosystem Wallets
65+
66+
In order to use social logins within your ecosystem, first configurethe allowed social auth methods on [your dashboard](https://thirdweb.com/dashboard).
67+
68+
<DocImage src={EcosystemSocialConfig}/>
69+
70+
Once configured, refer to the following guides to use social logins within your ecosystem:
71+
72+
<div className="my-4 grid gap-2 md:grid-cols-2 lg:grid-cols-3">
73+
<ArticleIconCard
74+
title="TypeScript"
75+
icon={TypeScriptIcon}
76+
description="Connect ecosystem wallets in TypeScript"
77+
href="/typescript/v5/ecosystemWallet#example"
78+
/>
79+
<ArticleIconCard
80+
title="React"
81+
icon={ReactIcon}
82+
description="Connect ecosystem wallets in React"
83+
href="/react/v5/ecosystem-wallet/get-started#configuring-auth-strategies"
84+
/>
85+
{/* TODO: Add react native specific getting started for ecosystem wallets */}
86+
<ArticleIconCard
87+
title="React Native"
88+
icon={ReactIcon}
89+
description="Connect ecosystem wallets in React Native"
90+
href="/react/v5/ecosystem-wallet/get-started#configuring-auth-strategies"
91+
/>
92+
<ArticleIconCard
93+
title=".NET"
94+
icon={DotNetIcon}
95+
description="Connect ecosystem wallets in .NET"
96+
href="/dotnet/wallets/providers/ecosystem-wallet#oauth-authentication-flow"
97+
/>
98+
<ArticleIconCard
99+
title="Unity"
100+
icon={UnityIcon}
101+
description="Connect ecosystem wallets in Unity"
102+
href="/unity/v5/wallets/ecosystem-wallet#login-with-socials-google-apple-facebook-etc"
103+
/>
104+
</div>
105+
106+
## Interacting with your App
107+
108+
Once a user signed in and their wallet is generated, you can use the **[Wallet Connection hooks](/typescript/v5/functions#wallets)** to get information about the connected wallet like getting the address, account, and more.
161 KB
Loading

apps/portal/src/app/react/v5/ecosystem-wallet/get-started/page.mdx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,11 @@ import {
33
TabsList,
44
TabsTrigger,
55
TabsContent,
6+
Callout,
67
DocImage,
78
createMetadata,
89
} from "@doc";
10+
import EcosystemSocialConfig from './social-config.png'
911

1012
export const metadata = createMetadata({
1113
title: "Connect users with Ecosystem Wallets",
@@ -61,6 +63,22 @@ const LoginComponent = () => {
6163
};
6264
```
6365

66+
## Configuring auth strategies
67+
68+
You can configure the allowed auth strategies on [your dashboard](https://thirdweb.com/dashboard).
69+
70+
<DocImage src={EcosystemSocialConfig}/>
71+
72+
For prebuilt UIs, the enabled auth strategies are automatically read from your dashbaord configurations.
73+
74+
For custom UIs, you can configure the auth options when connecting the wallet. See [using your own UI](#using-your-own-ui) for an example.
75+
76+
<Callout variant="warning" title="Using disabled auth strategies">
77+
Note that while you're allowed to pass any auth strategy today, we recommend only passing the strategies that are enabled on your dashboard. We might enforce this in the future.
78+
</Callout>
79+
80+
81+
6482
## Passing a partner ID
6583

6684
For closed ecosystems, you can pass a valid `partnerId` to the `ecosystemWallet` provided by the ecosystem owner.
161 KB
Loading

0 commit comments

Comments
 (0)