Go Back  FlyerTalk Forums > Travel&Dining > Travel Tools
Reload this Page >

ITA-Matrix-PowerTools - Userscript for Orbitz/DL/UA/AA/BA/CZ/IB/LA/LH/LX/TK

Community
Wiki Posts
Search
Old Nov 11, 2014, 10:54 am
FlyerTalk Forums Expert How-Tos and Guides
Last edit by: IAkH
Welcome to the ITA-Matrix-PowerTools
*** About ***
The ITA-Matrix-PowerTools are a user script maintained by fellow flyertalk members to enhance the already powerful Matrix of ITA Software by providing new features and booking links.

Features added to the itinerary details page:
  • convert times into 24h format
  • translation support
  • open fare rules in new window by default
  • price breakdown (base fare, taxes & carrier imposed surcharges)
  • editor mode (adjust cabin prior extraction)
  • multiple handy links (Seatguru, Planefinder, WhereToCredit)
  • new on page features like detailed mileage breakdown*, GCM-Map* and earned frequent flyer miles*
  • create links to various providers (OTAs / airlines / other tools) to try direct booking of your itinerary

Originally Posted by Error: Unable to find class IR6M2QD-k-i for itinRow.
If you see this error, currently you'll need to manually edit your installed script.

See posts from October 1st, 2018 for more information.
*requires background requests

The script may have lots of bugs and comes without warranty of any kind! Not all fares will be bookable or will price correctly in the booking engines. You are responsible for the money you spend - so double check your flights before purchasing AND use your sanity! Read this and the next two posts as an example: click

*** How it works ***
Using pure JavaScript we are "creating" some sort of hook that is periodically checking for page changes while working with the Matrix. As soon as you reload or leave the page the script stops (leaving the page or using the console-version) or starts from the beginning (using the userscript and perfoming a reload). Also this script is only running in these tabs/windows in which you are looking at the Matrix.
As soon as the script detects the itinerary page it reads its content - unless you activated the editor mode. It's parsing all the information found and creates - based on this information - several links to OTAs, airlines and other tools. Since we are able to remove, replace and add content to the page - we make them visible and clickable in a way you choose. By default there are no background requests.

*** How to get it running ***
There are three methods to install the script. All three below run exactly the same underlying script but are listed in order of installation complexity:

Method 1: Browser Extensions
Method 2: As a UserScript
It takes a moment to get it running but after that it will start automatically everytime you visit the Matrix and we will be able to store your settings. You will need to install a script manager.

Warning: Using a script manager and installing user scripts is a potential security risk - We need to mention it here.
Step 1: Install a script manager Step 2: Install the script
See the FAQ of your script manager how to install the script.
  • Through GreasyFork
  • Through OpenUserJS
  • Through GitHub: you should be asked whether you want to install it - make sure your script manager is running.
Method 3: iOS Safari Shortcut

Get the "Add ITA Matrix Powertools" Shortcut

Instructions much be run each time
  • Open ITA Matrix in Safari on your iPhone or iPad
  • Tap on the Share button in the bottom navigation
  • Scroll down through all the actions
  • Select Add ITA Matrix Powertools

Method 4: Console/Debug mode
You need to access the command line of your browser to execute the script. You can use either the regular version or the minified version. Just copy the entire text.

Chrome:
  1. Open Chrome DevTools: developer.chrome.com
  2. Switch to the console tab
  3. Paste the script into the command line: developer.chrome.com
  4. Run it
Firefox:
  1. Open the web console: developer.mozilla.org
  2. Switch to the console tab
  3. Paste the script into the command line: developer.mozilla.org
  4. Run it
Internet Explorer:
  1. Open the web console by pressing F12
  2. Switch to the console tab
  3. Paste the script into the command line - at the very bottom
  4. Run it by pressing the green triangle

*** How to use it ***
Once the script is running you should see a new line above the ITA logo:
Code:
Passengers (1a) Settings (v0.18) (Cabin: Auto)
As long as you see this line, there is no need to reexecute the script. Make sure to get used to the "Settings"-feature -> just click on Settings. Within the settings menu you can configure the script towards your needs/preferences. Enabling/disabling features and/or setting standard editions of providers on the fly. When using a script manager these settings should be stored and automatically load as soon as you visit matrix.itasoftware.com - but the passengers as well as the cabin detection will not be stored!
Your settings are "reloaded" everytime the itinerary details show up! If you want to use other settings, just get back to the flight selection and reselect your flights - the new settings will be used. This belongs to the passengers and cabin detection as well

Passengers:
The passenger count will not be taken from your search results! Use the passenger config on the upper left and make sure they are set before you get to the itinerary details. We had to do it this way because some providers require the age of children. But always make sure to search for the equivalent passenger count. There might be seat availability for one passenger but not for two!

Cabin detection:
You should set the cabin on the upper right to the appropriate main cabin you are looking for. Sometimes you will have economy/business class segments in mainly business/first class itineraries. These mixed itineraries make it hard to autodetect the main cabin - so you can set it manually.

*** Background requests - Privacy issues ***
Some features require to contact other servers. As long as you do not activate any of the autoload features within the settings there won't be any automatic background requests. You will have to initiate them manually. The following list will tell which features are contacting what server and what information will be transferred. All websites will know you are using this script und you are currently using the Matrix - what by the way applies to the link targets you click as well.
  • GCM-Map in inline mode - contacting gcmap.com (non SSL) providing full route data
  • WhereToCredit.com mileage accrual breakdown - contacting wheretocredit.com (non SSL or SSL - depending on whether you use the Matrix with or without SSL) providing full itinerary
  • Skimlinks affiliate links - loads a js script to adds affiliate ids to some links if and only if the "Support this tool" setting is enabled. If it is disabled, no external scripts are loaded
*** FT-Posts you should read ***
General statement regarding this script: click
How to fix class names yourself: click
Problems and limitations regarding pricing itins: click

*** Contributors ***
paul21, Steppo, IAkH, 18sas, Benchmarc and others!

I'd like to give special thanks to paul21 for starting this idea.

*** Latest Version ***
GitHub Repo

OR install directly: Executable Version minified

FYI
Steppo & IAkH (Adam Hwang) have full access to this repository.

Discussion - written by paul21:
The original posting can be found here, related to building links on delta's booking engine. The script scrapes the flight info from the itinerary (flight numbers, dates, class of service, price) and builds a link string to two booking engines (Orbitz/Delta). These links are the same links used by Google Flights (owns ITA) , Kayak, et. al. to drive purchases. I used the Google referrer codes in the scripts, so they should get the commission. It's beyond me why ITA doesn't have some form of purchase link. This a userscript, and like an ad-blocker, it modifies the way a page is viewed by editing DOM objects in the browser. Keep in mind that this tool is meant to do something you already do yourself, but to save time in the process. Any tickets issued by Orbitz/DL via these links could be issued via phone or web search. If the links work, you are avoiding a phone booking fee potentially.







Print Wikipost

ITA-Matrix-PowerTools - Userscript for Orbitz/DL/UA/AA/BA/CZ/IB/LA/LH/LX/TK

Thread Tools
 
Search this Thread
 
Old Nov 19, 2016, 12:20 pm
  #361  
 
Join Date: Sep 2010
Posts: 72
Hi, I've been trying to book a tricked VS flight using the tool, but the fare isn't bookable on any of the OTAs linked. I put in all the individual flights on Farefreaks, but even then I am unable to replicate the fare on ITA. The flights that I want do show up on Google flights, but again, they aren't bookable there.

any help regarding this would be greatly appreciated. I can post the ita link, or screenshots if required!

(my apologies if I'm in the wrong thread; I just couldn't figure where else to put my query!)
15blackknight is offline  
Old Nov 21, 2016, 3:11 pm
  #362  
 
Join Date: May 2007
Location: ORD, DEL
Programs: AA (Plt Pro; 1.5 MM)
Posts: 6,185
Please don't post any screenshots or other details of tricked flights. You'd be doing no favor to anyone including yourself. Keep trying. If you can't book it anywhere---including major OTAs, Google flights, links provided by Powertools---then it just might be a phantom fare.
aktchi is offline  
Old Nov 22, 2016, 7:51 am
  #363  
 
Join Date: Jan 2016
Posts: 610
Anyone has an issue of Priceline not showing "updated price"? When I'm about to pay, it keeps showing "calculating" on the right. The construction is complex, but legal as it's the Delta flash sale.
When I used it before, it would update the price to whatever it was +$6 for multiple airlines. (which is as expected, but not how it works now)
klanfa is offline  
Old Nov 23, 2016, 12:16 pm
  #364  
 
Join Date: Sep 2010
Posts: 72
Originally Posted by aktchi
Please don't post any screenshots or other details of tricked flights. You'd be doing no favor to anyone including yourself. Keep trying. If you can't book it anywhere---including major OTAs, Google flights, links provided by Powertools---then it just might be a phantom fare.
Don't worry, I obviously will colour out the x . I don't think it's a phantom fare because I've not been able to book any VS tricked fares across 7 different sectors and with 4 different Xs!

Is there any particular OTA that anyone would recommend for VS flights?
15blackknight is offline  
Old Nov 23, 2016, 7:52 pm
  #365  
 
Join Date: Aug 2015
Location: BR
Programs: TudoAzul Diamante, Smiles Diamante, Latam Gold
Posts: 102
Originally Posted by klanfa
Anyone has an issue of Priceline not showing "updated price"? When I'm about to pay, it keeps showing "calculating" on the right. The construction is complex, but legal as it's the Delta flash sale.
When I used it before, it would update the price to whatever it was +$6 for multiple airlines. (which is as expected, but not how it works now)
Try the mobile website..
psbaj is offline  
Old Nov 28, 2016, 7:38 pm
  #366  
A FlyerTalk Posting Legend, Moderator, Information Desk, Ambassador, Alaska Airlines
Hilton Contributor BadgeIHG Contributor Badge
 
Join Date: Dec 2006
Location: FAI
Programs: AS MVP Gold100K, AS 1MM, Maika`i Card, AGR, HH Gold, Hertz PC, Marriott Titanium LTG, CO, 7H, BA, 8E
Posts: 42,953
This is a solid tool!

Was able to book flights to PRG and back involving AS DL and DL coded KL flights during the last DL flash sale.

DL nor AF wanted to price the fare out with AS segments involved. (via multicity or power tools).

So, I'm able to stick to AS metal as much as I can. Ended up booking via Priceline.
beckoa is offline  
Old Nov 29, 2016, 5:33 pm
  #367  
 
Join Date: Apr 2014
Location: TLV, JFK, ORD and everywhere in between (no longer SEA)
Programs: Delta PM
Posts: 233
I was finally able to execute the script but for some reason it doesnt outputs the links. I only see the passenger/cabin options. where do I see the links?

I read through the wiki but I can't seem to see where the links are supposed to be executed? on top? if so, they're not so what am I doing wrong?

thanks!!
SeattleiteTelavivian is offline  
Old Nov 30, 2016, 2:01 am
  #368  
 
Join Date: May 2012
Location: MCI
Posts: 165
Originally Posted by SeattleiteTelavivian
I was finally able to execute the script but for some reason it doesnt outputs the links. I only see the passenger/cabin options. where do I see the links?

I read through the wiki but I can't seem to see where the links are supposed to be executed? on top? if so, they're not so what am I doing wrong?

thanks!!
I am using firefox and greasemonkey they show up along the right side for me.
jrweaver912 is offline  
Old Nov 30, 2016, 6:39 am
  #369  
 
Join Date: Apr 2014
Location: TLV, JFK, ORD and everywhere in between (no longer SEA)
Programs: Delta PM
Posts: 233
Originally Posted by jrweaver912
I am using firefox and greasemonkey they show up along the right side for me.
thank you!!!

I am wondering though why I get a different price when I try to book the flight through DL. It's completely different than what I see before I move over to them

any ideas what to do with that?
SeattleiteTelavivian is offline  
Old Dec 8, 2016, 10:12 am
  #370  
 
Join Date: May 2007
Location: Chicagoland
Posts: 375
Originally Posted by melrowgo
...
[*] A new tab opens to the multi-city search page on AA.com, but none of the transferred information had populated the search. If I recall, the link should have taken me to a page showing the itinerary on AA.com that would then allow me to purchase it.
...
I am still experiencing this same issue on a regular basis. (See original post for full details, ad nauseum.) Has anyone made headway on fixing this situation? I really miss that functionality in this otherwise amazing tool.
melrowgo is offline  
Old Dec 11, 2016, 8:07 am
  #371  
 
Join Date: Jun 2013
Location: Somewhere between if and else
Posts: 142
Finally I released the update... due to work and holiday (*g*) I have not managed to do it earlier.

To get rid of this "problem" - and future timezone problems that might occur - there is just one solution: Get the timezones.. somehow.

phsource - some of you might know him/her - wrote me a PM (thx!) with a possible solution and also provided a very useful file to solve this issue.
The idea was to implement moment.js and "hardcode" the timezones for most of the airports in the script.
Please let me explain the reasons why I did not choose this approach:
- We need to fix a problem affecting just a couple of itineraries
- I want to keep that script as lightweight as possible - hardcoding >4000 Airports is insane from that point. If we would focus an the main aiports we would lose the compatibility for "small" or "exotic" airports. In the end it would be just a matter of time when we run into the same problem again. It is a quick fix but not a solution.
- I don't like to use external scripts loaded every time even though we don't need it - at least not for 99.x% of the itineraries
- From my point of view there is no reason to use the sledgehammer (moment.js) for this minor issue

JavaScript is horrible for handling timezones and/or times at all...

As I said - from my point of view there is just one solutions to solve this issue in a reasonable way: Create a "service" and query it only when you need it.

This is what I did in v0.23:
Using this fantastic data source (Thx for this at this point) - http://efele.net/maps/tz/world/ - I am capable to get the offset from UTC for every airport I have in my database. Respecting daylight saving time as well - not part of the database but of the server - so this is the solution I wanted. If you have similar problems somewhere - this might be a solution for you as well.
I can just pass the airport and the departure/arrival date and time from our itinerary and calculate the offset for each departue/arrival.
Currently only the departure is enabled but the script as well as the server are prepared to handle the arrivals as well.

I rearranged the script in some parts and these changes give us some opportunities:
Since we are now able to "reload" the links "on the fly", we can adjust the passengers and the cabin detection on the result page. No need to reselect the flights. (yeah!)
You will find a new link right above American Airlines - "Resolve Timezones". Only click it when pricing the itinerary on AA (America and UK) fails - since it will only affect AA. If the reason is timezone related you should be fine then - it fixed the posted bug report.
Once again: This fix currently affects only American Airlines (The Europe/Asia/Pacific-Edition as well!) but the offset is added to the internal itinerary. So feel free to use it. As I said: everything is prepared to resolve the offsets for arrivals as well - just in case.

Booking classes and OTAs:
As I said a couple of times before, we have currently no OTA in the list capable of "forcing" a booking class. Only some airline links will provide the booking class requested (BA and IB are one of those not capable of).

Regarding new providers:
A3 is enforcing its upselling: I have not found a possibility to "force" flights or booking classes.

--------------------
Update (please remove old version if coming from v0.17 or earlier) to v0.23 using https://github.com/SteppoFF/ita-matrix-powertools/ or install/open directly

Installable/Executable Version
Executable Version minified

Happy searching
--------------------
Steppo is offline  
Old Dec 11, 2016, 12:16 pm
  #372  
 
Join Date: Jan 2016
Location: NYC
Programs: DL ✈️
Posts: 638
Steppo,

A

MILLION

THANKS.
tomasdev is offline  
Old Dec 11, 2016, 7:18 pm
  #373  
 
Join Date: May 2007
Location: Chicagoland
Posts: 375
Originally Posted by Steppo
Finally I released the update... due to work and holiday (*g*) I have not managed to do it earlier.
Outstanding! ^^ Thank you so much for the update.
melrowgo is offline  
Old Dec 12, 2016, 3:53 pm
  #374  
 
Join Date: Jan 2015
Location: London
Programs: Miles & Smiles
Posts: 4
Hi all,

I'm not sure if I'm missing a step but am ready to hit my head on the wall!

I'm trying to ticket the following:
STN PC X/IST PC MLX 28.29GRT12M5 PC X/IST PC STN 28.29GRT12M5 NUC 56.58 END ROE 0.79517 XT 13.00GB 11.39UB 12.70TR 1.70VQ 31.60YQ

Outbound: Lon to Mlx 16th Dec
Return: Mlx to Lon 24th Dec

It's for 2x adults and is coming up as £230 on Pegasus.

I've run the script through console on firefox and clicked through to all of the options but it keeps resetting or just not finding the fare (or anything close to it).

I feel like there is a step that I am skipping and really just can't remember it. If anyone knows, please help and honestly, I'd be completely fine with someone showing me a step-by-step written as if I'm a bit dense
sevk123 is offline  
Old Dec 13, 2016, 8:36 am
  #375  
 
Join Date: Aug 2014
Posts: 47
Thanks a lot for this script. It's soooo useful!

One question: could you add a feature to save some favorite itineraries? I think it could be pretty useful as ITA Matrix only saves last 5 itineraries. I have to input often the same data as I keep checking different flights...

If there were a way to load and autofill the fields for flights we saved previously, this tool could be even more useful.

Thanks for taking this into consideration!
Pcsl is offline  


Contact Us - Manage Preferences - Archive - Advertising - Cookie Policy - Privacy Statement - Terms of Service -

This site is owned, operated, and maintained by MH Sub I, LLC dba Internet Brands. Copyright © 2024 MH Sub I, LLC dba Internet Brands. All rights reserved. Designated trademarks are the property of their respective owners.