Giter Site home page Giter Site logo

megabyte0x / mexa Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bcnmy/mexa

0.0 0.0 0.0 814 KB

Repository contains smart contracts for biconomy's Mexa platform to implement meta transactions and allow dapp users to perform blockchain operations without holding any ether or other crypto currency.

License: MIT License

JavaScript 53.18% Solidity 46.82%

mexa's Introduction

Mexa By Biconomy

Mexa is Biconomy's implementation of meta transactions.

This repo contains the stuff that makes Biconomy tick, plus some cool resources that dApps can use to integrate meta transactions into their contracts.

๐Ÿคฉ Cool Contracts for Gasless Meta Transactions

Custom Meta Transactions

Inherit this in your contract and replace msg.sender with msgSender() and you're good to go! ๐Ÿ’ช This implementation is designed to work with eth_sign instead of EIP712 - due to it's wider support. Inherit this in your contract and replace msg.sender with msgSender() and you're good to go! ๐Ÿ’ช This implementation is designed to work with EIP712 signatures for providing a better messaging to the end users while getting their signatures.

EIP-2771 Secure Native Meta Transactions

With adherence to EIP-2771 to enable native meta transactions in your contract, you can just inherit a simple contract BaseRelayRecipient.sol and set the trusted forwarder address.

The Trusted Forwarder is responsible for signature verification and replay protection and forwards the transaction to your smart contract by appending the user address at the end of calldata. The _msgSender() method in your smart contract (inherited by BaseRelayRecipient) does the rest by returning the correct address for any context. Use _msgSender() wherever you use msg.sender.

FORWARD --> Save your ETH. Pay gas in ERC20 tokens

Using Biconomy Forward module, you can let your users pay the gas fee in ERC20 tokens and let your users save ETH and providing a seamless transaction experience.

Forward contracts can be found here

Refer our official documentation for more information on how to use Biconomy to start providing a seamless experience to your users.

๐Ÿ‘จโ€๐Ÿ’ป Working On Mexa

Providing Seed Phrase

To keep testing and deployment consistent, we use a seed phrase to generate the accounts we use - when testing and deploying contracts. You need to add file with name .secret to the root folder and add the 12 word mnemonic phrase corresponding to your account which will be used to deploy the contracts.

Providing API Keys

Both an Alchemy and an Infura API key will be needed to compile and test the contracts. # create necessary files touch .infura .alchemy # add keys to file

๐Ÿ‘ท Compiling Contracts

npx hardhat compile

โœ”๏ธ Running Tests

Run Unit Tests : npx hardhat test

โœ”๏ธ Running Test Coverage

npx hardhat coverage --solcoverjs ./.solcover.js

Note: Some tests are skipped while running coverage as per hardhat documentation

๐Ÿ“ก Deploying Contracts

See Hardhat Deploy

๐Ÿ‘‹ How to Reach Out to Us

Join our discord channel https://discord.gg/C4XtWtB

mexa's People

Contributors

tomarsachin2271 avatar divyan73 avatar biconomy avatar anubhavgirdhar avatar realkinando avatar ankurdubey521 avatar mundhrakeshav avatar dn1990 avatar gmsteuart avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.