getting started with civic application development
TRANSCRIPT
Reth
ink
Getting Started with Civic Application Development
Thom Robbins, Socrata
@trobbins
Leveraging the power of open data
Reth
ink
“Open data looks to make data that
belongs to the public broadly
accessible and usable by humans
and machines, free of any
constraints”
Reth
ink
WelcomeWhy open data?
The goal of open data is to take the valuable
resource out of government database silos, where
it sits idle and put it into the hands of the people
who can unlock it’s value
Reth
ink
What will we look at? Hacking the data
We will look at how you can
use a free and open API to tap
into this data for your
applications
Reth
ink
What does Socrata do?
We make it easy for
governments to share their
public data with application
developers
Reth
ink
What kind of data is out there?
Over 200+ governments (and
counting) of all types are
making their data available!
Reth
ink
How much data is there?
Reth
ink
Typical data types
Budget and spending
Police and crime
Transportation and geospatial
Heath & Public Safety
Reth
ink
What can you build?
http://open-data-apps.socrata.com/submit-app/
Reth
ink
Spotcrime.com
Reth
ink
Look at Cook
http://lookatcook.com/
Reth
ink
Yelp (San Francisco)
Reth
ink
The Socrata open data APIs
Data publisher
Consumer
Reth
ink
Step 1: Finding Data
• Information resource -
Dev.socrata.com/data
• Local site example
• Cambridge Open Data -
https://data.cambridgema.gov
/
• White House Open Data -
https://open.whitehouse.gov/
Reth
ink
Step 2: Getting the API endpoints
https://$domain/resource/$identifier.$ext
Reth
ink
Step 3: Simple filters
/resources/abcd-1234.json?source=ConEd
Reth
ink
Step 4: SoQL Queries
/resource/abcd-
1234.json?$where=kwh > 8000
More information available at: dev.socrata.com/docs/queries.html
Reth
ink
Advanced SoQl queries
Reth
ink
Step 5: Geo Queries
/resource/abcd-1234.json?
$where=within_circle(location, latitude, longitude,
distance(m))
Reth
ink
Step 6: Paging through data
/resource/abcd-1234.json?
$limit=50 & $offset=100
The default $limit is 1000 and $offset start at 0
Reth
ink
Step 7: Application Tokens
Register at http://dev.socrata.com/register
Include as
• X-App-Token: $token HTTP Header or….
• The $$app_token=$token parameter
Reth
ink
Check out the getting started guide
http://dev.socrata.com/consumers/examples/creating-an-application-with-asp-dotnet.html
Reth
ink
Need help?
The place for all your developer
needs:
http://dev.socrata.com
Reth
ink
Are you ready?
http://open-data-apps.socrata.com/submit-app/
Reth
ink
Thank You!
Find Us!
Socrata.com
Follow Us!
@Socrata
Friend Us!
facebook.com/socrata
Watch Us!
http://www.youtube.com/user/socratavideos