{"openapi":"3.1.0","info":{"title":"Sprite Atlas Shelf Layout","version":"1.0.0","description":"Pack nonrotated sprites into texture pages with a deterministic shelf layout and per-side gutters.","contact":{"email":"jeremy@jeremycarter.ca"}},"servers":[{"url":"https://gptenv-x402-catalog.defcronyke.workers.dev"}],"paths":{"/sprite-atlas-shelf-layout/v1/check":{"post":{"operationId":"sprite_atlas_shelf_layout","summary":"Pack nonrotated sprites into texture pages with a deterministic shelf layout and per-side gutters.","x-payment-info":{"protocols":[{"x402":{}}],"price":{"mode":"fixed","currency":"USD","amount":"0.04"}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"page_width":{"type":"integer","minimum":1,"maximum":16384},"page_height":{"type":"integer","minimum":1,"maximum":16384},"gutter":{"type":"integer","minimum":0,"maximum":64},"sprites":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":80},"width":{"type":"integer","minimum":1,"maximum":16384},"height":{"type":"integer","minimum":1,"maximum":16384}},"required":["id","width","height"],"additionalProperties":false}}},"required":["page_width","page_height","gutter","sprites"],"additionalProperties":false},"example":{"page_width":10,"page_height":10,"gutter":1,"sprites":[{"id":"square","width":5,"height":5},{"id":"thin","width":1,"height":3},{"id":"last","width":8,"height":2},{"id":"oversize","width":10,"height":1}]}}}},"responses":{"200":{"description":"Service result","content":{"application/json":{"schema":{"type":"object"},"example":{"pages":2,"placements":[{"id":"square","width":5,"height":5,"page":1,"x":1,"y":1},{"id":"thin","width":1,"height":3,"page":1,"x":8,"y":1},{"id":"last","width":8,"height":2,"page":2,"x":1,"y":1}],"oversize":["oversize"]}}}},"400":{"description":"Invalid request"},"402":{"description":"x402 exact payment required on Base"},"503":{"description":"Payment unavailable"}}}}}}