Improvement #30079
openImprovement #29635: Code Review, Upgrade and changes in Prompt of Email Boat
Step 3 - Flight API Service
50%
Description
Task 6.1: Add Flight API credentials (FLIGHT_API_URL, etc.) to .env.
Task 6.2: Create services/flightApi.js.
Task 6.3: Implement getAuthToken (the 2-step /BasicAuth and /token calls).
Task 6.4: Add token caching (with tokenExpiryTime) to getAuthToken.
Task 6.5: Implement getSearchId to call /api/Common/GetSearchId.
Task 6.6: Implement initiateFlightSearch to call /api/Flight/Search with the payload and headers.
Task 6.7: Implement pollFlightResults to poll /api/Flight/Result until PolStatus: false.
Task 6.8: Create the searchFlights wrapper function to run the full (auth -> id -> search -> poll) pipeline.
Task 6.9: Integrate searchFlights into the processMailbox loop in index.js.
Updated by Sachin Suresh 4 days ago
- Status changed from In Progress to On hold
- % Done changed from 0 to 50
All api calls implemented and flight results new api added for testing and future needs
holding task to implement flight filters such as price,departure and arrival times