Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create the "Timeline Photos" album using Facebook Graph API

What I Want

I need to create the posts on a page wall with a big preview pictures - like the ones that are displayed when you upload a photo. It will make sense to add those photos to the "Timeline Photos" album of a user (or page) using the Facebook Graph API.

Sure I can poll the users albums list and search for a type:"wall" one (i.e. the Timeline Photos in the English translation), but what if the album does not exist? How do I create one or how do I make Facebook Graph create it?

What Have I Tried

Tried posting to /me/feed with a message and a picture URL (params picture or source), but all it does is just create a type:"link" post with a small picture, while what I need is a type:"photo" one.

Once again, I need that because of the big photo that gets displayed on a wall if post is a photo. For instance, that happens when I upload a picture to the album that gets automatically created for my application. But the issue is that when there are several photos posted one after another, Facebook automatically groups them in a set that belongs to an album.

P.S.

Basically, what I want to achieve is having an ability to send the posts to a page wall with big preview photos on the wall itself that are not grouped by an album name.

Please help. Thanks

like image 351
mehov Avatar asked Nov 04 '22 03:11

mehov


1 Answers

Solved by posting a photo to /{page-id}/photos.

https://developers.facebook.com/docs/graph-api/reference/v2.0/page/photos

like image 124
mehov Avatar answered Nov 15 '22 05:11

mehov