For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
DiscordDashboard
DocumentationAPI ReferenceCookbook
DocumentationAPI ReferenceCookbook
  • Get Started
    • Introduction
    • Quickstart
    • Best Practices
  • Guides
    • Act SDK
    • Auth States
    • Conversations
    • Tools
  • Providers
    • OpenAI
    • Anthropic
  • Instances
    • Ubuntu
      • Browser
      • Code Execution
      • Environment Variables
    • Browser
    • Windows
  • Resources
    • Starter Templates
    • Cursor Rules
    • Cookbook
Logo
DiscordDashboard
InstancesUbuntu

Environment Variables

Manage environment variables in your Scrapybara instance
Was this page helpful?
Previous

Browser

Deploy a Browser instance
Next
Built with
Python
TypeScript
1

Start an instance

1from scrapybara import Scrapybara
2
3client = Scrapybara(api_key="your_api_key")
4instance = client.start_ubuntu()
2

Set environment variables

1# Set one or more environment variables
2instance.env.set(
3 variables={
4 "API_KEY": "secret_key",
5 "DEBUG": "true",
6 "DATABASE_URL": "postgresql://localhost:5432/db"
7 }
8)
3

Get environment variables

1# Get all environment variables
2response = instance.env.get()
3env_vars = response.variables
4

Delete environment variables

1# Delete specific environment variables
2instance.env.delete(
3 keys=["API_KEY", "DEBUG"]
4)