API Specification

Boarding Point API

v1.2.0 Active API Key Required

Fetch available boarding and dropping points for selected bus

Endpoint

POST /api/b2b/bus/boardingpoint.php

This API returns available boarding and dropping points for a selected bus result. Use this after selecting a bus from search results.

API Key Authentication

Authenticate requests via HTTP Header or Request Parameter
Required for all endpoints

Enjoy Holiday Hub APIs authenticate requests using your unique secret API Key. You can provide your key in either of the following standard formats:

Method 1: Header (Recommended)

Send key in standard HTTP header:

X-API-Key: demo_123456789
Method 2: Body / Query

Send key in JSON payload or query param:

"api_key": "demo_123456789"
Demo Sandbox Key: demo_123456789
Get your production key in Agent Portal

Request Parameters

FieldTypeRequiredDescription
SearchTokenIdstringRequiredToken received from search API
ResultIndexstringRequiredSelected bus result index

Request Example

JSON Response
{
    "api_key": "YOUR_API_KEY",
    "SearchTokenId": "SEARCH_TOKEN_HERE",
    "ResultIndex": "TB-35"
}

cURL Example

curl -X POST "https://enjoyholidayhub.com/api/b2b/bus/boardingpoint.php" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "X-API-Key: demo_123456789" \
  -d '{
    "SearchTokenId": "SEARCH_TOKEN",
    "ResultIndex": "TB-35",
    "api_key": "demo_123456789"
}'

Response Example

JSON Response
{
    "status": true,
    "data": {
        "boarding_points": [
            {
                "id": 1,
                "location": "ISBT Kashmere Gate",
                "time": "22:30"
            }
        ],
        "dropping_points": [
            {
                "id": 2,
                "location": "Jaipur Sindhi Camp",
                "time": "06:00"
            }
        ]
    }
}

Response (Error)

ERROR / NOTICE Invalid search token or result index
JSON Response
{
    "status": false,
    "message": "Invalid search token or result index"
}

Important Notes

  • 📍 Boarding and dropping points depend on selected bus
  • ⚠️ Always use valid SearchTokenId from search API
  • 🔁 Data may change based on availability
  • 🌐 User IP is handled internally by the system