Skip to content

feat: metamask delegation toolkit fusion mode#101

Merged
filmakarov merged 21 commits intodevelopfrom
feat/mm-dtk-fusion-mode
Jun 27, 2025
Merged

feat: metamask delegation toolkit fusion mode#101
filmakarov merged 21 commits intodevelopfrom
feat/mm-dtk-fusion-mode

Conversation

@filmakarov
Copy link
Contributor

@filmakarov filmakarov commented Jun 18, 2025

Adds the third fusion mode, which uses MM DeleGator SA as the funds origin for the trigger txn.
Prerequisites:

  • since account discovery is not available in the MM Delegation Toolkit yet, SDK expects Delegator account object to be provided as an argument.
  • delegator account should be funded with payment token and deployed ofc (as it is the case with eoa in other fusion modes)
  • Currently doesn't use ERCs 7715 and 7710 as ERC-7715 flow in MM DTK supports only 'native-token-stream' permission type yet.
  • Smart contracts for this functionality: New Fusioin Mode: MetaMask Delegation Toolkit mode mee-contracts#39

PR-Codex overview

This PR focuses on enhancing the MEE client functionality by introducing support for the MetaMask Delegation Toolkit (MM DTK), updating various components, and improving test coverage.

Detailed summary

  • Removed getFusionQuote.test.ts.
  • Added DEFAULT_MEE_NODE_URL in createMeeClient.ts.
  • Increased size limits in .size-limit.json.
  • Updated type casting in prepareForPermissions.ts.
  • Renamed account to companionAccount in several decorators.
  • Added delegatorSmartAccount to multiple quote parameters.
  • Introduced signMMDtkQuote for signing quotes with MM DTK.
  • Enhanced test cases for getMmDtkQuote and signMMDtkQuote.
  • Updated package.json with new dependencies and versions.

The following files were skipped due to too many changes: bun.lock

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

@filmakarov filmakarov changed the title feat: Metamask delegation toolkit fusion mode feat: metamask delegation toolkit fusion mode Jun 18, 2025
@filmakarov filmakarov requested review from alexcambose and vr16x June 18, 2025 15:19
Copy link
Collaborator

@vr16x vr16x left a comment

Choose a reason for hiding this comment

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

Most of the things LGTM. Just minor things needs to be changed if needed

@vr16x
Copy link
Collaborator

vr16x commented Jun 19, 2025

@filmakarov Test cases are failing, please pull the latest develop branch and fix all the test issues here.

@filmakarov
Copy link
Contributor Author

filmakarov commented Jun 19, 2025

@vr16x the PR included the latest develop branch at the time of submitting.

if you have been speaking about ci/cd tests, I think they fail because of 'frozen lockfile' setting

@vr16x
Copy link
Collaborator

vr16x commented Jun 20, 2025

Might be because of the bun lock file change. Can you fix this issue ?

@filmakarov
Copy link
Contributor Author

@vr16x unit tests are passing

@filmakarov filmakarov merged commit d1fd8af into develop Jun 27, 2025
4 of 6 checks passed
@filmakarov filmakarov deleted the feat/mm-dtk-fusion-mode branch June 27, 2025 19:22
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.

5 participants