Skip to main content
GET
/
api
/
fixtures
/
snapshot
Get the latest snapshot of fixtures, optionally starting at or within 30 days after a given epoch day
curl --request GET \
  --url https://txline.txodds.com/api/fixtures/snapshot \
  --header 'Authorization: Bearer <token>' \
  --header 'X-Api-Token: <api-key>'
import requests

url = "https://txline.txodds.com/api/fixtures/snapshot"

headers = {
"Authorization": "Bearer <token>",
"X-Api-Token": "<api-key>"
}

response = requests.get(url, headers=headers)

print(response.text)
const options = {
method: 'GET',
headers: {Authorization: 'Bearer <token>', 'X-Api-Token': '<api-key>'}
};

fetch('https://txline.txodds.com/api/fixtures/snapshot', 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://txline.txodds.com/api/fixtures/snapshot",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"X-Api-Token: <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://txline.txodds.com/api/fixtures/snapshot"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("X-Api-Token", "<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://txline.txodds.com/api/fixtures/snapshot")
.header("Authorization", "Bearer <token>")
.header("X-Api-Token", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://txline.txodds.com/api/fixtures/snapshot")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["X-Api-Token"] = '<api-key>'

response = http.request(request)
puts response.read_body
[
  {
    "Ts": 123,
    "StartTime": 123,
    "Competition": "<string>",
    "CompetitionId": 123,
    "FixtureGroupId": 123,
    "Participant1Id": 123,
    "Participant1": "<string>",
    "Participant2Id": 123,
    "Participant2": "<string>",
    "FixtureId": 123,
    "Participant1IsHome": true
  }
]
"<string>"
"<string>"
"<string>"
"<string>"

Authorizations

Authorization
string
header
required

User's session JWT.

X-Api-Token
string
header
required

The user's long-lived API token, obtained from the activation endpoint.

Headers

Authorization
string
required

Bearer token for the user's session JWT.

X-Api-Token
string
required

The user's long-lived API token.

Query Parameters

startEpochDay
integer

Optional. The day at or within 30 days after which the fixtures start. Defaults to the current day in UTC.

competitionId
integer<int32>

Optional. Filter by a specific competition ID.

Response

Ts
integer<int64>
required
StartTime
integer<int64>
required
Competition
string
required
CompetitionId
integer<int32>
required
FixtureGroupId
integer<int32>
required
Participant1Id
integer<int32>
required
Participant1
string
required
Participant2Id
integer<int32>
required
Participant2
string
required
FixtureId
integer<int64>
required
Participant1IsHome
boolean
required