hs_search {hypothesisr} | R Documentation |
Search hypothes.is annotations
Description
Search hypothes.is annotations.
Usage
hs_search(limit = NULL, offset = NULL, sort = "updated", order = "asc",
uri = NULL, user = NULL, text = NULL, any = NULL, custom = list())
Arguments
limit |
Integer. The maximum number of annotations to return. (Default: 20) |
offset |
Integer The minimum number of initial annotations to skip. This is used for pagination. For example if there are 65 annotations matching our search query and we're retrieving up to 30 annotations at a time, then to retrieve the last 5, set offset = 5. (Default = 0) |
sort |
Character. Specify which field the annotations should be sorted
by: |
order |
Character. Specify which order annotations should be sorted by:
|
uri |
Character. Search for annotations of a particular URI, for example
|
user |
Character. Search for annotations by a particular user. For
example, |
text |
Character. Search for annotations whose body text contains some
text, for example: |
any |
Character. Search for annotations whose |
custom |
A named list of any field in the results returned by hypothes.is as a name, and the search text as values. |
Value
A dataframe with annotation data.
Note
If any vectors are passed to these arguments, only the first values will be used.
Source
https://h.readthedocs.io/en/latest/api/#search
Examples
# Search for no more than 5 annotations containing the text "ulysses"
hs_search(text = "ulysses", limit = 5)
# Search with a custom field for tags
hs_search(custom = list(tags = "todo"))
# use the 'uri.parts' field to find annotations on a given domain (exclude
# the TLD, as this will result in all annotations on sites with, e.g., .org,
# as well.)
hs_search(custom = list(uri.parts = "programminghistorian"))