我在使用
时收到此回应Request request = Request.newUploadPhotoRequest(Session.getActiveSession(),selectedImageBitmap.get(0), uploadPhotoRequestCallback);
响应:
{Response: responseCode: 403, graphObject: null, error: {HttpStatus: 403, errorCode: 200, errorType: OAuthException, errorMessage: (#200) Permissions error}, isFromCache:false}
我的代码是
Session.openActiveSession(getActivity(), true, new StatusCallback() {
@Override
public void call(Session session, SessionState state, Exception exception) {
Request request
=Request.newUploadPhotoRequest(Session.getActiveSession(),selectedImageBitmap.get(0), uploadPhotoRequestCallback);
Bundle parameters = request.getParameters(); // <-- THIS IS IMPORTANT
parameters.putString("message", "Your Caption Here");
request.setParameters(parameters);
request.executeAsync();
}