pinterest api documentation [closed]
Asked Answered
M

10

98

Update Aug 2015: Pinterest provides it here now https://dev.pinterest.com/

Is there official or unofficial documentation on the v2 Pinterest API?

Things I know:

Update Mar 4 2014 Pinterest has unveiled a beta v3 API which you can request access to. Scroll down the page and you'll see the endpoints listed in the left column. https://developers.pinterest.com/api_docs/

Update Jan 9 2013 Since https://api.pinterest.com/v2 gives a 404, it seems to have been moved to v3. https://api.pinterest.com/v3

{ "status": "failure", "code": 11, "host": "053", "generated_at": "Wed, 09 Jan 2013 10:25:27 +0000", "message": "API method not found.", "data": null }

Update Nov 19, 2012 The unofficial api documentation at http://tijn.bo.lt/pinterest-api is gone, along with their entire website. I'm leaving the link in this post because it may come back online. Still no word from Pinterest to developers on their api status.

Update May 22, 2012 Pinterest has still not provided a public api. People are connecting to the api endpoints as the iPhone user agent, which is available to the iOS app

Update Apr 17, 2012 Thanks to tijn, we have unofficial version 1(now v2) Pinterest api docs, and reports that only read endpoints are currently available so RSS style feeds are possible within rate limits.

Update Apr 3, 2012 The unofficial Facebook group has some quality info on it and several people asking questions and posting fairly useful responses

Maplemaples answered 30/3, 2012 at 22:11 Comment(12)
That's a good tip on the iPhone endpoint. I hadn't heard about that.Bindweed
@DigitalBiscuits thanks for the heads up on tjin's website going downMaplemaples
any updates? seems this has gone stale :xOssa
@Ossa Pinterest has been silent about public development. My hunch is that they are nurturing a private, albeit quiet, third party developer network. There are a lifeless blog engineering.pinterest.com and Github account github.com/pinterest collecting dust.Maplemaples
Even among the unofficial ones and the older one I see only possibility to work on or get data for the logged in user. I wanted to do something like a keyword search :( for such a seemingly up and coming social platform I find this very irregular. Stats show me that the traffic from pinterest far exceeds twitter and I'm always tweeting..something to be learned here !Audie
request api access here: developers.pinterest.com/api_requestRattrap
@JPHellemons thanks, just made another request but haven't had a response in the past.Maplemaples
The link that you provide for the pins: api.pinterest.com/v3/pidgets/boards/[username]/[board_name]/… does only retrieve a few pins, do you know if there is any way to specify an offset? I tried w/o the API, but there is a "bookmarks" parameter used to retrieve each page and I have no idea about how to generate it.Burgoo
Sorry, not sure @BurgooMaplemaples
Right now api documentation shows "none" everywhere. Is the api still working?Youngster
@Youngster no problems for meMaplemaples
Any update regarding May 2018, many users facing Token Generation error now, I am also.Drennan
N
38

There is no Official API Docs available for Pinterest as of today.

But there is the unofficial documentation for v2 here: http://tijn.bo.lt/pinterest-api

Norvil answered 15/4, 2012 at 22:13 Comment(8)
Glad to see tijn updated it for v2, thanksMaplemaples
+1 Against @MikeGraceStoddart
@EncorePTL, I tried the curl requests listed tijn.bo.lt/pinterest-api but everything returns 404 for me, are all of these disabled?Divine
tijn.bo.lt is a dead link.Planer
you can still get it on internet archive: web.archive.org/web/20130308101718/http://tijn.bo.lt/…Felicefelicia
any jar file for pintrestNaturalize
links not workingArie
both links not working anymore.Drennan
N
65

I want to offer an update on the current status of the Pinterest API.

There is still no public API available. Pinterest also does not seem to be approving anyone who applies for access on their site.

As of right now, the endpoints of the Pinterest v3 API are almost complete although there is no official documentation. Below is a brief list of the types of endpoints that are available:

https://api.pinterest.com/v3/users/
https://api.pinterest.com/v3/search/
https://api.pinterest.com/v3/domains/
https://api.pinterest.com/v3/categories/
https://api.pinterest.com/v3/oauth/
https://api.pinterest.com/v3/boards/
https://api.pinterest.com/v3/pins/
https://api.pinterest.com/v3/batch/
https://api.pinterest.com/v3/login/

You may discover many sub-endpoints to each of the endpoint above. I do have a list of many available endpoints, but since they're not public, I'm not going to post them here (Hint: Most of them are easy to guess). All of the above endpoints require an access_token parameter except for the login endpoint.

To generate a valid access_token, the developer will need to be granted access to the API by Pinterest which we all know is currently almost impossible.

Another option is to write a script to simulate a log in action to the /v3/login endpoint with your Pinterest username and password. It will return an access_token if request is successful. I'm not going into details about how this is done, as this is never meant to be part of the public API and is meant only for users logging into Pinterest on their mobile app.

However, you can generate access token for your Pinterest account for existing apps that have been approved by Pinterest such as the Pinterest for iPhone:

https://www.pinterest.com/oauth/?consumer_id=1431594&response_type=token

You will see that the access_token is returned in the hash of the URL. You can now use this access_token to play with the endpoints and it is valid for one month. Have fun discovering them!

Endpoints that are public and do not require access_token:

Pins with a known username and known board name:

https://api.pinterest.com/v3/pidgets/boards/[username]/[board_name]/pins/

Pins with a known username:

https://api.pinterest.com/v3/pidgets/users/[username]/pins/

Retrieving the information of (a) particular pin(s):

http://api.pinterest.com/v3/pidgets/pins/info/?pin_ids=521150988102375972,10133167885969245

Count the number of pins:

http://api.pinterest.com/v1/urls/count.json?url=[urlEncodedLink]

Nikethamide answered 20/6, 2014 at 20:16 Comment(12)
Ben, nice tip on the oauth access token.Maplemaples
the only thing missing from these end points is the published date of the pin.Abed
Are there any more public requests that don't need an access token? The only other one I've found is pidgets/boards/highquality/pinsAmylo
Isn't there a request limit? Will they block my IP if I search for too many boards?Horselaugh
Since yesterday they do not seem to allow the use of the access token generated by iphone app. Don't know what they changed.Whitneywhitson
I'm not sure what I'm doing wrong, but I can't get any of the endpoints listed to work (I've setup my server with an SSL; so the oAuth bit does pass back a proper access_key). however, this bit doesn't work: (I use https://)+ api.pinterest.com/v3/boards?#access_token=pinterest_generated_token (I get a 405: not allowed error)Hansiain
@Hansiain The ones listed here are the groups of endpoints that are available. Each group has a number of endpoints, such as api.pinterest.com/v3/boards{numeric board id}/pins/?page_size=100&access_token={access token}Nikethamide
@BenWong, oh that's great to hear! is there a way to get just the list of All boards for a user though? that gives me the PINs; I need a way to get the boards for the user... thanks again for your reply... this is very helpful!Hansiain
It seems the trick with access_token doesn't work, it returns "Authentication failed." even with access_token. Any ideas how to workaround this?Commemorate
@CorbanBrook have you managed to find the published dates of the pins? Is there any way to get this info?Arapaho
Count the number of pins: is not workingIngraham
@BenWong So you posted this in 2014 and the official Pinterest API documentation still hasn't been updated with these V3 links. So which one should I use, V3 or V1 links?Peppel
N
38

