How to migrate users from magic.link

I’m currently using magic.link as my wallet provider. I now want to migrate to Web3Auth’s MPC Kit as my wallet provider. How can I go about doing that?

@bruno1 Thanks for reaching out.

Your request has been forwarded to our Dev team and we will get back with further updates.

@vjgee is there any more information on this? We’d like to start the migration immediately and there isn’t any clearly documented way on how to do it.

@bruno1 Sorry, your request is taking more time than expected.

I have followed up with our Dev team and we will get back once there is an update to share.

Thanks for the follow up with your dev team @vjgee . Have they responded with a way forward for the migration?

Hey @bruno1

Migrating from magic.link can be done in a variety of ways

  1. Migration of funds and assets into Web3Auth created wallet (preferred): Since in the frontend, while the user is logged in, you have access to the user’s wallet, you can ask them to migrate into the Web3Auth wallet. Here, you can login the user using Web3Auth within a session where magic was already logged in and transfer user assets into the Web3Auth-generated wallet. The only thing to make a note of here is that the key/ address will change.

  2. Importing the private key into Web3Auth infrastructure: Wirh magic.link, there is no direct way of exporting the private key for the user. Magic.link has a customized portal for each deployed app where they allow the user to manually export their private key. You can create a flow for the user where they can export the private key from magic link and paste it onto your website. Within your website, you can call the private key module for tKey SDK and import the private key into Web3Auth. You can achieve something similar with our MPC Core Kit SDK. This process is quite manual for the user.

  3. Importing a private key into your infrastructure: Here, the process of exporting the private key remains the same. However, while importing the private key, you have a choice of not passing it to Web3Auth. Instead, you can use the public key of Web3Auth to encrypt the private key of magic.link. You can store this encrypted private key in your infrastructure, and when the user logs in again, utilize the Web3Auth private key to decrypt it. This can be done using all Web3Auth SDKs.

Ideally, when you’re performing such a migration, it is mandatory to note the user experience. To achieve this with minimal friction to the user, make sure to schedule a call with the Web3Auth team, where we can recommend the best products for your usecase.

1 Like

Thanks for the response. I’d like to follow up on your response with 2 questions:

  1. Step 2 seems incomplete. “This process is quite manual for the user and only supported by t…”
    Could you please complete this statement as a very important caveat has been cut out the sentence.
  2. Why is step 1 your most preferred method? In our case, step one would seem to be the most inconvenient method as it would require us to simultaneously maintain both magic.link and web3Auth within our system as we slowly migrate users to web3Auth. And implementing the first migration would require quite some considerable time and effort. Is their a special reason why you’ve recommended that particular migration strategy?

For the tKey SDK, I’ve been able to find the functions to get and Set the imported Private Keys. What’s the equivalent group of functions for this functionality in the MPC Core Kit?

Hi,
The feature is not yet available in mpc-core-kit.
It will be available in the next release.
ETA of the next release is estimated to be by end of this week.

Hello @cherngwoei . Thanks for the response and I’ll be looking forward to the next release. Where can I check so as to be up to date with your releases?

@bruno1 Thanks for your patience.

Our team are continuing to work on releasing this but is take a little more time than expected. It should be out by next week.

Hey @bruno1

Just wanted to check with your regarding this. If you have any further questions, feel free to reach out to our business team, who will make sure all your queries are answered. Calendly - Web3Auth

We have our tKey and MPC Core Kit SDKs available for importing keys and they can be configured accordingly.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.