enhancementgood first issueintegrationnew-featurenew-integration
Métricas do repositório
- Stars
- (1.930 estrelas)
- Métricas de merge de PR
- (Métricas PR pendentes)
Description
Description
Add Skyscanner integration to sync travel search data including flight prices, car hire rates, and hotel pricing into CORE.
Reference Implementations
Existing Integrations (use as templates)
integrations/github/- API-based data integrationintegrations/linear/- Project management integrationintegrations/slack/- For reference
Required Files Structure
integrations/skyscanner/
├── src/
│ ├── index.ts # Main entry, API key spec
│ ├── schedule.ts # Sync logic
│ ├── utils.ts # Skyscanner API utilities
│ ├── account-create.ts # API key setup
│ └── create-activity.ts # Activity formatting
├── package.json
├── tsup.config.ts
└── README.md
Skyscanner Travel API Integration
Authentication Setup
- Use API Key authentication
- API keys managed through the Skyscanner Partner Portal
- All requests require JSON format for request/response bodies
- All responses localized by market, locale (language), and currency
Key Endpoints
POST /flights/live/search/create- Create a flight live price searchPOST /flights/live/search/poll/{sessionToken}- Poll flight search resultsPOST /flights/indicative/search- Get indicative flight pricesPOST /carhire/live/search/create- Create a car hire searchPOST /carhire/live/search/poll/{sessionToken}- Poll car hire resultsPOST /carhire/indicative/search- Get indicative car hire pricesPOST /hotels/live/search/create- Create a hotel searchPOST /hotels/live/search/poll/{sessionToken}- Poll hotel resultsGET /culture/markets- Get supported marketsGET /culture/locales- Get supported localesGET /culture/currencies- Get supported currencies
Events to Track
- Flight Searches - Flight price queries, price changes, and deal alerts
- Car Hire Searches - Car rental price queries and availability
- Hotel Searches - Hotel price queries, availability, and deals
- Price Trends - Indicative pricing trends over time
- Market Data - Locale and currency configuration
Implementation Tasks
- Set up basic integration structure following
integrations/github/src/index.tspattern - Implement API key authentication flow in
account-create.ts - Create API utilities in
utils.tsfor flights, car hire, and hotels - Implement sync logic in
schedule.tsfor polling live search results - Convert travel search results to CORE activity format
- Add error handling and rate limiting
- Create integration documentation
- Add to
integrations/README.md
Technical Notes
- Live price searches are asynchronous: create a session, then poll for results
- Every request requires market, locale, and currency parameters for localization
- Indicative prices are cached/approximate; live prices are real-time from providers
- API responses include carrier, agent, and place data that needs to be joined with itinerary data
- Consider caching indicative prices to reduce API calls
Resources
- Skyscanner Developer Documentation
- Skyscanner Developer Portal
- Getting Started Guide
- Carriers Overview
Labels
enhancement, integration, new-feature