There is no Official API Docs available for Pinterest as of today.

But there is the unofficial documentation for v2 here: http://tijn.bo.lt/pinterest-api

Norvil answered 15/4, 2012 at 22:13 Comment(8)
Glad to see tijn updated it for v2, thanksMaplemaples
+1 Against @MikeGraceStoddart
@EncorePTL, I tried the curl requests listed tijn.bo.lt/pinterest-api but everything returns 404 for me, are all of these disabled?Divine
tijn.bo.lt is a dead link.Planer
you can still get it on internet archive: web.archive.org/web/20130308101718/http://tijn.bo.lt/…Felicefelicia
any jar file for pintrestNaturalize
links not workingArie
both links not working anymore.Drennan
R
13

As of June 11, 2012 there is no officially released or documentation API for Pinterest. A Pinterest support page has a link to a form to be notified when it is officially released.

Reprehension answered 11/6, 2012 at 18:1 Comment(5)
I've filled out that Google docs form several times in the past year but Pinterest has not contacted me yet.Maplemaples
@DylanValade, same here. Looking forward to have an API. Now I just have to scrape html and parse it a bit. But there is no date to sort on or whatsoeverRattrap
@JPHellemons Thanks for posting the v3 updateMaplemaples
@JPHellemons did you ever find a way to make the date show up?Arapaho
Nope, sorry I have no updateRattrap
L
11

Check Pinterest API for a scraper for the time being.

Legibility answered 30/6, 2012 at 23:12 Comment(0)
W
5

If anyone's still interested, apparently URLs in the format

https://widgets.pinterest.com/v3/pidgets/users/{{ USER }}/pins

will return a nice payload of information, including user info.

