Aptogotchi: Integrate Aptos Keyless Accounts
Open Github Page
Introduction to Aptos Keyless
Aptogotchi Demo
Integration Steps
Configure your OpenID Integration
Install Aptos Typescript SDK
Setup Ephemeral Keys
Setup Login Button
Create Callback Page
Instantiate Keyless Account
More Resources
Aptos Developer Docs
Configure your OpenID Integration
Supported Identity Providers
Currently only Google is supported. We will support additional OIDC providers in the future (e.g., Apple, Kakaotalk, Microsoft, etc.).
The implicit flow (no authorization code exchange) is the preferred method of authentication. The integration steps below assume the use of implicit flow.
To support OpenID authentication, you will need a client_id
from Google and to setup authorized origins and redirect URIs.
- Setup your project in the Google API Console.
- Register for a Google Cloud account (if you don’t have one yet)
- Create a new project or select an existing one
- Go to the Credentials page.
- You may have to setup an OAuth consent screen if you haven't before.
- This is where you'll configure some App information and the scopes and permissions for your application.
- Select or create a new "OAuth 2.0 Client ID".
- Configure authorized origin (your dApp origin).
- This may be
http://localhost:3000
for local development. - Make sure to update these origins after you deploy your application.
- This may be
- Configure redirect URIs (the handler for the callback after authentication, which will receive the authorization code and/or
id_token
).- Ex:
http://localhost:3000/callback
for local development.
- Ex:
- Obtain the
client_id
of your application.- Save this in your
.env
variables orconstants
file.
- Save this in your