API docs

zpe-reports

mount /reports · base https://zpe.vc/reports · v1.0.1 · 2 operations · 0 write · 0 need no account · beta

the document this app serves now. Contract: https://zpe.vc/reports/_/api/v1/openapi.json · sha256 aff7ada2a991

GET /_/api/v1/reports Every report this caller may read, as a keyset page getReportIndex

Every report this caller may read, as a keyset page

Parameters

nameinrequiredtypenotes
cursorquerynostringThe last slug of the previous page, from x-next-cursor.
limitquerynointegerHow many rows to answer, at most 50.

Request body

None: this operation takes its arguments in the path and the query.

Responses

statusmeaningbody
200The caller's reports, name order, with the cursor for the next page in the body.object
401No session cookie, and no key the door knows.object
403A key was presented that is not granted this app for a read.object
429The door is rate-limiting this caller's key, so the read was not attempted.object
500This app failed while answeringobject
503The door did not answer, so nothing could be named and nothing was read.object

Example

Every report this caller may read, as a keyset page, with a token from the door.

GET /_/api/v1/reports
curl -X GET 'https://zpe.vc/reports/_/api/v1/reports?cursor=string&limit=20' \
  -H 'Authorization: Bearer $ZPE_TOKEN'
200 application/json
{
  "reports": [
    {
      "slug": "string",
      "label": "string",
      "published": false,
      "built_at": "string",
      "parts": 0,
      "sections": 0,
      "tables": 0
    }
  ],
  "next_cursor": null
}

The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.

GET /_/api/v1/reports/{slug} One report's build facts, to the caller that owns the slug getReportBySlug

One report's build facts, to the caller that owns the slug

Parameters

nameinrequiredtypenotes
slugpathyesstringThe client slug, as it appears in the report's address.

Request body

None: this operation takes its arguments in the path and the query.

Responses

statusmeaningbody
200What the publisher wrote: the build time, the page's size, its counts, and the loop's last pass.object
401No session cookie, and no key the door knows.object
403A key was presented that is not granted this app for a read.object
404No report at this slug for this caller. A slug that belongs to another account answers the same.object
429The door is rate-limiting this caller's key, so the read was not attempted.object
500This app failed while answeringobject
503The door did not answer, so nothing could be named and nothing was read.object

Example

One report's build facts, to the caller that owns the slug, with a token from the door.

GET /_/api/v1/reports/{slug}
curl -X GET 'https://zpe.vc/reports/_/api/v1/reports/string' \
  -H 'Authorization: Bearer $ZPE_TOKEN'
200 application/json
{
  "slug": "string",
  "label": "string",
  "published": false,
  "built_at": "string",
  "bytes": 0,
  "parts": 0,
  "sections": 0,
  "tables": 0,
  "loop": {
    "last_pass": "string",
    "outcome": "string",
    "last_publish": "string"
  }
}

The example is generated from the schema in the contract: the shape is the document's, the values are placeholders.