Skip to content

Context for Ethereum L1, L2, and L3 transactions

License

Notifications You must be signed in to change notification settings

Once-Upon/context

Repository files navigation

EVM Context

Screenshot 2023-12-01 at 1 26 47 PM

Context for Ethereum L1 and L2 transactions

If you want your protocol to work well on your own app, use a private indexer.
If you want your protocol to work well across all of web3, contribute to EVM Context.

Ideal contributors:

  • Protocol teams

Ideal users

  • Wallets
  • Web3 browsing tools
  • Web3 analytics tools

Quick start

Generating a new contextualization

npm run create:contextualizer [name of protocol] -- -h [transaction hash]`

The transaction hash is optional.

This will generate a new file called protocol/[name of protocol].ts and a test file called protocol/[name of protocol].spec.ts.

Tests

Running tests

npm run test

Writing tests

You should write unit tests for your PR using a real transaction.

If you used a tx hash when running npm run create:contextualizer, this is already set up for you.

To include more transactions in your tests, you can do this by running:

npm run grab:transaction [txHash] [nickname for the type of tx]

Finishing your new contextualization

Once that's ready, please open a PR on this repo and request review from pcowgill and jordanmessina

Running contextualizers

npm run run:contextualizers -- -l [number of transactions]

This will run contextualizers for the latest transactions.

License

See the LICENSE file for license rights and limitations (MIT).