Wiretap answered 23/9, 2014 at 2:10 Comment(0)
H
3

There's an unofficial Pinterest API in Mashape - https://www.mashape.com/ismaelc/pinterest-1#!documentation

Screenshot below:

enter image description here

And here's another one that might be worth looking at (uses PhantomJSCloud API) - https://www.mashape.com/novaleaf/pinterest-to-json#!documentation

Sample response looks like this:

{
  "pinterest_parser": {
    "boards": [
      {
        "boardCover": {
          "alt": "Stuff We Love / by Etsy",
          "src": "http://media-cache-ak0.pinimg.com/custom_covers/216x146/155303955839058075_1385935738.jpg"
        },
        "boardThumbs": [
          {
            "alt": "",
            "src": "http://media-cache-ec0.pinimg.com/45x45/eb/90/3d/eb903ddac82981f34f2071753ec2d9ac.jpg"
          },
          {
            "alt": "",
            "src": "http://media-cache-ec0.pinimg.com/45x45/01/54/79/015479f7d193838cab29334953416cf2.jpg"
          },
          {
            "alt": "",
            "src": "http://media-cache-ec0.pinimg.com/45x45/79/11/36/7911362bd2fb73a2b2edf8427e944c69.jpg"
          },
          {
            "alt": "",
            "src": "http://media-cache-ak0.pinimg.com/45x45/1b/a8/66/1ba866bdc7a4e4ee0d99fc838be1b2bb.jpg"
           }
        ],
        "href": "/etsy/products-i-love/",
        "pins": "690",
        "title": "Stuff We Love\n                            Etsy"
      },
...
Hildebrandt answered 10/5, 2013 at 0:20 Comment(0)
H
3

The question is quite old, but if anyone is still interested in an up-to-date answer: Pinterest has finally launched an official API, including an SDK for Javascript, Android and iOS.

I've been working on a PHP wrapper for it and noticed that not every endpoint in the documentation is working properly, but most of the things are working.

Hieroglyphic answered 12/8, 2015 at 10:2 Comment(0)
F
2

iv got a simple and quick way to post to Pinterest but unfortunately at this time it will only post a pin to a board and give the user the option to view their profile.

Im a iOS developer using Titanium Studio, build: 3.0.1.20.

var webView = Ti.UI.createWebView({
    url : 'http://pinterest.com/pin/create/button/?url='ADD WEBSITE URL HERE '&media='ADD PICTURE URL HERE'&description=ADD DESCRIPTION HERE',
    top : offset,
    right : offset,
    bottom : offset,
    left : offset,
    autoDetect : [Ti.UI.iOS.AUTODETECT_NONE]
});
Furlong answered 25/1, 2013 at 9:39 Comment(1)
Thanks @MatthewFitzgerald I tested your url and it works properly. This is the functionality of the Pin It button generator found here pinterest.com/about/goodies/#button_for_websitesMaplemaples
R
2

It seems that https://api.pinterest.com/v3/pins/jphellemons/

gives this message:

{
    "status": "failure", 
    "code": 2, 
    "host": "ngapi-10430284",  
    "generated_at": "Wed, 26 Jun 2013 14:56:44 +0000", 
    "message": "Authentication failed.", 
    "data": null
}

and url https://api.pinterest.com/v3/pins/ gives

{
    "status": "failure", 
    "code": 5, 
    "host": "ngapi-70bcb1cc", 
    "generated_at": "Wed, 26 Jun 2013 15:01:07 +0000", 
    "message": "Method not allowed", 
    "data": "405 Method Not Allowed"
}

So the upcoming API will be at that url I guess. Just authenticate with oAuth I guess. Because they hired John Yi recently

if you cannot wait for the official api: http://pinterestapi.co.uk/

update 18 june http://readwrite.com/2013/06/18/the-disappointing-tale-of-pinterests-long-awaited-api#awesm=~oeF8IxscKLvPhN

update 31 july http://allthingsd.com/20130731/about-that-pinterest-api-its-not-ready-yet/

Rattrap answered 26/6, 2013 at 15:2 Comment(0)
M
0

This is the official documentation for pinterest i found, And it helps may i hope it will help u also Official documentation

https://api.pinterest.com/v1/pins/431430839282408407/?access_token=aaa
https://api.pinterest.com/v1/boards/lorihiney/quotes/pins/?access_token=aa&limit=20&fields=id,link,counts
https://api.pinterest.com/v1/boards/mother1086/test-title/pins/?access_token=aaa&limit=2&fields=id,link,counts
Miscellanea answered 3/12, 2015 at 12:28 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.