Eddie
Eddie

Reputation: 7

Recieving 404 error when running get request to Amadeus low-fare-search API

Hi I am very new to Angular and programming in general and I have been trying to query the Amadeus low-fare-search with Angular HTTPClient and failing, I have been looking around for answers, but havent found anything specific to this, I have found some answers related to the specific problem of "unable to identify proxy".

And according to some the reason for this is that the URL is incorrect. But this is the URL on Amadeus page

Resource URL

This is the code i am trying to run :

search(){
    return this.http.get('http://api.sandbox.amadeus.com/v1.2/flights/low-fare-search?origin=IST&destination=BOS&departure_date=2018-10-15&return_date=2018-10-21&number_of_results=3&apikey=my API key')
    .subscribe((data) =>{
        console.log(data)},
        (err) => {console.log(err)});

Here is the error message

errorcode: "messaging.adaptors.http.flow.ApplicationNotFound" faultstring:"Unable to identify proxy for host: default and url: /v1.2/flights/low-fare-search"

Can someone explain to me in simple terms what could be causing this error?

Upvotes: 0

Views: 4517

Answers (1)

Anthony Roux
Anthony Roux

Reputation: 1481

In your example, you are using http instead of https

I tested your example and it works for me:

https://api.sandbox.amadeus.com/v1.2/flights/low-fare-search?origin=IST&destination=BOS&departure_date=2018-10-15&return_date=2018-10-21&number_of_results=3&apikey={your_api_key}

Upvotes: 1

Related Questions