Add admin/manager booking profile update API
All checks were successful
build-and-deploy / build-deploy (push) Successful in 37s
All checks were successful
build-and-deploy / build-deploy (push) Successful in 37s
This commit is contained in:
@@ -1879,6 +1879,56 @@ BOOKING APIS
|
||||
- 409 Conflict (booking closed)
|
||||
|
||||
|
||||
- Update booking profile API is this one:
|
||||
|
||||
POST /properties/{propertyId}/bookings/{bookingId}/profile
|
||||
|
||||
What it does:
|
||||
|
||||
- Updates booking profile fields at any booking stage (OPEN, CHECKED_IN, CHECKED_OUT, CANCELLED, NO_SHOW).
|
||||
- Supports partial updates for these fields only:
|
||||
- transportMode
|
||||
- childCount
|
||||
- maleCount
|
||||
- femaleCount
|
||||
- fromCity
|
||||
- toCity
|
||||
- memberRelation
|
||||
- If a provided field value is null, that field is cleared.
|
||||
- Recomputes adultCount and totalGuestCount when any of maleCount/femaleCount/childCount is updated.
|
||||
|
||||
Request body:
|
||||
|
||||
{
|
||||
"transportMode": "CAR",
|
||||
"childCount": 1,
|
||||
"maleCount": 1,
|
||||
"femaleCount": 1,
|
||||
"fromCity": "Varanasi",
|
||||
"toCity": "Lucknow",
|
||||
"memberRelation": "SELF"
|
||||
}
|
||||
|
||||
- Allowed roles: ADMIN, MANAGER
|
||||
- superAdmin can also access.
|
||||
|
||||
Error Codes
|
||||
|
||||
- 400 Bad Request
|
||||
- Invalid request body
|
||||
- Unknown fields
|
||||
- At least one field is required
|
||||
- Unknown transport mode
|
||||
- Transport mode disabled
|
||||
- Unknown member relation
|
||||
- childCount/maleCount/femaleCount must be integer or null
|
||||
- childCount/maleCount/femaleCount must be >= 0
|
||||
- fromCity/toCity/memberRelation/transportMode type invalid
|
||||
- 401 Unauthorized
|
||||
- 403 Forbidden
|
||||
- 404 Not Found
|
||||
|
||||
|
||||
- Booking check-out API is this one:
|
||||
|
||||
POST /properties/{propertyId}/bookings/{bookingId}/check-out
|
||||
|
||||
Reference in New Issue
Block a user