dev.knotless.getUsage

lexicons.knotless.dev

Documentation

How an appview is used, day by day, for its operators: it takes a service token for this method from one of the accounts it names as its operators, or the session cookie of one logged in to its pages. What it counted itself (requests, page views, visitors by a hash forgotten each day, what its handlers saw) beside what its index says the network wrote.

main query

How an appview is used, day by day, for its operators: it takes a service token for this method from one of the accounts it names as its operators, or the session cookie of one logged in to its pages. What it counted itself (requests, page views, visitors by a hash forgotten each day, what its handlers saw) beside what its index says the network wrote.

Parameters

days integer Optional

How many days back, today (UTC) the last.

Output

Encodingapplication/json
clients array Required

Requests by kind of client: browser, git, cli, bot or other.

days array Required

Each day asked about, oldest first.

events array Optional

What the handlers saw, by name and subject.

funnels array Optional

Of the accounts that did one thing in the days asked, not having in the 30 days before, how many went on to another.

hours array Optional

Each hour the appview took requests in, oldest first: when failures and slow answers came.

network ref#network Optional

No description available.

pages array Required

Pages drawn in a browser, by the route that drew them.

referrers array Required

The sites that sent visitors to the pages, by host.

routes array Required

Requests by route, busiest first.

Try It

Requests are sent directly from your browser. Some servers may block requests due to CORS.

