Ratehawk
RateHawk API integration for PHPTRAVELS: add your Key ID, Key Type and API key, enable the module and sell live RateHawk hotel rates with your own markup.
📌 Overview
This guide explains how to integrate the RateHawk API into your PHPTRAVELS-based travel booking system.
The integration allows you to:
Search hotels in real-time
Display hotel content locally (fast loading)
Process bookings with live pricing
Manage bookings with PNR confirmation
⚙️ 1. API Authentication & Setup
Steps:
Register with RateHawk and get API access
Collect the following credentials:
API Key
Key ID
Key Type
Go to your admin panel:
Enter your API credentials
Click Test API Connection
✅ Expected Result:
Search API working
Booking API working
Management API working
🗄️ 2. Database Configuration
To handle large hotel data, a separate database is required.
Steps:
Create a new database via:
CPanel / CloudPanel / Hosting Panel
Save credentials:
Database Name
Username
Password
Host
Add these details in your system settings
✅ This ensures:
Secure connection
Better performance
Scalable data handling
📥 3. Database Import & Content Setup
RateHawk provides a large dataset (30GB+) for hotel content.
Steps:
Download the database file from RateHawk or from our server https://modules.b-cdn.net/db.jsonl
Rename file to:
Upload file to:
Go to Admin Panel → Run Import Tool
⚠️ Important Notes
Import process can take 12–24+ hours
Depends on server performance
Keep process running (do not stop)
Recommended: Use VPS or dedicated server
🔍 4. Search, Pricing & Booking Flow
Once data is imported:
🔎 Hotel Search
Uses local database for:
Hotel names
Images
Descriptions
Locations
👉 Result: Fast loading search results
💰 Pricing & Availability
Pulled in real-time from RateHawk API
👉 Result: Accurate live pricing
🛒 Booking Flow
User selects hotel
System fetches live rates
Payment processed (e.g., Stripe)
Booking confirmed
✅ Output:
Booking status: Confirmed
PNR generated
Stored in admin panel
🚀 Best Practices
Use high-performance server (8GB+ RAM recommended)
Run import via CLI or background process
Enable caching for better speed
Monitor logs during import
💡 Need a Ready Solution?
We provide a complete travel booking system with:
Hotels (RateHawk, Hotelbeds, Agoda)
Flights (Amadeus, Travelport, Duffel)
Tours (Viator, Tiqets)
Cars & Transfers
B2B + B2C system
👉 Book a free meeting: https://phptravels.com/meeting
Last updated

