API Reference
Devbox
- The Devbox Object
- Devbox Lifecycle
- Devbox File Tools
- Devbox Shell Tools
- Devbox Network Tools
- Devbox Persistence Tools
- Devbox Observability Tools
- Devbox Add-ons
Blueprint
- The Blueprint Object
- Blueprint Lifecycle
- Blueprint Observability
Repository
- The Repository Object
- Repository Lifecycle
Code Scenario
- Code Scenario Lifecycle
- Scenarios Runs
- Custom Scenario Scorer
- Public Scenarios
Benchmark
- Benchmark Lifecycle
- Benchmark Runs
- Public Benchmarks
List Devboxes.
List all Devboxes while optionally filtering by status.
import Runloop from '@runloop/api-client';
const client = new Runloop({
bearerToken: process.env['RUNLOOP_API_KEY'], // This is the default and can be omitted
});
async function main() {
// Automatically fetches more pages as needed.
for await (const devboxView of client.devboxes.list()) {
console.log(devboxView.id);
}
}
main();
{
"devboxes": [
{
"id": "<string>",
"name": "<string>",
"status": "provisioning",
"create_time_ms": 123,
"end_time_ms": 123,
"blueprint_id": "<string>",
"snapshot_id": "<string>",
"metadata": {},
"failure_reason": "out_of_memory",
"shutdown_reason": "api_shutdown",
"launch_parameters": {
"launch_commands": [
"<string>"
],
"resource_size_request": "X_SMALL",
"keep_alive_time_seconds": 123,
"available_ports": [
123
],
"after_idle": {
"idle_time_seconds": 123,
"on_idle": "shutdown"
},
"custom_cpu_cores": 123,
"custom_gb_memory": 123
},
"capabilities": [
"unknown"
]
}
],
"has_more": true,
"total_count": 123,
"remaining_count": 123
}
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Query Parameters
Filter by status
provisioning
, initializing
, running
, suspending
, suspended
, resuming
, failure
, shutdown
The limit of items to return. Default is 20.
Load the next page of data starting after the item with the given ID.
Response
List of devboxes matching filter.
A Devbox represents a virtual development environment. It is an isolated sandbox that can be given to agents and used to run arbitrary code such as AI generated code.
The ID of the Devbox.
The current status of the Devbox.
provisioning
, initializing
, running
, suspending
, suspended
, resuming
, failure
, shutdown
Creation time of the Devbox (Unix timestamp milliseconds).
The launch parameters used to create the Devbox.
Set of commands to be run at launch time, before the entrypoint process is run.
Manual resource configuration for Devbox. If not set, defaults will be used.
X_SMALL
, SMALL
, MEDIUM
, LARGE
, X_LARGE
, XX_LARGE
, CUSTOM_SIZE
Time in seconds after which Devbox will automatically shutdown. Default is 1 hour.
A list of ports to make available on the Devbox. Only ports made available will be surfaced to create tunnels via the 'createTunnel' API.
Configure Devbox lifecycle based on idle activity. If after_idle is set, Devbox will ignore keep_alive_time_seconds.
custom resource size, number of cpu cores, must be multiple of 2.
custom memory size, number in Gi, must be a multiple of 2.
A list of capability groups this devbox has access to. This allows devboxes to be compatible with certain tools sets like computer usage APIs.
unknown
, computer_usage
, browser_usage
, language_server
The name of the Devbox.
The time the Devbox finished execution (Unix timestamp milliseconds). Present if the Devbox is in a terminal state.
The Blueprint ID used in creation of the Devbox, if the devbox was created from a Blueprint.
The Snapshot ID used in creation of the Devbox, if the devbox was created from a Snapshot.
The failure reason if the Devbox failed, if the Devbox has a 'failure' status.
out_of_memory
, out_of_disk
, execution_failed
The shutdown reason if the Devbox shutdown, if the Devbox has a 'shutdown' status.
api_shutdown
, keep_alive_timeout
, entrypoint_exit
, idle
, lambda_lifecycle
Was this page helpful?
import Runloop from '@runloop/api-client';
const client = new Runloop({
bearerToken: process.env['RUNLOOP_API_KEY'], // This is the default and can be omitted
});
async function main() {
// Automatically fetches more pages as needed.
for await (const devboxView of client.devboxes.list()) {
console.log(devboxView.id);
}
}
main();
{
"devboxes": [
{
"id": "<string>",
"name": "<string>",
"status": "provisioning",
"create_time_ms": 123,
"end_time_ms": 123,
"blueprint_id": "<string>",
"snapshot_id": "<string>",
"metadata": {},
"failure_reason": "out_of_memory",
"shutdown_reason": "api_shutdown",
"launch_parameters": {
"launch_commands": [
"<string>"
],
"resource_size_request": "X_SMALL",
"keep_alive_time_seconds": 123,
"available_ports": [
123
],
"after_idle": {
"idle_time_seconds": 123,
"on_idle": "shutdown"
},
"custom_cpu_cores": 123,
"custom_gb_memory": 123
},
"capabilities": [
"unknown"
]
}
],
"has_more": true,
"total_count": 123,
"remaining_count": 123
}