From ec3df312be6393353de99bf410ecfad3ecf54c44 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 29 Dec 2020 13:35:32 +0000 Subject: [PATCH] new lib version [CI SKIP] --- dist/core/OpenAPI.js | 2 +- dist/index.d.ts | 4 ++ dist/models/CreateResetToken.d.ts | 4 ++ dist/models/CreateResetToken.js | 5 +++ dist/models/CreateUser.d.ts | 1 + dist/models/ResetAlreadyRequestedError.d.ts | 4 ++ dist/models/ResetAlreadyRequestedError.js | 5 +++ dist/models/ResetPassword.d.ts | 4 ++ dist/models/ResetPassword.js | 5 +++ dist/models/User.d.ts | 1 + dist/models/UserDisabledError.d.ts | 4 ++ dist/models/UserDisabledError.js | 5 +++ dist/services/AuthService.d.ts | 29 ++++++++++++-- dist/services/AuthService.js | 41 ++++++++++++++++++-- dist/services/ImportService.d.ts | 8 ++-- dist/services/ImportService.js | 8 ++-- dist/services/PermissionService.d.ts | 10 ++--- dist/services/PermissionService.js | 10 ++--- dist/services/RunnerOrganisationService.d.ts | 10 ++--- dist/services/RunnerOrganisationService.js | 10 ++--- dist/services/RunnerService.d.ts | 10 ++--- dist/services/RunnerService.js | 10 ++--- dist/services/RunnerTeamService.d.ts | 10 ++--- dist/services/RunnerTeamService.js | 10 ++--- dist/services/StatusService.d.ts | 2 +- dist/services/StatusService.js | 2 +- dist/services/TrackService.d.ts | 9 +++-- dist/services/TrackService.js | 9 +++-- dist/services/UserGroupService.d.ts | 10 ++--- dist/services/UserGroupService.js | 10 ++--- dist/services/UserService.d.ts | 10 ++--- dist/services/UserService.js | 10 ++--- openapi.json | 2 +- 33 files changed, 188 insertions(+), 86 deletions(-) create mode 100644 dist/models/CreateResetToken.d.ts create mode 100644 dist/models/CreateResetToken.js create mode 100644 dist/models/ResetAlreadyRequestedError.d.ts create mode 100644 dist/models/ResetAlreadyRequestedError.js create mode 100644 dist/models/ResetPassword.d.ts create mode 100644 dist/models/ResetPassword.js create mode 100644 dist/models/UserDisabledError.d.ts create mode 100644 dist/models/UserDisabledError.js diff --git a/dist/core/OpenAPI.js b/dist/core/OpenAPI.js index 0aa61d8..b24e695 100644 --- a/dist/core/OpenAPI.js +++ b/dist/core/OpenAPI.js @@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true }); exports.OpenAPI = void 0; exports.OpenAPI = { BASE: '', - VERSION: '1.0.0', + VERSION: '0.0.5', WITH_CREDENTIALS: false, TOKEN: undefined, USERNAME: undefined, diff --git a/dist/index.d.ts b/dist/index.d.ts index b885aa2..3dfb0a8 100644 --- a/dist/index.d.ts +++ b/dist/index.d.ts @@ -7,6 +7,7 @@ export type { Auth } from './models/Auth'; export type { CreateAuth } from './models/CreateAuth'; export type { CreateParticipant } from './models/CreateParticipant'; export { CreatePermission } from './models/CreatePermission'; +export type { CreateResetToken } from './models/CreateResetToken'; export type { CreateRunner } from './models/CreateRunner'; export type { CreateRunnerGroup } from './models/CreateRunnerGroup'; export type { CreateRunnerOrganisation } from './models/CreateRunnerOrganisation'; @@ -39,6 +40,8 @@ export type { PrincipalNotFoundError } from './models/PrincipalNotFoundError'; export type { PrincipalWrongTypeError } from './models/PrincipalWrongTypeError'; export type { RefreshAuth } from './models/RefreshAuth'; export type { RefreshTokenCountInvalidError } from './models/RefreshTokenCountInvalidError'; +export type { ResetAlreadyRequestedError } from './models/ResetAlreadyRequestedError'; +export type { ResetPassword } from './models/ResetPassword'; export type { ResponseEmpty } from './models/ResponseEmpty'; export type { ResponseParticipant } from './models/ResponseParticipant'; export { ResponsePermission } from './models/ResponsePermission'; @@ -81,6 +84,7 @@ export type { UpdateRunnerTeam } from './models/UpdateRunnerTeam'; export type { UpdateUser } from './models/UpdateUser'; export type { User } from './models/User'; export { UserAction } from './models/UserAction'; +export type { UserDisabledError } from './models/UserDisabledError'; export type { UserGroup } from './models/UserGroup'; export type { UserGroupIdsNotMatchingError } from './models/UserGroupIdsNotMatchingError'; export type { UserGroupNotFoundError } from './models/UserGroupNotFoundError'; diff --git a/dist/models/CreateResetToken.d.ts b/dist/models/CreateResetToken.d.ts new file mode 100644 index 0000000..364041f --- /dev/null +++ b/dist/models/CreateResetToken.d.ts @@ -0,0 +1,4 @@ +export declare type CreateResetToken = { + username?: string; + email?: string; +}; diff --git a/dist/models/CreateResetToken.js b/dist/models/CreateResetToken.js new file mode 100644 index 0000000..1e550d8 --- /dev/null +++ b/dist/models/CreateResetToken.js @@ -0,0 +1,5 @@ +"use strict"; +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/models/CreateUser.d.ts b/dist/models/CreateUser.d.ts index 52ff72a..d557e4c 100644 --- a/dist/models/CreateUser.d.ts +++ b/dist/models/CreateUser.d.ts @@ -6,5 +6,6 @@ export declare type CreateUser = { email?: string; phone?: string; password: string; + enabled?: boolean; groups?: any; }; diff --git a/dist/models/ResetAlreadyRequestedError.d.ts b/dist/models/ResetAlreadyRequestedError.d.ts new file mode 100644 index 0000000..1487dc9 --- /dev/null +++ b/dist/models/ResetAlreadyRequestedError.d.ts @@ -0,0 +1,4 @@ +export declare type ResetAlreadyRequestedError = { + name: string; + message: string; +}; diff --git a/dist/models/ResetAlreadyRequestedError.js b/dist/models/ResetAlreadyRequestedError.js new file mode 100644 index 0000000..1e550d8 --- /dev/null +++ b/dist/models/ResetAlreadyRequestedError.js @@ -0,0 +1,5 @@ +"use strict"; +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/models/ResetPassword.d.ts b/dist/models/ResetPassword.d.ts new file mode 100644 index 0000000..759fc99 --- /dev/null +++ b/dist/models/ResetPassword.d.ts @@ -0,0 +1,4 @@ +export declare type ResetPassword = { + resetToken?: string; + password: string; +}; diff --git a/dist/models/ResetPassword.js b/dist/models/ResetPassword.js new file mode 100644 index 0000000..1e550d8 --- /dev/null +++ b/dist/models/ResetPassword.js @@ -0,0 +1,5 @@ +"use strict"; +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/models/User.d.ts b/dist/models/User.d.ts index d1f4cc9..e5125bc 100644 --- a/dist/models/User.d.ts +++ b/dist/models/User.d.ts @@ -11,6 +11,7 @@ export declare type User = { enabled: boolean; refreshTokenCount: number; profilePic?: string; + resetRequestedTimestamp?: string; actions?: any; id: number; }; diff --git a/dist/models/UserDisabledError.d.ts b/dist/models/UserDisabledError.d.ts new file mode 100644 index 0000000..d3c8467 --- /dev/null +++ b/dist/models/UserDisabledError.d.ts @@ -0,0 +1,4 @@ +export declare type UserDisabledError = { + name: string; + message: string; +}; diff --git a/dist/models/UserDisabledError.js b/dist/models/UserDisabledError.js new file mode 100644 index 0000000..1e550d8 --- /dev/null +++ b/dist/models/UserDisabledError.js @@ -0,0 +1,5 @@ +"use strict"; +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ +Object.defineProperty(exports, "__esModule", { value: true }); diff --git a/dist/services/AuthService.d.ts b/dist/services/AuthService.d.ts index 54bb1aa..fd37314 100644 --- a/dist/services/AuthService.d.ts +++ b/dist/services/AuthService.d.ts @@ -1,5 +1,6 @@ import type { Auth } from '../models/Auth'; import type { CreateAuth } from '../models/CreateAuth'; +import type { CreateResetToken } from '../models/CreateResetToken'; import type { HandleLogout } from '../models/HandleLogout'; import type { IllegalJWTError } from '../models/IllegalJWTError'; import type { InvalidCredentialsError } from '../models/InvalidCredentialsError'; @@ -8,12 +9,15 @@ import type { Logout } from '../models/Logout'; import type { PasswordNeededError } from '../models/PasswordNeededError'; import type { RefreshAuth } from '../models/RefreshAuth'; import type { RefreshTokenCountInvalidError } from '../models/RefreshTokenCountInvalidError'; +import type { ResetPassword } from '../models/ResetPassword'; import type { UsernameOrEmailNeededError } from '../models/UsernameOrEmailNeededError'; import type { UserNotFoundError } from '../models/UserNotFoundError'; export declare class AuthService { /** * Login - * Create a new access token object + * Login with your username/email and password.
You will receive: + * * access token (use it as a bearer token) + * * refresh token (will also be sent as a cookie) * @param requestBody CreateAuth * @returns any * @throws ApiError @@ -21,7 +25,7 @@ export declare class AuthService { static authControllerLogin(requestBody?: CreateAuth): Promise<(Auth | InvalidCredentialsError | UserNotFoundError | UsernameOrEmailNeededError | PasswordNeededError)>; /** * Logout - * Create a new access token object + * Logout using your refresh token.
This instantly invalidates all your access and refresh tokens. * @param requestBody HandleLogout * @returns any * @throws ApiError @@ -29,10 +33,29 @@ export declare class AuthService { static authControllerLogout(requestBody?: HandleLogout): Promise<(Logout | InvalidCredentialsError | UserNotFoundError | UsernameOrEmailNeededError | PasswordNeededError)>; /** * Refresh - * refresh a access token + * Refresh your access and refresh tokens using a valid refresh token.
You will receive: + * * access token (use it as a bearer token) + * * refresh token (will also be sent as a cookie) * @param requestBody RefreshAuth * @returns any * @throws ApiError */ static authControllerRefresh(requestBody?: RefreshAuth): Promise<(Auth | JwtNotProvidedError | IllegalJWTError | UserNotFoundError | RefreshTokenCountInvalidError)>; + /** + * Get reset token + * Request a password reset token.
This will provide you with a reset token that you can use by posting to /api/auth/reset/{token}. + * @param requestBody CreateResetToken + * @returns any + * @throws ApiError + */ + static authControllerGetResetToken(requestBody?: CreateResetToken): Promise<(Auth | UserNotFoundError | UsernameOrEmailNeededError)>; + /** + * Reset password + * Reset a user's utilising a valid password reset token.
This will set the user's password to the one you provided in the body.
To get a reset token post to /api/auth/reset with your username. + * @param token + * @param requestBody ResetPassword + * @returns any + * @throws ApiError + */ + static authControllerResetPassword(token: string, requestBody?: ResetPassword): Promise<(Auth | UserNotFoundError | UsernameOrEmailNeededError)>; } diff --git a/dist/services/AuthService.js b/dist/services/AuthService.js index 521387c..55fe198 100644 --- a/dist/services/AuthService.js +++ b/dist/services/AuthService.js @@ -5,7 +5,9 @@ const request_1 = require("../core/request"); class AuthService { /** * Login - * Create a new access token object + * Login with your username/email and password.
You will receive: + * * access token (use it as a bearer token) + * * refresh token (will also be sent as a cookie) * @param requestBody CreateAuth * @returns any * @throws ApiError @@ -20,7 +22,7 @@ class AuthService { } /** * Logout - * Create a new access token object + * Logout using your refresh token.
This instantly invalidates all your access and refresh tokens. * @param requestBody HandleLogout * @returns any * @throws ApiError @@ -35,7 +37,9 @@ class AuthService { } /** * Refresh - * refresh a access token + * Refresh your access and refresh tokens using a valid refresh token.
You will receive: + * * access token (use it as a bearer token) + * * refresh token (will also be sent as a cookie) * @param requestBody RefreshAuth * @returns any * @throws ApiError @@ -48,5 +52,36 @@ class AuthService { }); return result.body; } + /** + * Get reset token + * Request a password reset token.
This will provide you with a reset token that you can use by posting to /api/auth/reset/{token}. + * @param requestBody CreateResetToken + * @returns any + * @throws ApiError + */ + static async authControllerGetResetToken(requestBody) { + const result = await request_1.request({ + method: 'POST', + path: `/api/auth/reset`, + body: requestBody, + }); + return result.body; + } + /** + * Reset password + * Reset a user's utilising a valid password reset token.
This will set the user's password to the one you provided in the body.
To get a reset token post to /api/auth/reset with your username. + * @param token + * @param requestBody ResetPassword + * @returns any + * @throws ApiError + */ + static async authControllerResetPassword(token, requestBody) { + const result = await request_1.request({ + method: 'POST', + path: `/api/auth/reset/${token}`, + body: requestBody, + }); + return result.body; + } } exports.AuthService = AuthService; diff --git a/dist/services/ImportService.d.ts b/dist/services/ImportService.d.ts index 6888927..3977284 100644 --- a/dist/services/ImportService.d.ts +++ b/dist/services/ImportService.d.ts @@ -3,7 +3,7 @@ import type { ResponseRunner } from '../models/ResponseRunner'; export declare class ImportService { /** * Post json - * Create new runners from json and insert them (or their teams) into the provided group + * Create new runners from json and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param group * @param requestBody ImportRunner * @returns ResponseRunner @@ -12,7 +12,7 @@ export declare class ImportService { static importControllerPostJson(group?: number, requestBody?: Array): Promise>; /** * Post orgs json - * Create new runners from json and insert them (or their teams) into the provided org + * Create new runners from json and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param id * @param requestBody ImportRunner * @returns ResponseRunner @@ -30,7 +30,7 @@ export declare class ImportService { static importControllerPostTeamsJson(id: number, requestBody?: Array): Promise>; /** * Post csv - * Create new runners from csv and insert them (or their teams) into the provided group + * Create new runners from csv and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param group * @returns ResponseRunner * @throws ApiError @@ -38,7 +38,7 @@ export declare class ImportService { static importControllerPostCsv(group?: number): Promise>; /** * Post orgs csv - * Create new runners from csv and insert them (or their teams) into the provided org + * Create new runners from csv and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param id * @returns ResponseRunner * @throws ApiError diff --git a/dist/services/ImportService.js b/dist/services/ImportService.js index 533d031..7f22adc 100644 --- a/dist/services/ImportService.js +++ b/dist/services/ImportService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class ImportService { /** * Post json - * Create new runners from json and insert them (or their teams) into the provided group + * Create new runners from json and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param group * @param requestBody ImportRunner * @returns ResponseRunner @@ -24,7 +24,7 @@ class ImportService { } /** * Post orgs json - * Create new runners from json and insert them (or their teams) into the provided org + * Create new runners from json and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param id * @param requestBody ImportRunner * @returns ResponseRunner @@ -56,7 +56,7 @@ class ImportService { } /** * Post csv - * Create new runners from csv and insert them (or their teams) into the provided group + * Create new runners from csv and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param group * @returns ResponseRunner * @throws ApiError @@ -73,7 +73,7 @@ class ImportService { } /** * Post orgs csv - * Create new runners from csv and insert them (or their teams) into the provided org + * Create new runners from csv and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead. * @param id * @returns ResponseRunner * @throws ApiError diff --git a/dist/services/PermissionService.d.ts b/dist/services/PermissionService.d.ts index 6f40f86..3092e86 100644 --- a/dist/services/PermissionService.d.ts +++ b/dist/services/PermissionService.d.ts @@ -6,14 +6,14 @@ import type { UpdatePermission } from '../models/UpdatePermission'; export declare class PermissionService { /** * Get all - * Lists all permissions. + * Lists all permissions for all users and groups. * @returns ResponsePermission * @throws ApiError */ static permissionControllerGetAll(): Promise>; /** * Post - * Create a new runnerTeam object (id will be generated automagicly). + * Create a new permission for a existing principal(user/group).
If a permission with this target, action and prinicpal already exists that permission will be returned instead of creating a new one. * @param requestBody CreatePermission * @returns ResponsePermission * @throws ApiError @@ -21,7 +21,7 @@ export declare class PermissionService { static permissionControllerPost(requestBody?: CreatePermission): Promise; /** * Get one - * Returns a permissions of a specified id (if it exists) + * Lists all information about the permission whose id got provided. * @param id * @returns ResponsePermission * @throws ApiError @@ -29,7 +29,7 @@ export declare class PermissionService { static permissionControllerGetOne(id: number): Promise; /** * Put - * Update a permission object (id can't be changed). + * Update a permission object.
If updateing the permission object would result in duplicate permission (same target, action and principal) this permission will get deleted and the existing permission will be returned.
Please remember that ids can't be changed. * @param id * @param requestBody UpdatePermission * @returns ResponsePrincipal @@ -38,7 +38,7 @@ export declare class PermissionService { static permissionControllerPut(id: number, requestBody?: UpdatePermission): Promise; /** * Remove - * Delete a specified permission (if it exists). + * Deletes the permission whose id you provide.
If no permission with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponsePermission diff --git a/dist/services/PermissionService.js b/dist/services/PermissionService.js index 8a47def..586f3bb 100644 --- a/dist/services/PermissionService.js +++ b/dist/services/PermissionService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class PermissionService { /** * Get all - * Lists all permissions. + * Lists all permissions for all users and groups. * @returns ResponsePermission * @throws ApiError */ @@ -18,7 +18,7 @@ class PermissionService { } /** * Post - * Create a new runnerTeam object (id will be generated automagicly). + * Create a new permission for a existing principal(user/group).
If a permission with this target, action and prinicpal already exists that permission will be returned instead of creating a new one. * @param requestBody CreatePermission * @returns ResponsePermission * @throws ApiError @@ -33,7 +33,7 @@ class PermissionService { } /** * Get one - * Returns a permissions of a specified id (if it exists) + * Lists all information about the permission whose id got provided. * @param id * @returns ResponsePermission * @throws ApiError @@ -47,7 +47,7 @@ class PermissionService { } /** * Put - * Update a permission object (id can't be changed). + * Update a permission object.
If updateing the permission object would result in duplicate permission (same target, action and principal) this permission will get deleted and the existing permission will be returned.
Please remember that ids can't be changed. * @param id * @param requestBody UpdatePermission * @returns ResponsePrincipal @@ -63,7 +63,7 @@ class PermissionService { } /** * Remove - * Delete a specified permission (if it exists). + * Deletes the permission whose id you provide.
If no permission with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponsePermission diff --git a/dist/services/RunnerOrganisationService.d.ts b/dist/services/RunnerOrganisationService.d.ts index 3e5f0cf..1a5015b 100644 --- a/dist/services/RunnerOrganisationService.d.ts +++ b/dist/services/RunnerOrganisationService.d.ts @@ -5,14 +5,14 @@ import type { UpdateRunnerOrganisation } from '../models/UpdateRunnerOrganisatio export declare class RunnerOrganisationService { /** * Get all - * Lists all runnerOrganisations. + * Lists all organisations.
This includes their address, contact and teams (if existing/associated). * @returns ResponseRunnerOrganisation * @throws ApiError */ static runnerOrganisationControllerGetAll(): Promise>; /** * Post - * Create a new runnerOrganisation object (id will be generated automagicly). + * Create a new organsisation. * @param requestBody CreateRunnerOrganisation * @returns ResponseRunnerOrganisation * @throws ApiError @@ -20,7 +20,7 @@ export declare class RunnerOrganisationService { static runnerOrganisationControllerPost(requestBody?: CreateRunnerOrganisation): Promise; /** * Get one - * Returns a runnerOrganisation of a specified id (if it exists) + * Lists all information about the organisation whose id got provided. * @param id * @returns ResponseRunnerOrganisation * @throws ApiError @@ -28,7 +28,7 @@ export declare class RunnerOrganisationService { static runnerOrganisationControllerGetOne(id: number): Promise; /** * Put - * Update a runnerOrganisation object (id can't be changed). + * Update the organisation whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunnerOrganisation * @returns ResponseRunnerOrganisation @@ -37,7 +37,7 @@ export declare class RunnerOrganisationService { static runnerOrganisationControllerPut(id: number, requestBody?: UpdateRunnerOrganisation): Promise; /** * Remove - * Delete a specified runnerOrganisation (if it exists). + * Delete the organsisation whose id you provided.
If the organisation still has runners and/or teams associated this will fail.
To delete the organisation with all associated runners and teams set the force QueryParam to true (cascading deletion might take a while).
If no organisation with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunnerOrganisation diff --git a/dist/services/RunnerOrganisationService.js b/dist/services/RunnerOrganisationService.js index 43334b0..9665579 100644 --- a/dist/services/RunnerOrganisationService.js +++ b/dist/services/RunnerOrganisationService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class RunnerOrganisationService { /** * Get all - * Lists all runnerOrganisations. + * Lists all organisations.
This includes their address, contact and teams (if existing/associated). * @returns ResponseRunnerOrganisation * @throws ApiError */ @@ -18,7 +18,7 @@ class RunnerOrganisationService { } /** * Post - * Create a new runnerOrganisation object (id will be generated automagicly). + * Create a new organsisation. * @param requestBody CreateRunnerOrganisation * @returns ResponseRunnerOrganisation * @throws ApiError @@ -33,7 +33,7 @@ class RunnerOrganisationService { } /** * Get one - * Returns a runnerOrganisation of a specified id (if it exists) + * Lists all information about the organisation whose id got provided. * @param id * @returns ResponseRunnerOrganisation * @throws ApiError @@ -47,7 +47,7 @@ class RunnerOrganisationService { } /** * Put - * Update a runnerOrganisation object (id can't be changed). + * Update the organisation whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunnerOrganisation * @returns ResponseRunnerOrganisation @@ -63,7 +63,7 @@ class RunnerOrganisationService { } /** * Remove - * Delete a specified runnerOrganisation (if it exists). + * Delete the organsisation whose id you provided.
If the organisation still has runners and/or teams associated this will fail.
To delete the organisation with all associated runners and teams set the force QueryParam to true (cascading deletion might take a while).
If no organisation with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunnerOrganisation diff --git a/dist/services/RunnerService.d.ts b/dist/services/RunnerService.d.ts index 573b95e..1ae374f 100644 --- a/dist/services/RunnerService.d.ts +++ b/dist/services/RunnerService.d.ts @@ -7,14 +7,14 @@ import type { UpdateRunner } from '../models/UpdateRunner'; export declare class RunnerService { /** * Get all - * Lists all runners. + * Lists all runners from all teams/orgs.
This includes the runner's group and distance ran. * @returns ResponseRunner * @throws ApiError */ static runnerControllerGetAll(): Promise>; /** * Post - * Create a new runner object (id will be generated automagicly). + * Create a new runner.
Please remeber to provide the runner's group's id. * @param requestBody CreateRunner * @returns any * @throws ApiError @@ -22,7 +22,7 @@ export declare class RunnerService { static runnerControllerPost(requestBody?: CreateRunner): Promise<(ResponseRunner | RunnerGroupNeededError | RunnerGroupNotFoundError)>; /** * Get one - * Returns a runner of a specified id (if it exists) + * Lists all information about the runner whose id got provided. * @param id * @returns ResponseRunner * @throws ApiError @@ -30,7 +30,7 @@ export declare class RunnerService { static runnerControllerGetOne(id: number): Promise; /** * Put - * Update a runner object (id can't be changed). + * Update the runner whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunner * @returns ResponseRunner @@ -39,7 +39,7 @@ export declare class RunnerService { static runnerControllerPut(id: number, requestBody?: UpdateRunner): Promise; /** * Remove - * Delete a specified runner (if it exists). + * Delete the runner whose id you provided.
If no runner with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunner diff --git a/dist/services/RunnerService.js b/dist/services/RunnerService.js index 619e11c..fdb7abb 100644 --- a/dist/services/RunnerService.js +++ b/dist/services/RunnerService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class RunnerService { /** * Get all - * Lists all runners. + * Lists all runners from all teams/orgs.
This includes the runner's group and distance ran. * @returns ResponseRunner * @throws ApiError */ @@ -18,7 +18,7 @@ class RunnerService { } /** * Post - * Create a new runner object (id will be generated automagicly). + * Create a new runner.
Please remeber to provide the runner's group's id. * @param requestBody CreateRunner * @returns any * @throws ApiError @@ -33,7 +33,7 @@ class RunnerService { } /** * Get one - * Returns a runner of a specified id (if it exists) + * Lists all information about the runner whose id got provided. * @param id * @returns ResponseRunner * @throws ApiError @@ -47,7 +47,7 @@ class RunnerService { } /** * Put - * Update a runner object (id can't be changed). + * Update the runner whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunner * @returns ResponseRunner @@ -63,7 +63,7 @@ class RunnerService { } /** * Remove - * Delete a specified runner (if it exists). + * Delete the runner whose id you provided.
If no runner with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunner diff --git a/dist/services/RunnerTeamService.d.ts b/dist/services/RunnerTeamService.d.ts index c7297d4..48d1213 100644 --- a/dist/services/RunnerTeamService.d.ts +++ b/dist/services/RunnerTeamService.d.ts @@ -5,14 +5,14 @@ import type { UpdateRunnerTeam } from '../models/UpdateRunnerTeam'; export declare class RunnerTeamService { /** * Get all - * Lists all runnerTeams. + * Lists all teams.
This includes their parent organisation and contact (if existing/associated). * @returns ResponseRunnerTeam * @throws ApiError */ static runnerTeamControllerGetAll(): Promise>; /** * Post - * Create a new runnerTeam object (id will be generated automagicly). + * Create a new organsisation.
Please remember to provide it's parent group's id. * @param requestBody CreateRunnerTeam * @returns ResponseRunnerTeam * @throws ApiError @@ -20,7 +20,7 @@ export declare class RunnerTeamService { static runnerTeamControllerPost(requestBody?: CreateRunnerTeam): Promise; /** * Get one - * Returns a runnerTeam of a specified id (if it exists) + * Lists all information about the team whose id got provided. * @param id * @returns ResponseRunnerTeam * @throws ApiError @@ -28,7 +28,7 @@ export declare class RunnerTeamService { static runnerTeamControllerGetOne(id: number): Promise; /** * Put - * Update a runnerTeam object (id can't be changed). + * Update the team whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunnerTeam * @returns ResponseRunnerTeam @@ -37,7 +37,7 @@ export declare class RunnerTeamService { static runnerTeamControllerPut(id: number, requestBody?: UpdateRunnerTeam): Promise; /** * Remove - * Delete a specified runnerTeam (if it exists). + * Delete the team whose id you provided.
If the team still has runners associated this will fail.
To delete the team with all associated runners set the force QueryParam to true (cascading deletion might take a while).
If no team with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunnerTeam diff --git a/dist/services/RunnerTeamService.js b/dist/services/RunnerTeamService.js index afd72f4..e20493a 100644 --- a/dist/services/RunnerTeamService.js +++ b/dist/services/RunnerTeamService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class RunnerTeamService { /** * Get all - * Lists all runnerTeams. + * Lists all teams.
This includes their parent organisation and contact (if existing/associated). * @returns ResponseRunnerTeam * @throws ApiError */ @@ -18,7 +18,7 @@ class RunnerTeamService { } /** * Post - * Create a new runnerTeam object (id will be generated automagicly). + * Create a new organsisation.
Please remember to provide it's parent group's id. * @param requestBody CreateRunnerTeam * @returns ResponseRunnerTeam * @throws ApiError @@ -33,7 +33,7 @@ class RunnerTeamService { } /** * Get one - * Returns a runnerTeam of a specified id (if it exists) + * Lists all information about the team whose id got provided. * @param id * @returns ResponseRunnerTeam * @throws ApiError @@ -47,7 +47,7 @@ class RunnerTeamService { } /** * Put - * Update a runnerTeam object (id can't be changed). + * Update the team whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateRunnerTeam * @returns ResponseRunnerTeam @@ -63,7 +63,7 @@ class RunnerTeamService { } /** * Remove - * Delete a specified runnerTeam (if it exists). + * Delete the team whose id you provided.
If the team still has runners associated this will fail.
To delete the team with all associated runners set the force QueryParam to true (cascading deletion might take a while).
If no team with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseRunnerTeam diff --git a/dist/services/StatusService.d.ts b/dist/services/StatusService.d.ts index f018a28..7112de9 100644 --- a/dist/services/StatusService.d.ts +++ b/dist/services/StatusService.d.ts @@ -1,7 +1,7 @@ export declare class StatusService { /** * Get - * Lists all tracks. + * A very basic status/health endpoint that just checks if the database connection is available.
The available information depth will be expanded later. * @returns any Successful response * @throws ApiError */ diff --git a/dist/services/StatusService.js b/dist/services/StatusService.js index 225ec5e..23edbb8 100644 --- a/dist/services/StatusService.js +++ b/dist/services/StatusService.js @@ -8,7 +8,7 @@ const request_1 = require("../core/request"); class StatusService { /** * Get - * Lists all tracks. + * A very basic status/health endpoint that just checks if the database connection is available.
The available information depth will be expanded later. * @returns any Successful response * @throws ApiError */ diff --git a/dist/services/TrackService.d.ts b/dist/services/TrackService.d.ts index 273db2f..9ea4361 100644 --- a/dist/services/TrackService.d.ts +++ b/dist/services/TrackService.d.ts @@ -5,13 +5,14 @@ import type { Track } from '../models/Track'; export declare class TrackService { /** * Get all + * Lists all tracks. * @returns ResponseTrack * @throws ApiError */ static trackControllerGetAll(): Promise>; /** * Post - * Create a new track object (id will be generated automagicly). + * Create a new track.
Please remember that the track's distance must be greater than 0. * @param requestBody CreateTrack * @returns ResponseTrack * @throws ApiError @@ -19,7 +20,7 @@ export declare class TrackService { static trackControllerPost(requestBody?: CreateTrack): Promise; /** * Get one - * Returns a track of a specified id (if it exists) + * Lists all information about the track whose id got provided. * @param id * @returns ResponseTrack * @throws ApiError @@ -27,7 +28,7 @@ export declare class TrackService { static trackControllerGetOne(id: number): Promise; /** * Put - * Update a track object (id can't be changed). + * Update the track whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody Track * @returns ResponseTrack @@ -36,7 +37,7 @@ export declare class TrackService { static trackControllerPut(id: number, requestBody?: Track): Promise; /** * Remove - * Delete a specified track (if it exists). + * Delete the track whose id you provided.
If no track with this id exists it will just return 204(no content). * @param id * @returns ResponseTrack * @returns ResponseEmpty diff --git a/dist/services/TrackService.js b/dist/services/TrackService.js index 6f8dc0a..373140b 100644 --- a/dist/services/TrackService.js +++ b/dist/services/TrackService.js @@ -5,6 +5,7 @@ const request_1 = require("../core/request"); class TrackService { /** * Get all + * Lists all tracks. * @returns ResponseTrack * @throws ApiError */ @@ -17,7 +18,7 @@ class TrackService { } /** * Post - * Create a new track object (id will be generated automagicly). + * Create a new track.
Please remember that the track's distance must be greater than 0. * @param requestBody CreateTrack * @returns ResponseTrack * @throws ApiError @@ -32,7 +33,7 @@ class TrackService { } /** * Get one - * Returns a track of a specified id (if it exists) + * Lists all information about the track whose id got provided. * @param id * @returns ResponseTrack * @throws ApiError @@ -46,7 +47,7 @@ class TrackService { } /** * Put - * Update a track object (id can't be changed). + * Update the track whose id you provided.
Please remember that ids can't be changed. * @param id * @param requestBody Track * @returns ResponseTrack @@ -62,7 +63,7 @@ class TrackService { } /** * Remove - * Delete a specified track (if it exists). + * Delete the track whose id you provided.
If no track with this id exists it will just return 204(no content). * @param id * @returns ResponseTrack * @returns ResponseEmpty diff --git a/dist/services/UserGroupService.d.ts b/dist/services/UserGroupService.d.ts index d3331be..9e9146d 100644 --- a/dist/services/UserGroupService.d.ts +++ b/dist/services/UserGroupService.d.ts @@ -6,14 +6,14 @@ import type { UserGroupNotFoundError } from '../models/UserGroupNotFoundError'; export declare class UserGroupService { /** * Get all - * Lists all usergroups. + * Lists all groups.
The information provided might change while the project continues to evolve. * @returns UserGroup * @throws ApiError */ static userGroupControllerGetAll(): Promise>; /** * Post - * Create a new usergroup object (id will be generated automagicly). + * Create a new group.
If you want to grant permissions to the group you have to create them seperately by posting to /api/permissions after creating the group. * @param requestBody CreateUserGroup * @returns any * @throws ApiError @@ -21,7 +21,7 @@ export declare class UserGroupService { static userGroupControllerPost(requestBody?: CreateUserGroup): Promise<(UserGroup | UserGroupNotFoundError)>; /** * Get one - * Returns a usergroup of a specified id (if it exists) + * Lists all information about the group whose id got provided.
The information provided might change while the project continues to evolve. * @param id * @returns UserGroup * @throws ApiError @@ -29,7 +29,7 @@ export declare class UserGroupService { static userGroupControllerGetOne(id: number): Promise; /** * Put - * Update a usergroup object (id can't be changed). + * Update the group whose id you provided.
To change the permissions granted to the group please use /api/permissions instead.
Please remember that ids can't be changed. * @param id * @param requestBody UserGroup * @returns UserGroup @@ -38,7 +38,7 @@ export declare class UserGroupService { static userGroupControllerPut(id: number, requestBody?: UserGroup): Promise; /** * Remove - * Delete a specified usergroup (if it exists). + * Delete the group whose id you provided.
If there are any permissions directly granted to the group they will get deleted as well.
Users associated with this group won't get deleted - just deassociated.
If no group with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseUserGroup diff --git a/dist/services/UserGroupService.js b/dist/services/UserGroupService.js index 314466e..743412a 100644 --- a/dist/services/UserGroupService.js +++ b/dist/services/UserGroupService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class UserGroupService { /** * Get all - * Lists all usergroups. + * Lists all groups.
The information provided might change while the project continues to evolve. * @returns UserGroup * @throws ApiError */ @@ -18,7 +18,7 @@ class UserGroupService { } /** * Post - * Create a new usergroup object (id will be generated automagicly). + * Create a new group.
If you want to grant permissions to the group you have to create them seperately by posting to /api/permissions after creating the group. * @param requestBody CreateUserGroup * @returns any * @throws ApiError @@ -33,7 +33,7 @@ class UserGroupService { } /** * Get one - * Returns a usergroup of a specified id (if it exists) + * Lists all information about the group whose id got provided.
The information provided might change while the project continues to evolve. * @param id * @returns UserGroup * @throws ApiError @@ -47,7 +47,7 @@ class UserGroupService { } /** * Put - * Update a usergroup object (id can't be changed). + * Update the group whose id you provided.
To change the permissions granted to the group please use /api/permissions instead.
Please remember that ids can't be changed. * @param id * @param requestBody UserGroup * @returns UserGroup @@ -63,7 +63,7 @@ class UserGroupService { } /** * Remove - * Delete a specified usergroup (if it exists). + * Delete the group whose id you provided.
If there are any permissions directly granted to the group they will get deleted as well.
Users associated with this group won't get deleted - just deassociated.
If no group with this id exists it will just return 204(no content). * @param id * @param force * @returns ResponseUserGroup diff --git a/dist/services/UserService.d.ts b/dist/services/UserService.d.ts index c4bd719..d16eece 100644 --- a/dist/services/UserService.d.ts +++ b/dist/services/UserService.d.ts @@ -6,14 +6,14 @@ import type { UserGroupNotFoundError } from '../models/UserGroupNotFoundError'; export declare class UserService { /** * Get all - * Lists all users. + * Lists all users.
This includes their groups and permissions directly granted to them (if existing/associated). * @returns User * @throws ApiError */ static userControllerGetAll(): Promise>; /** * Post - * Create a new user object (id will be generated automagicly). + * Create a new user.
If you want to grant permissions to the user you have to create them seperately by posting to /api/permissions after creating the user. * @param requestBody CreateUser * @returns any * @throws ApiError @@ -21,7 +21,7 @@ export declare class UserService { static userControllerPost(requestBody?: CreateUser): Promise<(User | UserGroupNotFoundError)>; /** * Get one - * Returns a user of a specified id (if it exists) + * Lists all information about the user whose id got provided.
Please remember that only permissions granted directly to the user will show up here, not permissions inherited from groups. * @param id * @returns User * @throws ApiError @@ -29,7 +29,7 @@ export declare class UserService { static userControllerGetOne(id: number): Promise; /** * Put - * Update a user object (id can't be changed). + * Update the user whose id you provided.
To change the permissions directly granted to the user please use /api/permissions instead.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateUser * @returns User @@ -38,7 +38,7 @@ export declare class UserService { static userControllerPut(id: number, requestBody?: UpdateUser): Promise; /** * Remove - * Delete a user runner (if it exists). + * Delete the user whose id you provided.
If there are any permissions directly granted to the user they will get deleted as well.
If no user with this id exists it will just return 204(no content). * @param id * @param force * @returns User diff --git a/dist/services/UserService.js b/dist/services/UserService.js index bc274a0..12ef43a 100644 --- a/dist/services/UserService.js +++ b/dist/services/UserService.js @@ -5,7 +5,7 @@ const request_1 = require("../core/request"); class UserService { /** * Get all - * Lists all users. + * Lists all users.
This includes their groups and permissions directly granted to them (if existing/associated). * @returns User * @throws ApiError */ @@ -18,7 +18,7 @@ class UserService { } /** * Post - * Create a new user object (id will be generated automagicly). + * Create a new user.
If you want to grant permissions to the user you have to create them seperately by posting to /api/permissions after creating the user. * @param requestBody CreateUser * @returns any * @throws ApiError @@ -33,7 +33,7 @@ class UserService { } /** * Get one - * Returns a user of a specified id (if it exists) + * Lists all information about the user whose id got provided.
Please remember that only permissions granted directly to the user will show up here, not permissions inherited from groups. * @param id * @returns User * @throws ApiError @@ -47,7 +47,7 @@ class UserService { } /** * Put - * Update a user object (id can't be changed). + * Update the user whose id you provided.
To change the permissions directly granted to the user please use /api/permissions instead.
Please remember that ids can't be changed. * @param id * @param requestBody UpdateUser * @returns User @@ -63,7 +63,7 @@ class UserService { } /** * Remove - * Delete a user runner (if it exists). + * Delete the user whose id you provided.
If there are any permissions directly granted to the user they will get deleted as well.
If no user with this id exists it will just return 204(no content). * @param id * @param force * @returns User diff --git a/openapi.json b/openapi.json index 9404f41..59e037f 100644 --- a/openapi.json +++ b/openapi.json @@ -1 +1 @@ -{"components":{"schemas":{"IllegalJWTError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNonexistantOrRefreshtokenInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"InvalidCredentialsError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"NoPermissionError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UsernameOrEmailNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PasswordNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"JwtNotProvidedError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNotFoundOrRefreshTokenCountInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RefreshTokenCountInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"JwtUser":{"properties":{"id":{"type":"integer"},"uuid":{"format":"uuid","type":"string"},"email":{"format":"email","type":"string"},"username":{"type":"string"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"enabled":{"type":"boolean"},"refreshTokenCount":{"minLength":1,"type":"integer"},"profilePic":{"type":"string"}},"type":"object","required":["id","uuid","firstname","lastname","enabled","refreshTokenCount"]},"ResponsePrincipal":{"properties":{"id":{"type":"integer"}},"type":"object","required":["id"]},"ResponseUser":{"properties":{"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"},"username":{"type":"string"},"enabled":{"type":"boolean"},"profilePic":{"type":"string"},"groups":{"items":{},"type":"array"},"permissions":{"items":{},"type":"array"},"id":{"type":"integer"}},"type":"object","required":["firstname","middlename","lastname","phone","email","username","enabled","id"]},"Permission":{"properties":{"id":{"type":"integer"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string"}},"type":"object","required":["id","target","action"]},"Principal":{"properties":{"id":{"type":"integer"}},"type":"object","required":["id"]},"UserAction":{"properties":{"id":{"type":"integer"},"target":{"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string"},"changed":{"type":"string"}},"type":"object","required":["id","target","action"]},"ResponseUserGroup":{"properties":{"name":{"type":"string","minLength":1},"description":{"type":"string"},"permissions":{"items":{},"type":"array"},"id":{"type":"integer"}},"type":"object","required":["name","id"]},"UserGroup":{"properties":{"name":{"type":"string","minLength":1},"description":{"type":"string"},"id":{"type":"integer"}},"type":"object","required":["name","id"]},"User":{"properties":{"uuid":{"format":"uuid","type":"string"},"email":{"format":"email","type":"string"},"phone":{"type":"string"},"username":{"type":"string"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"password":{"minLength":1,"type":"string"},"groups":{},"enabled":{"type":"boolean"},"refreshTokenCount":{"type":"integer"},"profilePic":{"type":"string"},"actions":{},"id":{"type":"integer"}},"type":"object","required":["uuid","email","username","firstname","lastname","password","enabled","refreshTokenCount","id"]},"UserIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"Auth":{"properties":{"access_token":{"type":"string"},"refresh_token":{"type":"string"},"access_token_expires_at":{"type":"integer"},"refresh_token_expires_at":{"type":"integer"}},"type":"object","required":["access_token","refresh_token","access_token_expires_at","refresh_token_expires_at"]},"CreateAuth":{"properties":{"username":{"type":"string"},"email":{"type":"string","format":"email"},"password":{"type":"string","minLength":1}},"type":"object","required":["password"]},"Logout":{"properties":{"timestamp":{"type":"string"}},"type":"object","required":["timestamp"]},"HandleLogout":{"properties":{"token":{"type":"string"}},"type":"object"},"RefreshAuth":{"properties":{"token":{"type":"string"}},"type":"object"},"RunnerNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerGroupNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerGroupNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationHasRunnersError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationHasTeamsError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"Donation":{"properties":{"id":{"type":"integer"},"donor":{"minLength":1,"type":"string"}},"type":"object","required":["id","donor"]},"Participant":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["id","firstname","lastname"]},"Address":{"properties":{"id":{"type":"integer"},"description":{"type":"string"},"address1":{"minLength":1,"type":"string"},"address2":{"type":"string"},"postalcode":{"type":"string","minLength":1},"city":{"minLength":1,"type":"string"},"country":{"minLength":1,"type":"string"}},"type":"object","required":["id","address1","postalcode","city","country"]},"GroupContact":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"address":{},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["id","firstname","lastname"]},"DistanceDonation":{"properties":{"runner":{"minLength":1,"type":"string"},"amountPerDistance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"id":{"type":"integer"},"donor":{"minLength":1,"type":"string"}},"type":"object","required":["runner","amountPerDistance","id","donor"]},"Scan":{"properties":{"id":{"type":"integer"},"runner":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"valid":{"type":"boolean"}},"type":"object","required":["id","runner","distance","valid"]},"Track":{"properties":{"id":{"type":"integer"},"name":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"}},"type":"object","required":["id","name","distance"]},"ScanStation":{"properties":{"id":{"type":"integer"},"description":{"type":"string"},"track":{"minLength":1,"type":"string"},"key":{"type":"string","minLength":1},"enabled":{"type":"boolean"}},"type":"object","required":["id","track","key","enabled"]},"TrackScan":{"properties":{"track":{"minLength":1,"type":"string"},"card":{"minLength":1,"type":"string"},"station":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"timestamp":{"minLength":1,"type":"string","pattern":"d{4}-[01]d-[0-3]dT[0-2]d:[0-5]d:[0-5]d.d+Z?"},"id":{"type":"integer"},"runner":{"minLength":1,"type":"string"},"valid":{"type":"boolean"}},"type":"object","required":["track","card","station","distance","timestamp","id","runner","valid"]},"RunnerCard":{"properties":{"id":{"type":"integer"},"runner":{},"code":{"minLength":1,"type":"string"},"enabled":{"type":"boolean"}},"type":"object","required":["id","code","enabled"]},"Runner":{"properties":{"group":{"minLength":1,"type":"string"},"distance":{"type":"integer"},"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["group","distance","id","firstname","lastname"]},"RunnerGroup":{"properties":{"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["id","name"]},"RunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"string"},"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["parentGroup","id","name"]},"RunnerOrganisation":{"properties":{"address":{},"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["id","name"]},"RunnerTeamNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamHasRunnersError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamNeedsParentError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"AddressWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"AddressNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateParticipant":{"properties":{"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["firstname","lastname"]},"CreateRunner":{"properties":{"group":{"type":"integer"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["group","firstname","lastname"]},"ImportRunner":{"properties":{"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"team":{"type":"string"},"class":{"type":"string"}},"type":"object","required":["firstname","lastname"]},"ResponseParticipant":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"}},"type":"object","required":["id","firstname","middlename","lastname","phone","email"]},"ResponseRunner":{"properties":{"distance":{"type":"integer"},"group":{"$ref":"#/components/schemas/RunnerGroup"},"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"}},"type":"object","required":["distance","group","id","firstname","middlename","lastname","phone","email"]},"UpdateRunner":{"properties":{"id":{"type":"integer"},"group":{"$ref":"#/components/schemas/RunnerGroup"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["id","group","firstname","lastname"]},"ResponseEmpty":{"properties":{"response":{"type":"string"}},"type":"object","required":["response"]},"PermissionNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PermissionIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PermissionNeedsPrincipalError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PrincipalNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PrincipalWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreatePermission":{"properties":{"principal":{"minLength":1,"type":"integer"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string","minLength":1}},"type":"object","required":["principal","target","action"]},"UpdatePermission":{"properties":{"id":{"type":"integer"},"principal":{"minLength":1,"type":"string","$ref":"#/components/schemas/Principal"},"target":{"minLength":1,"type":"string"},"action":{"minLength":1,"type":"string"}},"type":"object","required":["id","principal","target","action"]},"ResponsePermission":{"properties":{"id":{"type":"integer"},"principal":{"minLength":1,"type":"string","$ref":"#/components/schemas/ResponsePrincipal"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string","minLength":1}},"type":"object","required":["id","principal","target","action"]},"GroupContactWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"GroupContactNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateRunnerGroup":{"properties":{"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["name"]},"CreateRunnerOrganisation":{"properties":{"address":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["name"]},"UpdateRunnerOrganisation":{"properties":{"id":{"type":"integer"},"address":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["id","name"]},"ResponseRunnerGroup":{"properties":{"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["id","name"]},"ResponseRunnerOrganisation":{"properties":{"address":{"minLength":1,"type":"string","$ref":"#/components/schemas/Address"},"teams":{"items":{},"type":"array"},"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["address","teams","id","name"]},"CreateRunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["parentGroup","name"]},"UpdateRunnerTeam":{"properties":{"id":{"type":"integer"},"parentGroup":{"minLength":1,"type":"string","$ref":"#/components/schemas/RunnerOrganisation"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["id","parentGroup","name"]},"ResponseRunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"string","$ref":"#/components/schemas/RunnerOrganisation"},"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["parentGroup","id","name"]},"TrackNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"TrackIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateTrack":{"properties":{"name":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"}},"type":"object","required":["name","distance"]},"ResponseTrack":{"properties":{"id":{"type":"integer"},"name":{"type":"string"},"distance":{"type":"integer"}},"type":"object","required":["id","name","distance"]},"GroupNameNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserGroupNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserGroupIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateUser":{"properties":{"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"username":{"type":"string"},"email":{"type":"string","format":"email"},"phone":{"type":"string"},"password":{"type":"string"},"groups":{}},"type":"object","required":["firstname","lastname","password"]},"UpdateUser":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"username":{"type":"string"},"email":{"type":"string","format":"email"},"phone":{"type":"string"},"password":{"type":"string"},"enabled":{"type":"boolean"},"groups":{}},"type":"object","required":["id","firstname","lastname","enabled"]},"CreateUserGroup":{"properties":{"name":{"type":"string"},"description":{"type":"string"}},"type":"object","required":["name"]}},"securitySchemes":{"AuthToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}},"info":{"title":"LfK! Backend API","version":"1.0.0","description":"The the backend API for the LfK! runner system."},"openapi":"3.0.0","paths":{"/api/auth/login":{"post":{"operationId":"AuthController.login","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAuth"}}},"description":"CreateAuth","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/InvalidCredentialsError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"},{"$ref":"#/components/schemas/PasswordNeededError"},{"$ref":"#/components/schemas/InvalidCredentialsError"}]}}},"description":""}},"summary":"Login","tags":["Auth"],"description":"Create a new access token object"}},"/api/auth/logout":{"post":{"operationId":"AuthController.logout","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HandleLogout"}}},"description":"HandleLogout","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Logout"},{"$ref":"#/components/schemas/InvalidCredentialsError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"},{"$ref":"#/components/schemas/PasswordNeededError"},{"$ref":"#/components/schemas/InvalidCredentialsError"}]}}},"description":""}},"summary":"Logout","tags":["Auth"],"description":"Create a new access token object"}},"/api/auth/refresh":{"post":{"operationId":"AuthController.refresh","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshAuth"}}},"description":"RefreshAuth","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/JwtNotProvidedError"},{"$ref":"#/components/schemas/IllegalJWTError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/RefreshTokenCountInvalidError"}]}}},"description":""}},"summary":"Refresh","tags":["Auth"],"description":"refresh a access token"}},"/api/runners":{"get":{"operationId":"RunnerController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner"],"security":[{"AuthToken":[]}],"description":"Lists all runners."},"post":{"operationId":"RunnerController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunner"}}},"description":"CreateRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/ResponseRunner"},{"$ref":"#/components/schemas/RunnerGroupNeededError"},{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["Runner"],"security":[{"AuthToken":[]}],"description":"Create a new runner object (id will be generated automagicly)."}},"/api/runners/{id}":{"get":{"operationId":"RunnerController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner"],"security":[{"AuthToken":[]}],"description":"Returns a runner of a specified id (if it exists)"},"put":{"operationId":"RunnerController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunner"}}},"description":"UpdateRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner"],"security":[{"AuthToken":[]}],"description":"Update a runner object (id can't be changed)."},"delete":{"operationId":"RunnerController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Runner"],"security":[{"AuthToken":[]}],"description":"Delete a specified runner (if it exists)."}},"/api/runners/import":{"post":{"operationId":"ImportController.postJSON","parameters":[{"in":"query","name":"group","required":false,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post json","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from json and insert them (or their teams) into the provided group"}},"/api/organisations/{id}/import":{"post":{"operationId":"ImportController.postOrgsJSON","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post orgs json","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from json and insert them (or their teams) into the provided org"}},"/api/teams/{id}/import":{"post":{"operationId":"ImportController.postTeamsJSON","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post teams json","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from json and insert them into the provided team"}},"/api/runners/import/csv":{"post":{"operationId":"ImportController.postCSV","parameters":[{"in":"query","name":"group","required":false,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post csv","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from csv and insert them (or their teams) into the provided group"}},"/api/organisations/{id}/import/csv":{"post":{"operationId":"ImportController.postOrgsCSV","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post orgs csv","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from csv and insert them (or their teams) into the provided org"}},"/api/teams/{id}/import/csv":{"post":{"operationId":"ImportController.postTeamsCSV","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post teams csv","tags":["Import"],"security":[{"AuthToken":[]}],"description":"Create new runners from csv and insert them into the provided team"}},"/api/permissions":{"get":{"operationId":"PermissionController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponsePermission"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Permission"],"security":[{"AuthToken":[]}],"description":"Lists all permissions."},"post":{"operationId":"PermissionController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreatePermission"}}},"description":"CreatePermission","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PrincipalNotFoundError"}}},"description":""}},"summary":"Post","tags":["Permission"],"security":[{"AuthToken":[]}],"description":"Create a new runnerTeam object (id will be generated automagicly)."}},"/api/permissions/{id}":{"get":{"operationId":"PermissionController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PermissionNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Permission"],"security":[{"AuthToken":[]}],"description":"Returns a permissions of a specified id (if it exists)"},"put":{"operationId":"PermissionController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdatePermission"}}},"description":"UpdatePermission","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePrincipal"}}},"description":""},"404":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/PermissionNotFoundError"},{"$ref":"#/components/schemas/PrincipalNotFoundError"}]}}},"description":""},"406":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/PermissionIdsNotMatchingError"},{"$ref":"#/components/schemas/PermissionNeedsPrincipalError"}]}}},"description":""}},"summary":"Put","tags":["Permission"],"security":[{"AuthToken":[]}],"description":"Update a permission object (id can't be changed)."},"delete":{"operationId":"PermissionController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Permission"],"security":[{"AuthToken":[]}],"description":"Delete a specified permission (if it exists)."}},"/api/teams":{"get":{"operationId":"RunnerTeamController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunnerTeam"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner Team"],"security":[{"AuthToken":[]}],"description":"Lists all runnerTeams."},"post":{"operationId":"RunnerTeamController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunnerTeam"}}},"description":"CreateRunnerTeam","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""}},"summary":"Post","tags":["Runner Team"],"security":[{"AuthToken":[]}],"description":"Create a new runnerTeam object (id will be generated automagicly)."}},"/api/teams/{id}":{"get":{"operationId":"RunnerTeamController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner Team"],"security":[{"AuthToken":[]}],"description":"Returns a runnerTeam of a specified id (if it exists)"},"put":{"operationId":"RunnerTeamController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunnerTeam"}}},"description":"UpdateRunnerTeam","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner Team"],"security":[{"AuthToken":[]}],"description":"Update a runnerTeam object (id can't be changed)."},"delete":{"operationId":"RunnerTeamController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamHasRunnersError"}}},"description":""}},"summary":"Remove","tags":["Runner Team"],"security":[{"AuthToken":[]}],"description":"Delete a specified runnerTeam (if it exists)."}},"/api/organisations":{"get":{"operationId":"RunnerOrganisationController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner Organisation"],"security":[{"AuthToken":[]}],"description":"Lists all runnerOrganisations."},"post":{"operationId":"RunnerOrganisationController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunnerOrganisation"}}},"description":"CreateRunnerOrganisation","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""}},"summary":"Post","tags":["Runner Organisation"],"security":[{"AuthToken":[]}],"description":"Create a new runnerOrganisation object (id will be generated automagicly)."}},"/api/organisations/{id}":{"get":{"operationId":"RunnerOrganisationController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner Organisation"],"security":[{"AuthToken":[]}],"description":"Returns a runnerOrganisation of a specified id (if it exists)"},"put":{"operationId":"RunnerOrganisationController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunnerOrganisation"}}},"description":"UpdateRunnerOrganisation","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner Organisation"],"security":[{"AuthToken":[]}],"description":"Update a runnerOrganisation object (id can't be changed)."},"delete":{"operationId":"RunnerOrganisationController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""},"406":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/RunnerOrganisationHasTeamsError"},{"$ref":"#/components/schemas/RunnerOrganisationHasRunnersError"}]}}},"description":""}},"summary":"Remove","tags":["Runner Organisation"],"security":[{"AuthToken":[]}],"description":"Delete a specified runnerOrganisation (if it exists)."}},"/api/status":{"get":{"operationId":"StatusController.get","responses":{"200":{"content":{"application/json":{}},"description":"Successful response"}},"summary":"Get","tags":["Status"],"description":"Lists all tracks."}},"/api/tracks":{"get":{"operationId":"TrackController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseTrack"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Track"],"security":[{"AuthToken":[]}]},"post":{"operationId":"TrackController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTrack"}}},"description":"CreateTrack","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""}},"summary":"Post","tags":["Track"],"security":[{"AuthToken":[]}],"description":"Create a new track object (id will be generated automagicly)."}},"/api/tracks/{id}":{"get":{"operationId":"TrackController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Track"],"security":[{"AuthToken":[]}],"description":"Returns a track of a specified id (if it exists)"},"put":{"operationId":"TrackController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Track"}}},"description":"Track","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Track"],"security":[{"AuthToken":[]}],"description":"Update a track object (id can't be changed)."},"delete":{"operationId":"TrackController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Track"],"security":[{"AuthToken":[]}],"description":"Delete a specified track (if it exists)."}},"/api/users":{"get":{"operationId":"UserController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/User"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["User"],"security":[{"AuthToken":[]}],"description":"Lists all users."},"post":{"operationId":"UserController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUser"}}},"description":"CreateUser","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/User"},{"$ref":"#/components/schemas/UserGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["User"],"security":[{"AuthToken":[]}],"description":"Create a new user object (id will be generated automagicly)."}},"/api/users/{id}":{"get":{"operationId":"UserController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserNotFoundError"}}},"description":""}},"summary":"Get one","tags":["User"],"security":[{"AuthToken":[]}],"description":"Returns a user of a specified id (if it exists)"},"put":{"operationId":"UserController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateUser"}}},"description":"UpdateUser","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["User"],"security":[{"AuthToken":[]}],"description":"Update a user object (id can't be changed)."},"delete":{"operationId":"UserController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["User"],"security":[{"AuthToken":[]}],"description":"Delete a user runner (if it exists)."}},"/api/usergroups":{"get":{"operationId":"UserGroupController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/UserGroup"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["User Group"],"security":[{"AuthToken":[]}],"description":"Lists all usergroups."},"post":{"operationId":"UserGroupController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUserGroup"}}},"description":"CreateUserGroup","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/UserGroup"},{"$ref":"#/components/schemas/UserGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["User Group"],"security":[{"AuthToken":[]}],"description":"Create a new usergroup object (id will be generated automagicly)."}},"/api/usergroups/{id}":{"get":{"operationId":"UserGroupController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupNotFoundError"}}},"description":""}},"summary":"Get one","tags":["User Group"],"security":[{"AuthToken":[]}],"description":"Returns a usergroup of a specified id (if it exists)"},"put":{"operationId":"UserGroupController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":"UserGroup","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["User Group"],"security":[{"AuthToken":[]}],"description":"Update a usergroup object (id can't be changed)."},"delete":{"operationId":"UserGroupController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseUserGroup"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["User Group"],"security":[{"AuthToken":[]}],"description":"Delete a specified usergroup (if it exists)."}}}} \ No newline at end of file +{"components":{"schemas":{"IllegalJWTError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNonexistantOrRefreshtokenInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"InvalidCredentialsError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"NoPermissionError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UsernameOrEmailNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PasswordNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"JwtNotProvidedError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserNotFoundOrRefreshTokenCountInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RefreshTokenCountInvalidError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"ResetAlreadyRequestedError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserDisabledError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"JwtUser":{"properties":{"id":{"type":"integer"},"uuid":{"format":"uuid","type":"string"},"email":{"format":"email","type":"string"},"username":{"type":"string"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"enabled":{"type":"boolean"},"refreshTokenCount":{"minLength":1,"type":"integer"},"profilePic":{"type":"string"}},"type":"object","required":["id","uuid","firstname","lastname","enabled","refreshTokenCount"]},"ResponsePrincipal":{"properties":{"id":{"type":"integer"}},"type":"object","required":["id"]},"ResponseUser":{"properties":{"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"},"username":{"type":"string"},"enabled":{"type":"boolean"},"profilePic":{"type":"string"},"groups":{"items":{},"type":"array"},"permissions":{"items":{},"type":"array"},"id":{"type":"integer"}},"type":"object","required":["firstname","middlename","lastname","phone","email","username","enabled","id"]},"Permission":{"properties":{"id":{"type":"integer"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string"}},"type":"object","required":["id","target","action"]},"Principal":{"properties":{"id":{"type":"integer"}},"type":"object","required":["id"]},"UserAction":{"properties":{"id":{"type":"integer"},"target":{"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string"},"changed":{"type":"string"}},"type":"object","required":["id","target","action"]},"ResponseUserGroup":{"properties":{"name":{"type":"string","minLength":1},"description":{"type":"string"},"permissions":{"items":{},"type":"array"},"id":{"type":"integer"}},"type":"object","required":["name","id"]},"UserGroup":{"properties":{"name":{"type":"string","minLength":1},"description":{"type":"string"},"id":{"type":"integer"}},"type":"object","required":["name","id"]},"User":{"properties":{"uuid":{"format":"uuid","type":"string"},"email":{"format":"email","type":"string"},"phone":{"type":"string"},"username":{"type":"string"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"password":{"minLength":1,"type":"string"},"groups":{},"enabled":{"type":"boolean"},"refreshTokenCount":{"type":"integer"},"profilePic":{"type":"string"},"resetRequestedTimestamp":{"type":"string"},"actions":{},"id":{"type":"integer"}},"type":"object","required":["uuid","email","username","firstname","lastname","password","enabled","refreshTokenCount","id"]},"UserIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"Auth":{"properties":{"access_token":{"type":"string"},"refresh_token":{"type":"string"},"access_token_expires_at":{"type":"integer"},"refresh_token_expires_at":{"type":"integer"}},"type":"object","required":["access_token","refresh_token","access_token_expires_at","refresh_token_expires_at"]},"CreateAuth":{"properties":{"username":{"type":"string"},"email":{"type":"string","format":"email"},"password":{"type":"string","minLength":1}},"type":"object","required":["password"]},"CreateResetToken":{"properties":{"username":{"type":"string"},"email":{"type":"string","format":"email"}},"type":"object"},"Logout":{"properties":{"timestamp":{"type":"string"}},"type":"object","required":["timestamp"]},"HandleLogout":{"properties":{"token":{"type":"string"}},"type":"object"},"RefreshAuth":{"properties":{"token":{"type":"string"}},"type":"object"},"ResetPassword":{"properties":{"resetToken":{"type":"string"},"password":{"type":"string","minLength":1}},"type":"object","required":["password"]},"RunnerNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerGroupNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerGroupNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationHasRunnersError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationHasTeamsError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerOrganisationWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"Donation":{"properties":{"id":{"type":"integer"},"donor":{"minLength":1,"type":"string"}},"type":"object","required":["id","donor"]},"Participant":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["id","firstname","lastname"]},"Address":{"properties":{"id":{"type":"integer"},"description":{"type":"string"},"address1":{"minLength":1,"type":"string"},"address2":{"type":"string"},"postalcode":{"type":"string","minLength":1},"city":{"minLength":1,"type":"string"},"country":{"minLength":1,"type":"string"}},"type":"object","required":["id","address1","postalcode","city","country"]},"GroupContact":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"address":{},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["id","firstname","lastname"]},"DistanceDonation":{"properties":{"runner":{"minLength":1,"type":"string"},"amountPerDistance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"id":{"type":"integer"},"donor":{"minLength":1,"type":"string"}},"type":"object","required":["runner","amountPerDistance","id","donor"]},"Scan":{"properties":{"id":{"type":"integer"},"runner":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"valid":{"type":"boolean"}},"type":"object","required":["id","runner","distance","valid"]},"Track":{"properties":{"id":{"type":"integer"},"name":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"}},"type":"object","required":["id","name","distance"]},"ScanStation":{"properties":{"id":{"type":"integer"},"description":{"type":"string"},"track":{"minLength":1,"type":"string"},"key":{"type":"string","minLength":1},"enabled":{"type":"boolean"}},"type":"object","required":["id","track","key","enabled"]},"TrackScan":{"properties":{"track":{"minLength":1,"type":"string"},"card":{"minLength":1,"type":"string"},"station":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"},"timestamp":{"minLength":1,"type":"string","pattern":"d{4}-[01]d-[0-3]dT[0-2]d:[0-5]d:[0-5]d.d+Z?"},"id":{"type":"integer"},"runner":{"minLength":1,"type":"string"},"valid":{"type":"boolean"}},"type":"object","required":["track","card","station","distance","timestamp","id","runner","valid"]},"RunnerCard":{"properties":{"id":{"type":"integer"},"runner":{},"code":{"minLength":1,"type":"string"},"enabled":{"type":"boolean"}},"type":"object","required":["id","code","enabled"]},"Runner":{"properties":{"group":{"minLength":1,"type":"string"},"distance":{"type":"integer"},"id":{"type":"integer"},"firstname":{"type":"string","minLength":1},"middlename":{"type":"string"},"lastname":{"type":"string","minLength":1},"phone":{"type":"string"},"email":{"format":"email","type":"string"}},"type":"object","required":["group","distance","id","firstname","lastname"]},"RunnerGroup":{"properties":{"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["id","name"]},"RunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"string"},"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["parentGroup","id","name"]},"RunnerOrganisation":{"properties":{"address":{},"id":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{}},"type":"object","required":["id","name"]},"RunnerTeamNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamHasRunnersError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"RunnerTeamNeedsParentError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"AddressWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"AddressNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateParticipant":{"properties":{"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["firstname","lastname"]},"CreateRunner":{"properties":{"group":{"type":"integer"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["group","firstname","lastname"]},"ImportRunner":{"properties":{"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"team":{"type":"string"},"class":{"type":"string"}},"type":"object","required":["firstname","lastname"]},"ResponseParticipant":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"}},"type":"object","required":["id","firstname","middlename","lastname","phone","email"]},"ResponseRunner":{"properties":{"distance":{"type":"integer"},"group":{"$ref":"#/components/schemas/RunnerGroup"},"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"}},"type":"object","required":["distance","group","id","firstname","middlename","lastname","phone","email"]},"UpdateRunner":{"properties":{"id":{"type":"integer"},"group":{"$ref":"#/components/schemas/RunnerGroup"},"firstname":{"minLength":1,"type":"string"},"middlename":{"type":"string"},"lastname":{"minLength":1,"type":"string"},"phone":{"type":"string"},"email":{"format":"email","type":"string"},"address":{"type":"integer"}},"type":"object","required":["id","group","firstname","lastname"]},"ResponseEmpty":{"properties":{"response":{"type":"string"}},"type":"object","required":["response"]},"PermissionNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PermissionIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PermissionNeedsPrincipalError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PrincipalNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"PrincipalWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreatePermission":{"properties":{"principal":{"minLength":1,"type":"integer"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string","minLength":1}},"type":"object","required":["principal","target","action"]},"UpdatePermission":{"properties":{"id":{"type":"integer"},"principal":{"minLength":1,"type":"string","$ref":"#/components/schemas/Principal"},"target":{"minLength":1,"type":"string"},"action":{"minLength":1,"type":"string"}},"type":"object","required":["id","principal","target","action"]},"ResponsePermission":{"properties":{"id":{"type":"integer"},"principal":{"minLength":1,"type":"string","$ref":"#/components/schemas/ResponsePrincipal"},"target":{"enum":["RUNNER","ORGANISATION","TEAM","TRACK","USER","USERGROUP","PERMISSION"],"type":"string","minLength":1},"action":{"enum":["GET","CREATE","UPDATE","DELETE","IMPORT"],"type":"string","minLength":1}},"type":"object","required":["id","principal","target","action"]},"GroupContactWrongTypeError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"GroupContactNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateRunnerGroup":{"properties":{"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["name"]},"CreateRunnerOrganisation":{"properties":{"address":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["name"]},"UpdateRunnerOrganisation":{"properties":{"id":{"type":"integer"},"address":{"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["id","name"]},"ResponseRunnerGroup":{"properties":{"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["id","name"]},"ResponseRunnerOrganisation":{"properties":{"address":{"minLength":1,"type":"string","$ref":"#/components/schemas/Address"},"teams":{"items":{},"type":"array"},"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["address","teams","id","name"]},"CreateRunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"integer"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["parentGroup","name"]},"UpdateRunnerTeam":{"properties":{"id":{"type":"integer"},"parentGroup":{"minLength":1,"type":"string","$ref":"#/components/schemas/RunnerOrganisation"},"name":{"type":"string","minLength":1},"contact":{"type":"integer"}},"type":"object","required":["id","parentGroup","name"]},"ResponseRunnerTeam":{"properties":{"parentGroup":{"minLength":1,"type":"string","$ref":"#/components/schemas/RunnerOrganisation"},"id":{"minLength":1,"type":"integer"},"name":{"minLength":1,"type":"string"},"contact":{"$ref":"#/components/schemas/GroupContact"}},"type":"object","required":["parentGroup","id","name"]},"TrackNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"TrackIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateTrack":{"properties":{"name":{"minLength":1,"type":"string"},"distance":{"exclusiveMinimum":true,"minimum":0,"type":"integer"}},"type":"object","required":["name","distance"]},"ResponseTrack":{"properties":{"id":{"type":"integer"},"name":{"type":"string"},"distance":{"type":"integer"}},"type":"object","required":["id","name","distance"]},"GroupNameNeededError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserGroupNotFoundError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"UserGroupIdsNotMatchingError":{"properties":{"name":{"type":"string"},"message":{"type":"string"}},"type":"object","required":["name","message"]},"CreateUser":{"properties":{"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"username":{"type":"string"},"email":{"type":"string","format":"email"},"phone":{"type":"string"},"password":{"type":"string"},"enabled":{"type":"boolean"},"groups":{}},"type":"object","required":["firstname","lastname","password"]},"UpdateUser":{"properties":{"id":{"type":"integer"},"firstname":{"type":"string"},"middlename":{"type":"string"},"lastname":{"type":"string"},"username":{"type":"string"},"email":{"type":"string","format":"email"},"phone":{"type":"string"},"password":{"type":"string"},"enabled":{"type":"boolean"},"groups":{}},"type":"object","required":["id","firstname","lastname","enabled"]},"CreateUserGroup":{"properties":{"name":{"type":"string"},"description":{"type":"string"}},"type":"object","required":["name"]}},"securitySchemes":{"AuthToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"A JWT based access token. Use /api/auth/login or /api/auth/refresh to get one."},"RefreshTokenCookie":{"type":"apiKey","in":"cookie","name":"lfk_backend__refresh_token","description":"A cookie containing a JWT based refreh token. Attention: Doesn't work in swagger-ui. Use /api/auth/login or /api/auth/refresh to get one."}}},"info":{"title":"LfK! Backend API","version":"0.0.5","description":"The the backend API for the LfK! runner system."},"openapi":"3.0.0","paths":{"/api/auth/login":{"post":{"operationId":"AuthController.login","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAuth"}}},"description":"CreateAuth","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/InvalidCredentialsError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"},{"$ref":"#/components/schemas/PasswordNeededError"},{"$ref":"#/components/schemas/InvalidCredentialsError"}]}}},"description":""}},"summary":"Login","tags":["Auth"],"description":"Login with your username/email and password.
You will receive: \n * access token (use it as a bearer token) \n * refresh token (will also be sent as a cookie)"}},"/api/auth/logout":{"post":{"operationId":"AuthController.logout","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HandleLogout"}}},"description":"HandleLogout","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Logout"},{"$ref":"#/components/schemas/InvalidCredentialsError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"},{"$ref":"#/components/schemas/PasswordNeededError"},{"$ref":"#/components/schemas/InvalidCredentialsError"}]}}},"description":""}},"summary":"Logout","tags":["Auth"],"description":"Logout using your refresh token.
This instantly invalidates all your access and refresh tokens.","security":[{"RefreshTokenCookie":[]}]}},"/api/auth/refresh":{"post":{"operationId":"AuthController.refresh","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshAuth"}}},"description":"RefreshAuth","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/JwtNotProvidedError"},{"$ref":"#/components/schemas/IllegalJWTError"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/RefreshTokenCountInvalidError"}]}}},"description":""}},"summary":"Refresh","tags":["Auth"],"description":"Refresh your access and refresh tokens using a valid refresh token.
You will receive: \n * access token (use it as a bearer token) \n * refresh token (will also be sent as a cookie)","security":[{"RefreshTokenCookie":[]}]}},"/api/auth/reset":{"post":{"operationId":"AuthController.getResetToken","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateResetToken"}}},"description":"CreateResetToken","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"}]}}},"description":""}},"summary":"Get reset token","tags":["Auth"],"description":"Request a password reset token.
This will provide you with a reset token that you can use by posting to /api/auth/reset/{token}."}},"/api/auth/reset/{token}":{"post":{"operationId":"AuthController.resetPassword","parameters":[{"in":"path","name":"token","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResetPassword"}}},"description":"ResetPassword","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/Auth"},{"$ref":"#/components/schemas/UserNotFoundError"},{"$ref":"#/components/schemas/UsernameOrEmailNeededError"}]}}},"description":""}},"summary":"Reset password","tags":["Auth"],"description":"Reset a user's utilising a valid password reset token.
This will set the user's password to the one you provided in the body.
To get a reset token post to /api/auth/reset with your username."}},"/api/runners":{"get":{"operationId":"RunnerController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all runners from all teams/orgs.
This includes the runner's group and distance ran."},"post":{"operationId":"RunnerController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunner"}}},"description":"CreateRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/ResponseRunner"},{"$ref":"#/components/schemas/RunnerGroupNeededError"},{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["Runner"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new runner.
Please remeber to provide the runner's group's id."}},"/api/runners/{id}":{"get":{"operationId":"RunnerController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the runner whose id got provided."},"put":{"operationId":"RunnerController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunner"}}},"description":"UpdateRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the runner whose id you provided.
Please remember that ids can't be changed."},"delete":{"operationId":"RunnerController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunner"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Runner"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the runner whose id you provided.
If no runner with this id exists it will just return 204(no content)."}},"/api/runners/import":{"post":{"operationId":"ImportController.postJSON","parameters":[{"in":"query","name":"group","required":false,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post json","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from json and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead."}},"/api/organisations/{id}/import":{"post":{"operationId":"ImportController.postOrgsJSON","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post orgs json","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from json and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead."}},"/api/teams/{id}/import":{"post":{"operationId":"ImportController.postTeamsJSON","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ImportRunner"},"type":"array"}}},"description":"ImportRunner","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post teams json","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from json and insert them into the provided team"}},"/api/runners/import/csv":{"post":{"operationId":"ImportController.postCSV","parameters":[{"in":"query","name":"group","required":false,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post csv","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from csv and insert them into the provided group.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead."}},"/api/organisations/{id}/import/csv":{"post":{"operationId":"ImportController.postOrgsCSV","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post orgs csv","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from csv and insert them into the provided org.
If teams/classes are provided alongside the runner's name they'll automaticly be created under the provided org and the runners will be inserted into the teams instead."}},"/api/teams/{id}/import/csv":{"post":{"operationId":"ImportController.postTeamsCSV","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunner"},"type":"array"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerGroupNeededError"}}},"description":""}},"summary":"Post teams csv","tags":["Import"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create new runners from csv and insert them into the provided team"}},"/api/permissions":{"get":{"operationId":"PermissionController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponsePermission"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Permission"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all permissions for all users and groups."},"post":{"operationId":"PermissionController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreatePermission"}}},"description":"CreatePermission","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PrincipalNotFoundError"}}},"description":""}},"summary":"Post","tags":["Permission"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new permission for a existing principal(user/group).
If a permission with this target, action and prinicpal already exists that permission will be returned instead of creating a new one."}},"/api/permissions/{id}":{"get":{"operationId":"PermissionController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PermissionNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Permission"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the permission whose id got provided."},"put":{"operationId":"PermissionController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdatePermission"}}},"description":"UpdatePermission","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePrincipal"}}},"description":""},"404":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/PermissionNotFoundError"},{"$ref":"#/components/schemas/PrincipalNotFoundError"}]}}},"description":""},"406":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/PermissionIdsNotMatchingError"},{"$ref":"#/components/schemas/PermissionNeedsPrincipalError"}]}}},"description":""}},"summary":"Put","tags":["Permission"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update a permission object.
If updateing the permission object would result in duplicate permission (same target, action and principal) this permission will get deleted and the existing permission will be returned.
Please remember that ids can't be changed."},"delete":{"operationId":"PermissionController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponsePermission"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Permission"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Deletes the permission whose id you provide.
If no permission with this id exists it will just return 204(no content)."}},"/api/teams":{"get":{"operationId":"RunnerTeamController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunnerTeam"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner Team"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all teams.
This includes their parent organisation and contact (if existing/associated)."},"post":{"operationId":"RunnerTeamController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunnerTeam"}}},"description":"CreateRunnerTeam","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""}},"summary":"Post","tags":["Runner Team"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new organsisation.
Please remember to provide it's parent group's id."}},"/api/teams/{id}":{"get":{"operationId":"RunnerTeamController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner Team"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the team whose id got provided."},"put":{"operationId":"RunnerTeamController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunnerTeam"}}},"description":"UpdateRunnerTeam","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner Team"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the team whose id you provided.
Please remember that ids can't be changed."},"delete":{"operationId":"RunnerTeamController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerTeam"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerTeamHasRunnersError"}}},"description":""}},"summary":"Remove","tags":["Runner Team"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the team whose id you provided.
If the team still has runners associated this will fail.
To delete the team with all associated runners set the force QueryParam to true (cascading deletion might take a while).
If no team with this id exists it will just return 204(no content)."}},"/api/organisations":{"get":{"operationId":"RunnerOrganisationController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Runner Organisation"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all organisations.
This includes their address, contact and teams (if existing/associated)."},"post":{"operationId":"RunnerOrganisationController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRunnerOrganisation"}}},"description":"CreateRunnerOrganisation","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""}},"summary":"Post","tags":["Runner Organisation"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new organsisation."}},"/api/organisations/{id}":{"get":{"operationId":"RunnerOrganisationController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Runner Organisation"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the organisation whose id got provided."},"put":{"operationId":"RunnerOrganisationController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateRunnerOrganisation"}}},"description":"UpdateRunnerOrganisation","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunnerOrganisationIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Runner Organisation"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the organisation whose id you provided.
Please remember that ids can't be changed."},"delete":{"operationId":"RunnerOrganisationController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseRunnerOrganisation"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""},"406":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/RunnerOrganisationHasTeamsError"},{"$ref":"#/components/schemas/RunnerOrganisationHasRunnersError"}]}}},"description":""}},"summary":"Remove","tags":["Runner Organisation"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the organsisation whose id you provided.
If the organisation still has runners and/or teams associated this will fail.
To delete the organisation with all associated runners and teams set the force QueryParam to true (cascading deletion might take a while).
If no organisation with this id exists it will just return 204(no content)."}},"/api/status":{"get":{"operationId":"StatusController.get","responses":{"200":{"content":{"application/json":{}},"description":"Successful response"}},"summary":"Get","tags":["Status"],"description":"A very basic status/health endpoint that just checks if the database connection is available.
The available information depth will be expanded later."}},"/api/tracks":{"get":{"operationId":"TrackController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ResponseTrack"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["Track"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all tracks."},"post":{"operationId":"TrackController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTrack"}}},"description":"CreateTrack","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""}},"summary":"Post","tags":["Track"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new track.
Please remember that the track's distance must be greater than 0."}},"/api/tracks/{id}":{"get":{"operationId":"TrackController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackNotFoundError"}}},"description":""}},"summary":"Get one","tags":["Track"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the track whose id got provided."},"put":{"operationId":"TrackController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Track"}}},"description":"Track","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["Track"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the track whose id you provided.
Please remember that ids can't be changed."},"delete":{"operationId":"TrackController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseTrack"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["Track"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the track whose id you provided.
If no track with this id exists it will just return 204(no content)."}},"/api/users":{"get":{"operationId":"UserController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/User"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["User"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all users.
This includes their groups and permissions directly granted to them (if existing/associated)."},"post":{"operationId":"UserController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUser"}}},"description":"CreateUser","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/User"},{"$ref":"#/components/schemas/UserGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["User"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new user.
If you want to grant permissions to the user you have to create them seperately by posting to /api/permissions after creating the user."}},"/api/users/{id}":{"get":{"operationId":"UserController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserNotFoundError"}}},"description":""}},"summary":"Get one","tags":["User"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the user whose id got provided.
Please remember that only permissions granted directly to the user will show up here, not permissions inherited from groups."},"put":{"operationId":"UserController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateUser"}}},"description":"UpdateUser","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["User"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the user whose id you provided.
To change the permissions directly granted to the user please use /api/permissions instead.
Please remember that ids can't be changed."},"delete":{"operationId":"UserController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["User"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the user whose id you provided.
If there are any permissions directly granted to the user they will get deleted as well.
If no user with this id exists it will just return 204(no content)."}},"/api/usergroups":{"get":{"operationId":"UserGroupController.getAll","responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/UserGroup"},"type":"array"}}},"description":""}},"summary":"Get all","tags":["User Group"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all groups.
The information provided might change while the project continues to evolve."},"post":{"operationId":"UserGroupController.post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateUserGroup"}}},"description":"CreateUserGroup","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"oneOf":[{"$ref":"#/components/schemas/UserGroup"},{"$ref":"#/components/schemas/UserGroupNotFoundError"}]}}},"description":""}},"summary":"Post","tags":["User Group"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Create a new group.
If you want to grant permissions to the group you have to create them seperately by posting to /api/permissions after creating the group."}},"/api/usergroups/{id}":{"get":{"operationId":"UserGroupController.getOne","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupNotFoundError"}}},"description":""}},"summary":"Get one","tags":["User Group"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Lists all information about the group whose id got provided.
The information provided might change while the project continues to evolve."},"put":{"operationId":"UserGroupController.put","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":"UserGroup","required":false},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}},"description":""},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupNotFoundError"}}},"description":""},"406":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroupIdsNotMatchingError"}}},"description":""}},"summary":"Put","tags":["User Group"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Update the group whose id you provided.
To change the permissions granted to the group please use /api/permissions instead.
Please remember that ids can't be changed."},"delete":{"operationId":"UserGroupController.remove","parameters":[{"in":"path","name":"id","required":true,"schema":{"type":"number"}},{"in":"query","name":"force","required":false,"schema":{"type":"boolean"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseUserGroup"}}},"description":""},"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResponseEmpty"}}},"description":""}},"summary":"Remove","tags":["User Group"],"security":[{"AuthToken":[]},{"RefreshTokenCookie":[]}],"description":"Delete the group whose id you provided.
If there are any permissions directly granted to the group they will get deleted as well.
Users associated with this group won't get deleted - just deassociated.
If no group with this id exists it will just return 204(no content)."}}}} \ No newline at end of file