OverviewProductsPlatformsAPI ReferenceResources

Limits & errors

What Facebook's API does not expose and the common errors when publishing.


What you cannot do

Facebook's API does not expose:

  • Posting to personal profiles (Pages only)
  • Events
  • Posting to Groups (deprecated by Facebook)
  • Going live (the separate Facebook Live API)
  • Interactive Story stickers
  • Demographic targeting (age, gender, interests) for organic posts; country-level geo-restriction is supported

Common errors

ErrorCauseFix
"Photos should be smaller than 4MB and saved as JPG or PNG."The image is above Facebook's real size limit or in an unsupported formatReduce it to under 4 MB as JPEG or PNG.
"Missing or invalid image file"Facebook could not process the image: corrupt, wrong format or an inaccessible URLOpen the URL in an incognito window. Use JPEG or PNG under 4 MB.
"Unable to fetch video file from URL."Facebook's servers could not download the videoUse a direct, public URL, not a cloud storage sharing link.
"Facebook tokens expired. Please reconnect."The OAuth token expired; Facebook tokens are short-livedReconnect the account. Subscribe to the account.disconnected webhook to catch this early.
"Confirm your identity before you can publish as this Page."Facebook triggered a security check on the PageLog into Facebook, open the Page and complete identity verification.
"Publishing failed due to max retries reached"All 3 retry attempts failedUsually temporary. Retry, or wait and try again.

A publishNow: true post that Facebook rejects returns 207 with post.status: "failed" and the message in platforms[].errorMessage:

JSON
{
  "message": "Post created but publishing failed",
  "error": "All platforms failed",
  "post": {
    "_id": "65f1c0a9e2b5af0012ab34cd",
    "status": "failed",
    "platforms": [
      {
        "platform": "facebook",
        "status": "failed",
        "errorMessage": "Facebook needs you to confirm your identity before you can publish as this Page. Open the Facebook mobile app, go to this Page, and complete the identity confirmation, then try again.",
        "errorCategory": "platform_rejected",
        "errorSource": "platform"
      }
    ]
  }
}

207 is a 2xx status, so fetch(...).ok is true; branch on the status code and on post.status. Error handling covers the envelope.

Was this page helpful?

On this page