OpenGraph.io API documentation

Site lookup 🕵

REQUEST

GET https://opengraph.io/api/1.1/site/

<URL encoded site URL>?app_id=xxxxxx

REQUEST PARAMETERREQUIREDEXAMPLEDESCRIPTION

cache_ok

no

false

This will force our servers to pull a fresh version of the site being requested. By default this value is true

max_cache_age

no

432000000

This specifies the maximum age in milliseconds that a cached response should be. If not specified the value is set to 5 days. (5 days * 24 hours * 60 minutes * 60 seconds * 1000 ms = 432,000,000 ms)

accept_lang

no

en-US,en;q=0.9 auto

This specifies the request language sent when requesting the url. This is useful if you want to get the site for languages other than english. The default setting for this will return an english version of a page if it exists. Note: if you specify the value auto the api will use the same language settings of your current request. For more information on what to supply for this field please see: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Language

app_id

yes

The API key for registered users.  Create an account (no cc ever required) to receive your app_id.

full_render

no

false

This will fully render the site using a chrome browser before parsing its contents. This is especially helpful for single page applications and JS redirects. This will slow down the time it takes to get a response by around 1.5 seconds.

use_proxy

no

false

Route your request through residential and mobile proxies to avoid bot detection. This will slow down requests 3-10 seconds and can cause requests to time out. NOTE: Proxies are a limited resource and expensive for our team maintain. Free accounts share a small pool of proxies. If you plan on using proxies often, paid accounts provide dedicated concurrent proxies for your account.

Response ElementParentDescription

hybridGraph

As much of the Open Graph data that can be inferred from the site requested. Our service will first check for proper OG tags on the site. If they exist the hybridGraph element will mirror them. For elements that are not discovered, our service will analyze the site’s markup to make best guesses for each OG data point where possible.For the quickest solution, we recommend you use this for your application if you just need to know basic information about the site

url

The url that was provided in the request. The URL must be URL Encoded. Please be sure to only URL encode the site. Do not URL encode the parameters you provide to the API such as the app_id. GOOD: https://opengraph.io/api/1.1/site/https%3A%2F%2Fwww.reddit.com%2Fr%2Fvideos%2F?app_id=XX BAD: https://opengraph.io/api/1.1/site/https://www.reddit.com/r/videos/?app_id=XX BAD: https://opengraph.io/api/1.1/site/https%3A%2F%2Fwww.reddit.com%2Fr%2Fvideos%2F%3Fapp_id%3DXX

htmlInferred

The resulting relevant information found when parsing the site’s markup.

openGraph

The OpenGraph tags pulled from the site. These values will be empty if there are no tags specified for a page. In most cases, you should probably be using the `hybridGraph` element

Example Response: ( http://opengraph.io/api/1.1/site/http%3A%2F%2Fmailchimp.com?app_id=YOURAPPID )

 {
    "hybridGraph": {
       "url": "http://mailchimp.com",
       "hybridGraph": {
       "title": "Send Better Email | MailChimp",
       "description": "MailChimp is the best way to design, send, and share email newsletters.",
       "image": "http://static.mailchimp.com/www/images/freddie-opengraph.png",
       "url": "http://mailchimp.com/",
       "type": "website",
       "site_name": "MailChimp"
 },
    "openGraph": {
       "error": null,
       "title": "Send Better Email | MailChimp",
       "type": "website",
       "admins": "4302132",
       "site_name": "MailChimp",
       "image": "http://static.mailchimp.com/www/images/freddie-opengraph.png",
       "url": "http://mailchimp.com/",
       "description": "MailChimp is the best way to design, send, and share email newsletters."
 },
    "htmlInferred": {
       "title": "Send Better Email | MailChimp",
       "description": "The latest album from Urban Seekers drops this Tuesday at finer record shops across the country. Stream the new album on the Double Double website and be sure to check out dates for the upcoming Urban Seekers tour.",
       "images": [
          "http://static.mailchimp.com/web/home/animation/neo.png"
       ],
      "image_guess": "http://static.mailchimp.com/web/home/animation/neo.png"
 },
    "_id": "530ef2bd4792516eea434270",
    "__v": 0,
    "accessed": 1,
    "updated": "2014-02-27T08:09:33.488Z",
    "created": "2014-02-27T08:09:33.487Z"
 }