Base URL for XRPC calls (e.g., https://api.bsky.social)
Parameters
How many days back, today (UTC) the last.
View raw schema
{
  "description": "How an appview is used, day by day, for its operators: it takes a service token for this method from one of the accounts it names as its operators, or the session cookie of one logged in to its pages. What it counted itself (requests, page views, visitors by a hash forgotten each day, what its handlers saw) beside what its index says the network wrote.",
  "output": {
    "encoding": "application/json",
    "schema": {
      "properties": {
        "clients": {
          "description": "Requests by kind of client: browser, git, cli, bot or other.",
          "items": {
            "ref": "#count",
            "type": "ref"
          },
          "type": "array"
        },
        "days": {
          "description": "Each day asked about, oldest first.",
          "items": {
            "ref": "#day",
            "type": "ref"
          },
          "type": "array"
        },
        "events": {
          "description": "What the handlers saw, by name and subject.",
          "items": {
            "ref": "#event",
            "type": "ref"
          },
          "type": "array"
        },
        "funnels": {
          "description": "Of the accounts that did one thing in the days asked, not having in the 30 days before, how many went on to another.",
          "items": {
            "ref": "#funnel",
            "type": "ref"
          },
          "type": "array"
        },
        "hours": {
          "description": "Each hour the appview took requests in, oldest first: when failures and slow answers came.",
          "items": {
            "ref": "#hour",
            "type": "ref"
          },
          "type": "array"
        },
        "network": {
          "ref": "#network",
          "type": "ref"
        },
        "pages": {
          "description": "Pages drawn in a browser, by the route that drew them.",
          "items": {
            "ref": "#count",
            "type": "ref"
          },
          "type": "array"
        },
        "referrers": {
          "description": "The sites that sent visitors to the pages, by host.",
          "items": {
            "ref": "#count",
            "type": "ref"
          },
          "type": "array"
        },
        "routes": {
          "description": "Requests by route, busiest first.",
          "items": {
            "ref": "#route",
            "type": "ref"
          },
          "type": "array"
        }
      },
      "required": [
        "days",
        "routes",
        "pages",
        "referrers",
        "clients"
      ],
      "type": "object"
    }
  },
  "parameters": {
    "properties": {
      "days": {
        "default": 14,
        "description": "How many days back, today (UTC) the last.",
        "maximum": 400,
        "minimum": 1,
        "type": "integer"
      }
    },
    "type": "params"
  },
  "type": "query"
}
count object

Something, and how many times.

Properties

n integer Required

No description available.

minimum: 0
name string Required

No description available.

View raw schema
{
  "description": "Something, and how many times.",
  "properties": {
    "n": {
      "minimum": 0,
      "type": "integer"
    },
    "name": {
      "type": "string"
    }
  },
  "required": [
    "name",
    "n"
  ],
  "type": "object"
}
day object

One day, in UTC.

Properties

authors integer Required

Accounts that made a repository, pushed, or wrote in a thread.

minimum: 0
checks integer Required

Check runs started.

minimum: 0
comments integer Required

No description available.

minimum: 0
day string Required

YYYY-MM-DD.

errors integer Required

Of those, failed (5xx).

minimum: 0
issues integer Required

No description available.

minimum: 0
pulls integer Required

No description available.

minimum: 0
pushes integer Required

No description available.

minimum: 0
repos integer Required

Repositories made, from the index.

minimum: 0
requests integer Required

Requests taken, but for health checks.

minimum: 0
views integer Required

Pages they drew.

minimum: 0
visitors integer Required

People whose browsers drew a page, each once.

minimum: 0
View raw schema
{
  "description": "One day, in UTC.",
  "properties": {
    "authors": {
      "description": "Accounts that made a repository, pushed, or wrote in a thread.",
      "minimum": 0,
      "type": "integer"
    },
    "checks": {
      "description": "Check runs started.",
      "minimum": 0,
      "type": "integer"
    },
    "comments": {
      "minimum": 0,
      "type": "integer"
    },
    "day": {
      "description": "YYYY-MM-DD.",
      "type": "string"
    },
    "errors": {
      "description": "Of those, failed (5xx).",
      "minimum": 0,
      "type": "integer"
    },
    "issues": {
      "minimum": 0,
      "type": "integer"
    },
    "pulls": {
      "minimum": 0,
      "type": "integer"
    },
    "pushes": {
      "minimum": 0,
      "type": "integer"
    },
    "repos": {
      "description": "Repositories made, from the index.",
      "minimum": 0,
      "type": "integer"
    },
    "requests": {
      "description": "Requests taken, but for health checks.",
      "minimum": 0,
      "type": "integer"
    },
    "views": {
      "description": "Pages they drew.",
      "minimum": 0,
      "type": "integer"
    },
    "visitors": {
      "description": "People whose browsers drew a page, each once.",
      "minimum": 0,
      "type": "integer"
    }
  },
  "required": [
    "day",
    "visitors",
    "views",
    "requests",
    "errors",
    "repos",
    "pushes",
    "pulls",
    "issues",
    "comments",
    "checks",
    "authors"
  ],
  "type": "object"
}
event object

Something the handlers saw, over the days asked.

Properties

accounts integer Required

Accounts that did anything of this name in the days asked, at most the last 30, as only the signed-in are known and none is kept longer.

minimum: 0
calls integer Required

No description available.

minimum: 0
failed integer Required

No description available.

minimum: 0
meanMs integer Required

Mean milliseconds; 0 for what is not timed.

minimum: 0
name string Required

What it was.

Known values: mcp.tool, mcp.signin, git.fetch, cli.version, gateway.delegated, gateway.push, gateway.commit
subject string Required

Of what: the tool, the repository as asked for, the version; empty for none.

View raw schema
{
  "description": "Something the handlers saw, over the days asked.",
  "properties": {
    "accounts": {
      "description": "Accounts that did anything of this name in the days asked, at most the last 30, as only the signed-in are known and none is kept longer.",
      "minimum": 0,
      "type": "integer"
    },
    "calls": {
      "minimum": 0,
      "type": "integer"
    },
    "failed": {
      "minimum": 0,
      "type": "integer"
    },
    "meanMs": {
      "description": "Mean milliseconds; 0 for what is not timed.",
      "minimum": 0,
      "type": "integer"
    },
    "name": {
      "description": "What it was.",
      "knownValues": [
        "mcp.tool",
        "mcp.signin",
        "git.fetch",
        "cli.version",
        "gateway.delegated",
        "gateway.push",
        "gateway.commit"
      ],
      "type": "string"
    },
    "subject": {
      "description": "Of what: the tool, the repository as asked for, the version; empty for none.",
      "type": "string"
    }
  },
  "required": [
    "name",
    "subject",
    "calls",
    "failed",
    "meanMs",
    "accounts"
  ],
  "type": "object"
}
funnel object

Accounts that did one thing in the days asked, not having in the 30 days before, and of them those that did the other then or within 30 days.

Properties

from string Required

An event's name.

reached integer Required

No description available.

minimum: 0
started integer Required

No description available.

minimum: 0
to string Required

An event's name.

View raw schema
{
  "description": "Accounts that did one thing in the days asked, not having in the 30 days before, and of them those that did the other then or within 30 days.",
  "properties": {
    "from": {
      "description": "An event's name.",
      "type": "string"
    },
    "reached": {
      "minimum": 0,
      "type": "integer"
    },
    "started": {
      "minimum": 0,
      "type": "integer"
    },
    "to": {
      "description": "An event's name.",
      "type": "string"
    }
  },
  "required": [
    "from",
    "to",
    "started",
    "reached"
  ],
  "type": "object"
}
hour object

No description available.

Properties

errors integer Required

Of those, the ones it failed (5xx).

minimum: 0
hour string Required

The hour, as YYYY-MM-DDTHH in UTC.

overTwo integer Required

Of those, the ones that took over two seconds.

minimum: 0
requests integer Required

No description available.

minimum: 0
View raw schema
{
  "properties": {
    "errors": {
      "description": "Of those, the ones it failed (5xx).",
      "minimum": 0,
      "type": "integer"
    },
    "hour": {
      "description": "The hour, as YYYY-MM-DDTHH in UTC.",
      "type": "string"
    },
    "overTwo": {
      "description": "Of those, the ones that took over two seconds.",
      "minimum": 0,
      "type": "integer"
    },
    "requests": {
      "minimum": 0,
      "type": "integer"
    }
  },
  "required": [
    "hour",
    "requests",
    "errors",
    "overTwo"
  ],
  "type": "object"
}
network object

The network as the index has it now.

Properties

accounts integer Required

Accounts that ever made a repository, pushed, or wrote in a thread.

minimum: 0
authorsMonth integer Required

And in the last 30.

minimum: 0
authorsWeek integer Required

Accounts that did so in the last 7 days.

minimum: 0
repos integer Required

No description available.

minimum: 0
View raw schema
{
  "description": "The network as the index has it now.",
  "properties": {
    "accounts": {
      "description": "Accounts that ever made a repository, pushed, or wrote in a thread.",
      "minimum": 0,
      "type": "integer"
    },
    "authorsMonth": {
      "description": "And in the last 30.",
      "minimum": 0,
      "type": "integer"
    },
    "authorsWeek": {
      "description": "Accounts that did so in the last 7 days.",
      "minimum": 0,
      "type": "integer"
    },
    "repos": {
      "minimum": 0,
      "type": "integer"
    }
  },
  "required": [
    "accounts",
    "repos",
    "authorsWeek",
    "authorsMonth"
  ],
  "type": "object"
}
route object

A route, by the pattern it matched, and how it answered.

Properties

errors integer Required

Failed (5xx).

minimum: 0
meanMs integer Required

Mean milliseconds to the answer's head.

minimum: 0
method string Required

The HTTP method.

overHalf integer Required

Requests that took over half a second.

minimum: 0
overTwo integer Required

Requests that took over two seconds.

minimum: 0
requests integer Required

No description available.

minimum: 0
route string Required

Its pattern, as /api/{authority}/{repo}/tree.

surface string Required

Where it is.

Known values: pages, api, git, xrpc, mcp, install, other
View raw schema
{
  "description": "A route, by the pattern it matched, and how it answered.",
  "properties": {
    "errors": {
      "description": "Failed (5xx).",
      "minimum": 0,
      "type": "integer"
    },
    "meanMs": {
      "description": "Mean milliseconds to the answer's head.",
      "minimum": 0,
      "type": "integer"
    },
    "method": {
      "description": "The HTTP method.",
      "type": "string"
    },
    "overHalf": {
      "description": "Requests that took over half a second.",
      "minimum": 0,
      "type": "integer"
    },
    "overTwo": {
      "description": "Requests that took over two seconds.",
      "minimum": 0,
      "type": "integer"
    },
    "requests": {
      "minimum": 0,
      "type": "integer"
    },
    "route": {
      "description": "Its pattern, as /api/{authority}/{repo}/tree.",
      "type": "string"
    },
    "surface": {
      "description": "Where it is.",
      "knownValues": [
        "pages",
        "api",
        "git",
        "xrpc",
        "mcp",
        "install",
        "other"
      ],
      "type": "string"
    }
  },
  "required": [
    "surface",
    "method",
    "route",
    "requests",
    "errors",
    "meanMs",
    "overHalf",
    "overTwo"
  ],
  "type": "object"
}

Lexicon Garden

@