GET /v1/dashboard/session

Whether the caller has a dashboard session. Public; carries no data.

Auth. None. Anyone can call this route.

Responses

StatusMeaningBody
200Sign-in stateobject
429Too many requests from this client address. Wait the number of seconds in Retry-After, then try again.Error

Example response

{
  "signed_in": true
}

Code samples

Set KEY to your own token first.

curl

curl \
  "https://api.sasek.org/ledger/v1/dashboard/session"

JavaScript

const res = await fetch("https://api.sasek.org/ledger/v1/dashboard/session", {
});
const data = await res.json();

Python

import json
import os
import urllib.request

request = urllib.request.Request(
    "https://api.sasek.org/ledger/v1/dashboard/session",
    method="GET",
)
with urllib.request.urlopen(request) as response:
    print(json.load(response))