garden.lexicon.suggest

lexicon.garden

Documentation

Typeahead suggestions for indexed lexicons. Unlike garden.lexicon.browse, the query is matched against every segment-aligned suffix of an NSID, so 'feed.post' matches 'app.bsky.feed.post'. Results are sorted by NSID ascending and are not paginated.

main query

Typeahead suggestions for indexed lexicons. Unlike garden.lexicon.browse, the query is matched against every segment-aligned suffix of an NSID, so 'feed.post' matches 'app.bsky.feed.post'. Results are sorted by NSID ascending and are not paginated.

Parameters

lexiconType array of string Optional

Filter suggestions to these definition types. Repeat the parameter for multiple types. Omit to include all types.

limit integer Optional

Maximum number of suggestions to return.

q string Required

Search prefix, matched against an NSID or any of its segment-aligned suffixes.

Output

Encodingapplication/json
suggestions array Required

No description available.

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
Filter suggestions to these definition types. Repeat the parameter for multiple types. Omit to include all types.
Maximum number of suggestions to return.
Search prefix, matched against an NSID or any of its segment-aligned suffixes.
View raw schema
{
  "type": "query",
  "output": {
    "schema": {
      "type": "object",
      "required": [
        "suggestions"
      ],
      "properties": {
        "suggestions": {
          "type": "array",
          "items": {
            "ref": "#lexiconSuggestion",
            "type": "ref"
          }
        }
      }
    },
    "encoding": "application/json"
  },
  "parameters": {
    "type": "params",
    "required": [
      "q"
    ],
    "properties": {
      "q": {
        "type": "string",
        "maxLength": 253,
        "minLength": 2,
        "description": "Search prefix, matched against an NSID or any of its segment-aligned suffixes."
      },
      "limit": {
        "type": "integer",
        "default": 10,
        "maximum": 20,
        "minimum": 1,
        "description": "Maximum number of suggestions to return."
      },
      "lexiconType": {
        "type": "array",
        "items": {
          "type": "string",
          "maxLength": 32,
          "knownValues": [
            "record",
            "query",
            "procedure",
            "subscription",
            "permission-set"
          ]
        },
        "maxLength": 5,
        "description": "Filter suggestions to these definition types. Repeat the parameter for multiple types. Omit to include all types."
      }
    }
  },
  "description": "Typeahead suggestions for indexed lexicons. Unlike garden.lexicon.browse, the query is matched against every segment-aligned suffix of an NSID, so 'feed.post' matches 'app.bsky.feed.post'. Results are sorted by NSID ascending and are not paginated."
}
lexiconSuggestion object

An indexed lexicon whose NSID matched the query.

Properties

did string did Required

DID of the authority that published the lexicon.

lexiconType string Optional

Definition type of the lexicon's main def. Absent when the indexed type is unknown.

maxLength: 32 bytes
Known values: record, query, procedure, subscription, permission-set
nsid string nsid Required

The full NSID of the lexicon.

uri string at-uri Required

AT-URI of the com.atproto.lexicon.schema record backing this suggestion.

View raw schema
{
  "type": "object",
  "required": [
    "nsid",
    "did",
    "uri"
  ],
  "properties": {
    "did": {
      "type": "string",
      "format": "did",
      "description": "DID of the authority that published the lexicon."
    },
    "uri": {
      "type": "string",
      "format": "at-uri",
      "description": "AT-URI of the com.atproto.lexicon.schema record backing this suggestion."
    },
    "nsid": {
      "type": "string",
      "format": "nsid",
      "description": "The full NSID of the lexicon."
    },
    "lexiconType": {
      "type": "string",
      "maxLength": 32,
      "description": "Definition type of the lexicon's main def. Absent when the indexed type is unknown.",
      "knownValues": [
        "record",
        "query",
        "procedure",
        "subscription",
        "permission-set"
      ]
    }
  },
  "description": "An indexed lexicon whose NSID matched the query."
}

Lexicon Garden

@