restfb-examples icon indicating copy to clipboard operation
restfb-examples copied to clipboard

@deprecate method

Open pradeepjadi opened this issue 6 years ago • 1 comments

Message Request processing failed; nested exception is com.restfb.exception.FacebookOAuthException: Received Facebook error response of type OAuthException: (#200) Requires either publish_to_groups permission and app being installed in the group, or manage_pages and publish_pages as an admin with sufficient administrative permission (code 200, subcode null) 'null - null'

and FacebookType publishPhotoResponse = fbClient.publish("me/photos", FacebookType.class, BinaryAttachment.with("cat.png", getClass().getResourceAsStream("/cat.png")), Parameter.with("message", "Test cat"));

its shows Open Declaration BinaryAttachment com.restfb.BinaryAttachment.with(String filename, InputStream data)

@Deprecated

Deprecated. use the stream-less API passing a byte[] for data

Creates a binary attachment.

Parameters: filename The attachment's filename. data The attachment's data. Returns: A binary attachment. Throws: IllegalArgumentException - If data is null or filename is null or blank.

pradeepjadi avatar Sep 27 '18 11:09 pradeepjadi

Looks like a duplicate to me. The deprecated method is not the problem here...

nbartels avatar Sep 27 '18 14:09 nbartels