In this step-by-step guide, we'll walk through the process of decoding the token received from Memberstack and translating it into a Xano token. This will enable secure authentication and authorization for your web or mobile application using the Xano platform.
First, you need to decode the token you're receiving from Memberstack. This can be done using the JWSD function in Xano.
Security section and click on JWSD.JWT Token input to the token you received from Memberstack.-----BEGIN PUBLIC KEY----- and -----END PUBLIC KEY-----.Public Key field in Xano.Signature to RS256.Save.Now, you should see the decoded token output, including the user's name, email address, and Memberstack ID.
Next, you'll want to store the user in your Xano database for future reference.
users) in your Xano project to store user information.name, email, and memberstackID.users table, using the decoded token information from the previous step.With the user information stored in your Xano database, you can now generate a Xano token for authentication and authorization purposes.
Security section and click on Auth Token.Table to the table you created for storing user information (e.g., users).ID to the ID of the user record you just created.Expires field to specify the token's expiration time (e.g., 1h for one hour).Save.You should now see the generated Xano token in the output.
Finally, you can use the generated Xano token for authentication and authorization purposes in your application.
Authentication header to access them.By following these steps, you've successfully decoded the Memberstack token, stored the user information in your Xano database, and generated a Xano token for secure authentication and authorization purposes.
Join 100,000+ people already building with Xano.
Start today and scale to millions.
Start building for free