Function getRaceParticipantsList

  • Returns a list of all participants from a single race by given ID (if it exists).

    Race is identified by its stringified ObjectID.

    Filter options

    • dnf - filter participants by their status of finishing the race.

    Sort options

    • startDate - sort participants by their start date
    • endDate - sort participants by their end date
    • score - sort participants by their score

    Usage

    const raceId: string = "5f5e555d5a578b6";
    const participantsAll: RacePlayer[] = await sdk.getRaceParticipantsList({ raceId });
    const participantsDnf: RacePlayer[] = await sdk.getRaceParticipantsList({ raceId, filter: { dnf: true }});
    const participantsLeaderboards: RacePlayer[] =
    await sdk.getRaceParticipantsList({ raceId, sort: { score: 'desc' }});

    Parameters

    Returns Promise<RacePlayer[]>

Generated using TypeDoc