A finished game, move by move: the board after each move and the score.
curl --request GET \
--url https://www.smashandclash.in/api/v1/games/{id}/replayimport requests
url = "https://www.smashandclash.in/api/v1/games/{id}/replay"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://www.smashandclash.in/api/v1/games/{id}/replay', 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://www.smashandclash.in/api/v1/games/{id}/replay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://www.smashandclash.in/api/v1/games/{id}/replay"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://www.smashandclash.in/api/v1/games/{id}/replay")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.smashandclash.in/api/v1/games/{id}/replay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"ruleset": "mutators",
"players": {
"A": "<string>",
"B": "<string>"
},
"seed": 123,
"firstPlayer": "A",
"score": {
"A": 123,
"B": 123
},
"moveCount": 123,
"moves": [
{
"n": 123,
"seat": "A",
"name": "<string>",
"notation": "<string>",
"captures": 123,
"score": {},
"board": [
{}
]
}
],
"id": "<string>",
"winner": "A",
"chessTiles": [
{}
],
"replayUrl": "<string>"
}{
"status": 123,
"error": "<string>",
"code": "bad_request",
"hint": "<string>",
"type": "<string>",
"title": "<string>",
"detail": "<string>",
"docs": "<string>"
}replays
A finished game, move by move: the board after each move and the score.
A finished game, move by move: the board after each move and the score. Games still being played have no replay yet (409).
GET
/
games
/
{id}
/
replay
A finished game, move by move: the board after each move and the score.
curl --request GET \
--url https://www.smashandclash.in/api/v1/games/{id}/replayimport requests
url = "https://www.smashandclash.in/api/v1/games/{id}/replay"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://www.smashandclash.in/api/v1/games/{id}/replay', 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://www.smashandclash.in/api/v1/games/{id}/replay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://www.smashandclash.in/api/v1/games/{id}/replay"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://www.smashandclash.in/api/v1/games/{id}/replay")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.smashandclash.in/api/v1/games/{id}/replay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"ruleset": "mutators",
"players": {
"A": "<string>",
"B": "<string>"
},
"seed": 123,
"firstPlayer": "A",
"score": {
"A": 123,
"B": 123
},
"moveCount": 123,
"moves": [
{
"n": 123,
"seat": "A",
"name": "<string>",
"notation": "<string>",
"captures": 123,
"score": {},
"board": [
{}
]
}
],
"id": "<string>",
"winner": "A",
"chessTiles": [
{}
],
"replayUrl": "<string>"
}{
"status": 123,
"error": "<string>",
"code": "bad_request",
"hint": "<string>",
"type": "<string>",
"title": "<string>",
"detail": "<string>",
"docs": "<string>"
}Path Parameters
Response
The replay.
Available options:
mutators, classic Show child attributes
Show child attributes
What decided the deal (shown once the game is over).
Available options:
A, B Show child attributes
Show child attributes
Show child attributes
Show child attributes
Available options:
A, B, draw, null