Skip to content

Add guide for indexing Etherlink EVM contracts with Envio - #463

Open
Jordy-Baby wants to merge 2 commits into
etherlinkcom:mainfrom
Jordy-Baby:docs/indexing-envio-guide
Open

Jordy-Baby wants to merge 2 commits into
etherlinkcom:mainfrom
Jordy-Baby:docs/indexing-envio-guide

Conversation

@Jordy-Baby

@Jordy-Baby Jordy-Baby commented Sep 24, 2026 •

Copy link
Copy Markdown

Hey @NicNomadic, thanks again for getting the Envio listing merged. This adds an "Indexing contracts with Envio" guide next to the existing Graph guide.

  • New page docs/evm/developing/indexing-envio.md, added to sidebars.js right after indexing-graph
  • Adds a link to the new guide on the data indexers page
  • Walks through indexing WXTZ (0xc9B53AB2679f573e480d01e0f49e2B5CFB7a3EAb) on Etherlink Mainnet with HyperIndex and HyperSync

Every command, config snippet and output in the guide comes from a real run on Etherlink Mainnet, and the sample query results match the on-chain logs. npm run build passes and the page shows in the sidebar.

Lmk if you require anything further on our end.

Adds a HyperIndex guide next to the The Graph guide, adds it to the
sidebar and links to it from the data indexers page.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Sep 24, 2026

Copy link
Copy Markdown

@Jordy-Baby is attempting to deploy a commit to the Trili Tech Team on Vercel.

A member of the Team first needs to authorize it.

@NicNomadic
NicNomadic self-requested a review September 29, 2026 13:59
```

When the CLI asks whether you want to add another contract, select `I'm finished`.
If the `ENVIO_API_TOKEN` environment variable is not set, the CLI asks you to create a new API token or add an existing one to the project's `.env` file.

@NicNomadic NicNomadic Sep 29, 2026 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Can you specify what are the required rights for this token, so that one can create it manually instead of relying on envio.dev to create it on behalf of one's github account?

My bad, I thought it's trying to create a Github access token for Envio, but it's just creating an Envio API token, using one's Github account. So the question becomes: is there another way of creating an Envio token without authorizing it to use one's Github account? Knowing that some developers might be reluctant to grant this permission.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

hey @NicNomadic, thanks for testing this :)

right now the Envio dashboard only supports signing in with GitHub, so there isn't another way to create the token yet

I'll pass the feedback on to our team. lmk if you require anything further on our end

@NicNomadic

Copy link
Copy Markdown
Collaborator

Thanks for this nice contribution. I'm waiting for the answer in the thread above to continue testing your tutorial.

When the CLI asks whether you want to add another contract, select `I'm finished`.
If the `ENVIO_API_TOKEN` environment variable is not set, the CLI asks you to create a new API token or add an existing one to the project's `.env` file.

The CLI generates the project, runs code generation and installs the dependencies:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I tried nevertheless with a fresh Github account but I was stuck when doing pnpx envio init:

  1. First, you should mention which kind of token to create. I assumed HyperSync, was it rather HyperRPC?

  2. I had some warning when using pnm 11.10.0 (WARN] The "workspaces" field in package.json is not supported by pnpm. Create a "pnpm-workspace.yaml" file instead.), which disappeared when I upgraded to pnpm 12.8.1. Should you mention a minimal pnpm version?

  3. The script ultimately fails during installing dependencies, here is the trace.

    Installing dependencies with pnpm...
    ...
    [WARN] Issues with peer dependencies found. Run "pnpm peers check" to list them.
    dependencies:

    • envio 3.12.1
      devDependencies:
    • @types/node 24.12.2
    • typescript 6.0.3
    • vitest 4.1.0
      Error: ERR_PNPM_IGNORED_BUILDS
      × installing dependencies
      ╰─▶ Ignored build scripts: esbuild@0.27.7
      help: Run "pnpm approve-builds" to pick which dependencies should be allowed
      to run scripts.
      [11:41:11.766] ERROR: Failed installing project dependencies: pnpm install exited with code 1

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Hey @NicNomadic, thanks for running through it with a fresh account, this is really useful.

  1. It's a HyperSync token, the free one on the HyperSync tokens page. HyperRPC is a separate product and isn't needed here. The prerequisites now say that and link the steps.
  2. I couldn't reproduce the workspaces warning on pnpm 11.10.0, and the generated package.json has no workspaces field, so I've left out a minimum pnpm version.
  3. Reproduced on pnpm 11.10.0 and 12.8.1. pnpm 11 and later stop the install until the esbuild build script is approved, where pnpm 10 only warns. The project files are already generated at that point, so running pnpm approve-builds esbuild in the project folder gets past it. I've added that step to the guide and tested the rest of it on pnpm 12.8.1 (pnpm test, pnpm dev and the queries). There's also a fix open for the CLI at Approve the esbuild build script in pnpm projects created by envio init enviodev/hyperindex#1680

The update is pushed. Lmk if you require anything further on our end.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the answers 1 and 2.
As for 3, I did try pnpm approve-builds as suggested by the tool but I got There are no packages awaiting approval. I can try this again tomorrow if anything has changed.

@NicNomadic NicNomadic Oct 2, 2026 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I tried again right now, still no approvals pending, and running pnpx envio init again after that gets stuck the same. Let me know when the fix lands (and what should I update, if any) so I can retest it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

2 participants