Tripit Export Github API code not working
New here? Learn about Bountify and follow @bountify to get notified of new bounties! x

I am not a coder. Trying to use a Github repo mattbaylisFL/tripit-to-flightdiary to use Tripit's API to get out my list of flights.

Get through the auth. Get to running It does seem to run for a while - like it's doing something then get this error.

Traceback (most recent call last):
File "C:\Users\XXX\Documents\GitHub\tripit-to-flightdiary\", line 19, in
File "C:\Users\XXX\Documents\GitHub\tripit-to-flightdiary\", line 16, in main
print json.dumps(get_trips(), indent=4)
File "C:\Users\XXX\Documents\GitHub\tripit-to-flightdiary\", line 13, in get_trips
'page_size/500/include_objects/true', auth=auth).json()
File "C:\Python27\lib\site-packages\requests\", line 896, in json
return complexjson.loads(self.text, **kwargs)
File "C:\Python27\lib\", line 339, in loads
return _default_decoder.decode(s)
File "C:\Python27\lib\json\", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Python27\lib\json\", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded

I made a tripit account, created an app and went through the process described in the README in the Github repo. However, I had to change foo to a dummy URL ( in order for the process to work. Then I ran after adding a past trip in my profile and it successfully printed out a sensible response without throwing any exception. The error you're getting is likely because you're receiving an empty response, but I tried a few things and I never managed to get that.
CyteBode 8 months ago
Okay, I managed to get your error by mutating the URL. Even if part of it is wrong the site responds with a 200 status code (no error) and an XML response which the JSON module of course cannot parse. So either re-download the files from the repository or make sure that the URL is indeed '' 'traveler/true/past/true/format/json/' 'page_size/500/include_objects/true' (in three lines, which Python joins automatically).
CyteBode 8 months ago
Thanks. Awesome. I want to pay you but I think you didn't do it as a solution. Can you do so?
sebmack 8 months ago
Thanks! I've posted a solution so you can accept it.
CyteBode 8 months ago
awarded to ahmedengu

Crowdsource coding tasks.

2 Solutions

Winning solution


I have created a fork of the repo with an updated readme and the required changes
the repo can be found here:


Just make sure that you are using python 2.7

and follow the instructions

i don't have any trips yet but the concept is the same


  1. download and extract the repo:
  2. install python 2.7
  3. run pip install -r requierements.txt
  4. update creds.json
  5. run and follow python the creds.json gonna get updated automatically
  6. run python ... tripit.json gonna get generated automatically containing the trips

Hope that's clear

Best Regards,


Hi. Awesome stuff. Haven't tested it but looks easier. Cytebode actually helped me out with my malformed URL so I will work out how to reward both once it's in. I'll also post another challenge too!
sebmack 8 months ago
Thank you
ahmedengu 8 months ago

As I found out in the comments above, it was just a malformed URL.

Thanks for the tip!
CyteBode 8 months ago
View Timeline