API de props de jogador NFL com preços Pinnacle
Resposta: a Pinnacle publica player props NFL como eventos special em american-football. No Builder/Pro, /v1/odds?sport=american-football devolve-os com parentId ao jogo. Free/Hobby são main-only.
Exemplo#
import os, requests
from collections import defaultdict
H = {"x-api-key": os.environ["PINNFEED_KEY"]} # ps_live_...
# 1) find the NFL league id once (college football is a different league)
ev = requests.get("https://pinnfeed.io/v1/events", headers=H, timeout=10,
params={"sport": "american-football", "q": "nfl", "limit": 200}).json()["events"]
print({(e["league"]["id"], e["league"]["name"]) for e in ev if e["league"]})
LEAGUE = int(input("NFL league id: "))
# 2) games and props together (no main=true: that would drop the specials)
data = requests.get("https://pinnfeed.io/v1/odds", headers=H, timeout=15,
params={"sport": "american-football", "league": LEAGUE, "limit": 500}).json()["events"]
games = {e["id"]: e for e in data if not e.get("special")}
props = defaultdict(list)
for e in data:
if e.get("special") and e.get("parentId") in games:
props[e["parentId"]].append(e)
for gid, items in props.items():
g = games[gid]
print(f'{g["away"]} @ {g["home"]} ({len(items)} props)')
for p in items[:10]:
for m in p["markets"]:
line = " | ".join(f'{o["name"]} {o["decimal"]} (fair {o.get("fair")})' for o in m["outcomes"])
print(" ", p["special"]["description"], m["type"], m.get("line"), line)
{ "type": "subscribe", "sports": ["american-football"], "leagues": [LEAGUE_ID], "specials": true }
Relacionado: specials, NFL API.
CTA#
Builder (€99/mês). Teste 3 dias; cartão obrigatório. REST gratis: signup.
Player props da NBA (o mesmo padrão)#
Os player props da NBA usam o mesmo padrão de eventos special com parentId, em sport=basketball. Busque o id da NBA com q=nba. Não passe main=true se quiser os specials.
Perguntas frequentes#
Free inclui props NFL?#
Não — Builder.
Conteúdo educativo para adultos?#
Sim (18+).
Conteúdo educativo para maiores de 18 anos. Sem palpites nem lucro garantido. No Brasil, aposte apenas em operadores autorizados pela SPA/MF.