---
title: "Rivet"
description: "Rivet's engine, durable actors for AI agents and realtime apps, installed in a project as a Managed Application. Not open to accounts yet."
---

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

# Rivet

**Not open yet.** Managed Applications are not open to accounts yet. This page says how Rivet works as it is built, ahead of their opening, and may change before then.

[Rivet](https://www.rivet.dev/) runs long-lived actors addressed by key: each keeps its state, a SQLite database, a queue and realtime connections, and sleeps when nothing asks for it. An installation of it is one Rivet engine of your own, version 3.0.0 (Apache-2.0), packaged by the platform: your runner (your app, built with RivetKit) and your clients connect to it. Its source is [rivet-dev/rivet](https://github.com/rivet-dev/rivet).

```bash
glac install rivet --set disk_gib=20
```

## What an installation is made of

| Part | What it is |
|---|---|
| The app `<name>-engine` | The engine: a stateful Cube service, port 6420, on an instance of its own. It sleeps after `idle_seconds` without a request, and a request wakes it. |
| Its Volume `engine/data` | The engine's disk, at `/var/lib/rivet`: its log of recent writes and its read cache, 40% of it each. |
| Its bucket `actors` | The durable copy of every actor's data, kept by the engine in object storage under a prefix of the installation's own. |
| Its admin token | Made once at the install, kept as a secret of the project's; in `admin_token` and `endpoint`. |

## Parameters

| Parameter | What it is |
|---|---|
| `size.vcpus` | The engine's vCPUs at the most: 1 to 8, 1 unless you say. |
| `size.memory_gib` | Its memory at the most, in GiB: 0.5 to 16, 1 unless you say. |
| `disk_gib` | Its Volume's size, in GiB: 2 to 1,024, 10 unless you say. Fixed once it is made. |
| `idle_seconds` | How long the engine stays awake with no request before it sleeps: 10 to 600, 600 unless you say. |

## Outputs

| Output | What it is |
|---|---|
| `url` | The engine's address, which answers the internet. |
| `endpoint` | What a runner and a client of RivetKit take as `RIVET_ENDPOINT`: the address with the admin token in it. Secret. |
| `admin_token` | The engine's admin token, for calls that need it (`Authorization: Bearer …`). Secret. |
| `private_url` | The engine on the project's private network: `http://<name>-engine.internal:6420`, for your apps and your sandboxes on the network. |

The create's answer has every output; afterwards the secret ones are shown to a key with the `admin` scope, and in the console.

## Using it

Point your runner and your clients at `endpoint` (or, from the project's own apps and sandboxes, at `private_url` with the admin token). Once the engine is first up, the platform makes its default pool of runners (`default`, in the namespace `default`), which your runner joins, and the installation is `ready` once it has: the engine answers its health a little before its storage takes commands, and a call made in between is refused `overloaded` (retryable). An actor's state is the engine's: it writes it to its Volume first, and to its bucket for good, so it outlives the engine's instance.

## Its health through the API

`GET /v1/managed/rivet/{installation}/health` asks the engine how it is, on its instance (which it wakes), and answers what it said: `{"object": "rivet_health", "installation_id": "ins-…", "engine": {"status": "ok", "version": "3.0.0", …}}`. While the engine does not answer, it is refused 503 `engine_not_ready` (retryable). It takes a key with the `read` scope.

## What it costs

What its engine's instance uses, its Volume and its bucket, at Cube's prices ([what an installation costs](/docs/managed-applications/#what-it-costs)). Its calculator says what a month of it comes to at these inputs: 1 vCPU and 1 GiB awake around the clock, its CPU busy 5% of the time, a 10 GB Volume, 1 GB in its bucket, a million requests and 1 GB to the internet:

| Meter | A month |
|---|---|
| CPU | 36 vCPU-hours |
| Memory | 720 GiB-hours |
| Requests | 1,000,000 |
| Volume data | 11 GB-months |
| Volume cache | 10 GB-months |
| Traffic to the internet | 1 GB |

While the engine sleeps it uses no CPU time or memory; what it keeps while it sleeps is billed as any sleeping instance's.

Source: https://glac.ai/docs/managed-applications/rivet/index.mdx
