Documentation ¶
Index ¶
- Variables
- type BannedChampion
- type ChampionInfo
- type ChampionMasteryDTO
- type Client
- type ClientOption
- type CurrentGameInfo
- type CurrentGameParticipant
- type EntriesParams
- type FeaturedGameInfo
- type FeaturedGames
- type GameCustomizationObject
- type Incident
- type LOL
- func (l *LOL) ActiveGames(encryptedSummonerID string) (*CurrentGameInfo, *http.Response, error)
- func (l *LOL) AllChampionMastery(encryptedSummonerID string) (*[]ChampionMasteryDTO, *http.Response, error)
- func (l *LOL) ChallengerLeagues(queue string) (*LeagueListDTO, *http.Response, error)
- func (l *LOL) ChampionMastery(encryptedSummonerID, championID string) (*ChampionMasteryDTO, *http.Response, error)
- func (l *LOL) ChampionRotations() (*ChampionInfo, *http.Response, error)
- func (l *LOL) Entries(queue, tier, division string, params *EntriesParams) ([]LeagueEntryDTO, *http.Response, error)
- func (l *LOL) EntriesBySummoner(encryptedSummonerID string) ([]LeagueEntryDTO, *http.Response, error)
- func (l *LOL) FeaturedGames() (*FeaturedGames, *http.Response, error)
- func (l *LOL) GrandmasterLeagues(queue string) (*LeagueListDTO, *http.Response, error)
- func (l *LOL) LeagueExpEntries(queue, tier, division string, params *LeagueExpEntriesParams) ([]LeagueEntryDTO, *http.Response, error)
- func (l *LOL) Leagues(leagueID string) (*LeagueListDTO, *http.Response, error)
- func (l *LOL) MasterLeagues(queue string) (*LeagueListDTO, *http.Response, error)
- func (l *LOL) MasteryScore(encryptedSummonerID string) (int, *http.Response, error)
- func (l *LOL) Matches(matchID string) (*MatchDTO, *http.Response, error)
- func (l *LOL) Matchlists(encryptedAccountID string, params *MatchlistsParams) (*MatchlistDTO, *http.Response, error)
- func (l *LOL) Status() (*ShardStatus, *http.Response, error)
- func (l *LOL) SummonerByAccount(encryptedAccountID string) (*SummonerDTO, *http.Response, error)
- func (l *LOL) SummonerByID(encryptedID string) (*SummonerDTO, *http.Response, error)
- func (l *LOL) SummonerByName(summonerName string) (*SummonerDTO, *http.Response, error)
- func (l *LOL) SummonerByPUUID(encryptedPUUID string) (*SummonerDTO, *http.Response, error)
- func (l *LOL) Timelines(matchID string) (*MatchTimelineDTO, *http.Response, error)
- type LeagueEntryDTO
- type LeagueExpEntriesParams
- type LeagueItemDTO
- type LeagueListDTO
- type MasteryDTO
- type MatchDTO
- type MatchEventDTO
- type MatchFrameDTO
- type MatchParicipantDTO
- type MatchPositionDTO
- type MatchReferenceDTO
- type MatchTimelineDTO
- type MatchlistDTO
- type MatchlistsParams
- type Message
- type MiniSeriesDTO
- type Observer
- type Participant
- type ParticipantDTO
- type ParticipantIdentityDTO
- type ParticipantStatsDTO
- type ParticipantTimelineDTO
- type Perks
- type PlayerDTO
- type Service
- type ShardStatus
- type SummonerDTO
- type TFT
- func (t *TFT) Challenger() (*LeagueListDTO, *http.Response, error)
- func (t *TFT) Entries(tier, division string, params *EntriesParams) ([]LeagueEntryDTO, *http.Response, error)
- func (t *TFT) EntriesBySummoner(encryptedSummonerID string) ([]LeagueEntryDTO, *http.Response, error)
- func (t *TFT) Grandmaster() (*LeagueListDTO, *http.Response, error)
- func (t *TFT) Leagues(leagueID string) (*LeagueListDTO, *http.Response, error)
- func (t *TFT) Master() (*LeagueListDTO, *http.Response, error)
- func (t *TFT) MatchesByPUUID(encryptedPUUID string) ([]string, *http.Response, error)
- type TeamBansDTO
- type TeamStatsDTO
- type Translation
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type BannedChampion ¶
type ChampionInfo ¶
type ChampionMasteryDTO ¶
type ChampionMasteryDTO struct { ChampionLevel int `json:"championLevel"` ChestGranted bool `json:"chestGranted"` ChampionPoints int `json:"championPoints"` ChampionPointsSinceLastLevel int `json:"championPointsSinceLastLevel"` ChampionPointsUntilNextLevel int `json:"championPointsUntilNextLevel"` SummonerID string `json:"summonerId"` TokensEarned int `json:"tokensEarned"` ChampionID int `json:"championId"` LastPlayTime int64 `json:"lastPlayTime"` }
type ClientOption ¶
ClientOption is a func that operates on *Client
func WithHTTPClient ¶
func WithHTTPClient(httpClient *http.Client) ClientOption
WithHTTPClient set the client http.Client and the sling http.Client
type CurrentGameInfo ¶
type CurrentGameInfo struct { GameID int64 `json:"gameId"` GameStartTime int64 `json:"gameStartTime"` PlatformID string `json:"platformId"` GameMode string `json:"gameMode"` MapID int64 `json:"mapId"` GameType string `json:"gameType"` BannedChampions []BannedChampion `json:"bannedChampions"` Observers Observer `json:"observers"` Participants []CurrentGameParticipant `json:"participants"` GameLength int64 `json:"gameLength"` GameQueueConfigID int64 `json:"gameQueueConfigId"` }
type CurrentGameParticipant ¶
type CurrentGameParticipant struct { ProfileIconID int64 `json:"profileIconId"` ChampionID int64 `json:"championId"` SummonerName string `json:"summonerName"` GameCustomizationObjects []GameCustomizationObject `json:"gameCustomizationObjects"` Bot bool `json:"bot"` Perks Perks `json:"perks"` Spell2ID int64 `json:"spell2Id"` Spell1ID int64 `json:"spell1Id"` TeamID int64 `json:"teamId"` SummonerID string `json:"summonerId"` }
type EntriesParams ¶
type EntriesParams struct {
Page string `url:"page,omitempty"`
}
type FeaturedGameInfo ¶
type FeaturedGameInfo struct { GameID int64 `json:"gameId"` GameStartTime int64 `json:"gameStartTime"` PlatformID string `json:"platformId"` GameMode string `json:"gameMode"` MapID int64 `json:"mapId"` GameType string `json:"gameType"` BannedChampions []BannedChampion `json:"bannedChampions"` Observers Observer `json:"observers"` Participants []CurrentGameParticipant `json:"participants"` GameLength int64 `json:"gameLength"` GameQueueConfigID int64 `json:"gameQueueConfigId"` }
type FeaturedGames ¶
type FeaturedGames struct { ClientRefreshInterval int64 `json:"clientRefreshInterval"` GameList []FeaturedGameInfo `json:"gameList"` }
type GameCustomizationObject ¶
type LOL ¶
type LOL struct {
// contains filtered or unexported fields
}
LOL provides methods to interface with lol resource
func (*LOL) ActiveGames ¶
ActiveGames GET /lol/spectator/v4/active-games/by-summoner/{encryptedSummonerId}
func (*LOL) AllChampionMastery ¶
func (l *LOL) AllChampionMastery(encryptedSummonerID string) (*[]ChampionMasteryDTO, *http.Response, error)
AllChampionMastery GET /lol/champion-mastery/v4/champion-masteries/by-summoner/{encryptedSummonerID}
func (*LOL) ChallengerLeagues ¶
ChallengerLeagues GET /lol/league/v4/challengerleagues/by-queue/{queue}
func (*LOL) ChampionMastery ¶
func (l *LOL) ChampionMastery(encryptedSummonerID, championID string) (*ChampionMasteryDTO, *http.Response, error)
ChampionMastery GET /lol/champion-mastery/v4/champion-masteries/by-summoner/{encryptedSummonerID}/by-champion/{championID}
func (*LOL) ChampionRotations ¶
func (l *LOL) ChampionRotations() (*ChampionInfo, *http.Response, error)
ChampionRotations GET /lol/platform/v3/champion-rotations
func (*LOL) Entries ¶
func (l *LOL) Entries(queue, tier, division string, params *EntriesParams) ([]LeagueEntryDTO, *http.Response, error)
Entries GET /lol/league/v4/entries/{queue}/{tier}/{division}
func (*LOL) EntriesBySummoner ¶
func (l *LOL) EntriesBySummoner(encryptedSummonerID string) ([]LeagueEntryDTO, *http.Response, error)
EntriesBySummoner GET /lol/league/v4/entries/by-summoner/{encryptedSummonerId}
func (*LOL) FeaturedGames ¶
func (l *LOL) FeaturedGames() (*FeaturedGames, *http.Response, error)
FeaturedGames GET /lol/spectator/v4/featured-games
func (*LOL) GrandmasterLeagues ¶
GrandmasterLeagues GET /lol/league/v4/grandmasterleagues/by-queue/{queue}
func (*LOL) LeagueExpEntries ¶
func (l *LOL) LeagueExpEntries(queue, tier, division string, params *LeagueExpEntriesParams) ([]LeagueEntryDTO, *http.Response, error)
LeagueExpEntries GET /lol/league-exp/v4/entries/{queue}/{tier}/{division}
func (*LOL) MasterLeagues ¶
MasterLeagues GET /lol/league/v4/masterleagues/by-queue/{queue}
func (*LOL) MasteryScore ¶
MasteryScore GET /lol/champion-mastery/v4/scores/by-summoner/{encryptedSummonerID}
func (*LOL) Matchlists ¶
func (l *LOL) Matchlists(encryptedAccountID string, params *MatchlistsParams) (*MatchlistDTO, *http.Response, error)
Matchlists GET /lol/match/v4/matchlists/by-account/{encryptedAccountID}
func (*LOL) Status ¶
func (l *LOL) Status() (*ShardStatus, *http.Response, error)
Status GET /lol/status/v3/shard-data
func (*LOL) SummonerByAccount ¶
SummonerByAccount GET /lol/summoner/v4/summoners/by-account/{encryptedAccountID}
func (*LOL) SummonerByID ¶
SummonerByID GET /lol/summoner/v4/summoners/{encryptedID}
func (*LOL) SummonerByName ¶
SummonerByName GET /lol/summoner/v4/summoners/by-name/{summonerName}
func (*LOL) SummonerByPUUID ¶
SummonerByPUUID GET /lol/summoner/v4/summoners/by-puuid/{encryptedPUUID}
type LeagueEntryDTO ¶
type LeagueEntryDTO struct { QueueType string `json:"queueType"` SummonerName string `json:"summonerName"` HotStreak bool `json:"hotStreak"` MiniSeries MiniSeriesDTO `json:"miniSeries"` Wins int `json:"wins"` Veteran bool `json:"veteran"` Losses int `json:"losses"` Rank string `json:"rank"` Tier string `json:"tier"` Inactive bool `json:"inactive"` FreshBlood bool `json:"freshBlood"` LeagueID string `json:"leagueId"` SummonerID string `json:"summonerId"` LeaguePoints int `json:"leaguePoints"` }
type LeagueExpEntriesParams ¶
type LeagueExpEntriesParams struct {
Page string `url:"page,omitempty"`
}
type LeagueItemDTO ¶
type LeagueItemDTO struct { SummonerName string `json:"summonerName"` HotStreak bool `json:"hotStreak"` MiniSeries MiniSeriesDTO `json:"miniSeries"` Wins int `json:"wins"` Veteran bool `json:"veteran"` Losses int `json:"losses"` FreshBlood bool `json:"freshBlood"` Inactive bool `json:"inactive"` Rank string `json:"rank"` SummonerID string `json:"summonerId"` LeaguePoints int `json:"leaguePoints"` }
type LeagueListDTO ¶
type LeagueListDTO struct { LeagueID string `json:"leagueId"` Tier string `json:"tier"` Entries []LeagueItemDTO `json:"entries"` Queue string `json:"queue"` Name string `json:"name"` }
type MasteryDTO ¶
type MatchDTO ¶
type MatchDTO struct { SeasonID int `json:"seasonId"` QueueID int `json:"queueId"` GameID int64 `json:"gameId"` ParticipantIdentities []ParticipantIdentityDTO `json:"participantIdentities"` GameVersion string `json:"gameVersion"` PlatformID string `json:"platformId"` GameMode string `json:"gameMode"` MapID int `json:"mapId"` GameType string `json:"gameType"` Teams []TeamStatsDTO `json:"teams"` Participants []ParticipantDTO `json:"participants"` GameDuration int `json:"gameDuration"` GameCreation int64 `json:"gameCreation"` }
type MatchEventDTO ¶
type MatchEventDTO struct { EventType string `json:"eventType"` TowerType string `json:"towerType"` TeamID int `json:"teamId"` AscendedType string `json:"ascendedType"` KillerID int `json:"killerId"` LevelUpType string `json:"levelUpType"` PointCaptured string `json:"pointCaptured"` AssistingParticipantIDs []int `json:"assistingParticipantIDs"` WardType string `json:"wardType"` MonsterType string `json:"monsterType"` Type string `json:"type"` SkillSlot int `json:"skillSlot"` VictimID int `json:"victimId"` Timestamp int64 `json:"timestamp"` AfterID int `json:"afterId"` MonsterSubType string `json:"monsterSubType"` LaneType string `json:"laneType"` ItemID int `json:"itemId"` ParticipantID int `json:"participantId"` BuildingType string `json:"buildingType"` CreatorID int `json:"creatorId"` Position MatchPositionDTO `json:"position"` BeforeID int `json:"beforeId"` }
type MatchFrameDTO ¶
type MatchFrameDTO struct { Timestamp int `json:"timestamp"` ParticipantFrames map[string]MatchParicipantDTO `json:"participantFrames"` Events []MatchEventDTO `json:"events"` }
type MatchParicipantDTO ¶
type MatchParicipantDTO struct { TotalGold int `json:"totalGold"` TeamScore int `json:"teamScore"` ParticipantID int `json:"participantId"` Level int `json:"level"` CurrentGold int `json:"currentGold"` MinionsKilled int `json:"minionsKilled"` DominionScore int `json:"dominionScore"` Position MatchPositionDTO `json:"position"` XP int `json:"xp"` JungleMinionsKilled int `json:"jungleMinionsKilled"` }
type MatchPositionDTO ¶
type MatchReferenceDTO ¶
type MatchTimelineDTO ¶
type MatchTimelineDTO struct { Frames []MatchFrameDTO `json:"frames"` FrameInterval int }
type MatchlistDTO ¶
type MatchlistDTO struct { Matches []MatchReferenceDTO `json:"matches"` TotalGames int `json:"totalGames"` StartIndex int `json:"startIndex"` EndIndex int `json:"endIndex"` }
type MatchlistsParams ¶
type MiniSeriesDTO ¶
type Participant ¶
type Participant struct { ProfileIconID int64 `json:"profileIconId"` ChampionID int64 `json:"championId"` SummonerName string `json:"summonerName"` Bot bool `json:"bot"` Spell2ID int64 `json:"spell2Id"` Spell1ID int64 `json:"spell1Id"` TeamID int64 `json:"teamId"` SummonerID string `json:"summonerId"` }
type ParticipantDTO ¶
type ParticipantDTO struct { Spell1ID int `json:"spell1Id"` ParticipantID int `json:"participantId"` Timeline ParticipantTimelineDTO `json:"timeline,omitempty"` Spell2ID int `json:"spell2Id"` TeamID int `json:"teamId"` Stats ParticipantStatsDTO `json:"stats"` ChampionID int `json:"championId"` Masteries []MasteryDTO `json:"masteries"` }
type ParticipantIdentityDTO ¶
type ParticipantStatsDTO ¶
type ParticipantStatsDTO struct { NeutralMinionsKilledTeamJungle int `json:"neutralMinionsKilledTeamJungle"` VisionScore int `json:"visionScore"` MagicDamageDealtToChampions int `json:"magicDamageDealtToChampions"` LargestMultiKill int `json:"largestMultiKill"` TotalTimeCrowdControlDealt int `json:"totalTimeCrowdControlDealt"` LongestTimeSpentLiving int `json:"longestTimeSpentLiving"` Perk1Var1 int `json:"perk1Var1"` Perk1Var3 int `json:"perk1Var3"` Perk1Var2 int `json:"perk1Var2"` TripleKills int `json:"tripleKills"` Perk5 int `json:"perk5"` Perk4 int `json:"perk4"` PlayerScore9 int `json:"playerScore9"` PlayerScore8 int `json:"playerScore8"` Kills int `json:"kills"` PlayerScore1 int `json:"playerScore1"` PlayerScore0 int `json:"playerScore0"` PlayerScore3 int `json:"playerScore3"` PlayerScore2 int `json:"playerScore2"` PlayerScore5 int `json:"playerScore5"` PlayerScore4 int `json:"playerScore4"` PlayerScore7 int `json:"playerScore7"` PlayerScore6 int `json:"playerScore6"` Perk5Var1 int `json:"perk5Var1"` Perk5Var3 int `json:"perk5Var3"` Perk5Var2 int `json:"perk5Var2"` TotalScoreRank int `json:"totalScoreRank"` NeutralMinionsKilled int `json:"neutralMinionsKilled"` StatPerk1 int `json:"statPerk1"` StatPerk0 int `json:"statPerk0"` DamageDealtToTurrets int `json:"damageDealtToTurrets"` PhysicalDamageDealtToChampions int `json:"physicalDamageDealtToChampions"` DamageDealtToObjectives int `json:"damageDealtToObjectives"` Perk2Var2 int `json:"perk2Var2"` Perk2Var3 int `json:"perk2Var3"` TotalUnitsHealed int `json:"totalUnitsHealed"` Perk2Var1 int `json:"perk2Var1"` Perk4Var1 int `json:"perk4Var1"` TotalDamageTaken int `json:"totalDamageTaken"` Perk4Var3 int `json:"perk4Var3"` WardsKilled int `json:"wardsKilled"` LargestCriticalStrike int `json:"largestCriticalStrike"` LargestKillingSpree int `json:"largestKillingSpree"` QuadraKills int `json:"quadraKills"` MagicDamageDealt int `json:"magicDamageDealt"` FirstBloodAssist bool `json:"firstBloodAssist"` Item2 int `json:"item2"` Item3 int `json:"item3"` Item0 int `json:"item0"` Item1 int `json:"item1"` Item6 int `json:"item6"` Item4 int `json:"item4"` Item5 int `json:"item5"` Perk1 int `json:"perk1"` Perk0 int `json:"perk0"` Perk3 int `json:"perk3"` Perk2 int `json:"perk2"` Perk3Var3 int `json:"perk3Var3"` Perk3Var2 int `json:"perk3Var2"` Perk3Var1 int `json:"perk3Var1"` DamageSelfMitigated int `json:"damageSelfMitigated"` MagicalDamageTaken int `json:"magicalDamageTaken"` Perk0Var2 int `json:"perk0Var2"` FirstInhibitorKill bool `json:"firstInhibitorKill"` TrueDamageTaken int `json:"trueDamageTaken"` Assists int `json:"assists"` Perk4Var2 int `json:"perk4Var2"` GoldSpent int `json:"goldSpent"` TrueDamageDealt int `json:"trueDamageDealt"` ParticipantID int `json:"participantId"` PhysicalDamageDealt int `json:"physicalDamageDealt"` SightWardsBoughtInGame int `json:"sightWardsBoughtInGame"` TotalDamageDealtToChampions int `json:"totalDamageDealtToChampions"` PhysicalDamageTaken int `json:"physicalDamageTaken"` TotalPlayerScore int `json:"totalPlayerScore"` Win bool `json:"win"` ObjectivePlayerScore int `json:"objectivePlayerScore"` TotalDamageDealt int `json:"totalDamageDealt"` NeutralMinionsKilledEnemyJungle int `json:"neutralMinionsKilledEnemyJungle"` Deaths int `json:"deaths"` WardsPlaced int `json:"wardsPlaced"` PerkPrimaryStyle int `json:"perkPrimaryStyle"` PerkSubStyle int `json:"perkSubStyle"` TurretKills int `json:"turretKills"` FirstBloodKill bool `json:"firstBloodKill"` TrueDamageDealtToChampions int `json:"trueDamageDealtToChampions"` GoldEarned int `json:"goldEarned"` KillingSprees int `json:"killingSprees"` UnrealKills int `json:"unrealKills"` FirstTowerAssist bool `json:"firstTowerAssist"` FirstTowerKill bool `json:"firstTowerKill"` ChampLevel int `json:"champLevel"` DoubleKills int `json:"doubleKills"` InhibitorKills int `json:"inhibitorKills"` FirstInhibitorAssist bool `json:"firstInhibitorAssist"` Perk0Var1 int `json:"perk0Var1"` CombatPlayerScore int `json:"combatPlayerScore"` Perk0Var3 int `json:"perk0Var3"` VisionWardsBoughtInGame int `json:"visionWardsBoughtInGame"` PentaKills int `json:"pentaKills"` TotalHeal int `json:"totalHeal"` TotalMinionsKilled int `json:"totalMinionsKilled"` TimeCCingOthers int `json:"timeCCingOthers"` StatPerk2 int `json:"statPerk2"` }
type ParticipantTimelineDTO ¶
type ParticipantTimelineDTO struct { Lane string `json:"lane"` ParticipantID int `json:"participantId"` CsDiffPerMinDeltas map[string]float64 `json:"csDiffPerMinDeltas"` GoldPerMinDeltas map[string]float64 `json:"goldPerMinDeltas"` XpDiffPerMinDeltas map[string]float64 `json:"xpDiffPerMinDeltas"` CreepsPerMinDeltas map[string]float64 `json:"creepsPerMinDeltas"` XpPerMinDeltas map[string]float64 `json:"xpPerMinDeltas"` Role string `json:"role"` DamageTakenDiffPerMinDeltas map[string]float64 `json:"damageTakenDiffPerMinDeltas"` DamageTakenPerMinDeltas map[string]float64 `json:"damageTakenPerMinDeltas"` }
type PlayerDTO ¶
type PlayerDTO struct { CurrentPlatformID string `json:"currentPlatformId"` SummonerName string `json:"summonerName"` MatchHistoryURI string `json:"matchHistoryUri"` PlatformID string `json:"platformId"` CurrentAccountID string `json:"currentAccountId"` ProfileIcon int `json:"profileIcon"` SummonerID string `json:"summonerId"` AccountID string `json:"accountId"` }
type ShardStatus ¶
type SummonerDTO ¶
type TFT ¶
type TFT struct {
// contains filtered or unexported fields
}
TFT provides methods to interface with tft resource
func (*TFT) Challenger ¶
func (t *TFT) Challenger() (*LeagueListDTO, *http.Response, error)
Challenger GET /tft/league/v1/challenger
func (*TFT) Entries ¶
func (t *TFT) Entries(tier, division string, params *EntriesParams) ([]LeagueEntryDTO, *http.Response, error)
Entries GET /tft/league/v1/entries/{tier}/{division}
func (*TFT) EntriesBySummoner ¶
func (t *TFT) EntriesBySummoner(encryptedSummonerID string) ([]LeagueEntryDTO, *http.Response, error)
EntriesBySummoner GET /tft/league/v1/entries/by-summoner/{encryptedSummonerID}
func (*TFT) Grandmaster ¶
func (t *TFT) Grandmaster() (*LeagueListDTO, *http.Response, error)
Grandmaster GET /tft/league/v1/grandmaster
type TeamBansDTO ¶
type TeamStatsDTO ¶
type TeamStatsDTO struct { FirstDragon bool `json:"firstDragon"` Bans []TeamBansDTO `json:"bans"` FirstInhibitor bool `json:"firstInhibitor"` Win string `json:"win"` FirstRiftHerald bool `json:"firstRiftHerald"` FirstBaron bool `json:"firstBaron"` BaronKills int `json:"baronKills"` RiftHeraldKills int `json:"riftHeraldKills"` FirstBlood bool `json:"firstBlood"` TeamID int `json:"teamId"` FirstTower bool `json:"firstTower"` VilemawKills int `json:"vilemawKills"` InhibitorKills int `json:"inhibitorKills"` TowerKills int `json:"towerKills"` DominionVictoryScore int `json:"dominionVictoryScore"` DragonKills int `json:"dragonKills"` }