Search
We use a minimal fuzzy search engine to return search results from requests to the /search?q=${search_query}
endpoint. There's currently no rate limit on this API endpoint, but there might be in the future, so always check Rate Limits page.
Request Example
Method: GET
{
"Content-Type": "application/json"
}
There's no body to this request.
Return Example
{
"posts": [ // An array of posts
{
// Post data
}
],
"users": [ // An array of users
{
// User data
}
],
"communities": [ // An array of communities
{
// Community data
}
]
}
{
"error": "Query parameter 'q' is required"
}
This error occurs when the request doesn't contain a search query.
{
"error": "Failed to search posts"
}
This error occurs when the API fails to query the posts from the database.
{
"error": "Failed to search users"
}
This error occurs when the API fails to query the users from the database.
{
"error": "Failed to search communities"
}
This error occurs when the API fails to query the communities from the database.
Formatting
The correct formatting for search queries is: /search?q=this+is+spicy
, where whitespace characters get replaced with +
characters.
Last updated