Created
February 11, 2012 00:01
-
-
Save elee/1794249 to your computer and use it in GitHub Desktop.
MetroTransit API example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import urllib2 | |
| import json | |
| from pprint import pprint | |
| stop_id = 1200 | |
| pprint(json.load(urllib2.urlopen('http://svc.metrotransit.org/NexTrip/%s?format=json' % stop_id))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment