> ## Documentation Index
> Fetch the complete documentation index at: https://docs.costgraph.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Sprites sandboxes

> Run CostGraph workflows and CI jobs in Sprites sandboxes: the key to create, its permissions, and its limits

Sprites are persistent, hardware-isolated Linux microVMs on Fly.io for AI agents, dev environments and untrusted code, billed by the second and free when idle.

The following table shows what CostGraph runs on this provider.

| Workflows | CI runners | Connect with |
| - | - | - |
| Yes | Yes | Integrations or your own dispatcher |

## Connect

Connect Sprites on Integrations, and CostGraph starts sandboxes in your Sprites account. You don't run anything yourself.

1. In CostGraph, go to **Integrations > Sandbox > Sprites**.

2. Enter these fields:

   * **API token** (`SPRITES_TOKEN`, required): A Sprites API token from sprites.dev/account.

3. Click **Connect**.

### Your own dispatcher

To keep the key out of CostGraph or reach a private network, run your own dispatcher instead.
Set `provider` to `sprites` and the preceding fields as environment variables, as described in [Run your own dispatcher](https://docs.costgraph.ai/costgraph/workflows/managed-sandboxes.md#run-your-own-dispatcher).

## Key and permissions

SPRITES\_TOKEN is a Sprites API token for one Fly.io organization (format org/token-id/secret), created at sprites.dev/account, by "sprite login" (Fly.io sign-in adds a token for your org) or `sprite org auth --org <name>`; configure CI with `sprite auth setup --token`. Sent as Authorization: Bearer to api.sprites.dev.

A token is bound to a single organization. Sprites doesn't document permission levels or read-only tokens.

Sources: [docs.fly.io: sprites](https://docs.fly.io/sprites), [docs.fly.io: authentication](https://docs.fly.io/sprites/cli/authentication), [docs.fly.io: lifecycle](https://docs.fly.io/sprites/concepts/lifecycle), [sprites.dev: account](https://sprites.dev/account).

## Limits

* Each Sprite runs with 8 vCPUs (not changeable); memory assigned per Sprite and autoscaled; 100 GB disk that does not autoscale. ([source](https://docs.fly.io/sprites/concepts/lifecycle))
* Pauses (warm, memory kept) after about 30 seconds idle; later goes cold (VM stopped, processes restart on wake). ([source](https://docs.fly.io/sprites/concepts/lifecycle))
* Max lifetime, regions, architecture: not documented. ([source](https://docs.fly.io/sprites))

## Related

* [Supported sandbox providers](https://docs.costgraph.ai/costgraph/workflows/sandbox-providers.md)
* [Run workflows on a managed sandbox provider](https://docs.costgraph.ai/costgraph/workflows/managed-sandboxes.md)
* [Run CI jobs in sandboxes](https://docs.costgraph.ai/costgraph/autopilot/ci-sandboxes.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.