The livediagram CLI

Read, build, edit and discuss your work from a terminal: install, sign in, the commands, and profiles.

Applies To

livediagram, liveplanner, livedocuments and livedesign

It sits beside the MCP server, not in place of it. Both call the same API with an API token, and the API owns every change, so an older copy of the CLI never writes the old way.

Install

Sign In

You need a livediagram account: the CLI acts as you, through an API token, and never as a guest. There are three ways to give it one. Whichever you use, the CLI checks the token with the API before keeping it.

In the Browser

The CLI opens a sign-in page in your browser (and prints its address, in case the browser does not open). Sign in if you are not already, and you reach an approval card, Connect livediagram CLI. Leave Read-only access off to let the CLI change canvases, or switch it on so it can find and view canvases but not create, edit, delete or share them. The card also says where the access goes: your own computer, 127.0.0.1 and a port number. Choose Connect, and the page says You're signed in: return to your terminal.

The approval card: an optional Read-only access switch, where the access goes, then Connect.

The terminal waits up to ten minutes for you. If the browser cannot reach it (on a remote machine, say), use a device code instead.

On a Machine Without a Browser

Device sign-in: the terminal shows the page and a code, which you enter under Connect a terminal on any device.

A code lasts ten minutes. If the page says it couldn't find the code, check it and try again; if it has expired, run the command again for a new one. Choosing Cancel on the page stops the terminal waiting. Only enter a code that a terminal you are using is showing you.

With an API Token

or store it for this machine, reading it from stdin:

Check or Sign Out

Where Your Token Is Kept

Find and Read Canvases

A few commands read livediagram's catalogues rather than your canvases, which helps before writing anything:

Comments and Waiting

Files, Exports and Pictures

Help, Guides and the Agent Skill

Output and Exit Codes

Exit codeMeaning
0Done
1Refused: the input was understood but not accepted
2Usage: the command line does not parse
3Not found, or ambiguous: a canvas, tab or element
4Not signed in, or not allowed (a read-only token's writes)
5Conflict: the tab changed since you read it; read, retry
6Rate limited
7Network or server failure

Errors and Rate Limits

The CLI is subject to the same limits as any API client, per token: on the hosted service, 300 writes and 120 reads a minute. Over that, a command exits with 6 and asks you to wait a minute and retry. A read-only token's writes exit with 4. Errors and Rate Limits has the full list and the status codes behind these exit codes.

Usage Counts

Updates

Keep It Safe

How this works in 3 other apps

Was this article helpful?

Still need help?

Try Troubleshooting, or tell us what you were trying to do.

Contact us