Delegates - DNC 2024

 

ON THIS PAGE      Show

 

 

 

 

Description

Following the announcement of President Joe Biden’s decision to exit the race for President, the Elections API tracked the updated delegate allocation for a new presidential nominee. All rounds of voting during the delegate selection process were captured.

 

  Notes

 

  • Existing data feeds tracking the results of the Democratic Party’s 2024 primary elections and initial delegate allocations did not change. They continued to show the results of the completed Democratic presidential primary elections and nominating events.

  • The returned data elements for the types of delegate allocation data are the same as in the National Presidential Delegate Tracking Reports; however, no delegate reports were generated for the special DNC 2024 delegate allocation. The results were represented in the Delegates - DNC 2024 API method responses only, as documented below.

 

 

 

Required Request Headers

 

Header

Description

Example

x-api-key

Specifies the API key to authorize the request. The x-apikey header is also currently supported.

apikey

Accept-Encoding

Compresses the response to the gzip format.

gzip

Optional Request Header

 

Header

Description

Example

Accept

The MIME type of the returned data format: XML or JSON. The default is application/xml. The format parameter value takes precedence over the Accept header value when both are specified.

application/json

Request URI

 

Method

Request URI

GET

https://api.ap.org/v3/elections/delegates/{electionYear}/special/{stage}?[{OptionalParameters}]

 

  Important

 

The request URI must be URL-encoded.

 

 

 

Required Parameters

Parameter

Description

Example

electionYear

Year of the presidential election (in the YYYY format) for which to return delegate data.

2024

stage

One of the following:

  • preconvention. Tracks delegate allocation from voting that occurs before a party’s presidential nominating convention, such as a virtual roll call.

  • convention. Tracks delegate allocation from voting that occurs during a party’s presidential nominating convention.

preconvention

Optional Parameters

The following parameters can be used to control the returned data and format:

 

Parameter

Description

Example

votingRound

The round of voting during the delegate selection process. Possible values are latest, 1 and 2. A list of all available reports is returned by default.

latest

type

The type of delegate data to return. Multiple values are not allowed. Possible values are:

  • summary. Returns the cumulative ("DelSum") data, which is the current summary delegate total for each candidate across the country as well as the change in the past 24 hours, past week and past month. This is the default value.

  • state. Returns the state-by-state ("DelState") data, which is the current delegate total for each candidate in each state and at the national level as well as the change in the past 24 hours.

  • super. Returns the unpledged/super delegates ("DelSuper") data, which is the current delegate and unpledged delegate totals for each candidate in each state and at the national level (note that anonymous unpledged delegates are not counted at the state level).

state

format

The response format (xml or json). The format parameter value takes precedence over the Accept header value when both are specified. If no format is specified as the format parameter value or in the Accept header, XML is returned.

json

resultsType

Indicates whether to return live or test delegate data. Possible values are t or test for test data and l or live for live data (this is the default).

  Important

 

To receive test data, make sure to add the optional resultsType=t parameter to the request URL.

 

 

 

t

test

party

The code of the party for which to return delegate data. The default and the only valid value is "Dem".

 

Request URI Examples

Sample URI

Returned Results

https://api.ap.org/v3/elections/delegates/2024/special/convention?format=json&votingRound=latest

Cumulative ("DelSum") delegate allocation data in the JSON format from the latest round of voting during DNC 2024.

https://api.ap.org/v3/elections/delegates/2024/special/preconvention?type=state&votingRound=1

State-by-state ("DelState") delegate allocation data in the XML format from the first round of voting before DNC 2024.

Response

On success, returns the standard HTTP status code of "200 – OK" and results in the requested format (XML or JSON). The response contains the DNC 2024 delegate allocation data of the requested type. For information about error codes, see API Codes.

Data Elements

XML Element

JSON Property

Description

delDataType

"delDataType"

The tag for this response: delSum, delState or delSuper.

@ApiVersion

"apiVersion"

The API version number; for example, 3.1.

@ApiBuild

"apiBuild"

The API build number; for example, 3.1.461.

...

...

For information about the data elements in each delegate allocation data type, see:

 

  Note

 

No National Presidential Delegate Tracking Reports were generated for the special DNC 2024 delegate allocation. The results were represented in the Delegates - DNC 2024 API method responses only.

 

 

 

 

link

"nextrequest"

Indicates a link for the next request that must be used to request data newer than the data in the previously returned response.

@rel="next"

@href

 

The specific URL for the next request.

Response Examples

The following examples show partial JSON and XML responses containing the DNC 2024 state-by-state ("DelSum") delegate allocation data.

 

JSON

XML

...

...