memecub

How do I build a meme generator that uses emoji with an open source API?

Build it in three layers: an emoji source (OpenMoji or a Unicode emoji API for the characters and images), a renderer that draws your caption plus emoji onto a template, and a template source. For templates, memecub's REST API returns real memes by search, and its MCP server or CLI lets an AI agent pick and place them; the keyless trial gives 20 searches a day. Keep emoji rendering and meme search separate so you can swap either one later.

Pick your emoji source first

OpenMoji is an open source emoji set you can use for the images themselves; a Unicode emoji API gives you the character plus metadata. Choose OpenMoji if you need consistent artwork you can style, and a Unicode API if you just need the characters and names.

Store emoji as characters (👍) or aliases (:thumbsup:) in your input format, and resolve aliases to characters before rendering. That way users can type either form and your renderer only handles one case.

Render caption plus emoji onto a template

A simple pipeline: load a template image, draw the caption text with a font that includes emoji glyphs, then composite any emoji images at fixed positions. Keep positions in a small config per template so you can add templates without touching code.

Test with a laughing-crying emoji and a distorted or scaled emoji early; those two catch most font and sizing bugs. Escape user text before it reaches your render call so quotes and emoji do not break the string.

Add a meme search API for real templates

Instead of shipping only blank templates, let users search a meme library. memecub's REST API returns memes by search (1 credit per call), and the keyless trial allows 20 searches a day, so you can prototype without a key.

If your generator is agent-driven, connect the remote MCP server at https://memecub.com/mcp, or install the skill with npx skills add https://memecub.com into Claude Code, Codex or Cursor. The CLI npx memecub is handy for quick lookups while developing.

When a search returns nothing that fits, the AI meme maker at /generate can create an image from a character, action and caption description in about 10 seconds. Note that most library memes are collected from the web and are for personal chats, not commercial use; a filter shows openly licensed images for commercial projects.

Tone and etiquette

Keep generated memes clearly labeled as generated, and do not build features that put real people into meme images; memecub's generator refuses real people for the same reason.

Respect licenses: open-source emoji sets and openly licensed images are safe to redistribute, while web-collected memes should stay in personal use. Show the source next to each template in your app.

Nothing quite right? Make one

Pick a character, type a caption, get it in about 10 seconds — free to try.

More that fit

FAQ

How do I generate emoji memes from text programmatically?

Parse the text into caption and emoji tokens, resolve aliases to characters, then render the caption and emoji onto a template image with a library like Pillow or node-canvas. Keep template positions in config so new templates need no code changes.

Is there a free open source emoji meme API?

OpenMoji and Unicode emoji APIs cover the emoji side openly. For meme templates, memecub's REST API has a keyless trial of 20 searches a day, and its free plan includes monthly credits.

Can I use an open source emoji set commercially?

OpenMoji states its emojis are free to use under its license, so check that license before shipping. Web-collected memes are different: copyright stays with the original creators and they are not for commercial use.

How do I connect a meme API to an AI coding agent?

Use the remote MCP server at https://memecub.com/mcp, or install the skill with `npx skills add https://memecub.com` into Claude Code, Codex or Cursor. The agent can then search memes and place them while you build the app.

What if no template matches the emoji I want?

Fall back to a generated image: describe the character, action and caption to an AI meme maker and use the result as the template. memecub's /generate takes about 10 seconds per image and refuses real people.