Android Studio中Java实现视频压缩遇Graph API错误求助
Hey there, let's break down what's going on here. You're trying to implement video compression with tools like SiliCompressor in Android Studio (Java), but you're hitting a Facebook Graph API error that seems totally unrelated to your compression task. That's confusing, right? Let's fix this.
First, let's clarify the error:
Unsupported get request. Object with ID '698664617315269' does not exist, cannot be loaded due to missing permissions, or does not support this operation.
This error has nothing to do with your video compression logic—it means some dependency in your project is making an unintended call to Facebook's Graph API, probably trying to fetch data for that specific object ID (which is either invalid, you don't have permissions for it, or the endpoint doesn't support the request).
Here are actionable steps to resolve this:
Check and exclude unwanted Facebook dependencies from your compression library
Some video compression tools (like older versions of SiliCompressor) might include Facebook SDK dependencies by default, even if you don't use any Facebook features. To fix this, modify your app-levelbuild.gradleto exclude those dependencies:// If you're using SiliCompressor: implementation('com.iceteck.silicompressorr:silicompressor:2.2.4') { exclude group: 'com.facebook.android' exclude module: 'facebook-core' exclude module: 'facebook-graph-api' }Sync your project after making this change—this should stop the unwanted Graph API calls.
Switch to a pure video compression library
If excluding dependencies doesn't work, consider using a library that's focused solely on video compression, no extra social integrations. For example:- FFmpeg-based libraries like
FFmpegKit(lightweight, customizable for compression tasks) - Android's native
MediaCodecAPI (for fully custom, dependency-free compression—requires more code but gives you full control)
- FFmpeg-based libraries like
Trace the error source with Logcat
Open Android Studio's Logcat, filter for "Facebook" or "GraphAPI", and look at the stack trace of the error. This will tell you exactly which class/method is triggering the API call. If it's coming from your own code (maybe accidental Facebook SDK usage), you can fix that directly. If it's from the compression library, the exclude step above should resolve it.Verify Facebook SDK setup (if you actually need it)
If your project does require Facebook integration, double-check:- The object ID
698664617315269is valid (maybe it's a test ID that's been deleted) - Your Facebook app has the necessary permissions to access that object
- You're using the correct Graph API version for your SDK
- The object ID
But given you're working on video compression, the first two steps are the most likely fixes—you don't need Facebook's SDK for a compression task!
内容的提问来源于stack exchange,提问作者Rodrigo Costa

