Example 1 with an “implicit flow” with no code
This is simple integration for a CMS like Webflow or a Single Page Application in JS or a dApp. For this first example, you need the Altme Wallet and an Email Proof as a verifiable credential.
Later you could check the verifier data and change the parameters and landing page style in minutes on https://talao.co. The example below is the verifier named “Example 1” in the select list. Make a copy of that verifier if you want to change the parameters.
So let’s try this verifier.
You can call it from a button link with a standard <a href=…> balise or you can just copy this link in your browser :
Replace if needed the redirect_uri argument by your own website.
You will be requested to present an email proof and then you will received an id_token like that one below in your browser (id_token=eyJhbGciO…..):
eyJhbGciOiJSUzI1NiIsImtpZCI6IjEyMyIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJ4Z2RmZGJ6d3JpIiwiZW1haWwiOiJ0aGllcnJ5QGFsdG1lLmlvIiwiZXhwIjoxNjY2MTk4M jczLjY2ODQ5MiwiaWF0IjoxNjY2MTk3MjczLjY2ODQ4NCwiaXNzIjoiaHR0cHM6Ly90YWxhby5jby9zYW5kYm94L29wIiwibm9uY2UiOm51bGwsInN1YiI6ImRpZDprZXk6ejZN a3R1d0x2U1VZZUplV0pnRHZKNlJmdFR2eVJTb05SR1h4Y2tlRTQ0cVRLa0tWIiwidXBkYXRlZF9hdCI6MTY2NTg0Mjc1MS4wfQ.MdWtxU8CjgSHfRgwUQWMMvhCLdgHzwQolWFwhtx -i3WJpZowwtpKSxh4smGPPhtBr4JPGYFAhjklZ2ojbW64VS8S07TNh3Q75TrgixAVguYnvsWCh5CLcxBRlcFW7iyWFm1WZ9VtNqXvlIL50tbfSQnpkcGVKbg2dmUKmuvUVDE1 qoJDedz7YKL3qWobkxzsrUlDGTKLvOHKdU3kaXnkGmiVxpZtwbIhE3pa27CjGFKAMX4rXOuiJ5N81LDX06GjV9KU4a4T5J2Bd2tgfvafjhJuTQD-1MaTWJMu_ZTiHEjr4PTqYe_C olYS2a_Ougwk2FTQ6dKIQWClwhCZ-QfWuw
As you will see in an implicit flow, the id_token is passed as a fragment (#), you can intercept it with JS in your page.
Copy this id_token and go to https://jwt.io , paste the id_token value in the left side and you will get the following json data decrypted :
"email": "[email protected]",
- “sub” is the subject ID, in our case it is the DID of the user (walletr Decentralized IDentifier). You can check that DID in your wallet settiongs !
- “aud” is the issuer URL in the OpenID format
- “email” is the main data of your verifiable credential
Based on that example you can request different types of credentials to authenticate your users as :
- Over 13
- Over 18
- Phone proof
- Gender proof
- Nationality proof
- Blockchain address
- ID card
- Custom credentials…
To make your own verifier, you just need to go to the plateform https://talao.co and to copy the example and configure the landing pasge.
More secured options are available with an OpenID authorization code flow.