Aller au contenu

API console: admin-search

Cette page est générée à partir de server/api/openapi.yaml. Son contenu est en anglais ; ne la modifiez pas à la main.

Global search of the admin console (PRD V3 U2). Handlers: internal/admin/search.

Search the whole platform

operationId adminSearch · auth: adminSession

Operator search over users, organisations, orders, requests, ledger transactions, API keys, channels, models and system settings, with the same query shapes as consoleSearch (@ matches user emails by prefix; names match organisation names, channel names, model names and setting keys). At most 5 hits per group. Every call is written to the audit log as admin.search (an sk- query is recorded as its first 10 characters).

Parameter In Type Required Description
q query string yes The search text; leading and trailing spaces are ignored. (minLength: 1, maxLength: 200)
Status Meaning Body
200 OK application/json SearchResults
default Error envelope. The HTTP status follows the error kind. application/json Error

Response 200 application/json — SearchResults

  • query (string, required) — The query as it was searched (trimmed; an sk- query cut to 10 characters).
  • kind (“uuid” | “key_prefix” | “email” | “name”, required) — How the query was read.
  • groups (array of SearchGroup, required) — Only groups with at least one hit, in a fixed order per scope.
    • type (SearchHitType, required)
    • items (array of SearchHit, required, maxItems: 5)
      • id (string, required) — The object’s id (a UUID), or the setting key for setting hits.
      • title (string, required) — Main label, e.g. the key name, email, organisation name or model slug.
      • subtitle (string, required) — Secondary label (key prefix, model display name, amount, setting description); may be empty.
      • status (string, required) — The object’s status as its own API reports it (active, paid, …); empty when it has none.
      • org_id (string, required, nullable) — Organisation the object belongs to (admin search), null otherwise.