Skip to content
PuniDocs
Open Puni

Auth commands


Sign a machine in to your library and keep its token.

Sign a machine in once; every remote command then finds its token. Read Scopes and tokens for what a token allows.

puni authSign a machine in to your library and keep its token.

CommandWhat it does
puni auth loginRequest a code, open the approval page, and save the device token for this origin. Type the printed code on that page.
puni auth statusReport the saved token for an origin and when it expires, without contacting the server.
puni auth logoutRevoke the token on the server, then remove it from the credentials file.

#auth login

Request a code, open the approval page, and save the device token for this origin. Type the code the terminal prints on that page; it shows the name this terminal gave, the access it asks for, and when and where the request started. A sign-in asks for read and write. Add --scope share to also create and revoke share links, or --scope read for reading only. Rendering and sculpting come from a token made in Settings → Agents, never from signing in.

puni auth login --base-url https://puni.design [--scope read|write|share] [--no-open]

FlagTypeDefaultValuesWhat it does
--base-urlstringThe studio origin, such as https://puni.design. Defaults to PUNI_BASE_URL, else the one studio you are signed in to. HTTPS, except loopback.
--scopestringwriteread, write, shareThe access to ask for: read, write (read and write) or share (read, write and share links). Rendering and sculpting are never granted by signing in.
--no-openbooleanfalsePrint the approval link instead of opening a browser.
--auth-filestringRead and write credentials in this file instead of ~/.config/puni/credentials.json.
--jsonbooleanfalseAnswer with one JSON envelope instead of the shell view. Exception: agent serve streams raw lifecycle JSON lines before its final envelope.
--help -hbooleanPrint the command list.

#Run auth login

bash
puni auth login --base-url https://puni.design
puni auth login --base-url https://puni.design --scope share

#auth status

Report the saved token for an origin and when it expires, without contacting the server.

puni auth status --base-url https://puni.design

FlagTypeDefaultValuesWhat it does
--base-urlstringThe studio origin, such as https://puni.design. Defaults to PUNI_BASE_URL, else the one studio you are signed in to. HTTPS, except loopback.
--auth-filestringRead and write credentials in this file instead of ~/.config/puni/credentials.json.
--jsonbooleanfalseAnswer with one JSON envelope instead of the shell view. Exception: agent serve streams raw lifecycle JSON lines before its final envelope.
--help -hbooleanPrint the command list.

#Run auth status

bash
puni auth status --base-url https://puni.design --json

#auth logout

Revoke the token on the server, then remove it from the credentials file.

puni auth logout --base-url https://puni.design

FlagTypeDefaultValuesWhat it does
--base-urlstringThe studio origin, such as https://puni.design. Defaults to PUNI_BASE_URL, else the one studio you are signed in to. HTTPS, except loopback.
--auth-filestringRead and write credentials in this file instead of ~/.config/puni/credentials.json.
--jsonbooleanfalseAnswer with one JSON envelope instead of the shell view. Exception: agent serve streams raw lifecycle JSON lines before its final envelope.
--help -hbooleanPrint the command list.

#Run auth logout

bash
puni auth logout --base-url https://puni.design --json

Back to the command line index for every group.

Was this useful?