The Favorites API lets users bookmark places they want to revisit. Each favorite record links a user (Documentation Index
Fetch the complete documentation index at: https://mintlify.com/jparra-amell/api_solsql/llms.txt
Use this file to discover all available pages before exploring further.
id) to a place (place_id). You can retrieve favorites by user, check whether a specific user-place pair is already favorited, or remove a favorite using either its primary key or the user-place combination directly.
GET /api/Favorites
Returns all favorites in the system.Response
Unique identifier for the favorite record.
ID of the user who saved the favorite.
Display name of the user.
ID of the favorited place.
Display name of the place.
ISO 8601 timestamp of when the favorite was added.
GET /api/Favorites/
Returns a single favorite record by its ID.Path parameters
The unique ID of the favorite record to retrieve.
Response
Returns a singleFavorites object. See field descriptions under GET /api/Favorites.
Error codes
| Code | Description |
|---|---|
| 404 | No favorite found with the given id. |
| 500 | Internal server error. |
GET /api/Favorites/byUser/
Returns all favorites saved by a specific user.Path parameters
The ID of the user whose favorites you want to retrieve.
Response
Returns an array ofFavorites objects. See field descriptions under GET /api/Favorites.
Error codes
| Code | Description |
|---|---|
| 500 | Internal server error. |
This endpoint returns an empty array if the user has no favorites — it does not return
404.GET /api/Favorites/user//place/
Returns the favorite record for a specific user-place combination. Use this to check whether a user has already saved a particular place before showing a “Save” button.Path parameters
The ID of the user.
The ID of the place.
Response
Returns a singleFavorites object. See field descriptions under GET /api/Favorites.
Error codes
| Code | Description |
|---|---|
| 404 | No favorite found for the given userId and placeId. |
| 500 | Internal server error. |
POST /api/Favorites
Adds a place to a user’s favorites list.Request body
ID of the user adding the favorite.
ID of the place to add.
Response
Returns200 OK with a JSON success message:
Error codes
| Code | Description |
|---|---|
| 400 | The database rejected the insert (e.g., the place is already favorited). |
| 500 | Internal server error. |
DELETE /api/Favorites/
Deletes a favorite record by its primary key.Path parameters
The
favorite_id of the record to delete.Response
Returns204 No Content on successful deletion.
Error codes
| Code | Description |
|---|---|
| 400 | Database error — could not delete the record (e.g., constraint). |
| 500 | Internal server error. |
DELETE /api/Favorites/usuario//lugar/
Deletes a favorite identified by the user and place combination. Use this when you want to remove a favorite without looking up itsfavorite_id first.
Path parameters
The ID of the user whose favorite you want to remove.
The ID of the place to unfavorite.
Response
Returns204 No Content on successful deletion.
Error codes
| Code | Description |
|---|---|
| 400 | Database error — could not delete the record (e.g., constraint). |
| 500 | Internal server error. |