Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Example queries



Search for records using the search term "sibelius":

https://api.finna.fi/v1/search?lookfor=sibelius

Search CDs using the search term "sibelius":

https://api.finna.fi/v1/search?lookfor=sibelius&filter[]=format:"1/Sound/CD/"

Search online images using the search term "sibelius" https://api.finna.fi/v1/search?lookfor=sibelius&filter[]=online_boolean:"1"&filter[]=format:"0/Image/"&field[]=title&field[]=images
Search online images using the search term "sibelius", faceted by organization

https://api.finna.fi/v1/search?lookfor=sibelius&filter[]=online_boolean:"1"&filter[]=format:"0/Image/"&facet[]=building&field[]=title&field[]=images

Search for records from years 1870-1890

https://api.finna.fi/v1/search?lookfor=&filter[]=search_daterange_mv:"[1870%20TO%201890]"

Formats of all records

https://api.finna.fi/v1/search?lookfor=&facet[]=format

Set limit to 0 if you don't need records:

 https://api.finna.fi/v1/search?lookfor=&facet[]=format&limit=0

All online images

https://api.finna.fi/v1/search?lookfor=&filter[]=online_boolean:"1"&filter[]=format:"0/Image/"

All records with the allowed use "Modifications allowed, also commercial use"

https://api.finna.fi/v1/search?lookfor=&filter[]=usage_rights_str_mv:usage_B

All organizations, names in swedish

https://api.finna.fi/v1/search?lookfor=&facet[]=building&lng=sv

Records with "sibelius" as author

https://api.finna.fi/v1/search?lookfor=sibelius&type=Author

Retrieve a single record by ID

https://api.finna.fi/v1/record?id=fennica.123

Retrieve two records by ID

https://api.finna.fi/v1/record?id[]=fennica.123&id[]=fennica.124

To return possible field values for a facet field you can perform a query without a search term and filters.

https://api.finna.fi/v1/search?lookfor=&facet[]=format&prettyPrint=1&limit=0

A query may be targeted to a specific (non-facet) index field by including the field in the search term.

Note: put facet fields in the filter-parameter. For example:

?lookfor=format:0/Book/ (not supported)

?lookfor=&filter[]=format:0/Book/ (use this instead)

 https://api.finna.fi/v1/search?lookfor=publication_place_txt_mv:pomarkku&field[]=id&field[]=publication_place_str_mv&field[]=placesOfPublication&field[]=publicationInfo&prettyPrint=1

NOT & AND filters

The search term may also include a more complex query, for example a target (non-facet) field or a logical operator. See also 'type' parameter of Search action.

Search using search terms "sibelius" and "festival"

https://api.finna.fi/v1/search?lookfor=sibelius+AND+festival 

...