DocumentationSubstreamsBasicsAuthentication

Authentication

Before running any Substreams packages, you need to authenticate with a Substreams provider. These providers are responsible for executing Substreams packages. Authenticating is a simple process, and below, we outline this authentication process for two primary providers: StreamingFast and Pinax.

StreamingFast

To authenticate with StreamingFast, follow these steps:

  1. Obtain an API Key: Generate one at StreamingFast.
  2. Configure Authentication: Add the API key to your environment. For example, you can set it as an environment variable:
export SUBSTREAMS_API_TOKEN=<YOUR_API_KEY>

Once this is set, subsequent Substreams commands that require authentication will use this API key.

For more detailed instructions, refer to the StreamingFast Authentication documentation.

Pinax

To authenticate with Pinax, follow these steps:

  1. Create a Project: Go to the Pinax App and create a new project. This generates an API key associated with that project.
  2. View Configurations: Once your project is created, you can view the configurations for this project, including the API key.
  3. Configure Authentication: Similar to StreamingFast, you can set the API key as an environment variable:
export SUBSTREAMS_API_KEY=<YOUR_API_KEY>

Detailed configuration options can be found on the Pinax platform once you have created a project.