Additional Resources
...
Aggregator Beta
What are Sessions?
Session Setup Guide
6min
Creating a session is similar to logging into our app. With active sessions, all other transactions within the app are signless and instantaneous.
Creating a session involves signing 2 transactions in metamask
- Transaction 1 : This generates a JSON Web Token (JWT) which is valid for 30 days. It is generated by signing your Smart Wallet address and timestamp.
- Transaction 2 : This involves signing specific bytes for Arbitrum and Optimism. The session key stored on your browser enables authorized transactions like swaps, bridges, trades, and gas tank deposits.
- Head to your account to activate the session. Click on Create Session
- Sign Transaction 1 to generate JWT token.
![Document image Document image](https://images.archbee.com/tlTHHA14JH0KqPP32avUY/YGnzPTkG_F_sMvNyybDHU_screenshot-2023-12-22-at-54856-pm.png?format=webp)
![Document image Document image](https://images.archbee.com/tlTHHA14JH0KqPP32avUY/SA5Dj6TPM3zVYZIBLX5Mw_arbitrum-one.png?format=webp)
- After signing Transaction 1, if desired you can verify the message of Transaction 2.
- Copy data from the modal and follow the outlined steps in the next section.
![Document image Document image](https://images.archbee.com/tlTHHA14JH0KqPP32avUY/RZni0pwvVb8cD_wS9STdY_screenshot-2023-12-22-at-54907-pm.png?format=webp)
- Click "Sign" in the second popup to set up the session.
![Document image Document image](https://images.archbee.com/tlTHHA14JH0KqPP32avUY/9ALSc7eE7fZdYc-R36qeO_arbitrum-one.png?format=webp)
- Copy the code snippet by clicking on click here to copy data.
- Replace the contents of data.json file with the copied code snippet data from step 1.
- Save the file (cmd+s, ctrl+s).
- Run “pnpm verify” on the terminal.
- Compare the signature payloud output printed with that shown in message of the second MetaMask popup.
Updated 23 Dec 2023
![Doc contributor](https://s3.amazonaws.com/archbee-animals/rabbit.png)
Did this page help you?