Koyeb python sdk
Actively maintained. Last release 4 days ago, commits in 22 of the last 26 weeks. A safe choice.
pip install koyeb-sdkKoyeb python sdk
This is the official Python SDK for Koyeb, a platform that allows you to deploy and manage applications and services in the cloud.
Modules
koyeb.api: Contains the synchronous API client and methods to interact with Koyeb's REST API. Documentationkoyeb.api_async: Contains the asynchronous API client (httpx-based) and methods to interact with Koyeb's REST API. Documentationkoyeb.sandbox: Contains the Sandbox module. Documentation
Koyeb Sanboxes
A Koyeb sandbox is an isolated, ephemeral environment designed to safely run, test, and experiment with code without affecting other systems or requiring complex setup. It provides developers with a virtualized or containerized execution space where dependencies, environment variables, and runtime contexts can be fully controlled and discarded after use.
You should use a sandbox to:
- Execute untrusted or user-generated code securely
- Prototype applications quickly
- Test APIs or libraries in clean environments
- Demonstrate functionality without configuring local infrastructure
Sandboxes are especially valuable in platforms for AI model evaluation, online coding environments, CI/CD pipelines, and educational tools that require safe, reproducible, and on-demand compute environments.
Install the SDK
pip install koyeb-sdk
Set the Koyeb API token
Using the Koyeb Python SDK requires an API token. Complete the following steps to generate the token and make it accessible to your environment:
- In the Koyeb control panel, navigate to Settings.
- Click the API tab.
- Click Create API token and provide a name and description. You can use the following:
Name:
Description:sandbox-quickstartFor accessing the Koyeb Python SDK to generate sandboxes - Click Create to complete token creation. Note that the token value will not be accessible later, so take note of it as needed.