YGO API
  1. AI Search & Trip Planning
YGO API
  • Overview
  • Core Concepts
  • Authentication
  • Quickstart Guide
  • AI Search & Trip Planning
  • Booking Flow
  • Environments
  • General
    • Check API health status
      GET
    • Get current API key context
      GET
  • AI Search & Trip Planning
    • Send message to YGO AI
      POST
  • Product Search (Classic)
    • Search for hotel & package offers
      POST
    • Get transfers for booking
      POST
    • Get package price calendar
      POST
  • Bookings
    • Get or create open booking
      POST
    • Update open booking
      POST
    • Update booking status and trigger workflows
      POST
    • List bookings
      POST
    • Get booking
      POST
  • Schemas
    • Schemas
      • PackageSearchRequest
      • GetTransfersRequest
      • GetOpenBookingRequest
      • SaveOpenBookingRequest
      • SaveBookingStatusRequest
      • ListBookingsRequest
      • GetBookingRequest
      • GetPackageCalendarRequest
      • Product
      • TransferOptionsResponse
      • Booking
      • ProductTexts
      • TransferOption
      • BookingDetails
      • TripReference
      • PackageCalendarResponse
      • LocaleContent
      • Trip
      • BookingItemInput
      • PackageCalendarDate
      • ProductImage
      • TransferImage
      • BookingItem
      • ProductDetails
      • PickupInformation
      • Traveller
      • PackageOffer
      • PickupLocation
      • TourOperator
      • Pickup
      • Image
      • Accommodation
      • CheckPickup
      • Room
      • TransferRemark
      • Transport
      • CancellationPolicy
      • Flight
      • Airport
      • Price
      • PriceByPax
      • SuccessResponse
      • ErrorResponse
      • Hotel
      • HotelFeatures
      • FeatureState
      • RoomFeatures
      • RoomContent
      • Facility
    • Response
      • Unauthorized
  1. AI Search & Trip Planning

Send message to YGO AI

POST
/sendMessage

Process travel queries using YGO AI's advanced multi-agent system with augmented, multi-source hotel data. Supports natural language, structured data, or hybrid inputs for maximum flexibility.

Choose Your Model:

ModelSpeedUse CaseBest For
packagelist<3sPackage search with smart filtersHotel discovery, search refinement
hotelinfo<2sHotel details and amenities"Ask about hotel" features, Q&A
hotelreviews<2sGuest review analysisReview summaries, sentiment insights
activityinfo<2sActivity/tour informationActivity details, tour Q&A
"" (empty)5-10sFull trip planningComplex itinerary generation

Key Capabilities:

  • Multi-Modal Input: Accept text prompts, structured parameters, or both
  • Superior Data Quality: Hotel information augmented from multiple sources for unmatched accuracy and completeness
  • Multi-Layer Smart Filtering: Three-tier filter architecture from basic supplier filters to deep content search
  • Smart Package Search: Find hotels with flexible durations, enhanced filters, and conversion-driven ranking
  • Hotel Intelligence: Get detailed information with integrated guest review analysis
  • Activity Details: Comprehensive activity and attraction information
  • 50+ Languages: Full localization including responses, quick replies, and product summaries
  • Lightning Fast: Specialized models are 80% faster than full planning flow

How It Works:

  1. Send a message (natural language, structured data, or both)
  2. YGO AI routes to the optimal AI flow based on your Model parameter
  3. Receives intelligent, context-aware response with recommendations
  4. Continue conversation using same ChatID for iterative refinement

Coming Soon: Voice input support for hands-free experiences.

Request

Authorization
or
Body Params application/json

Examples

Responses

🟢200OK
application/json
Message processed successfully
Body

🟠400Bad Request
🟠401Unauthorized
🟠404Record Not Found
🔴500Server Error
Request Request Example
Shell
JavaScript
Java
Swift
cURL
curl --location --request POST 'https://api.ygo.ai/v1/sendMessage' \
--header 'Content-Type: application/json' \
--data-raw '{
    "ChatID": "chat_abc123",
    "Content": "I want a beach hotel in Greece with pool for around 5 nights in August under €1500",
    "UserID": "user_customer123",
    "Locale": "en",
    "Model": "packagelist"
}'
Response Response Example
200 - Package search results
{
    "Data": {
        "ID": "run_xyz789",
        "ChatID": "chat_abc123",
        "UserID": "user_customer123",
        "Content": "Find me hotels in Barcelona with pool for around 5 nights",
        "Locale": "en",
        "Model": "packagelist",
        "TripParams": {
            "Destination": "Barcelona",
            "DestinationName": "Barcelona, Spain",
            "StartDate": "2025-06-15",
            "EndDate": "2025-06-20",
            "FlexibleNights": [
                4,
                5,
                6
            ],
            "StayDirectDuration": 5,
            "TravellersAmount": 2,
            "Latitude": 41.3851,
            "Longitude": 2.1734,
            "Packages": [
                {
                    "ID": 12345,
                    "HotelName": "Hotel Barcelona Beach",
                    "Price": {
                        "Amount": 850,
                        "Currency": "EUR",
                        "PerPerson": true
                    },
                    "Details": {
                        "Hotel": {
                            "Features": {
                                "Pool": "yes",
                                "Wifi": "yes",
                                "AirCondition": "yes"
                            },
                            "StarRating": 4,
                            "Images": [
                                {
                                    "URL": "https://cdn.ygo.ai/hotels/12345_main.jpg"
                                }
                            ]
                        }
                    },
                    "ConversionScore": 0.92
                }
            ]
        },
        "Messages": [
            {
                "Role": "assistant",
                "Content": "I found 45 hotels in Barcelona with pool for 4-6 nights starting June 15th. The results are sorted by best match based on your preferences. Prices range from €750 to €1,450 per person."
            }
        ],
        "QuickReplies": [
            "Show only 4-star hotels",
            "Filter by budget under €1000",
            "Hotels near the beach",
            "Add gym and spa filter"
        ],
        "Intents": [
            "PACKAGE_SEARCH",
            "HOTEL_WITH_POOL"
        ],
        "Instructions": []
    },
    "Error": null
}
Modified at 2025-10-16 15:33:38
Previous
Get current API key context
Next
Product Search (Classic)
Built with