/election_dates

Election dates by point or by state

Election dates by point

Given a latitude and longitude point, a list of election dates will be returned for the particular point (address) that have occurred 1 year in the past and will occur 1 year in the future according to today's date.

Required parameters: lat, long

Optional parameters: none

chevron-rightExample callhashtag
https://api4.ballotpedia.org/data/election_dates/point?lat=40.5550746&long=-74.27596989999999
chevron-rightExample responsehashtag
{
            "success": true,
            "data": {
                "elections": [
                    {
                        "type": "General",
                        "id": 18742,
                        "date": "2020-11-03",
                        "description": null
                    },
                    {
                        "type": "General",
                        "id": 18775,
                        "date": "2020-11-03",
                        "description": "U.S. Presidential election"
                    },
                    {
                        "type": "General",
                        "id": 22516,
                        "date": "2021-11-02",
                        "description": null
                    }
                ]
            },
            "message": null
        }

Election dates by parameters

Election dates can be queried via several parameters which will return data from 2018+ and several years into the future. Data is returned in an ascending matter according to date, with limits of 25 results per page.

Required parameters: none

Optional parameters:

  • state={state abbreviation}

  • type=General,Primary,Special,Recall

  • year={year}

  • page={number}

chevron-rightExample call with no optional parameters definedhashtag
chevron-rightExample responsehashtag

Example call querying for all Special Elections that occurred in Wisconsin in 2020.

chevron-rightExample call querying for all Special Elections that occurred in Wisconsin in 2020.hashtag
chevron-rightExample responsehashtag

Last updated