{"id":41518950,"url":"https://github.com/nodecraft/crafthead","last_synced_at":"2026-01-23T20:44:30.031Z","repository":{"id":38844720,"uuid":"235022077","full_name":"nodecraft/crafthead","owner":"nodecraft","description":"Super scalable Minecraft avatar generation, built on Cloudflare Workers","archived":false,"fork":false,"pushed_at":"2026-01-17T23:22:05.000Z","size":1267,"stargazers_count":95,"open_issues_count":7,"forks_count":8,"subscribers_count":6,"default_branch":"master","last_synced_at":"2026-01-18T11:58:51.752Z","etag":null,"topics":["cloudflare-workers","hacktoberfest","minecraft","minecraft-avatar","rust","typescript"],"latest_commit_sha":null,"homepage":"https://crafthead.net","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nodecraft.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"astei"}},"created_at":"2020-01-20T04:59:00.000Z","updated_at":"2026-01-17T23:22:09.000Z","dependencies_parsed_at":"2026-01-18T01:03:20.900Z","dependency_job_id":null,"html_url":"https://github.com/nodecraft/crafthead","commit_stats":null,"previous_names":["nodecraft/crafthead","astei/crafthead"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nodecraft/crafthead","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nodecraft%2Fcrafthead","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nodecraft%2Fcrafthead/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nodecraft%2Fcrafthead/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nodecraft%2Fcrafthead/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nodecraft","download_url":"https://codeload.github.com/nodecraft/crafthead/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nodecraft%2Fcrafthead/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28699803,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-23T17:25:48.045Z","status":"ssl_error","status_checked_at":"2026-01-23T17:25:47.153Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cloudflare-workers","hacktoberfest","minecraft","minecraft-avatar","rust","typescript"],"created_at":"2026-01-23T20:44:27.383Z","updated_at":"2026-01-23T20:44:30.020Z","avatar_url":"https://github.com/nodecraft.png","language":"TypeScript","funding_links":["https://github.com/sponsors/astei"],"categories":[],"sub_categories":[],"readme":"# Crafthead\n\nCrafthead is a highly scalable, serverless Minecraft avatar rendering\nsolution built on [Cloudflare Workers](https://workers.cloudflare.com).\nIt runs on any of Cloudflare's 200+ datacenters worldwide with minimal\nlatency.\n\n**Note**: if you're a causal browser and wound up here, you probably want\nto go to [Crafthead.net](https://crafthead.net), the public instance\nof Crafthead I run.\n\n## Features\n\n* **Extremely fast**\n* Supports UUID fetching (dashed or not dashed) and username lookups\n* Renders avatars from 8px to 300px\n\n## Overall breakdown\n\nCrafthead is split into two primary components: the request handler frontend,\nwritten in TypeScript, and the image generation logic, written in Rust and\ninvoked by TypeScript by way of WebAssembly. This means it is possible to use\nCrafthead's image generation from within the browser, provided you had another\nmethod of loading the skins from the browser. However, the most convenient way\nto use Crafthead is to use the publicly-hosted instance that does the rendering\non Cloudflare's extensive edge network.\n\nThe request handler (located under the `worker` directory) receives every request\nto Crafthead. It first parses each request to figure out what it is asking for. If\nCrafthead can't determine what the request is, it will use Cloudflare Workers Sites\nto serve the index page or a 404 page. Once it has determined what is to be retrieved\n(and misses the top-level cache), each request is \"normalized\" (essentially, this\nentails changing all username requests to use UUIDs instead) and the skin is looked\nup (all stages of this are cached in Workers KV and in the local cache for speed).\n\nSkin and profile requests are fully serviced by the TypeScript request handler, however if\nan avatar, helm, or cube render (with others TBD) are requested, the skin, size, and render\nrequest are passed to the image generation logic written in Rust (located in `src`). The Rust\ncomponent determines what is to be rendered, loads the skin's PNG using the `image` crate,\nrenders the desired image (using the primitives of the `image` crate and the `1mageproc` crate),\nsaves the PNG into memory, and returns it to the TypeScript request handler to be sent to the client.\nThis is why Crafthead requires a paid Cloudflare Workers plan: image handling is computationally\nexpensive, and the 10ms CPU limit is insufficient for all but the smallest requests.\n\n## Rolling your own\n\n### Step 1: Reconsider\n\nUse the public instance I've made available. You don't have to pay a single\ndime for it. I pick up all the costs. Plus, if you use it, you get speedy\nperformance all the time since it is more likely my instance will be available\nto run immediately compared to yours.\n\nIf, on the other hand, you're looking to _hack_ on Crafthead, then keep reading.\n\n### Step 2: You want to do it?\n\nYou will need to have the following:\n\n* A **paid** Cloudflare Workers plan. The Worker can be Bundled or Unbound,\n  though the production setup is anticipated to be on the Unbound plan in the future.\n  This is because Crafthead uses Workers KV and can easily exceed the CPU limits on\n  the free plan.\n* The `wrangler` CLI.\n* [Node.js](https://nodejs.org).\n* [Rust](https://www.rust-lang.org/learn/get-started).\n* [wasm-pack](https://rustwasm.github.io/wasm-pack/installer/).\n\nThen:\n\n* Copy `wrangler.toml.dev` to `wrangler.toml` and fill in your own `account_id`.\n  in your configuration with the output from the command.\n* Use `npm ci` to install all the development dependencies\n* You may need to remove the `services` section from `wrangler.toml`\n* Use `wrangler publish`. You're done!\n\n### Notes on `wrangler preview`\n\nIf you're looking to test Crafthead using `wrangler preview` or `wrangler dev`,\nyou should use the special-cased usernames `MHF_Steve` and `char`, which return\nthe default \"Steve\" skin. If your code affects username lookups, however, you\nshould consider deploying to `workers.dev` instead.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnodecraft%2Fcrafthead","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnodecraft%2Fcrafthead","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnodecraft%2Fcrafthead/lists"}