Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add tv-channels #410

Merged
merged 1 commit into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions doc/specs/schemas/TvGame.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
type: object

properties:
user:
allOf:
- $ref: './LightUser.yaml'
- type: object
properties:
flair:
$ref: './Flair.yaml'
rating:
type: number
gameId:
type: string
color:
type: string
enum:
- 'white'
- 'black'

required:
- user
- rating
- gameId
- color
260 changes: 167 additions & 93 deletions doc/specs/tags/tv/api-tv-channels.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ get:
- TV
security: []
responses:
"200":
'200':
description: The list of games being played for each speed and variant.
headers:
Access-Control-Allow-Origin:
Expand All @@ -19,96 +19,170 @@ get:
content:
application/json:
schema:
example: {
"bot": {
"user": { "id": "leelachess", "name": "LeelaChess", "title": "BOT" },
"rating": 2660,
"gameId": "Zznv9MIl",
"color": "black"
},
"blitz": {
"user": { "id": "lekkerkortook", "name": "LekkerKortOok" },
"rating": 2603,
"gameId": "hTJ4v7Mp",
"color": "black"
},
"racingKings": {
"user": { "id": "chesslo21", "name": "chesslo21" },
"rating": 2123,
"gameId": "lgCDl5Of",
"color": "white"
},
"ultraBullet": {
"user": { "id": "farmville", "name": "Farmville" },
"rating": 2338,
"gameId": "NEY6OQ32",
"color": "white"
},
"bullet": {
"user": { "id": "nurmibrah", "name": "nurmiBrah" },
"rating": 2499,
"gameId": "5LgyE516",
"color": "black"
},
"classical": {
"user": { "id": "holden_m_j_thomas", "name": "Holden_M_J_Thomas" },
"rating": 1806,
"gameId": "k3oLby6N",
"color": "white"
},
"threeCheck": {
"user": { "id": "pepellou", "name": "pepellou", "patron": true },
"rating": 1978,
"gameId": "Og5RCvmu",
"color": "black"
},
"antichess": {
"user": { "id": "maria-bakkar", "name": "maria-bakkar" },
"rating": 2103,
"gameId": "toCr41yx",
"color": "black"
},
"computer": {
"user": { "id": "oh_my_goat_im_so_bat", "name": "oh_my_goat_Im_so_bat" },
"rating": 2314,
"gameId": "TkI4qZxu",
"color": "black"
},
"horde": {
"user": { "id": "habitualchess", "name": "HabitualChess" },
"rating": 1803,
"gameId": "oMofN63H",
"color": "white"
},
"rapid": { "user": { "id": "denpayd", "name": "DenpaYD" }, "rating": 2289, "gameId": "IcWOl8ee" },
"atomic": {
"user": { "id": "meetyourdemise", "name": "MeetYourDemise" },
"rating": 2210,
"gameId": "tvMxtCMN",
"color": "white"
},
"crazyhouse": {
"user": { "id": "mathace", "name": "mathace" },
"rating": 2397,
"gameId": "i3gTZlUb",
"color": "black"
},
"chess960": {
"user": { "id": "voja_7", "name": "voja_7" },
"rating": 1782,
"gameId": "lrXLcedu",
"color": "white"
},
"kingOfTheHill": {
"user": { "id": "nadime", "name": "Nadime" },
"rating": 1500,
"gameId": "DsQn8aEV",
"color": "white"
},
"best": {
"user": { "id": "lekkerkortook", "name": "LekkerKortOok" },
"rating": 2603,
"gameId": "hTJ4v7Mp",
"color": "black"
type: object
required:
- bot
- blitz
- racingKings
- ultraBullet
- bullet
- classical
- threeCheck
- antichess
- computer
- horde
- rapid
- atomic
- crazyhouse
- chess960
- kingOfTheHill
- best
properties:
bot:
$ref: '../../schemas/TvGame.yaml'
blitz:
$ref: '../../schemas/TvGame.yaml'
racingKings:
$ref: '../../schemas/TvGame.yaml'
ultraBullet:
$ref: '../../schemas/TvGame.yaml'
bullet:
$ref: '../../schemas/TvGame.yaml'
classical:
$ref: '../../schemas/TvGame.yaml'
threeCheck:
$ref: '../../schemas/TvGame.yaml'
antichess:
$ref: '../../schemas/TvGame.yaml'
computer:
$ref: '../../schemas/TvGame.yaml'
horde:
$ref: '../../schemas/TvGame.yaml'
rapid:
$ref: '../../schemas/TvGame.yaml'
atomic:
$ref: '../../schemas/TvGame.yaml'
crazyhouse:
$ref: '../../schemas/TvGame.yaml'
chess960:
$ref: '../../schemas/TvGame.yaml'
kingOfTheHill:
$ref: '../../schemas/TvGame.yaml'
best:
$ref: '../../schemas/TvGame.yaml'

example:
{
'bot':
{
'user': { 'id': 'leelachess', 'name': 'LeelaChess', 'title': 'BOT' },
'rating': 2660,
'gameId': 'Zznv9MIl',
'color': 'black',
},
'blitz':
{
'user': { 'id': 'lekkerkortook', 'name': 'LekkerKortOok' },
'rating': 2603,
'gameId': 'hTJ4v7Mp',
'color': 'black',
},
'racingKings':
{
'user': { 'id': 'chesslo21', 'name': 'chesslo21' },
'rating': 2123,
'gameId': 'lgCDl5Of',
'color': 'white',
},
'ultraBullet':
{
'user': { 'id': 'farmville', 'name': 'Farmville' },
'rating': 2338,
'gameId': 'NEY6OQ32',
'color': 'white',
},
'bullet':
{
'user': { 'id': 'nurmibrah', 'name': 'nurmiBrah' },
'rating': 2499,
'gameId': '5LgyE516',
'color': 'black',
},
'classical':
{
'user': { 'id': 'holden_m_j_thomas', 'name': 'Holden_M_J_Thomas' },
'rating': 1806,
'gameId': 'k3oLby6N',
'color': 'white',
},
'threeCheck':
{
'user': { 'id': 'pepellou', 'name': 'pepellou', 'patron': true },
'rating': 1978,
'gameId': 'Og5RCvmu',
'color': 'black',
},
'antichess':
{
'user': { 'id': 'maria-bakkar', 'name': 'maria-bakkar' },
'rating': 2103,
'gameId': 'toCr41yx',
'color': 'black',
},
'computer':
{
'user': { 'id': 'oh_my_goat_im_so_bat', 'name': 'oh_my_goat_Im_so_bat' },
'rating': 2314,
'gameId': 'TkI4qZxu',
'color': 'black',
},
'horde':
{
'user': { 'id': 'habitualchess', 'name': 'HabitualChess' },
'rating': 1803,
'gameId': 'oMofN63H',
'color': 'white',
},
'rapid':
{
'user': { 'id': 'denpayd', 'name': 'DenpaYD' },
'rating': 2289,
'gameId': 'IcWOl8ee',
'color': 'white',
},
'atomic':
{
'user': { 'id': 'meetyourdemise', 'name': 'MeetYourDemise' },
'rating': 2210,
'gameId': 'tvMxtCMN',
'color': 'white',
},
'crazyhouse':
{
'user': { 'id': 'mathace', 'name': 'mathace' },
'rating': 2397,
'gameId': 'i3gTZlUb',
'color': 'black',
},
'chess960':
{
'user': { 'id': 'voja_7', 'name': 'voja_7' },
'rating': 1782,
'gameId': 'lrXLcedu',
'color': 'white',
},
'kingOfTheHill':
{
'user': { 'id': 'nadime', 'name': 'Nadime' },
'rating': 1500,
'gameId': 'DsQn8aEV',
'color': 'white',
},
'best':
{
'user': { 'id': 'lekkerkortook', 'name': 'LekkerKortOok' },
'rating': 2603,
'gameId': 'hTJ4v7Mp',
'color': 'black',
},
}
}
Loading