Hi, does anyone has tried before using instagram Api in a juce project?
I’d like to do some stuffs using URL and passing somethings like
URL myUrl(“https://graph.facebook.com/v3.2/17841405822304914?fields=biography%2Cid%2Cusername%2Cwebsite&access_token=EAACwX…”)
to do what I need but I don’t understand how …
I structured for example this class, but actually I don’t know how leave a like on a media or a comment:
class MyProfile : public User
{
public:
/** with this constructor the user can authenticate his profile and perform the access
@param username the username of user who want to perform the acess
@param password the password of user who want to perform the acess
*/
MyProfile(String name, String pass) : User(name)
{
pass = password;
//HERE WE NEED TO PERFORM THE ACCESS
}
/** with this you can leave a like on media passd in param, if it happens it returns true, else it returns false
@param onMediaId the media which we want to leave the like (referred by Id)
*/
bool performLike(String onMediaId) { return false; }
/** with this you can leave a comment on media passd in param, if it happens it returns the comment with the text we put as second param, else it returns an empty comment
@param onMediaId the media which we want to leave the comment (referred by Id)
@param comment the text of the comment that we want to leave
*/
Comment performComment(String onMediaId, String comment) { return Comment(); }
/** with this you can leave a message the user passd in param, if it happens it returns the text of the messaeg we put as second param, else it returns an empty String()
@param toUserId the user we want send the message (referred by Id)
@param message the text of the message that we want to leave
*/
String performMessage(String toUserId, String message) { return String(); }
/** with this we can see the stories published by the user passed as param
@param ofUserId the user we want to see the stories (referred by Id)
*/
void seeStories(String ofuserId) {}
/** with this you can start to follow another user passed in param, it returns true if the operation is successful, flase if it's not
@param userId the ID of user you want to follow (referred by Id)
*/
bool performFollow(String userId) { return false; }
/** with this you can stop to follow another user passed in param, it returns true if the operation is successful, flase if it's not
@param userId the media which the authenticate user want to leave the like (referred by Id)
*/
bool performUnfollow(String userId)
{
if (this->getFollowedIds().contains(userId, true))
{
/* HANDLE STUFFS AND RETURN THE TRUTH */ return false;
}
return false;
}
private:
String password;
};
Anyone that could give any advice?