Ouverture + clôture + timeline d'un special
curl --request GET \
--url https://api.apinn.io/api/specials/history \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.apinn.io/api/specials/history"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.apinn.io/api/specials/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.apinn.io/api/specials/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.apinn.io/api/specials/history"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.apinn.io/api/specials/history")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.apinn.io/api/specials/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"opening": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
],
"closing": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
],
"history": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
]
}specials
Ouverture + clôture + timeline d'un special
Miroir de /api/history pour les marchés specials (props, outrights, corners, buteurs…). Renvoie opening, closing et history en un appel.
La timeline ne contient que des CHANGEMENTS, jamais deux points identiques d’affilée. Un point est créé dès que bouge la cote (odds), la limite de mise (max_win) ou la ligne (handicap). Chaque point porte l’identité complète du marché (special_name, period, handicap, max_win) : la série se lit seule, sans jointure. Plan Sharp.
GET
/
api
/
specials
/
history
Ouverture + clôture + timeline d'un special
curl --request GET \
--url https://api.apinn.io/api/specials/history \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.apinn.io/api/specials/history"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.apinn.io/api/specials/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.apinn.io/api/specials/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.apinn.io/api/specials/history"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.apinn.io/api/specials/history")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.apinn.io/api/specials/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"opening": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
],
"closing": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
],
"history": [
{
"event_id": 123,
"special_id": 123,
"special_name": "<string>",
"contestant_id": 123,
"contestant_name": "<string>",
"handicap": 123,
"odds": 123,
"todds": 123,
"period": 123,
"max_win": 123,
"cutoff": "<string>",
"timestamp": "<string>",
"true_odds_by_model": {}
}
]
}Autorisations
Paramètres de requête
Événement (obligatoire si special_id est absent).
Limiter à un marché special précis.
Ne renvoyer que les points postérieurs à cet horodatage ISO.
Modèle de devig des todds.
Options disponibles:
LOG, EM, MPTO, SHIN, OR