GET
5 min read
Get Booking
GET
/api/v1/bookings/{id}
Retrieve a single booking by ID
Get Booking
Retrieve details of a specific booking by its ID.
Path Parameters
| Parameter | Type | Description |
|---|---|---|
id |
integer | The booking ID |
Example Request
curl -X GET "https://hydra.marketdragon.ph/api/v1/bookings/1" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Accept: application/json"
Example Response
{
"data": {
"id": 1,
"company_id": 1,
"customer_name": "John Smith",
"customer_email": "[email protected]",
"customer_phone": "+1234567890",
"vehicle_make": "Toyota",
"vehicle_model": "Camry",
"vehicle_year": 2022,
"vehicle_plate": "ABC 123",
"service_type": "Oil Change",
"scheduled_date": "2024-01-20",
"scheduled_time": "10:00",
"duration_minutes": 60,
"status": "confirmed",
"notes": "Customer prefers synthetic oil",
"reference_number": "BK4A7F2C9E",
"qr_code_url": "https://hydra.marketdragon.ph/p/acme-auto/booking/550e8400-e29b-41d4-a716-446655440000",
"confirmed_at": "2024-01-18T14:30:00+00:00",
"cancelled_at": null,
"created_at": "2024-01-15T08:30:00+00:00",
"updated_at": "2024-01-18T14:30:00+00:00"
}
}
Error Responses
403 Forbidden
{
"message": "You do not have access to this booking."
}
404 Not Found
{
"message": "No query results for model [Booking] 999"
}
Back to Bookings
Was this helpful?