Docs
Coverage MatrixDocumentationRelease LogLog In

Push Draft Trades

NFL Push Draft Trades provides summary details of all in-draft trades in real-time.

Syntax

https://api.sportradar.com/draft/nfl/{access_level}/stream/en/trades/subscribe?api_key={your_api_key}

Replace placeholders with the following query parameters:

ParameterDescription
access_levelDefines the access level of your API key as Production (production), or Trial (trial).
your_api_keyYour API key.

Optional Query String Parameters

In addition to the URL parameters listed above, you can filter the Trades information with one or more of the following optional query string parameters.

๐Ÿ“˜

Optional query string parameters must be added after your API key with an ampersand (&). If you are filtering for more than one result, separate the results with a comma (,) and no spaces.

Replace placeholders with the following query parameters:

ParameterDescription
draftDraft id expressed as: sd:draft:{draft_id}.
Example: draft=sd:draft:04b11293-240e-4340-8f4f-ded6c6281fe9

Code Samples

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/draft/nfl/trial/stream/en/trades/subscribe?api_key={your_api_key}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/draft/nfl/trial/stream/en/trades/subscribe",
    params = {'api_key': 'your_api_key'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/draft/nfl/trial/stream/en/trades/subscribe?api_key={your_api_key}'

Samples with Query String Params

require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.sportradar.us/draft/nfl/trial/stream/en/trades/subscribe?api_key={your_api_key}&draft=sd:draft:04b11293-240e-4340-8f4f-ded6c6281fe9&league=NFL")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
import requests
import json

r = requests.get("https://api.sportradar.com/draft/nfl/trial/stream/en/trades/subscribe",
    params = {'api_key': 'your_api_key', 'draft': 'sd:draft:04b11293-240e-4340-8f4f-ded6c6281fe9', 'league': 'NFL'},
    allow_redirects=False)

redirect_url = r.headers['Location']
r = requests.get(redirect_url, stream=True)

for line in r.iter_lines():
    # filter out keep-alive new lines
    if line:
        decoded_line = line.decode('utf-8')
        print(json.loads(decoded_line))
curl -L GET 'api.sportradar.us/draft/nfl/trial/stream/en/trades/subscribe?api_key={your_api_key}&draft=sd:draft:04b11293-240e-4340-8f4f-ded6c6281fe9&league=NFL'

Response Sample

The above commands return json like this.



Data Points

Draft Info:
AttributeParent ElementTypeDescription
end_datedraftDateEnd date of a draft
ex. 2022-04-30
iddraftGUIDUnique ID of a draft
ex. 01c63362-299c-48a0-b725-63fa18fca261
start_datedraftDateStart date of a draft
ex. 2022-04-30
statusdraftStringStatus of a draft
ex. closed
yeardraftIntegerYear of a draft
Trade Info:
AttributeParent ElementTypeDescription
idtradeGUIDUnique ID of a trade
ex. 3fc4ffa0-fe54-4d9a-bf53-e85df0e2cefd
sequencetradeIntegerSequence number of a trade
ex. 1648829953213
completetradeBooleanSignifies a trade is complete
aliastransactions - to_team/from_teamStringTrade team alias
ex. MIN (Minnesota)
idtransactionsGUIDUnique ID of a trade
ex. 88db5bd9-f8ef-4ddc-a4fc-0de7a04b2d56
idtransactions - to_team/from_teamGUIDUnique ID of a trade team
ex. 82d2d380-3834-4938-835f-aec541e5ece7
markettransactions - to_team/from_teamStringTrade team market name
ex. Minnesota
nametransactions - to_team/from_teamStringTrade team name
ex. Vikings
Pick Info:
AttributeParent ElementTypeDescription
amountitemsStringAmount of trade compensation
iditemsStringUnique ID of a draft item
typeitemsStringType of a draft item
ex. future_pick or player
rounditem - future_pickIntegerFuture pick round number
yearitem - future_pickIntegerFuture pick draft year
compensatoryitem - pickBooleanSignifies a compensatory draft pick
iditem - pickGUIDUnique ID of a draft pick
ex. ca6b8dae-e835-49e4-9638-b30cdd3969a8
numberitem - pickIntegerNumber of a draft pick within a round
supplementalitem - pickBooleanSignifies a supplemental draft pick
overallitem - pickIntegerOverall number of a draft pick
Round Info:
AttributeParent ElementTypeDescription
end_dateroundDateEnd date of a round
ex. 2022-04-30
idroundGUIDUnique ID of a round
ex. 2e9eee59-fdc4-4dbf-bafa-b1cc80976fdb
numberroundIntegerNumber of a round
start_dateroundDateStart date of a round
ex. 2022-04-30
League:
AttributeParent ElementTypeDescription
aliasleagueStringAlias of a league
ex. NFL
idleagueGUIDUnique ID of a league
ex. 3c6d318a-6164-4290-9bbc-bf9bb21cc4b8
nameleagueStringName of a league
ex. National Football League
Players:
AttributeParent ElementTypeDescription
first_nameplayerStringFirst name of a player
ex. Patrick
idplayerGUIDUnique ID of a player
ex. 11cad59d-90dd-449c-a839-dddaba4fe16c
last_nameplayerStringLast name of a player
ex. Mahomes
positionplayerStringPosition of a player
See our FAQ for a list of valid positions
source_idplayerGUIDUnique ID of a player's source team
ex. 9fe7c9f9-5830-4e22-953d-054a44342323
sr_idplayerGUIDUnique Sportradar ID of a player
ex. sr:player:1234416
Coaches:
AttributeParent ElementTypeDescription
first_namecoachStringFirst name of a coach
ex. Dennis
idcoachGUIDUnique ID of a coach
ex. ef1b4704-0ce4-4977-a882-2b14413dd2d2
last_namecoachStringLast name of a coach
ex. Allen
source_idcoachGUIDUnique ID of a player's source team
ex. 9fe7c9f9-5830-4e22-953d-054a44342323
Metadata:
AttributeParent ElementTypeDescription
leaguemetadataStringAlias of a league
ex. NFL
draftmetadataStringUnique ID of a draft
ex. sd:draft:04b11293-240e-4340-8f4f-ded6c6281fe9
localemetadataStringLanguage code
ex. en (English)
operationmetadataStringOperation of an update
update, delete
versionmetadataStringVersion of the API
ex. v1