api and open
lyrelog api calls any dashboard API route with your sign-in; lyrelog open goes to the same page in the dashboard.
api
lyrelog api calls any route of the dashboard's API with your sign-in, like gh api. It's for
anything the other commands don't wrap yet.
lyrelog api <method> <path>- The method is
GET,POST,PUT,PATCHorDELETE. - The path may leave out
/api:projects/{project}is/api/projects/{project}. Give the path only. The server comes from--urlorLYRELOG_URL. {project}becomes the current project's id (the default one, or-p).
lyrelog api GET /api/me{"admin":false,"organizations":[{"id":4,"name":"Alex Rivera","role":"owner","plan":"free","plan_until":null}],"user":{"id":10,"email":"alex@example.com","name":"Alex Rivera"}}lyrelog api GET projects/{project}/regions -F from=1763500000000
lyrelog api PATCH projects/{project} --data '{"retention_days":30}'
lyrelog api POST projects/{project}/views --data @view.json| Flag | What |
|---|---|
-F, --field | key=value. On a GET it's a query parameter; on POST, PUT and PATCH it's a field of the JSON body (numbers, true, false and null are sent as such). Repeat it for more. |
-d, --data | The request body as it is: JSON, @file to read a file, or @- for stdin. Not with -F. |
The answer is printed as it comes. At a terminal, JSON is indented and coloured. An answer
with no body prints its status ({"status":204} in JSON mode). A failure exits with the same
exit codes as every command, with the error as JSON on stderr
in JSON mode.
These are the routes the dashboard itself uses, and they aren't documented here. For a documented API to read events from scripts, use the Read API.
open
lyrelog open opens a page of the dashboard in your browser, on the current project.
lyrelog open errors
lyrelog open person gc-2e427d7b
lyrelog open settings --printhttps://app.lyrelog.com/p/e8bc11c6e22f/settings| Page | What |
|---|---|
| (none) | The explorer |
events | The explorer |
errors | The Errors page |
sessions | Sessions |
people | The project's people |
insights | Insights |
releases | Releases |
keys | API keys |
settings | Project settings |
projects | All projects |
usage | Usage and plan |
account | Your account |
organization | Your organization |
person <id> | One person's page |
event <id> | The explorer, searching for one event |
| Flag | What |
|---|---|
--print | Print the address instead of opening it |
Over SSH, or when no browser can be opened, it prints the address. In JSON mode, for an
agent or a script, it doesn't open anything: it prints {"url":"..."}.