Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add session key docs #1357

Open
wants to merge 30 commits into
base: main
Choose a base branch
from
Open

docs: add session key docs #1357

wants to merge 30 commits into from

Conversation

howydev
Copy link
Collaborator

@howydev howydev commented Feb 12, 2025

Pull Request Checklist


PR-Codex overview

This PR introduces new documentation for managing Session Keys in the Modular Account V2. It covers adding, using, and removing session keys, along with their permissions and security features.

Detailed summary

  • Added Session Keys section in sidebar/smart-contracts.ts.
  • Created documentation for:
    • Overview of Session Keys.
    • Adding Session Keys.
    • Using Session Keys.
    • Removing Session Keys.
  • Included example code snippets for each operation.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

howydev and others added 9 commits February 11, 2025 16:44
* docs: add ma v2 page

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: review fixes

* chore: remove comment to standardize

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: imports in example

* fix: lint

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* chore: make it consistent

---------

Co-authored-by: avarobinson <[email protected]>
* feat: add Choosing a Smart Account page

* chore: lint

* feat: benchmarks

* feat: add mav2 overview

* docs: update table to display diff from MAv2 as a percentage increase

* docs: adding in feature table and other account details

* docs: updating copy

* docs: updating multisig

* chore: cleanup gas benchmarks, remove runtime column

* docs: clarify safe 4337 module

* docs: remove sidebar link

* docs: remove repeated table, add details

* docs: mention ERC-4337

* docs: link audits, clarify legacy contracts

* docs: rename legacy to other

* docs: specify MAv2 breaking the sub-100k gas barrier

* chore: format

---------

Co-authored-by: Ava Robinson <[email protected]>
* docs: add ma v2 page

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: review fixes

* chore: remove comment to standardize

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: imports in example

* fix: lint

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* chore: make it consistent

* docs: restructure smart accounts layout

* fix: pr review

* Update site/pages/concepts/intro-to-account-kit.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/choosing-a-smart-account.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/install-plugins.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/sidebar/smart-contracts.ts

Co-authored-by: avarobinson <[email protected]>

* fix: broken linksg

---------

Co-authored-by: avarobinson <[email protected]>
Co-authored-by: Ava Robinson <[email protected]>
…s to use mav2 (#1343)

* docs: fixes typo

* docs: updating guide to clean up account types and sidebar;

* docs: cleaning up configs and advanced table

* docs: fixing copy

* docs: updating type param to be optional

* docs: adds missing parameter definitions and fixes typos

* docs: adds wording modifications

* docs: fixing merge conflict

---------

Co-authored-by: Ava Robinson <[email protected]>
* docs: add ma v2 page

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: review fixes

* chore: remove comment to standardize

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* fix: imports in example

* fix: lint

* Update site/pages/smart-contracts/modular-account-v2/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/modular-account/getting-started.mdx

Co-authored-by: avarobinson <[email protected]>

* chore: make it consistent

* docs: restructure smart accounts layout

* fix: pr review

* Update site/pages/concepts/intro-to-account-kit.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/resources/terms.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/choosing-a-smart-account.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/pages/smart-contracts/install-plugins.mdx

Co-authored-by: avarobinson <[email protected]>

* Update site/sidebar/smart-contracts.ts

Co-authored-by: avarobinson <[email protected]>

* fix: broken linksg

* docs: re-arranging sidebar for new account layout and updating references

* chore: readd lost commit from ava

---------

Co-authored-by: howydev <[email protected]>
* docs: adds 7702 react page

* docs: adds note about gas sponsorship

* docs: add note about getting access to testnet

* docs: adding 7702 details

* docs: modifies copy

* docs: adds ERC-4337 account benefits

* docs: fixing link

---------

Co-authored-by: Ava Robinson <[email protected]>
Copy link

vercel bot commented Feb 12, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
aa-sdk-site 🛑 Canceled (Inspect) Feb 12, 2025 10:08pm
aa-sdk-ui-demo 🛑 Canceled (Inspect) Feb 12, 2025 10:08pm

@howydev howydev force-pushed the howy/add-session-key-docs branch from 0bf455a to 7739fee Compare February 12, 2025 19:22

### Automate actions

With the ability to delegate specific permissions to session keys, users can automate actions within predefined limits. Session keys can be used to streamline processes like recurring payments, contract interactions, or any activity that benefits from automation.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have an actual exmaple of this? Is this like executing limit orders on the backend without the users interaction?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, exactly!


- The module must be installed with both validation and execution hooks, the validation hook track gas, whereas the execution hook tracks value
- Special paymasters must be explicitly configured to count against limits (SDK WIP)
- Limits can be updated dynamically after installation (SDK WIP)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove SDK WIP and either replace with unsupported or coming soon

],
});

// Adding a session key that has a 1 eth native token spend limit
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wait isnt this the same as the other example?

howydev and others added 13 commits February 12, 2025 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants