Kindly guide me where can I get a reliable and updated airport Master API. The airport API should have all the information about all the airports in the world and I also want to know how much do they charge for the API.
Location Identifiers & Airline Designators data files available with daily updates
The perfect solution to feeding your coding database. These files (more information in right hand column) are available as a 12 month subscription or a one-time web download. For the subscription, you will be granted access to the password protected extranet site upon purchase where you can retrieve the data files update daily.
Navigraph and Aerosoft provide relatively cheap (~€25/yr) subscription to regular AIRAC updates for the simulation community. The databases include all the airport information that is required for FMS (navigation).
In both cases, the databases are plain-text files which are rather trivial to parse without any special API. For example:
A,YMML,MELBOURNE INTL,-37.673333,144.843333,434,10000,11000,11900,0 R,09,83,7500,148,0,0.000,0,-37.660756,144.822247,395,3.00,50,1,0 R,16,161,11998,197,1,109.700,160,-37.653192,144.834911,432,3.00,50,1,0 R,27,263,7500,148,1,109.300,263,-37.662261,144.848089,407,3.00,50,1,0 R,34,341,11998,197,0,0.000,0,-37.685789,144.840994,330,3.00,50,1,0 IMS,YMML ILS/CAT III,109.700,0,1,195,-37.656667,144.833611,434,YM,0,0,11.5,0.0 IMW,YMML ILS/CAT I,109.300,0,0,195,-37.660000,144.810000,434,YM,0,0,0.0,0.0
One can get a free sample of the whole database (at some point in the past) with a demo version of some software packages that use such database; for example, this one.