Packs
Set a pack's icon
The picture beside the pack's name, in the Studio and in Minecraft's pack list. Either a file (a PNG, JPEG, WebP or GIF, up to 2MB) or the name of one of the pack's block textures, which is what a block's Set as icon does: that texture is the icon from then on, so deleting it leaves the pack without one. Owner or team admin only.
/packs/{pack}/iconPath parameters
packstringrequiredThe pack's slug, as returned by the packs endpoints.
Body
texturestringA block texture's name from the asset listing. Send this or file.
fileobjectThe picture. Exactly one of upload, url, base64 or text.
uploadstringThe upload id from POST /uploads, after PUTting the file to its URL. The way to send anything big, or anything already on disk.
urlstringA public https URL to fetch the file from.
base64stringThe file's bytes as base64 (a data: URI is fine). Up to 8MB.
textstringThe file as text, for formats that are text (model JSON, .bbmodel). Up to 8MB.
Response · 200
Set.
packstringrequiredThe pack.
statusstringrequiredAlways ok.
Error codes
Branch on error.code, never on the message.
file_fetch_failed400A file given by url couldn't be downloaded.
invalid_request400Something in the body or query is wrong. message says what.
invalid_api_key401The key isn't one of ours, or it has been revoked.
missing_api_key401No Authorization: Bearer header was sent.
wrong_key_kind401An MCP key sent to the REST API, or an API key sent to the MCP server. Each only opens its own.
account_suspended403The account is suspended, so its keys open nothing. message says until when, if the suspension has an end date.
forbidden403Valid key, but not permitted to do this in this pack.
plan_required403The key is valid, but its account's plan does not include the API.
not_found404No such pack, asset or job.
upload_not_found404No upload by that id. Uploads expire after fifteen minutes and are used once.
file_too_large413The file is over the limit for what it's being used as. message says the limit.