Tenor GIF API

Request API Key

Become a Tenor API Partner

Partners Include

Tenor's API helps partners drive a daily use–case around visual expression in messaging, chat and community apps of all kinds, free of charge.

Highlights include:

  • Search and browse for relevant GIFs by term, emoji, or entire conversations.
  • Support for 30+ languages
  • Optimized for mobile to deliver GIFs that load fast and consume less bandwidth
  • Support for content–rating filters
  • Support for video (including audio)

An extended API is also available for partners with 10M+ Daily Active Users

Tags

Get a list of popular or promoted tags and categories.

https://api.tenor.co/v1/tags?key=LIVDSRZULELA

Parameters:

NameTypeRequiredDefault ValueDescription
typestringnofeaturedspecify a category of tags to retrieve. Possible values: "featured", "explore". Multiple types can be specified, each type separated with a comma

Examples:

https://api.tenor.co/v1/tags?key=LIVDSRZULELA

https://api.tenor.co/v1/tags?key=LIVDSRZULELA&type=featured,explore

Response:

{
  "tags": [
    {
      "searchterm": "hello", 
      "path": "https://api.tenor.co/v1/search?tag=hello", 
      "image": "https://media.tenor.co/images/6088f94e6eb5dd7584dedda0fe1e52e1/raw", 
      "name": "#hello"
    }, 
    {
      "searchterm": "mindblown", 
      "path": "https://api.tenor.co/v1/search?tag=mindblown", 
      "image": "https://media.tenor.co/images/5f99e73ac47aaa89758e32b57a26d418/raw", 
      "name": "#mindblown"
    }, 
    {
      "searchterm": "omg", 
      "path": "https://api.tenor.co/v1/search?tag=omg", 
      "image": "https://media.tenor.co/images/e7071c31f53d2b2b411346a7f4838cfc/raw", 
      "name": "#omg"
    }, 
    {
      "searchterm": "bye", 
      "path": "https://api.tenor.co/v1/search?tag=bye", 
      "image": "https://media.tenor.co/images/6627db4ce5f307a5647b6445d63e542a/raw", 
      "name": "#bye"
    }
  ]
}

Video Clips

Get popular video clips

https://api.tenor.co/v1/music?key=LIVDSRZULELA

Parameters:

NameTypeRequiredDefault ValueDescription
keystringyesn/aclient key for privileged API access
limitintegerno20fetch up to a specified number of results (max: 50).
posstringnon/aget results starting at position "value". Use a non-zero "next" value returned by API results to get the next set of results. pos is not an index and may be an integer, float, or string

Examples:

https://api.tenor.co/v1/music?key=LIVDSRZULELA&limit=10

Response:

GIFs

Get GIFs by their IDs.

https://api.tenor.co/v1/gifs?ids=<ids>&key=LIVDSRZULELA

Parameters:

NameTypeRequiredDefault ValueDescription
idsstringyesn/aa comma separated list of GIF IDs (max: 50)
keystringyesn/aclient key for privileged API access

Examples:

https://api.tenor.co/v1/gifs?key=LIVDSRZULELA&ids=5079878,4900007

Response:

Response Objects

Example

{
  "next": "30",
  "results": [
    {
      "id": "3576876",
      "title": "zach galifianakis",
      "url": "http://gif.co/paFI.gif",
      "created": 1417282444.029527,
      "hasaudio": false,
      "tags": [
        "thumbsup",
        "zachgalifianakis"
      ],
      "composite":{
        "video": "https://media.tenor.co/videos/c9125209120e9d2c263f4a0eedb6bacb/mp4",
        "preview": "https://media.tenor.co/images/364c6c1c7de3d4a9c01e4fb1d3ad5c06/raw"
      },
      "media": [
        {
          "tinygif": {
            "url": "https://media.tenor.co/images/a6fff4732f3047440b491cde9ea63409/raw",
            "preview": "https://media.tenor.co/images/d7f352f4c609ebb30b96d157a850bb9d/raw"
          }
          "gif": {
            "url": "https://media.tenor.co/images/65b3da99d3626f98e84f014f01d62b31/raw",
            "preview": "https://media.tenor.co/images/364c6c1c7de3d4a9c01e4fb1d3ad5c06/raw"
          },
          "mp4": {
            "url": "https://media.tenor.co/videos/c9125209120e9d2c263f4a0eedb6bacb/mp4",
            "preview": "https://media.tenor.co/images/364c6c1c7de3d4a9c01e4fb1d3ad5c06/raw"
          },
          "webm": {
            "url": "https://media.tenor.co/videos/e43301b7f50bdbe1fb3c8f43b76264fb/webm",
            "preview": "https://media.tenor.co/images/364c6c1c7de3d4a9c01e4fb1d3ad5c06/raw"
          }
        }
      ]
    }
    ...
  ]
}

Response

KeyValue TypeDescription
nextstringa position identifier to use with the next API query to retrieve the next set of results, or null if there are no further results.
resultsResult[]an array of Result objects, containing GIF and video data

Result

KeyValue TypeDescription
composite{
"video": string,
"preview": string
}
for GIF Stories, a composite video containing all of the individual GIFs in this object in MP4 format, otherwise null.
createdtimestampa unix timestamp representing when this post was created.
hasaudiobooleantrue if this post contains audio (only video formats support audio, the gif image file format can not contain audio information).
idstringTenor result identifier
mediaMediaCollectiona collection of Media objects
tagsstring[]an array of tags for the post
titlestringthe title of the post.
urlstringa short URL to view the post on tenor.co.

MediaCollection

KeyValue TypeDescription
gifMediaa large-format GIF, good for desktop use
mp4Mediaa video version of the GIF
tinygifMediaa small-format GIF, good for mobile use
webmMediaa video version of the GIF

Media

KeyValue TypeDescription
previewstringa url to a preview image of the media source
urlstringa url to the media source

Errors

KeyValue TypeDescription
codenumberan optional numeric code
errorstringa string message describing the error

Examples

{
  "code": 1,
  "error": "Localtime is not a valid naive time (%h:%m)."
}
{
  "code": 5,
  "error": "Valid id is required."
}
{
  "error": "no result"
}

Attribution

All content retrieved from the Tenor API must be properly attributed by including the phrase "Powered by Tenor" where API results are used. You can use either text or one of our "Powered by Tenor" logos.

Get Attribution Logos

API Key

Our docs include a restricted, rate limited example key (LIVDSRZULELA) for you to use while evaluating our API. Before deploying your integration to production, please request your own API key (it's free) so that we can deliver an optimized experience for your audience.

Get API Key

Extended API

We also offer a range of advanced API endpoints and drop-in SDKs that provide a full-set of auto-suggestion, advanced search, and personalization features. We are available to work closely with out partners to help achieve their goals around 5/7 DAU, retention, or engagement by providing a visual expression language used daily.

Request Documentation Access