TTP Tour Flavor Test
How it works:
- Uses
TTPChatWidget with flavor: { type: 'tours', partnerId: 'mock-tour' }
- The backend injects tour tools (
search_tours, book_tour, get_tour_booking, show_media)
- Tour cards display when the agent sends
show_items messages
- Booking summary updates on
cart_updated messages
- Gallery (
show_media) opens fullscreen for tour photos, highlights, etc.
Loading SDK...
Widget Configuration
Test Actions (Simulated Messages)
Show Tour Items
Injects a show_items message with mock tour packages.
Show Gallery
Injects a show_media message to test fullscreen gallery with tour photos.
Booking Updated
Injects a cart_updated message to test the booking summary bar.
Console Commands
// Access the widget instance
window.testWidget
// Inject messages manually
window.testWidget._flavor.messageHandlers['show_items']({
t: 'show_items',
items: [
{ id: 'TOUR-001', name: 'Old City Walking Tour', category: 'Walking Tours', price: 49.99, currency: 'USD', imageUrl: '...', available: true, tags: ['walking', 'history'], description: '3-hour guided walking tour' }
],
title: 'Available Tours'
});