Search code examples
androidfacebookfacebook-graph-apifacebook-android-sdk

Explicitly shared photo facebook


It's a way possible to send a photo to facebook with explicitly_shared false and not appear in timeline of user?

SharePhoto photo = new SharePhoto.Builder()
        .setBitmap(image)
        .build();
SharePhotoContent content = new SharePhotoContent.Builder()
        .addPhoto(photo)
        .build();

Or maybe... I am sending in the open graph a storie to facebook and the image doesn't go to album, it's possible?

    ShareOpenGraphObject object = new ShareOpenGraphObject.Builder()
            .putString("fb:app_id", "app_id")
            .putString("og:type", "object_type")
            .putString("og:title", title())
            .putString("og:description", message)
            .putString("og:url", urlShare)
            .putString("og:image", imageUrl)
            .build();
    ShareOpenGraphAction action = new ShareOpenGraphAction.Builder()
            .setActionType("action_type")
            .putBoolean("fb:explicitly_shared", true)
            .putObject("object", object)
            .build();
    ShareOpenGraphContent content = new ShareOpenGraphContent.Builder()
            .setPreviewPropertyName("object")
            .setAction(action)
            .build();

    ShareApi.share(content, this);

The image in ".putString("og:image", imageUrl)" goes to storie and timeline but I want the same image in the album photos too. How to do it?


Solution

  • I solved my problem doing two requests to facebook, one with the storie and other with the photo to album, if anyone knows another way to do just one request would be good.