Skip to content

Session commands

Common global behavior is documented in the CLI hub. The complete session-management command contracts follow.

Previous gdsgate session list/kill/watch calls remain aliases.

gdsgate sessions list

Lists the live sessions you are permitted to terminate (filtered by the Cedar killSession action).

Columns: id, owner, resource, kind, src ip, started, holds. --wide adds serial, the access certificate the session was opened with. --json prints one object per session.

holds is what the session was opened with:

holds Session After sessions kill
key Holder proved possession of a key. The holder keeps the certificate.
cookie Opened through the clientless browser entry. Access ends until the person signs in again.
gdsgate --config client.toml sessions list
# id        owner  resource  kind      src ip     started              holds
# 5f3c1234  alice  prod-db   postgres  10.0.0.14  2026-09-21 09:12:40  key

gdsgate sessions kill [<id>] [--principal <p>] [--resource <r>]

Terminates live sessions and audits each one. Pass one selector: <id>, --principal or --resource. Only sessions the policy permits are ended.

SESSION_ID=5f3c1234  # replace with an id from `sessions list`
gdsgate --config client.toml sessions kill "$SESSION_ID"
gdsgate --config client.toml sessions kill --principal alice
gdsgate --config client.toml sessions kill --resource prod-db
Argument Default Purpose
<id> none A single session id. Mutually exclusive with the selectors below.
--principal <p> none Every live session owned by this principal.
--resource <r> none Every live session on this backend resource.

gdsgate sessions watch

Streams opens and closes of live sessions you may act on, until interrupted.

list kill watch