This is a standalone TypeScript library for accepting playtak.com API inputs and tournament information, and outputting tournament status.
The goal of this prototype is to generate code that could be used in other backends/frontends for Tak, and ultimately reduce the work required to run tournaments.
> npm run start -- --tournament doc/example-tournament-group-stage.json --gamesApiResponse doc/example-api-response-pretty.json
> npm run start -- --tournament doc/example-tournament-group-stage.json --gamesApiUrl 'https://api.playtak.com/v1/games-history?page=0&limit=100&type=Tournament&mirror=true'
> npm run start -- --tournament doc/example-tournament-group-stage.json --gamesApiResponse doc/example-api-response-pretty.json --outputFormat json > tournament-status-output.json
# Running against a real tournament, and providing players from a CSV file
> npm run start -- --tournament data/2024-11-16-intermediate-tournament.tournamentInfo.json --playersCsv data/2024-11-16-intermediate-tournament.players.csv --gamesApiUrl 'https://api.playtak.com/v1/games-history?page=0&limit=400&type=Tournament&mirror=true'
- Clone the repository
- Install the Node 22, as per the version defined in
.nvmrc
(e.g. vianvm
orfnm
). - Run
npm install
- Run
npm test
to run the tests, ornpm test:watch
during development iterations. - Run
npm run dev:all_checks
on code changes before committing.
When types are changed, rerun npm run dev:recreate_auto_guard
to update the guard files.