Get Hotel/Apartment/Resort Rooms

Get available rooms for a specific hotel. Retrieve detailed room information including types, pricing, capacity, and availability status for a particular property.

GET /v2/merpi/hotels/:hotel_id/rooms

Retrieve all available rooms for a specific hotel, including room types, pricing, capacity, and availability status.

Path Parameters

Parameter
Type
Required
Description

hotel_id

number

Yes

The unique identifier of the hotel

Example Request

GET {{url}}/v2/merpi/hotels/16/rooms

javascript

const hotelId = 16;
const response = await fetch(`{{url}}/v2/merpi/hotels/${hotelId}/rooms`, {
  method: 'GET',
  headers: {
    'X-API-KEY': 'your_api_key_here',
    'TransactionMedium': 'Web'
  }
});
const data = await response.json();

Get list of rooms for a single hotel, apartment, or resort

get

Retrieve all available rooms for a specific hotel, apartment, or resort. This endpoint returns detailed room information including room name, description, pricing per night with breakdown, maximum occupancy, images, and real-time availability status. This endpoint is strictly for fetching rooms belonging to a single property.

Path parameters
hotel_idintegerRequired

ID of the hotel, apartment, or resort.

Example: 2
Query parameters
pageintegerOptional

Page number for pagination.

Example: 1
per_pageintegerOptional

Number of rooms per page.

Example: 20
Responses
get
/v2/merpi/hotels/{hotel_id}/rooms
200

List of rooms for the specified property

Response Fields

Hotel Summary

Field
Type
Description

id

number

Hotel identifier

name

string

Hotel name

Room Object

Field
Type
Description

id

number

Unique room identifier (use this for booking)

hotel_id

number

Parent hotel identifier

number_of_rooms

string

Number of rooms available of this type

room_name

string

Room category name (e.g., Basic, Deluxe, Suite)

type

string|null

Additional room type classification

description

string|null

Detailed room description

max_occupancy

number

Maximum number of guests allowed

price

number

Price per night in Naira

is_available

boolean

Current availability status

images

array

Room images with URLs

created_at

string

Record creation timestamp

updated_at

string

Last update timestamp

Important Notes

Availability Check: Always call this endpoint immediately before booking to ensure real-time room availability. The is_available field indicates current status.

Room ID for Booking: Use the id field (not hotel_id) when making a booking request.

Pricing: The price field represents the cost per night. Total booking cost = price × number of nights × number of rooms.

Occupancy: Check max_occupancy to ensure the room can accommodate your guest count.

Integration Flow

Next Steps

After retrieving room information:

  1. Display available rooms with pricing to your users

  2. Allow users to select room type and quantity

  3. Proceed to Book Hotel Room to complete the reservation

Last updated