Facebook Posting API
Post text, links, photos and video to Facebook Pages from your app, one key per customer or agent.
- Text, link, photo and video posts to Pages
- Connect Pages through Facebook Login
- A webhook when video processing finishes
- Limits and a log per key, not per Page
const pk = new Postkey(process.env.POSTKEY_KEY);
await pk.posts.create({
accounts: [
"acc_fb_page_456"
],
content: "Our spring hours start Monday: 8am to 6pm.",
facebook: {
link: "https://example.com/hours"
}
});- Facebookpublished
1 call · key customer_42
Your first Facebook post in three steps
- 1
Connect Facebook
Your customer signs in through Facebook's own login. You get an account ID, never a password.
- 2
Make a key
Create a key for that customer or agent, scoped to their accounts, with the caps you choose.
- 3
Post
Send the post to /v1/posts with that key. The Facebook result comes back in the response and by webhook.
Every Facebook format, one endpoint
Pick a format to see the exact request and what comes back. Options that only make sense on Facebook sit under "facebook".
A text post, with an optional link preview.
1POST https://api.postkey.dev/v1/posts2Authorization: Bearer pk_cust_42_…3Content-Type: application/json4 5{6 "accounts": [7 "acc_fb_page_456"8 ],9 "content": "Our spring hours start Monday: 8am to 6pm.",10 "facebook": {11 "link": "https://example.com/hours"12 }13}200 · published
Counted against customer_42 only.
{
"id": "post_3k9d2",
"status": "published",
"results": [
{
"account": "acc_fb_page_456",
"platform": "facebook",
"status": "published",
"url": "https://www.facebook.com/…"
}
]
}Everything you need for Facebook posting
Checked against Facebook's rules
Before anything is sent, Postkey checks it against Facebook's published limits:
Pages, not profiles
Meta's API publishes to Facebook Pages. Postkey lists the Pages a person manages when they connect, and you post to the ones you choose.
Link previews
Add a link and Facebook builds the preview card from the page's own tags. Nothing extra to send.
Video tracked to the end
Facebook processes video after upload. You get a webhook when it's live, or the reason it failed.
Facebook Login
Page owners connect with Facebook's own login and permission screen. You never handle their password.
One Page, many keys
Two of your customers can't touch each other's Pages. Each key only sees the accounts you gave it.
Also for Facebook
Keys & control
Every Facebook post has an owner
Each customer or agent posts to Facebook through its own key: only its accounts, its own caps, its own log, and an off switch that touches nothing else.
Works with your stack
Your code
Node and Python SDKs with the same calls, or plain REST from anything that speaks HTTP.
- Node
- Python
- {}REST
No-code tools
Call the REST API from an HTTP step in n8n, Make or Zapier. Give each workflow its own key.
- n8n
- Make
- Zapier
AI agents & MCP
The MCP server lets Claude, Cursor and other agent tools post through their own key, with caps they can't change.
- MCP server
Beyond Facebook
Same request shape on every platform. Add an account ID and the post goes there too.
- X Posting APIText · Image · Video · Thread
- Instagram Posting APIFeed post · Reel · Story · Carousel
- You're hereFacebook Posting APIText · Photo · Video
- TikTok Posting APIVideo · Photo
- LinkedIn Posting APIText · Image · Document
- YouTube Posting APIVideo
- YouTube Shorts Posting APIShort
- Pinterest Posting APIPin
- Google Business Posting APIUpdate post · Offer · Event
Facebook posting questions
Something not here? Email hello@postkey.dev.
Can I post to a personal Facebook profile?
No. Meta's API only allows publishing to Pages. That's a Facebook rule, not a Postkey one.
What can I post to a Page?
Text posts with or without a link, photo posts and video posts.
Who needs to connect the Page?
Someone who manages the Page. They sign in with Facebook, pick the Pages, and you get an account ID for each.
Why does a video post say 'processing'?
Facebook processes video before it appears. The call returns right away and a webhook follows with the final result.
Can I post to Facebook and Instagram together?
Yes. Put both account IDs in one request. You get a separate result for each.
Can I schedule Facebook posts instead?
Yes. Add scheduledFor to the same request. See the Facebook Scheduling API page for details.
Post to Facebook with a key per customer.
Get a key, connect an account, send the request above.
Free to start. Read the docs