To connect to your Bunny Database, you’ll need your Database URL and an Access Token. Both can be obtained and managed from the Dashboard.Documentation Index
Fetch the complete documentation index at: https://docs.bunny.net/llms.txt
Use this file to discover all available pages before exploring further.
Accessing credentials
Navigate to Dashboard > Edge Platform > Database > [Select Database] > Access to view and manage your database connection details.
- View your Database URL
- Generate new access tokens
- Regenerate all access tokens
- Copy or download existing tokens
Database URL
Your Database URL is the endpoint used to connect to your database. It follows this format:Access tokens
Access tokens authenticate your requests to the database. Bunny Database provides two types of tokens:- Full Access: Read and write permissions for all database operations
- Read Only: Limited to SELECT queries and read operations only
Generating new tokens
To create a new access token for an additional application while keeping existing tokens valid:- Navigate to Dashboard > Edge Platform > Database > [Select Database] > Access
- Click Generate Tokens
- New full-access and read-only tokens will be created
- Copy or download your tokens immediately
Regenerating tokens
If your tokens are exposed or compromised, regenerate them to invalidate all existing tokens:- Navigate to Dashboard > Edge Platform > Database > [Select Database] > Access
- Click Regenerate Tokens
- All previous tokens will be immediately invalidated
- New full-access and read-only tokens will be created
- Copy or download your new tokens immediately
Using credentials with client libraries
Pass your Database URL and access token to the client library when creating a connection:Using credentials with HTTP API
When making direct HTTP requests to the database API endpoint (/v2/pipeline), include your access token as a Bearer token in the Authorization header:
Using credentials with Magic Containers and Edge Scripting
When you add database credentials to a Magic Container or Edge Script, they are automatically available as environment variables:BUNNY_DATABASE_URL: Your database URLBUNNY_DATABASE_AUTH_TOKEN: Your access token