Get list of offices

52 views
Skip to first unread message

Stephen Melrose

unread,
Oct 29, 2015, 12:04:44 PM10/29/15
to Open Civic Data
Hi,

I recently discovered the Open Civic Data API and I'm looking to use it to gain a list of the offices within the United States. By offices, I mean any seat that someone can run in an election for, from federal all the way down to the local level.

I think I need to get the list of organizations and/or jurisdictions to accomplish this. Is that correct?

I registered for an API key, which I have since activated, but I can't get the API to actually work for my to search. I just keep getting,

{
    error
: "Authorization Required: obtain a key at http://sunlightfoundation.com/api/accounts/register/#ocd"
}

I'm hitting the URL with my activated API key like so,


Any thoughts?

Thanks,

Steve

Patrick Connolly

unread,
Nov 25, 2015, 5:38:08 PM11/25/15
to Open Civic Data
I'm just starting to experiment with the API as well. But I'm not getting that specific error on that url, so perhaps it's that there's something wonky with your API key activation.

Having said that, that specific query returns no results, even though it's in the docs as working.

Since the query below, with full name and case sensitivity, works, I have to assume something's changed on the server side and the docs are a bit behind.


fwiw, it seems that some on the filter parameteres on other endpoints fail to return results even when full text is provided, so I think some things are awry at the moment.
Reply all
Reply to author
Forward
0 new messages