pkshultz / michigan-memes

The open source meme generator.

Home Page:https://memegen.link

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

memegen.link

An API to generate meme images based solely on requested URLs.

Unix: Unix Build Status Windows: Windows Build Status
Metrics: Coverage Status Scrutinizer Code Quality
Issues: Stories in Ready

Generating Images

Visit http://memegen.link/api to browse the API and view examples.

The URLs contain all the information necessary to generate the image. For example, http://memegen.link/buzz/memes/memes-everywhere.jpg produces:

Sample Image

But, the site can also produce masked URLs to conceal the joke:

http://memegen.link/_YnV6egltZW1lcy9tZW1lcy1ldmVyeXdoZXJl.jpg

For any image, lose the extension to see a list of all format options:

http://memegen.link/buzz/memes/memes-everywhere

Special Characters

In URLs, spaces can be inserted using dashes or underscores:

  • dash (-) → space ( )
  • underscore (_) → space ( )
  • 2 dashes (--) → dash (-)
  • 2 underscores (__) → underscore (_)

Reserved URL characters can be escaped:

  • tilde + Q (~q) → question mark (?)
  • tilde + P (~p) → percentage (%)
  • tilde + H (~h) → hashtag/pound (#)
  • tilde + S (~s) → slash (/)
  • 2 single qutoes ('') → double quote (")

For example, http://memegen.link/doge/~hspecial-characters~q/underscore__-dash--.jpg produces:

Escaped Characters

Alternate Styles

Some memes come in multiple forms, which can be selected via ?alt=<style>:

Template with Styles

For example: http://memegen.link/sad-biden/sad-joe-biden/doesn't-think-you'll-vote.jpg?alt=scowl

Or, you can use your own image URL as the style. For example, http://memegen.link/custom/my-pretty/background.jpg?alt=http://www.gstatic.com/webp/gallery/1.jpg produces:

Custom Background

Alternate Fonts

Additional fonts are available (see: http://memegen.link/api/fonts) and can be selected via ?font=<name>.

For example, http://memegen.link/joker/pick-a-different-font/people-lose-their-minds.jpg?font=typoline-demo produces:

Custom Font

Custom sizes

Images can be scaled to a specific width via ?width=<int> or a specific height via ?height= <int>. If both parameters are provided, the image will be padded to the exact dimensions.

For example, https://memegen.link/both/width-or-height/why-not-both~q.jpg?height=350&width=600 produces:

Custom Size

Preview Images

API clients that want to show a preview of an image while the user is still typing should disable caching and analytics via ?preview=true.

Social Media

Add ?share=true to optimize images sizes for sharing on social media.

Adding Templates

To add a new template, please follow the contributor instructions.

Thanks go to danieldiekmeier/memegenerator for the inspiration!

Sample Clients

Type Language Source Link
Slack Python nicolewhite/slack-meme ---
Slack Go CptSpaceToaster/slackbot ---
Slack --- --- http://www.memetizer.com
Hain JavaScript Metrakit/hain-plugin-meme ---
Website Clojure jasich/mighty-fine-memes http://www.mightyfinememes.com

Additional clients can be found by searching for code examples on GitHub.

About

The open source meme generator.

https://memegen.link

License:MIT License


Languages

Language:Python 68.4%Language:HTML 19.7%Language:Makefile 6.3%Language:CSS 4.6%Language:JavaScript 0.8%Language:Shell 0.2%