All you have to do is GET one of these URLs:
http://api.automeme.net/texthttp://api.automeme.net/htmlhttp://api.automeme.net/text.jsonhttp://api.automeme.net/html.jsontext may be abbreviated to txt.api.autome.me also works.\n)..json to the URL.There are some differences between text and
html output:
text |
html |
||
|---|---|---|---|
| Emphasis | _DERP_ |
<em>DERP</em> |
DERP |
| Smart quotes | IT'S |
IT’S |
IT’S |
| Ellipsis | ... |
… |
… |
| Em dash | -- |
— |
— |
| Snowman | SNOWMAN |
☃ |
☃ |
html uses some HTML entities,
and <em> tags for emphasis.text will try to use the ASCII equivalents.Ten memes are returned by default. This can be changed by appending
?lines=n to the URL, where n is a
number in the range 1–80. For example: http://api.automeme.net/text?lines=25
If you liked Automeme before it was cool, use the vocab=hipster
parameter for some unique hipster words.
Significant changes to the API will be posted to the Automeme blog.
curl api.automeme.net/text?lines=1
var url = 'http://api.automeme.net/text.json',
memes = [];
$.getJSON(url, function(result) {
memes = result;
console.log(result[0]);
});
import urllib
url = 'http://api.automeme.net/text'
memes = urllib.urlopen(url).read().splitlines()
print memes[0]
require 'open-uri'
url = 'http://api.automeme.net/text'
memes = open(url).read.split("\n")
puts memes.first
use LWP::Simple;
getprint 'http://api.automeme.net/text?lines=1';
$url = 'http://api.automeme.net/text?lines=1';
$meme = file_get_contents($url);
echo $meme;
Old API commands are still supported:
| Current API | Old API |
|---|---|
/text |
/moar.txt |
/html |
/moar.html |
/text.json |
/moar.txt.json |
/html.json |
/moar.html.json |
The domain names automeme.net and
meme.boxofjunk.ws can still be used for now, but only the old commands
will work with these.
Ruby example by jamiew. Perl example by perigrin. PHP example by epochblue.
« Return