Flight Price
Learn how to use MrScraper to extract flight prices, airlines, and schedules for price monitoring and booking analysis.
Instead of checking flight prices across multiple websites, you can use the AI Scraper to pull flight details, prices, and schedules automatically using only a URL and a short prompt.
Here’s a real-world example of how you can use MrScraper to collect live flight data from a booking site.
Scenario
You’re building a flight price comparison tool or tracking prices for popular routes. In this example, you want to monitor flights from New York City to London so travelers can quickly find the best deals.
Step 1: Create a New AI Scraper
- Go to the Scrapers page by clicking the triangle icon on the left sidebar.
- Click on the Create Scraper button.
- Select the Listing Scraper option.
- In the URL field, enter the URL of the flight search results page. For this example, we'll search for flights from New York City (NYC) to London (LON):
https://id.trip.com/m/flights/xflightfirst/?triptype=0&classtype=0&classgroupsearch=true&adult=1&child=0&infant=0&from=searchForm&stoptype=0&lowpricesource=searchForm&ddate=2025-11-22&dcitycode=NYC&acitycode=LON&locale=en-ID&curr=IDR&transactionid=20251120174344105- Click on the Start Scraping button to start scraping.
Result :
{
"mode": "direct",
"links": [
"flight_card_4",
"flight_card_3",
"flight_card_1",
"flight_card_2",
"flight_card_5"
],
"flights": [
{
"price": "Rp4,960,870",
"airline": "Jetblue Airways",
"aircraft": "Airbus A321neo",
"duration": "7h 21m",
"top_label": "Cheapest nonstop",
"arrival_time": "09:30",
"price_numeric": "4960870",
"departure_time": "21:09",
"original_price": "Rp 5,097,750",
"arrival_airport": "LHR T2",
"next_day_arrival": "+1",
"departure_airport": "JFK T5",
"low_stock_warning": null,
"original_price_numeric": "5097750",
"carry_on_baggage_included": false
},
{
"price": "Rp5,051,840",
"airline": "Jetblue Airways",
"aircraft": "Airbus A321neo",
"duration": "7h 1m",
"top_label": null,
"arrival_time": "22:00",
"price_numeric": "5051840",
"departure_time": "09:59",
"original_price": "Rp 5,191,430",
"arrival_airport": "LHR T2",
"next_day_arrival": null,
"departure_airport": "JFK T5",
"low_stock_warning": null,
"original_price_numeric": "5191430",
"carry_on_baggage_included": false
},
{
"price": "Rp7,248,600",
"airline": "United Airlines",
"aircraft": "Boeing 767-300/300ER",
"duration": "7h 20m",
"top_label": null,
"arrival_time": "06:20",
"price_numeric": "7248600",
"departure_time": "18:00",
"original_price": "Rp 7,453,760",
"arrival_airport": "LHR T2",
"next_day_arrival": "+1",
"departure_airport": "EWR C",
"low_stock_warning": "<5 left",
"original_price_numeric": "7453760",
"carry_on_baggage_included": true
},
{
"price": "Rp7,287,450",
"airline": "American Airlines",
"aircraft": "Boeing 777-300ER",
"duration": "6h 50m",
"top_label": null,
"arrival_time": "09:40",
"price_numeric": "7287450",
"departure_time": "21:50",
"original_price": "Rp 7,493,770",
"arrival_airport": "LHR T3",
"next_day_arrival": "+1",
"departure_airport": "JFK T8",
"low_stock_warning": null,
"original_price_numeric": "7493770",
"carry_on_baggage_included": true
},
{
"price": "Rp7,431,410",
"airline": "Austrian Airlines (Codeshare)",
"aircraft": "Boeing 767-300/300ER",
"duration": "7h 20m",
"top_label": null,
"arrival_time": "06:20",
"price_numeric": "7431410",
"departure_time": "18:00",
"original_price": "Rp 7,642,020",
"arrival_airport": "LHR T2",
"next_day_arrival": "+1",
"departure_airport": "EWR C",
"low_stock_warning": "<5 left",
"original_price_numeric": "7642020",
"carry_on_baggage_included": true
}
],
"total_flights": 5
}Step 2: Filter Out
Tell the AI to filter your scraped results based on specific rules. In this example, we filter for flights under Rp 6,000,000 using the following prompt:
Get only flight with cost less than Rp 6.000.000Here’s a sample output:
{
"mode": "direct",
"count": 2,
"flights": [
{
"price": "Rp4,960,870",
"airline": "Jetblue Airways",
"aircraft": "Airbus A321neo",
"duration": "7h 21m",
"arrival_time": "09:30",
"price_numeric": 4960870,
"departure_time": "21:09",
"arrival_airport": "LHR T2",
"departure_airport": "JFK T5"
},
{
"price": "Rp5,051,840",
"airline": "Jetblue Airways",
"aircraft": "Airbus A321neo",
"duration": "7h 1m",
"arrival_time": "22:00",
"price_numeric": 5051840,
"departure_time": "09:59",
"arrival_airport": "LHR T2",
"departure_airport": "JFK T5"
}
]
}Step 3: Use the Data
You can now use this clean flight data for price tracking, comparison tools, or travel apps. Filtering helps budget travelers quickly find the cheapest options.