3dck-org / trip-planner-api

1 stars 0 forks source link

[API] User can add trip as favorite #27

Closed Tronerta closed 2 years ago

Tronerta commented 2 years ago
  1. Added parameter favorite_only to /api/v1/trips. If it's true, the result will be only favorited by current user trips. Otherwise - all trips.
  2. Added new endpoints /api/v1/trips/{id}/add_to_favorite and /api/v1/trips/{id}/remove_from_favorite, which will add or remove trip to favorites of the current user. In case of success the result will be { success: true }, otherwise there will be an errror.
  3. Added new field favorite: true/false to all trip related endpoint.