catalog.media.commit
Commit a staged upload into the media library (variants generated async).
- scope:
catalog:write - storefront-visible (bumps the catalog generation): no
- destructive: no
Payload
| field | type | required | notes |
|---|---|---|---|
sha | string (/^[a-f0-9]{64}$/) | yes | |
mime | "image/jpeg" | "image/png" | "image/webp" | "image/gif" | "image/svg+xml" | yes | |
bytes | integer (1..20971520) | yes | |
width | integer (1..20000) | no | |
height | integer (1..20000) | no |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"sha": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"mime": {
"type": "string",
"enum": [
"image/jpeg",
"image/png",
"image/webp",
"image/gif",
"image/svg+xml"
]
},
"bytes": {
"type": "integer",
"minimum": 1,
"maximum": 20971520
},
"width": {
"type": "integer",
"minimum": 1,
"maximum": 20000
},
"height": {
"type": "integer",
"minimum": 1,
"maximum": 20000
}
},
"required": [
"sha",
"mime",
"bytes"
],
"additionalProperties": false
}Generated from the live platform registries at build time โ reference pages cannot go stale. Markdown variant: /reference/commands/catalog.media.commit.md