No description
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
yxzero 0cd0d0e406 fix: treat shmeado unresponsive page as 429
Shmeado never returns HTTP 429. When their Hypixel fetch fails they
serve a 200 with apiStatusWarningUnresponsive and Invalid Name/UUID
for a real player. Map that page to ErrTooManyRequests.
2026-11-08 15:22:57 +08:00
.gitignore init 2026-06-04 20:45:36 +08:00
bench_test.go init 2026-06-04 20:45:36 +08:00
crafty.go feat: add crafty.gg as a player stats source 2026-11-08 01:02:42 +08:00
crafty_test.go feat: add crafty.gg as a player stats source 2026-11-08 01:02:42 +08:00
crypto.go fix: repair 25karma and skycrypt sources after anti-scraping/build changes 2026-06-17 18:49:27 +08:00
go.mod init 2026-06-04 20:45:36 +08:00
httpstatus.go fix: treat shmeado unresponsive page as 429 2026-11-08 15:22:57 +08:00
httpstatus_test.go feat: add crafty.gg as a player stats source 2026-11-08 01:02:42 +08:00
karma25.go fix: return 429 when any source is rate-limited 2026-08-16 14:01:52 +08:00
karma25_test.go feat: add crafty.gg as a player stats source 2026-11-08 01:02:42 +08:00
README.md feat: add crafty.gg as a player stats source 2026-11-08 01:02:42 +08:00
shmeado.go fix: treat shmeado unresponsive page as 429 2026-11-08 15:22:57 +08:00
shmeado_test.go fix: treat shmeado unresponsive page as 429 2026-11-08 15:22:57 +08:00
skycrypt.go fix: scrape skycrypt profile summary from stats page 2026-11-07 23:43:50 +08:00
skycrypt_test.go fix: scrape skycrypt profile summary from stats page 2026-11-07 23:43:50 +08:00
stats.go init 2026-06-04 20:45:36 +08:00

hypixel-scraper

A Go library for fetching Hypixel player statistics by scraping third-party stat sites. No official API key required.

Sources

Source Function Data
25karma.xyz FetchPlayer Network level, rank, BedWars, SkyWars (primary)
shmeado.club FetchPlayerShmeado Same as above (secondary/fallback)
crafty.gg FetchPlayerCrafty Same as above (secondary/fallback)
sky.shiiyu.moe FetchSkyBlock SkyBlock level, networth, purse, bank

Install

go get github.com/yx-zero/hypixel-scraper

Usage

package main

import (
    "fmt"
    hypixelscraper "github.com/yx-zero/hypixel-scraper"
)

func main() {
    client := hypixelscraper.NewClient()

    // General stats (primary source - 25karma)
    stats, err := client.FetchPlayer("DrDonutt")
    if err != nil {
        panic(err)
    }
    fmt.Printf("%s [%s] - Level %.2f\n", stats.Username, stats.Rank, stats.NetworkLevel)
    fmt.Printf("BedWars: Level %d | FKDR %.2f | %dW/%dL\n",
        stats.BedWarsLevel, stats.BedWarsFKDR, stats.BedWarsWins, stats.BedWarsLosses)
    fmt.Printf("SkyWars: Level %d | KDR %.2f | %dK/%dD\n",
        stats.SkyWarsLevel, stats.SkyWarsKDR, stats.SkyWarsKills, stats.SkyWarsDeaths)

    // General stats (secondary source - shmeado)
    stats2, _ := client.FetchPlayerShmeado("DrDonutt")

    // General stats (secondary source - crafty)
    stats3, _ := client.FetchPlayerCrafty("DrDonutt")

    // SkyBlock stats (SkyCrypt)
    sb, err := client.FetchSkyBlock("56ms")
    if err != nil {
        panic(err)
    }
    fmt.Printf("SkyBlock Level: %.2f\n", sb.SkyBlockLevel)
    fmt.Printf("Networth: %.0f\n", sb.TotalNetworth)
    fmt.Printf("Purse: %.0f | Bank: %.0f\n", sb.Purse, sb.Bank)
}

Custom Transport

The HTTPClient field is exported. You can pass a custom http.RoundTripper at creation or modify it later:

// With a custom transport (proxy, h2, etc.)
client := hypixelscraper.NewClientWithTransport(myTransport)

// Or modify after creation
client := hypixelscraper.NewClient()
client.HTTPClient.Transport = myProxy

Available Fields

PlayerStats (FetchPlayer / FetchPlayerShmeado / FetchPlayerCrafty)

Field Type Description
Username string Minecraft username
UUID string Player UUID
Rank string Hypixel rank (VIP_PLUS, MVP_PLUS, SUPERSTAR, [PIG+++], etc.)
NetworkLevel float64 Hypixel network level
BedWarsLevel int BedWars star level
BedWarsFinalKills int Total BedWars final kills
BedWarsFinalDeaths int Total BedWars final deaths
BedWarsFKDR float64 Final kill/death ratio
BedWarsKills int Total BedWars kills
BedWarsDeaths int Total BedWars deaths
BedWarsKDR float64 Kill/death ratio (non-final)
BedWarsWins int Total BedWars wins
BedWarsLosses int Total BedWars losses
BedWarsBedsBroken int Total beds broken
BedWarsBedsLost int Total beds lost
SkyWarsLevel int SkyWars star level
SkyWarsKills int Total SkyWars kills
SkyWarsDeaths int Total SkyWars deaths
SkyWarsKDR float64 Kill/death ratio

SkyBlockStats (FetchSkyBlock)

Field Type Description
Username string Minecraft username
UUID string Player UUID (dashed)
ProfileName string SkyBlock profile name (Strawberry, Banana, etc.)
SkyBlockLevel float64 SkyBlock level with progress
TotalNetworth float64 Networth in coins (excluding cosmetics)
UnsoulboundNetworth float64 Deprecated, always 0 (no longer exposed without a Cloudflare challenge)
Purse float64 Coins in purse
Bank float64 Coins in bank

How It Works

No headless browsers. Pure HTTP requests with reversed API protections:

  • 25karma.xyz - Reversed their API obfuscation layer (time-based token generation using BigInt prime-chain hashing, XOR'd fingerprint auth, and a full key deobfuscation engine using FNV hashing + xorshift PRNG). Falls back to plain mode if deobfuscation fails. Next anti-scraping update when?
  • shmeado.club - Server-rendered HTML parsing with regex extraction from labeled stat sections.
  • crafty.gg - Uses the JSON API behind their Hypixel pages (api.crafty.gg/api/v2/players/...). Cloudflare there only blocks non-browser User-Agents, so a Chrome UA is enough.
  • sky.shiiyu.moe - The SvelteKit remote API endpoints are now behind a Cloudflare challenge, so we parse the profile summary the server embeds in the stats page's hydration data (devalue uneval JS object literal) instead. One request per lookup.

License

MIT

Sponsors