Application Programming Interface

This is the people's data. In the interests of making it as accessible as possible, we've introduced an easy-to-use RESTful application programming interface (API). No need to request an API key, register, or anything like that.

Supported Formats

We currently support JSON, XML, and CSV. To select your format, simply use the appropriate extension.


http://allyourcells.com/cell_sites.js
http://allyourcells.com/cell_sites.xml
http://allyourcells.com/cell_sites.csv

Number of results

By default, on each request we return 50 results. You can customize this, requesting up to 500 results at a time, using the per_page parameter:


http://allyourcells.com/cell_sites.js?per_page=5

You can request additional pages using the page parameter:


http://allyourcells.com/cell_sites.js?per_page=5&page=2

Searching

All search conditions are namespaced:


http://allyourcells.com/cell_sites.js?search[conditions][CONDITION_NAME]=VALUE

Columns

Column Type
id integer
lat float
lng float
photo_file_name string
photo_content_type string
photo_file_size integer
photo_updated_at datetime
created_at datetime
updated_at datetime
creator_id integer
updater_id integer
photo_md5_hash string
email_uid integer
licensee string
callsign string
location_number string
address string
city string
county string
state string
nepa string
qzone string
tower_reg string
supporting_structure_height float
structure_height float
structure_type string
license_id string

These columns can be combined with a few modifiers, like COLUMN_NAME_is, COLUMN_NAME_greater_than, and COLUMN_NAME_less_than


http://allyourcells.com/cell_sites.js?search[conditions][state_is]=CA
http://allyourcells.com/cell_sites.js?search[conditions][structure_height_greater_than]=500

Multiple conditions can be combied


http://allyourcells.com/cell_sites.js?search[conditions][state_is]=CA&search[conditions][structure_height_greater_than]=500

Geographic Searching

We currently support a bounding-box search:


http://allyourcells.com/cell_sites.js?search[conditions][within_bounds][sw_point]=37.72&[conditions][within_bounds][sw_point]=-122.57&search[conditions][within_bounds][ne_point]=37.83&[conditions][within_bounds][ne_point]=-122.29

Ordering Results

You can order your results by any column by adding ascend_by_COLUMN_NAME or descend_by_COLUMN_NAME. For example:


http://allyourcells.com/cell_sites.js?search[conditions][ascend_by_created_at]=1
http://allyourcells.com/cell_sites.js?search[conditions][descend_by_structure_height]=1