thirdweb

Create a wallet with SMS/Email login

Create a wallet with SMS/Email login

Last updated:

December 18, 2021

Use the thirdweb SDK with magic.link

Jake Loo

magic.link provides wallet for users that login through SMS, Email or Social.

Magic is a developer SDK that integrates with your application to enable passwordless authentication using magic links (similar to Slack and Medium). Magic enables blazing-fast, hardware-secured, passwordless login with a few lines of code — even if you have an existing auth solution.

To learn more about how to set up magic.link in your project, look at:

Magic for Web

How to use our SDK with magic.link

1. Install our SDK and Magic SDK

npm install @3rdweb/sdk ethers magic-sdk

2. Setting up our SDK

import { ThirdwebSDK } from "@3rdweb/sdk"; import { ethers } from "ethers" import { Magic } from "magic-sdk"; // Dependent on your setup! const magic = new Magic(...) // The magic.link wallet that will be making the sdk contract calls const provider = new ethers.providers.Web3Provider(magic.rpcProvider); const signer = provider.getSigner(); // Initialize SDK instance with the magic.link signer. const sdk = new ThirdwebSDK(signer); // Access any modules using our the SDK. sdk.getNFTModule("0x...");

Resources for using magic.link on the blockchains


Ready to build your first web3 app? Get early access & add web3 features to your project today.

Jake Loo

Contents

How to use our SDK with magic.link

1. Install our SDK and Magic SDK

2. Setting up our SDK

Resources for using magic.link on the blockchains