Get a single historical version of a deck
curl --request GET \
--url https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n} \
--header 'Authorization: Bearer <token>' \
--header 'X-Partner-Id: <api-key>' \
--header 'X-Signature: <api-key>'import requests
url = "https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}"
headers = {
"X-Signature": "<api-key>",
"X-Partner-Id": "<api-key>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Signature': '<api-key>',
'X-Partner-Id': '<api-key>',
Authorization: 'Bearer <token>'
}
};
fetch('https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}', 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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}",
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-Partner-Id: <api-key>",
"X-Signature: <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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Signature", "<api-key>")
req.Header.Add("X-Partner-Id", "<api-key>")
req.Header.Add("Authorization", "Bearer <token>")
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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}")
.header("X-Signature", "<api-key>")
.header("X-Partner-Id", "<api-key>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Signature"] = '<api-key>'
request["X-Partner-Id"] = '<api-key>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"version_number": 123,
"name_at_version": "<string>",
"edited_at": "2023-11-07T05:31:56Z",
"history_type": "<string>",
"visibility": [
"<string>"
]
}Decks
Get a single historical version of a deck
Returns the nth-oldest historical record. Position 1 is the create event. Out-of-range n returns 404 NOT_FOUND. Visibility rules of the underlying deck are respected.
GET
/
api
/
public
/
v1
/
games
/
{game}
/
decks
/
{id}
/
versions
/
{n}
Get a single historical version of a deck
curl --request GET \
--url https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n} \
--header 'Authorization: Bearer <token>' \
--header 'X-Partner-Id: <api-key>' \
--header 'X-Signature: <api-key>'import requests
url = "https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}"
headers = {
"X-Signature": "<api-key>",
"X-Partner-Id": "<api-key>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Signature': '<api-key>',
'X-Partner-Id': '<api-key>',
Authorization: 'Bearer <token>'
}
};
fetch('https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}', 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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}",
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-Partner-Id: <api-key>",
"X-Signature: <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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Signature", "<api-key>")
req.Header.Add("X-Partner-Id", "<api-key>")
req.Header.Add("Authorization", "Bearer <token>")
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.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}")
.header("X-Signature", "<api-key>")
.header("X-Partner-Id", "<api-key>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.flexslot.gg/api/public/v1/games/{game}/decks/{id}/versions/{n}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Signature"] = '<api-key>'
request["X-Partner-Id"] = '<api-key>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"version_number": 123,
"name_at_version": "<string>",
"edited_at": "2023-11-07T05:31:56Z",
"history_type": "<string>",
"visibility": [
"<string>"
]
}Authorizations
PartnerHmac & PartnerSlug & PersonalAccessTokenPartnerHmac & PartnerSlugApiKeyPersonalAccessTokenOAuth2DPoP & OAuth2DPoPProofOAuth2Bearer
HMAC-SHA256 over canonical request string. Format: v1.<unix_seconds>.<hex_hmac_sha256>.
Partner identifier slug. Required alongside X-Signature for HMAC auth.
User-issued personal access token (format: flx_pat_).
Was this page helpful?