Service

Name Get Reservation Replies
Description Get the replies of a reservation.
Method GET
URL /reservations/{reservation}/replies
Example /api/reservations/11111111/replies
Access OWNER, MANAGER, TRAVELER

HTTP Headers

Authorization eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXUyJ9...

Parameters

Fields Type Required Description
reservation text yes Reservation id.

Response

            
                [                     
                    {
                     "id": 8232,
                     "date_created": "2017-04-11T13:29:58-0400",
                     "message": "Hello traveler",
                     "name": "John Owner",
                     "user_type": "owner"
                    },
                    {
                     "id": 8233,
                     "date_created": "2017-04-11T13:31:27-0400",
                     "message": "Hello owner",
                     "name": "John Doe",
                     "user_type": "traveler"
                    },
                    ...
                ]
            
            

Response Codes

Code Message Cause Possible Frontend Message [Behavior]
EC000 Internal error in API Internal error connecting the database "Oops! Looks like we hit a snag. Try closing the app and reopening it."
EC001 User not found Token user id doesn't match our records "Sorry, We couldn't find your information!"
EC003 Reservation not found Reservation id doesn't match our records "Sorry, We couldn't find that reservation!"
EC004 Not found result There are problems finding the data in our database [Don't show the replies]
EC031 Reservation not belong to that user The user logged in is not the reservation's traveler or the owner "Sorry, you do not have access to that reservation!"
SC006 User no authorization The token role is not valid for using the API services "You have been logged out." - [Take the user to the login screen]
SC014 Expired token The token has expired "You have been logged out." - [Take the user to the login screen]
VID234 Invalid input for reservation Reservation id is not a number "Sorry, We couldn't find that reservation!" - [Call the API again using a valid value for reservation id]