Search for books with (optional) filter properties, including optional userId and location filters.
Query parameters
-
Search parameter to find specific books by name, author, or genre.
-
Filter parameter for the language of the book.
Values are
English,Finnish,Bengali,Spanish,French,German,Russian,Arabic,Chinese, orJapanese. -
Filter parameter for the condition of the book.
Values are
New,Like New,Good,Fair, orPoor. -
Filter parameter for the genre of the book.
Values are
Fantasy,Science Fiction,Mystery,Horror,Romance,Thriller,Historical Fiction, orNon-Fiction. -
Filter parameter for owner's book.
-
Filter parameter for books except mine.
-
Filter books within radius of these coordinates - latitude
-
Filter books within radius of these coordinates - longitude
-
Search radius in kilometers for location-based filtering
-
Filter books by city
-
Filter books by country
GET
/api/v1/books
curl \
--request GET 'http://localhost:8080/api/v1/books'
Response examples (500)
{
"error": {
"code": "string",
"message": "string",
"target": "string",
"details": [
{
"code": "string",
"message": "string",
"target": "string"
}
]
}
}
Response examples (401)
{
"error": {
"code": "string",
"message": "string",
"target": "string",
"details": [
{
"code": "string",
"message": "string",
"target": "string"
}
]
}
}
Response examples (404)
{
"error": {
"code": "string",
"message": "string",
"target": "string",
"details": [
{
"code": "string",
"message": "string",
"target": "string"
}
]
}
}
Response examples (403)
{
"error": {
"code": "string",
"message": "string",
"target": "string",
"details": [
{
"code": "string",
"message": "string",
"target": "string"
}
]
}
}
Response examples (400)
{
"error": {
"code": "string",
"message": "string",
"target": "string",
"details": [
{
"code": "string",
"message": "string",
"target": "string"
}
]
}
}
Response examples (200)
{
"_embedded": {
"books": [
{
"id": "string",
"title": "string",
"author": "string",
"genres": [
"string"
],
"language": "string",
"description": "string",
"condition": "string",
"coverPhotoUrl": "string",
"bookLocation": "string",
"location": {
"latitude": 42.0,
"longitude": 42.0,
"address": "string",
"city": "string",
"country": "string",
"postalCode": "string",
"radiusKm": 42
},
"offeredAgo": "string",
"ownerId": "string",
"offeredBy": "string"
}
]
},
"_links": {
"additionalProperty1": {
"href": "string",
"hreflang": "string",
"title": "string",
"type": "string",
"deprecation": "string",
"profile": "string",
"name": "string",
"templated": true
},
"additionalProperty2": {
"href": "string",
"hreflang": "string",
"title": "string",
"type": "string",
"deprecation": "string",
"profile": "string",
"name": "string",
"templated": true
}
},
"page": {
"size": 42,
"totalElements": 42,
"totalPages": 42,
"number": 42
}
}