- Set the API key as the
E2B_API_KEYenvironment variable to avoid passing it each time you create a sandbox. - Or pass it directly to the
Sandboxconstructor as shown below:
Where to find API key
You can get your API key at dashboard.Access token
The access token is used only by the interactive CLI login commandse2b auth login and e2b auth configure, which set up your local workstation. It is not needed in the SDK, and you do not need to set it as an environment variable to use the CLI.