resolve manual DTOs

This commit is contained in:
2025-12-18 22:19:40 +01:00
parent 4a3087ae35
commit d617654928
179 changed files with 3716 additions and 1257 deletions

View File

@@ -3,7 +3,9 @@ import type {
LeagueAdminProtestsDTO,
ApplyPenaltyCommandDTO,
RequestProtestDefenseCommandDTO,
} from '../../types';
ReviewProtestCommandDTO,
} from '../../types/generated';
import type { RaceProtestsDTO } from '../../types';
/**
* Protests API Client
@@ -32,12 +34,12 @@ export class ProtestsApiClient extends BaseApiClient {
}
/** Review protest */
reviewProtest(input: { protestId: string; stewardId: string; decision: string; decisionNotes: string }): Promise<void> {
reviewProtest(input: ReviewProtestCommandDTO): Promise<void> {
return this.post<void>(`/protests/${input.protestId}/review`, input);
}
/** Get protests for a race */
getRaceProtests(raceId: string): Promise<{ protests: any[] }> {
return this.get<{ protests: any[] }>(`/races/${raceId}/protests`);
getRaceProtests(raceId: string): Promise<RaceProtestsDTO> {
return this.get<RaceProtestsDTO>(`/races/${raceId}/protests`);
}
}