Fetch module.
- Source:
Methods
-
<static> fetchHtml(url, callback)
-
Fetch html
Parameters:
Name Type Description urlstring URL to fetch.
callbackfunction Callback when done.
- Source:
-
<static> pixabayApiFetch(queryData, callback)
-
Pixabay API fetch function.
Parameters:
Name Type Description queryDataobject Query data.
Properties
Name Type Argument Default Description usernamestring Pixabay user name.
keystring Pixabay access key.
idstring <optional>
id, id_hash, or a comma separated list of values to retrieve details or high resolution URLs of specific images. In a comma separated list, ids and id_hashs cannot be used together. Note: The number of id_hash queries for "response_group=image_details" is limited to 30 images per day and to 350 images in 30 days. The same limit aplies to id queries for "response_group=high_resolution". When over quota, the API tells you to slow down.
search_termstring <optional>
A URL encoded string to search for. If omitted, all images are returned in the selected order. Example: "yellow+flower"
langstring <optional>
"en" Language code of the language to be searched in. Accepted values: id, cs, de, en, es, fr, it, nl, no, hu, ru, pl, pt, ro, fi, sv, tr, ja, ko, zh Default: "en"
image_typestring <optional>
"all" A media type to search within. Accepted values: "all", "photo", "clipart", "vector" Default: "all"
orientationstring <optional>
"all" Whether an image is wider than it is tall, or taller than it is wide. Accepted values: "all", "landscape", "portrait" Default: "all"
min_widthstring <optional>
"0" Minimum image width. Default: "0"
min_heightstring <optional>
"0" Minimum image height. Default: "0"
editors_choicestring <optional>
Select images that have received an Editor's Choice award. Accepted values: "true", "false" Default: "false"
orderstring <optional>
"popular" How the results should be ordered. Accepted values: "popular", "latest" Default: "popular"
pagestring <optional>
1 Returned search results are paginated. Use this parameter to select the page number. Default: 1
per_pagestring <optional>
20 Determine the number of results per page. Accepted values: 8 - 100 Default: 20
callbackfunction Callback when done.