US Elections

Election Candidates

Candidates for president, U.S. Senate, U.S. House, governor and other statewide offices, with party, home state, years and the number of races and wins. Pass slug for one candidate with every race: year, office, state, party, votes, share and result. Members of Congress carry an official portrait link.

The list answer is {total, limit, offset, sort, order, rows, about}; with slug it is {candidate, races, about}. sort is name, last_year, first_year, races or wins.

get/elections/candidates

Request

  • Base URL: https://api.dataporium.io
  • URL: https://api.dataporium.io/elections/candidates
  • Auth: API key in query parameter apikey

Query parameters

slugstring

One candidate by slug

qstring

Name contains this text

statestring

Home state

partystring

Latest party: D, R or other

officestring

Ran for this office (comma-separated office codes)

yearinteger

Ran in this election year

wonboolean

true = won at least one race

in_congressboolean

true = current or former member of Congress

sortstring

Sort field (see the endpoint description)

orderstring

asc or desc

limitinteger

Rows per page (default 50 to 100, at most 1000)

offsetinteger

Rows to skip, for paging

Response

Successful response (JSON).

object required

Changes

No recorded changes to this operation across all 1 revision of this API.