Skip to content

Commit

Permalink
Clarify parameter interaction in searchContent method (#346)
Browse files Browse the repository at this point in the history
- offset parameter will only be interpreted by Mastodon server if a type is specified; if not, default value of 0 will always be used by server
- this behaviour is currently not documented by Mastodon, see issue: mastodon/documentation#1336

Closes #342.
  • Loading branch information
bocops committed Nov 15, 2023
1 parent 4a5b82b commit 6cffd23
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class SearchMethods(private val client: MastodonClient) {

/**
* Search for content in accounts, statuses and hashtags.
* @see <a href="https://github.com/mastodon/documentation/issues/1336">Mastodon issue: incomplete documentation of offset/type parameters</a>
* @param query string to search for
* @param type to specify if you are looking for a specific typology
* @param resolve whether to resolve non-local accounts
Expand All @@ -43,7 +44,7 @@ class SearchMethods(private val client: MastodonClient) {
* @param maxId to return results whose id will be lesser than this one
* @param minId to return results whose id will be newer than this one
* @param limit to limit number of results within a range of 20-40 per category
* @param offset to skip the first n results
* @param offset to skip the first n results; only used if a type is specified
* @see <a href="https://docs.joinmastodon.org/methods/search/">Mastodon API documentation: methods/search</a>
*/
@JvmOverloads
Expand Down

0 comments on commit 6cffd23

Please sign in to comment.