how to use IATA-3 letter code in Sabre instaFlights Search API? - php

I am using instaFlights Search API of Sabre. I am unable to get response for any of the IATA 3-letter codes other then "JFK" and "LAX". Whenever I pass any other IATA code in the request like "DXB", i recieve an error.
please note that I am working on test environment and testing the api on the link given below.
link of API test page
The error that i receive every time i request with any other IATA Code.

Are you in CERT or PROD?
If you are still in CERT, only a subset of available flight schedules/fares will be found and returned. Do you have access to PROD? If you're working in PROD and not getting any results then I would think something else is malformed in your request.

InstaFlight is limited to specific POS (Point of Sale) and the available city pairs are tied to the POS being used.
I recommed you to contact the API Support team for further details.

Related

MapQuest API - Insight from users

I need to be able to extract a list of states the route passes through. Is there any functionality within the api that will provide this information?
e.g. A route that crosses 6 states from start point to end point. Get list of states. Preferably in order of crossing.
I'm not looking for code help. I've searched through the api and google with no results.
There is no function in the MapQuest directions api that returns a list of states for a route. But if the stateBoundaryDisplay parameter is set to true, the response will contain details like, "Crossing into Nebraska", in the maneuver text. The manuevers will be in the correct order.

Poloniex push api

I am interested in writing some basic php to interface with the Poloniex push api.
Their website provides the following info:
https://poloniex.com/support/api/
A php wrapper can be found here:
http://pastebin.com/iuezwGRZ
From what i can determine there are three APIs being push, public and trading. The public and trading APIs provide functions that can be passed parameters etc. The push api stumps me totally as i cannot determine how it works.
The first link above states the API pushes live data and different feeds can be subscribed to.
My questions are:
A) How can php receive a live stream of data?
B) How do i subscribe to a feed?
I may have misunderstood the oush api and my apologies in advance if this is the case.
Edit1:
I believe i need a WAMP client to connect to a WAMP router such as Minion.
https://github.com/Vinelab/minion
Edit2:
Node.js example
http://pastebin.com/dMX7mZE0
The push API is based on Websocket protocol.
Initially you need first to make a connection to the websocket server,
after that you need to register to a data stream (price update stream for example), after that as soon as the server make an update to something (a price ), all connected clients who where previously registred to it will synchronously received the updated price
Finally you got the last price without the need of doublecheck at regular interval if the price has changed

MailChimp API V3 Creating Interest (group)

I have a web app written in PHP that uses Mailchimp API v3. It was working ok until two days ago. I can't figure out what is going on. When I try to create new interest, I get 500 error, so in my response I don't get interest ID which I use later on. However, the interest gets created, which is weird.
I use the correct ENDPOINT. It's the same one shown in the API Playground. Even when I try to do this in the PLAYGROUND, I get the same error, but the interest (group) gets created.
Endopoint:
"http://".$dc.".api.mailchimp.com/3.0/lists/".$list_id."/interest-categories/".$subgroup_id."/interests"

error blockchain recive api code

as you see in the title
i need help with bitcoin payments api
i have a website all i need is an api that generate a new address for each payment and send the amount that i specify and get a call back with an invoice_id and a link and a number
i did everything as mentioned on the blockchain api page not the wallet api
but i cant get it done because i dont recive a callback
i can generate address and the money come back to my address all the problem is i dont recive the callback to my url
also when i test the URL manualy everything is working
anyone can help me or can give me a working version of blockchain api i use this [https://github.com/blockchain/receive_payment_php_demo]
You can go to the receive payments API page here: https://blockchain.info/api/api_receive and put in your callback URL, as well as a bitcoin address. When you click 'submit', you can see an option to fire test callbacks to see if the blockchain server can interface properly with yours (and if not, what error message is generated).

Using Service Account For Google Analytics

I wanted to create a web service like feature that would provide me the JSON response from the google analytics, i plan to do some processing on the GA data and then output the response to the user who would have requested for my service.
I selected PHP as my language and used google-api-php-client from google and now since i don't want to authorize every time to get Token, i thought of using Service account with which i would directly use keys.
I downloaded the sample code from Google changed client ID and Service Account Name and Key location.
But then this Error Came
Catchable fatal error: Argument 3 passed to Google_HostedmodelsServiceResource::predict()
must be an instance of Google_Input, none given, called in /var/www/webservice/GA/serviceanalytics.php
on line 62 and defined in /var/www/webservice/GA/google-api-php-client/src/contrib/Google_PredictionService.php on line 36
I found that the second argument that example is passing should have been the third argument.
So what should be the second argument. A little insight or a working code will be appreciated :)
Thanks
The link you have posted svn/trunk/examples/prediction/serviceAccount.php
Is for use with Google Preditions api If you have supplied a client ID and Service Account Name and Key location for an api that was set up to allow google analytics this wont work. I sugest you look for an example using Google Analtyics or change the apis console to allow preditions api while you are getting to know the sample code for Google Preditions.

Categories