{"openapi":"3.1.0","info":{"title":"Memeoki meme API","version":"2.1.0","description":"Turn a sentence into classic memes with fresh captions, in 21 languages. Free. Every image carries a small memeoki.com mark.","x-logo":{"url":"https://memeoki.com/apple-touch-icon.png"}},"servers":[{"url":"https://memeoki.com"}],"externalDocs":{"url":"https://memeoki.com/llms.txt","description":"Also available as an MCP server at https://memeoki.com/mcp"},"paths":{"/api/memes":{"post":{"operationId":"makeMemes","summary":"Make memes from a sentence","parameters":[{"name":"x-api-key","in":"header","required":false,"schema":{"type":"string"},"description":"Optional free key from POST /api/keys for a higher, tracked daily limit."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["prompt"],"properties":{"prompt":{"type":"string","maxLength":280,"description":"What the meme is about"},"lang":{"type":"string","enum":["en","es","pt","fr","de","it","nl","pl","tr","ru","uk","ar","he","hi","bn","id","vi","th","ja","ko","zh"]},"count":{"type":"integer","minimum":1,"maximum":8,"default":6},"tone":{"type":"string","enum":["weirder","wholesome","roast"],"description":"Optional style"},"only":{"type":"string","description":"Limit to one template id"}}},"example":{"prompt":"when the build passes on the first try","count":3,"lang":"en"}}}},"responses":{"200":{"description":"Memes","content":{"application/json":{"schema":{"type":"object","properties":{"memes":{"type":"array","items":{"type":"object","properties":{"template":{"type":"string","description":"Template id"},"captions":{"type":"object","additionalProperties":{"type":"string"}},"image_url":{"type":"string","format":"uri","description":"Finished PNG with the memeoki.com mark, ready to post"},"edit_url":{"type":"string","format":"uri","description":"Link people can open to remix the meme"},"credit":{"type":"string"}}}}}}}}},"400":{"description":"Missing prompt","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"limit":{"type":"integer"},"resets_at":{"type":"string","format":"date-time"}}}}}},"429":{"description":"Daily limit reached. Get a free key from POST /api/keys or wait until resets_at.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"limit":{"type":"integer"},"resets_at":{"type":"string","format":"date-time"}}}}}}}}},"/r/{template}/{captions}.png":{"get":{"operationId":"renderMeme","summary":"Exact captions on one template, as a PNG (instant, no AI)","parameters":[{"name":"template","in":"path","required":true,"schema":{"type":"string"}},{"name":"captions","in":"path","required":true,"schema":{"type":"string"},"description":"base64url of JSON {slot: text}"},{"name":"w","in":"query","required":false,"schema":{"type":"integer","minimum":120,"maximum":720},"description":"Smaller width for previews"}],"responses":{"200":{"description":"PNG image","content":{"image/png":{}}},"404":{"description":"Unknown template"}}}},"/api/templates":{"get":{"operationId":"listTemplates","summary":"Every template with its caption slots","parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Templates"}}}},"/api/keys":{"post":{"operationId":"createKey","summary":"Get a free API key","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string"},"contact":{"type":"string"}}}}}},"responses":{"201":{"description":"Your key"}}}},"/api/usage":{"get":{"operationId":"getUsage","summary":"Today's usage for your key","parameters":[{"name":"x-api-key","in":"header","required":false,"schema":{"type":"string"},"description":"Optional free key from POST /api/keys for a higher, tracked daily limit."}],"responses":{"200":{"description":"Usage"}}}},"/api/memes/{id}":{"get":{"operationId":"getMeme","summary":"Get a shared meme","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The meme"},"404":{"description":"Not found"}}}}}}