Data dictionaries

District

The area a contest is voted in: a state, a congressional or legislative district, a county, a city, a ward or a school district.

Returned by
GET /v1/contests, GET /v1/contests/{id}, GET /v1/elections/{slug}/export
Found in
Contest (district)

How it connects

  • Many contests share a district. id matches an officeholder’s district_id, which links a contest to whoever holds the seat now.
  • ocd_id is the Open Civic Data division id, the same id other civic data uses; filter contests with districts={ocd_id}.

Good to know

  • type is open: it comes from the election offices’ own classifications, so new values can appear as we load more places.
  • ocd_id is null for a few local districts that have no Open Civic Data division.

Fields

FieldTypeMeaningExample
idintegerDistrict id. Matches an officeholder’s district_id.1
ocd_idstringor nullOpen Civic Data division id, used in districts= filters.ocd-division/country:us/state:ca
namestringDistrict name.California
levelstringLevel of government.federal, state, county, city, school, special meaningsstate
typestringKind of district: statewide, congressional, state_upper, state_lower, county, council, school, …151 values so far: meaningsstatewide
statestringor nullTwo capital letters (USPS code)USPS state code.CA

Download every dictionary as CSV or JSON.

District data dictionary · BallotData API