-
Notifications
You must be signed in to change notification settings - Fork 573
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
proposed new search lexicons (#1594)
* proposed new search lexicons * lexicons: lint * lexicons: fix actors typo * lexicons: camelCase bites again, ssssss * lexicons: add 'q' and mark 'term' as deprecated for search endpoints * codegen for search lexicon updates * bsky: prefer 'q' over 'term' in existing search endpoints * search: bugfix * lexicons: make unspecced search endpoints return skeleton obj * re-codegen for search skeleton obj
- Loading branch information
Showing
37 changed files
with
1,671 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"lexicon": 1, | ||
"id": "app.bsky.feed.searchPosts", | ||
"defs": { | ||
"main": { | ||
"type": "query", | ||
"description": "Find posts matching search criteria", | ||
"parameters": { | ||
"type": "params", | ||
"required": ["q"], | ||
"properties": { | ||
"q": { | ||
"type": "string", | ||
"description": "search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended" | ||
}, | ||
"limit": { | ||
"type": "integer", | ||
"minimum": 1, | ||
"maximum": 100, | ||
"default": 25 | ||
}, | ||
"cursor": { | ||
"type": "string", | ||
"description": "optional pagination mechanism; may not necessarily allow scrolling through entire result set" | ||
} | ||
} | ||
}, | ||
"output": { | ||
"encoding": "application/json", | ||
"schema": { | ||
"type": "object", | ||
"required": ["posts"], | ||
"properties": { | ||
"cursor": { "type": "string" }, | ||
"hitsTotal": { | ||
"type": "integer", | ||
"description": "count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits" | ||
}, | ||
"posts": { | ||
"type": "array", | ||
"items": { | ||
"type": "ref", | ||
"ref": "app.bsky.feed.defs#postView" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"errors": [{ "name": "BadQueryString" }] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"lexicon": 1, | ||
"id": "app.bsky.unspecced.defs", | ||
"defs": { | ||
"skeletonSearchPost": { | ||
"type": "object", | ||
"required": ["uri"], | ||
"properties": { | ||
"uri": { "type": "string", "format": "at-uri" } | ||
} | ||
}, | ||
"skeletonSearchActor": { | ||
"type": "object", | ||
"required": ["did"], | ||
"properties": { | ||
"did": { "type": "string", "format": "did" } | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
{ | ||
"lexicon": 1, | ||
"id": "app.bsky.unspecced.searchActorsSkeleton", | ||
"defs": { | ||
"main": { | ||
"type": "query", | ||
"description": "Backend Actors (profile) search, returning only skeleton", | ||
"parameters": { | ||
"type": "params", | ||
"required": ["q"], | ||
"properties": { | ||
"q": { | ||
"type": "string", | ||
"description": "search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. For typeahead search, only simple term match is supported, not full syntax" | ||
}, | ||
"typeahead": { | ||
"type": "boolean", | ||
"description": "if true, acts as fast/simple 'typeahead' query" | ||
}, | ||
"limit": { | ||
"type": "integer", | ||
"minimum": 1, | ||
"maximum": 100, | ||
"default": 25 | ||
}, | ||
"cursor": { | ||
"type": "string", | ||
"description": "optional pagination mechanism; may not necessarily allow scrolling through entire result set" | ||
} | ||
} | ||
}, | ||
"output": { | ||
"encoding": "application/json", | ||
"schema": { | ||
"type": "object", | ||
"required": ["actors"], | ||
"properties": { | ||
"cursor": { "type": "string" }, | ||
"hitsTotal": { | ||
"type": "integer", | ||
"description": "count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits" | ||
}, | ||
"actors": { | ||
"type": "array", | ||
"items": { | ||
"type": "ref", | ||
"ref": "app.bsky.unspecced.defs#skeletonSearchActor" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"errors": [{ "name": "BadQueryString" }] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{ | ||
"lexicon": 1, | ||
"id": "app.bsky.unspecced.searchPostsSkeleton", | ||
"defs": { | ||
"main": { | ||
"type": "query", | ||
"description": "Backend Posts search, returning only skeleton", | ||
"parameters": { | ||
"type": "params", | ||
"required": ["q"], | ||
"properties": { | ||
"q": { | ||
"type": "string", | ||
"description": "search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended" | ||
}, | ||
"limit": { | ||
"type": "integer", | ||
"minimum": 1, | ||
"maximum": 100, | ||
"default": 25 | ||
}, | ||
"cursor": { | ||
"type": "string", | ||
"description": "optional pagination mechanism; may not necessarily allow scrolling through entire result set" | ||
} | ||
} | ||
}, | ||
"output": { | ||
"encoding": "application/json", | ||
"schema": { | ||
"type": "object", | ||
"required": ["posts"], | ||
"properties": { | ||
"cursor": { "type": "string" }, | ||
"hitsTotal": { | ||
"type": "integer", | ||
"description": "count of search hits. optional, may be rounded/truncated, and may not be possible to paginate through all hits" | ||
}, | ||
"posts": { | ||
"type": "array", | ||
"items": { | ||
"type": "ref", | ||
"ref": "app.bsky.unspecced.defs#skeletonSearchPost" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"errors": [{ "name": "BadQueryString" }] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.