Versions in this module Expand all Collapse all v0 v0.11.1 May 9, 2026 v0.11.0 May 9, 2026 v0.10.0 May 5, 2026 v0.9.5 May 4, 2026 v0.9.4 May 4, 2026 v0.9.3 May 4, 2026 v0.9.2 May 4, 2026 v0.9.1 May 4, 2026 v0.9.0 May 4, 2026 Changes in this version + var ErrNotFound = fmt.Errorf("resource not found") + func Do(req *http.Request) (*http.Response, error) + func DoAndParse[T any](req *http.Request) (val T, err error) + func NewAPIv2Request(ctx context.Context, method, path string, body io.Reader) (*http.Request, error) + func NewWebRequest(ctx context.Context, method, path string, body io.Reader) (*http.Request, error) + func SetAuthHeader(req *http.Request, accessToken string) + func SetDefaultHeaders(req *http.Request) + type BatchResponse struct + Users []UserFromBatch + type Beatmap struct + DifficultyRating float32 + ID int + MaxCombo int + TotalLength int + type BeatmapExtended struct + AR float32 + BPM float32 + BeatmapSetId int + type BeatmapSet struct + Artist string + Covers Covers + FavouriteCount int + PreviewURL string + Title string + type Client struct + func NewClient(clientID, clientSecret string) *Client + func (c *Client) DownloadReplay(ctx context.Context, accessToken string, scoreId int) ([]byte, error) + func (c *Client) ExchangeToken(ctx context.Context, code, redirectUri string) (ExchangeTokenResponse, error) + func (c *Client) GetClientAccessToken(ctx context.Context) (ClientToken, error) + func (c *Client) GetMe(ctx context.Context, accessToken string) (UserExtended, error) + func (c *Client) GetMultiRooms(ctx context.Context, accessToken string) ([]MultiRoom, error) + func (c *Client) GetRankings(ctx context.Context, accessToken string, cursor *Cursor, opts ...RankingsOpts) (Rankings, error) + func (c *Client) GetScore(ctx context.Context, accessToken string, scoreId int) (Score, error) + func (c *Client) GetUser(ctx context.Context, accessToken string, userId int) (UserExtended, error) + func (c *Client) GetUserScores(ctx context.Context, accessToken string, userId int, limit, offset int) ([]Score, error) + func (c *Client) GetUsers(ctx context.Context, accessToken string, userIds []int) (BatchResponse, error) + func (c *Client) TokenRefresh(ctx context.Context, refreshToken string) (ExchangeTokenResponse, error) + type ClientToken struct + AccessToken string + ExpiresIn int + TokenType string + type Covers struct + SlimCoverURL string + type Cursor struct + Page int + type ExchangeTokenResponse struct + AccessToken string + ExpiresIn int + RefreshToken string + TokenType string + func (r ExchangeTokenResponse) ExpiresAt() time.Time + type MultiRoom struct + RecentParticipants []User + type Rankings struct + Cursor *Cursor + Ranking []UserStats + type RankingsOpts struct + Country *string + type Ruleset string + var ModeCatch Ruleset = "fruits" + var ModeMania Ruleset = "mania" + var ModeStandard Ruleset = "osu" + var ModeTaiko Ruleset = "taiko" + type Score struct + Accuracy float32 + Beatmap BeatmapExtended + BeatmapID int + BeatmapSet BeatmapSet + HasReplay bool + ID int + Mods []ScoreMod + PP float32 + ReplayLegacy bool + Statistics ScoreStatistics + User User + UserId int + func (s Score) ModsAcronyms() []string + func (s Score) Replay() bool + type ScoreMod struct + Acronym string + type ScoreStatistics struct + Great *int + Meh *int + Miss *int + Ok *int + type User struct + AvatarURL string + CountryCode string + ID int + IsActive bool + IsBot bool + IsDeleted bool + IsOnline bool + IsSupporter bool + LastVisit time.Time + Statistics UserStatistics + Username string + type UserExtended struct + CoverURL string + Discord string + HasSupported bool + Interests string + JoinDate time.Time + Location *string + MaxBlocks int + MaxFriends int + Occupation *string + Playmode string + Playstyle []string + PostCount int + ProfileHue *int + ProfileOrder []string + Title *string + TitleURL *string + Twitter *string + Website *string + type UserFromBatch struct + AvatarURL string + CountryCode string + ID int + IsActive bool + IsBot bool + IsDeleted bool + IsOnline bool + IsSupporter bool + LastVisit time.Time + StatisticsRulesets struct{ ... } + Username string + type UserStatistics struct + GlobalRank int + PP float32 + type UserStats struct + GlobalRank int + PP float32 + User User