From f7cd3864b0d054c31b71817cf4dff6c30337cb86 Mon Sep 17 00:00:00 2001 From: Elisey Mironov Date: Sat, 12 Jul 2025 12:46:13 +0300 Subject: [PATCH 1/8] Create endpoints.md --- endpoints.md | 93 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 endpoints.md diff --git a/endpoints.md b/endpoints.md new file mode 100644 index 0000000..f7d1a03 --- /dev/null +++ b/endpoints.md @@ -0,0 +1,93 @@ +GET /api/v1/tournir/list/{id} - Получить список турниров, на которые зарегистрирован участник по id участника + +id: String +title: String? +description: String? +sport: String? +typeTournament: String? +typeGroup: String? +matchesNumbers: Int? +startTime: String? +createdAt: String? +entryCost: Double? +maxParticipants: Int? +registrationDeadline: String? +place: String? +organizedId: String? +tournirInstantState: String + +POST /api/v1/tournir/{id} - Отправить информацию о турнире по его id при изменении состояния турнира + +id: String +title: String? +description: String? +sport: String? +typeTournament: String? +typeGroup: String? +matchesNumbers: Int? +startTime: String? +createdAt: String? +entryCost: Double? +maxParticipants: Int? +registrationDeadline: String? +place: String? +organizedId: String? +tournirInstantState: String + +GET /api/v1/MatchStats/{id} - Получить статистику матчей по id турнира + +tournamentID: String +sport: String? +timePlayed: Double? +goals: Int? +assists: Int? +fouls: Int? +points: Int? +knockdowns: Int? +setsWon: Int? +yellowCards: Int? +pauses: Int? +winnerID: String? + +POST /api/v1/MatchStats/{id} - Отправить статистику матчей по id турнира + +tournamentID: String (по нему ищите список участников турнира) +sport: String? +timePlayed: Double? +goals: Int? +assists: Int? +fouls: Int? +points: Int? +knockdowns: Int? +setsWon: Int? +yellowCards: Int? +pauses: Int? +wins: Int? +loses: Int? +winnerID: String? + +GET /api/v1/user/stat/{id} - Получить общую статистику пользователя по его id +sport: String? +wins: Int? +loses: Int? +matches: Int? +bigWins: Int? +winrate: Int? (число 0-100) + +GET /api/v1/tournir/set/{id(tournir)} – получение списка пар людей, которые будут соревноваться +id: String +title: String? +description: String? +sport: String? +typeTournament: String? +typeGroup: String? +matchesNumbers: Int? +startTime: String? +createdAt: String? +entryCost: Double? +maxParticipants: Int? +registrationDeadline: String? +place: String? +organizedId: String? +tournirInstantState: String + From d15ebca40b1881154ccf6a63a087d95a3ae72816 Mon Sep 17 00:00:00 2001 From: Elisey Mironov Date: Sat, 12 Jul 2025 12:46:51 +0300 Subject: [PATCH 2/8] Rename endpoints.md to endpoints.txt --- endpoints.md => endpoints.txt | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename endpoints.md => endpoints.txt (100%) diff --git a/endpoints.md b/endpoints.txt similarity index 100% rename from endpoints.md rename to endpoints.txt From b4166264abfa10cb85f6f8f68e7a9c48447571cd Mon Sep 17 00:00:00 2001 From: Elisey Mironov Date: Sat, 12 Jul 2025 12:56:12 +0300 Subject: [PATCH 3/8] Update endpoints.txt --- endpoints.txt | 52 ++++++++++++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 21 deletions(-) diff --git a/endpoints.txt b/endpoints.txt index f7d1a03..7d452ec 100644 --- a/endpoints.txt +++ b/endpoints.txt @@ -1,5 +1,6 @@ GET /api/v1/tournir/list/{id} - Получить список турниров, на которые зарегистрирован участник по id участника + id: String title: String? description: String? @@ -16,8 +17,10 @@ place: String? organizedId: String? tournirInstantState: String + POST /api/v1/tournir/{id} - Отправить информацию о турнире по его id при изменении состояния турнира + id: String title: String? description: String? @@ -34,38 +37,45 @@ place: String? organizedId: String? tournirInstantState: String + GET /api/v1/MatchStats/{id} - Получить статистику матчей по id турнира + tournamentID: String sport: String? -timePlayed: Double? -goals: Int? -assists: Int? -fouls: Int? -points: Int? -knockdowns: Int? -setsWon: Int? -yellowCards: Int? -pauses: Int? +timePlayed: [String: Double]? (String - UserID, Double - значение) +goals: [String: Int]? +assists: [String: Int]? +fouls: [String: Int]? +points: [String: Int]? +knockdowns: [String: Int]? +setsWon: [String: Int]? +yellowCards: [String: Int]? +pauses: [String: Int]? +wins: [String: Int]? +loses: [String: Int]? winnerID: String? + POST /api/v1/MatchStats/{id} - Отправить статистику матчей по id турнира -tournamentID: String (по нему ищите список участников турнира) + +tournamentID: String sport: String? -timePlayed: Double? -goals: Int? -assists: Int? -fouls: Int? -points: Int? -knockdowns: Int? -setsWon: Int? -yellowCards: Int? -pauses: Int? -wins: Int? -loses: Int? +timePlayed: [String: Double]? (String - UserID, Double - значение) +goals: [String: Int]? +assists: [String: Int]? +fouls: [String: Int]? +points: [String: Int]? +knockdowns: [String: Int]? +setsWon: [String: Int]? +yellowCards: [String: Int]? +pauses: [String: Int]? +wins: [String: Int]? +loses: [String: Int]? winnerID: String? + GET /api/v1/user/stat/{id} - Получить общую статистику пользователя по его id sport: String? wins: Int? From 5397b4b95c41aff1f599442ca482a74817bc7c3e Mon Sep 17 00:00:00 2001 From: alexander-gileta Date: Sat, 12 Jul 2025 14:56:26 +0300 Subject: [PATCH 4/8] Update endpoints.txt --- endpoints.txt | 3 --- 1 file changed, 3 deletions(-) diff --git a/endpoints.txt b/endpoints.txt index 7d452ec..448bae8 100644 --- a/endpoints.txt +++ b/endpoints.txt @@ -51,7 +51,6 @@ points: [String: Int]? knockdowns: [String: Int]? setsWon: [String: Int]? yellowCards: [String: Int]? -pauses: [String: Int]? wins: [String: Int]? loses: [String: Int]? winnerID: String? @@ -70,7 +69,6 @@ points: [String: Int]? knockdowns: [String: Int]? setsWon: [String: Int]? yellowCards: [String: Int]? -pauses: [String: Int]? wins: [String: Int]? loses: [String: Int]? winnerID: String? @@ -100,4 +98,3 @@ registrationDeadline: String? place: String? organizedId: String? tournirInstantState: String - From 187f8035757792141302ac25022e0bfeff6a6afe Mon Sep 17 00:00:00 2001 From: alexander-gileta Date: Sat, 12 Jul 2025 15:01:30 +0300 Subject: [PATCH 5/8] Create endpoints_edited.txt --- endpoints_edited.txt | 134 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100644 endpoints_edited.txt diff --git a/endpoints_edited.txt b/endpoints_edited.txt new file mode 100644 index 0000000..036872a --- /dev/null +++ b/endpoints_edited.txt @@ -0,0 +1,134 @@ +{ + "GET /api/v1/tournir/list/{id}": { + "description": "Получить список турниров, на которые зарегистрирован участник по id участника", + "params": { + "id": "String" + }, + "response": [ + { + "id": "String", + "title": "String?", + "description": "String?", + "sport": "String?", + "typeTournament": "String?", + "typeGroup": "String?", + "matchesNumbers": "Int?", + "startTime": "String?", + "createdAt": "String?", + "entryCost": "Double?", + "maxParticipants": "Int?", + "registrationDeadline": "String?", + "place": "String?", + "organizedId": "String?", + "tournirInstantState": "String" + } + ] + }, + + "POST /api/v1/tournir/{id}": { + "description": "Отправить информацию о турнире по его id при изменении состояния турнира", + "params": { + "id": "String" + }, + "body": { + "id": "String", + "title": "String?", + "description": "String?", + "sport": "String?", + "typeTournament": "String?", + "typeGroup": "String?", + "matchesNumbers": "Int?", + "startTime": "String?", + "createdAt": "String?", + "entryCost": "Double?", + "maxParticipants": "Int?", + "registrationDeadline": "String?", + "place": "String?", + "organizedId": "String?", + "tournirInstantState": "String" + } + }, + + "GET /api/v1/MatchStats/{id}": { + "description": "Получить статистику матчей по id турнира", + "params": { + "id": "String" + }, + "response": { + "tournamentID": "String", + "sport": "String?", + "timePlayed": { "String": "Double" }, + "goals": { "String": "Int" }, + "assists": { "String": "Int" }, + "fouls": { "String": "Int" }, + "points": { "String": "Int" }, + "knockdowns": { "String": "Int" }, + "setsWon": { "String": "Int" }, + "yellowCards": { "String": "Int" }, + "wins": { "String": "Int" }, + "loses": { "String": "Int" }, + "winnerID": "String?" + } + }, + + "POST /api/v1/MatchStats/{id}": { + "description": "Отправить статистику матчей по id турнира", + "params": { + "id": "String" + }, + "body": { + "tournamentID": "String", + "sport": "String?", + "timePlayed": { "String": "Double" }, + "goals": { "String": "Int" }, + "assists": { "String": "Int" }, + "fouls": { "String": "Int" }, + "points": { "String": "Int" }, + "knockdowns": { "String": "Int" }, + "setsWon": { "String": "Int" }, + "yellowCards": { "String": "Int" }, + "wins": { "String": "Int" }, + "loses": { "String": "Int" }, + "winnerID": "String?" + } + }, + + "GET /api/v1/user/stat/{id}": { + "description": "Получить общую статистику пользователя по его id", + "params": { + "id": "String" + }, + "response": { + "sport": "String?", + "wins": "Int?", + "loses": "Int?", + "matches": "Int?", + "bigWins": "Int?", + "winrate": "Int?" // число 0-100 + } + }, + + "GET /api/v1/tournir/set/{id}": { + "description": "Получение списка пар людей, которые будут соревноваться", + "params": { + "id": "String" // tournir id + }, + "response": { + "id": "String", + "title": "String?", + "description": "String?", + "sport": "String?", + "typeTournament": "String?", + "typeGroup": "String?", + "matchesNumbers": "Int?", + "startTime": "String?", + "createdAt": "String?", + "entryCost": "Double?", + "maxParticipants": "Int?", + "registrationDeadline": "String?", + "place": "String?", + "organizedId": "String?", + "tournirInstantState": "String" + } + } +} From ea31ffa968821012c038e3ae9b10f1fe72b08354 Mon Sep 17 00:00:00 2001 From: alexander-gileta Date: Sat, 12 Jul 2025 15:30:35 +0300 Subject: [PATCH 6/8] Update endpoints_edited.txt --- endpoints_edited.txt | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/endpoints_edited.txt b/endpoints_edited.txt index 036872a..ffb0664 100644 --- a/endpoints_edited.txt +++ b/endpoints_edited.txt @@ -57,16 +57,16 @@ "response": { "tournamentID": "String", "sport": "String?", - "timePlayed": { "String": "Double" }, - "goals": { "String": "Int" }, - "assists": { "String": "Int" }, - "fouls": { "String": "Int" }, - "points": { "String": "Int" }, - "knockdowns": { "String": "Int" }, - "setsWon": { "String": "Int" }, - "yellowCards": { "String": "Int" }, - "wins": { "String": "Int" }, - "loses": { "String": "Int" }, + "timePlayed": "hashmap{"String": "Double"}", + "goals": "hashmap{"String": "Int"}", + "assists": "hashmap{"String": "Int"}", + "fouls": "hashmap{"String": "Int"}", + "points": "hashmap{"String": "Int"}", + "knockdowns": "hashmap{"String": "Int"}", + "setsWon": "hashmap{"String": "Int"}", + "yellowCards": "hashmap{"String": "Int"}", + "wins": "hashmap{"String": "Int"}", + "loses": "hashmap{"String": "Int"}", "winnerID": "String?" } }, @@ -79,16 +79,16 @@ "body": { "tournamentID": "String", "sport": "String?", - "timePlayed": { "String": "Double" }, - "goals": { "String": "Int" }, - "assists": { "String": "Int" }, - "fouls": { "String": "Int" }, - "points": { "String": "Int" }, - "knockdowns": { "String": "Int" }, - "setsWon": { "String": "Int" }, - "yellowCards": { "String": "Int" }, - "wins": { "String": "Int" }, - "loses": { "String": "Int" }, + "timePlayed": "hashmap{"String": "Double"}", + "goals": "hashmap{"String": "Int"}", + "assists": "hashmap{"String": "Int"}", + "fouls": "hashmap{"String": "Int"}", + "points": "hashmap{"String": "Int"}", + "knockdowns": "hashmap{"String": "Int"}", + "setsWon": "hashmap{"String": "Int"}", + "yellowCards": "hashmap{"String": "Int"}", + "wins": "hashmap{"String": "Int"}", + "loses": "hashmap{"String": "Int"}", "winnerID": "String?" } }, @@ -111,7 +111,7 @@ "GET /api/v1/tournir/set/{id}": { "description": "Получение списка пар людей, которые будут соревноваться", "params": { - "id": "String" // tournir id + "id": "String" }, "response": { "id": "String", From 5b9c6875090f3c5816a0e4a99f877bd90116c1e9 Mon Sep 17 00:00:00 2001 From: exresai <159822044+exresai@users.noreply.github.com> Date: Sat, 12 Jul 2025 17:25:25 +0300 Subject: [PATCH 7/8] Update endpoints_edited.txt --- endpoints_edited.txt | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/endpoints_edited.txt b/endpoints_edited.txt index ffb0664..862d0d9 100644 --- a/endpoints_edited.txt +++ b/endpoints_edited.txt @@ -114,21 +114,8 @@ "id": "String" }, "response": { - "id": "String", - "title": "String?", - "description": "String?", - "sport": "String?", - "typeTournament": "String?", - "typeGroup": "String?", - "matchesNumbers": "Int?", - "startTime": "String?", - "createdAt": "String?", - "entryCost": "Double?", - "maxParticipants": "Int?", - "registrationDeadline": "String?", - "place": "String?", - "organizedId": "String?", - "tournirInstantState": "String" + "first": "User" //User это (id, name, surname, patronymic, phoneNumber, email, hashedPassword, dateOfBirth, age, sex, weight, height, createdAt, bio, avatarUrl, admin) + "second": "User" } } } From 53dacc52cd6481d5c6856c82a13e02e8a9b0b6c9 Mon Sep 17 00:00:00 2001 From: exresai <159822044+exresai@users.noreply.github.com> Date: Sat, 12 Jul 2025 20:13:26 +0300 Subject: [PATCH 8/8] Update endpoints_edited.txt --- endpoints_edited.txt | 67 ++++++++++++++++++-------------------------- 1 file changed, 28 insertions(+), 39 deletions(-) diff --git a/endpoints_edited.txt b/endpoints_edited.txt index 862d0d9..c277bfe 100644 --- a/endpoints_edited.txt +++ b/endpoints_edited.txt @@ -50,46 +50,48 @@ }, "GET /api/v1/MatchStats/{id}": { - "description": "Получить статистику матчей по id турнира", + "description": "Получить список матчей с их статистикой по id турнира", "params": { "id": "String" }, "response": { "tournamentID": "String", + "matchID": "String" + "first": "User" // User - (id, nme, surname, patronymic, phoneNumber, email, hashedPassword, dateOfBirth, age, sex, weight, height, creatdAt, bio, avatarUrl, admin) + "second": "User" "sport": "String?", - "timePlayed": "hashmap{"String": "Double"}", - "goals": "hashmap{"String": "Int"}", - "assists": "hashmap{"String": "Int"}", - "fouls": "hashmap{"String": "Int"}", - "points": "hashmap{"String": "Int"}", - "knockdowns": "hashmap{"String": "Int"}", - "setsWon": "hashmap{"String": "Int"}", - "yellowCards": "hashmap{"String": "Int"}", - "wins": "hashmap{"String": "Int"}", - "loses": "hashmap{"String": "Int"}", - "winnerID": "String?" + "timePlayed": "Int?", + "goals": "(Int, Int)?", // список из двух интов + "assists": "(Int, Int)?", + "fouls": "(Int, Int)?", + "points": "(Int, Int)?", + "knockdowns": "(Int, Int)?", + "setsWon": "(Int, Int)?", + "yellowCards": "(Int, Int)?", + "isFirstWinner": "Bool?" // nil - не сыграли, true - победил первый, false - победил второй } }, "POST /api/v1/MatchStats/{id}": { - "description": "Отправить статистику матчей по id турнира", + "description": "Отправить список со статистикой матчей по id турнира", "params": { "id": "String" }, "body": { "tournamentID": "String", + "matchID": "String" + "first": "User" // User - (id, nme, surname, patronymic, phoneNumber, email, hashedPassword, dateOfBirth, age, sex, weight, height, creatdAt, bio, avatarUrl, admin) + "second": "User" "sport": "String?", - "timePlayed": "hashmap{"String": "Double"}", - "goals": "hashmap{"String": "Int"}", - "assists": "hashmap{"String": "Int"}", - "fouls": "hashmap{"String": "Int"}", - "points": "hashmap{"String": "Int"}", - "knockdowns": "hashmap{"String": "Int"}", - "setsWon": "hashmap{"String": "Int"}", - "yellowCards": "hashmap{"String": "Int"}", - "wins": "hashmap{"String": "Int"}", - "loses": "hashmap{"String": "Int"}", - "winnerID": "String?" + "timePlayed": "Int?", + "goals": "(Int, Int)?", //список из двух интов + "assists": "(Int, Int)?", + "fouls": "(Int, Int)?", + "points": "(Int, Int)?", + "knockdowns": "(Int, Int)?", + "setsWon": "(Int, Int)?", + "yellowCards": "(Int, Int)?", + "isFirstWinner": "Bool?" // nil - не сыграли, true - победил первый, false - победил второй } }, @@ -100,22 +102,9 @@ }, "response": { "sport": "String?", - "wins": "Int?", - "loses": "Int?", - "matches": "Int?", - "bigWins": "Int?", + "totalWins": "Int?", + "totalLoses": "Int?", "winrate": "Int?" // число 0-100 } - }, - - "GET /api/v1/tournir/set/{id}": { - "description": "Получение списка пар людей, которые будут соревноваться", - "params": { - "id": "String" - }, - "response": { - "first": "User" //User это (id, name, surname, patronymic, phoneNumber, email, hashedPassword, dateOfBirth, age, sex, weight, height, createdAt, bio, avatarUrl, admin) - "second": "User" - } } }