0

I didn't know Java + Facebook integration would cost an arm and a leg. Does anyone have a sample code to post to Facebook page as admin?

I understand the OAuth process, I just need to send an OAuthRequest with my text using scribe lib . And if possible, How to send a byte[] (a picture).

request.addBodyParameter("status", "Testing: Updating my facebook status through Java"); service.signRequest(accessToken, request);
Response response = request.send();

I have tried the above code from scribe example but I get {"error":{"message":"(#100) Can only call this method on valid test users for your app","type":"OAuthException","code":100}}

Thanks.

Babajide Prince
  • 552
  • 1
  • 10
  • 25

1 Answers1

1

I believe you need to generate an application token (assuming you have all the proper permissions) using the app secret and using this newly created token in your posts, etc.