Skip to content

Pins the run for the caller.

POST
/v1/m/sessions/runs/{ref}/pin
curl --request POST \
--url https://example.com/v1/m/sessions/runs/example/pin \
--header 'Authorization: Bearer <token>'

Pins the run for the caller. The entity middleware has already resolved the run and concealed an unreadable one as absent; the handler only re-reads the row inside its own transaction so a run that vanished mid-flight still refuses as 404 rather than pinning a ref with no session.

ref
required
string

Path parameter ref.

X-Olivares-Tenant
string format: uuid

Target tenant id; required when the principal can act in more than one tenant.

The run’s pin state for the caller

Media type application/json
object
pinned
required

Whether THIS caller has the session pinned; both directions are idempotent.

boolean
pinned_at

When this caller pinned it; present when pinned is true. Run list and get reads carry the same per-caller fields.

string
run_ref
required

The operated session’s stable reference.

string
Example generated
{
"pinned": true,
"pinned_at": "example",
"run_ref": "example"
}

Bad request

Media type application/json
object
Example generated
{}

Unauthenticated

Media type application/json
object
Example generated
{}

Forbidden

Media type application/json
object
Example generated
{}

Not found

Media type application/json
object
Example generated
{}

Conflict / setup required

Media type application/json
object
Example generated
{}

Rate limited

Media type application/json
object
Example generated
{}