Facebook Page
CLI examples for Facebook Page publishing in OpenQuok
Connect your agent today
Draft from chat, review in your calendar, and publish only what you approve.
Text-only Page post
openquok posts:create
-c "Hello from our Page"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>" With image
At publish time the backend resolves each stored object key to a public https:// URL for Meta to fetch.
test -f ./hero.jpg && test -s ./hero.jpg
IMAGE=$(openquok upload ./hero.jpg | jq -c '[{id: .data.id, path: (.data.path // .data.filePath)}]')
openquok posts:create
-c "Photo update"
-m "$IMAGE"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>" Link post
Pass an optional URL in providerSettingsByIntegrationId:
openquok posts:create
-c "Read more on our site"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>"
--providerSettingsByIntegrationId '{"<facebook-page-integration-id>":{"url":"https://example.com/article"}}' Multi-photo carousel
MEDIA=$(jq -s 'add'
<(openquok upload ./a.jpg | jq '[{id: .data.id, path: (.data.path // .data.filePath)}]')
<(openquok upload ./b.jpg | jq '[{id: .data.id, path: (.data.path // .data.filePath)}]'))
openquok posts:create
-c "Two photos, one post"
-m "$MEDIA"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>" Story (image or MP4)
Stories require at least one attachment. Set post_type: story on --settings or inside providerSettingsByIntegrationId. Each attachment publishes as its own Story.
test -f ./story.jpg && test -s ./story.jpg
MEDIA=$(openquok upload ./story.jpg | jq -c '[{id: .data.id, path: (.data.path // .data.filePath)}]')
openquok posts:create
-c ""
-m "$MEDIA"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>"
--settings '{"post_type":"story"}' Nested web-composer bucket (same behavior):
openquok posts:create
-c ""
-m "$MEDIA"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>"
--providerSettingsByIntegrationId '{"<facebook-page-integration-id>":{"facebook":{"postType":"story"}}}' Stories vs feed posts
Link url and follow-up facebook.replies apply to feed posts only. For Stories, omit both.
Scheduled follow-up comments
providerSettings.facebook.replies[] carries follow-up replies that publish as comments on the Page post after a fixed delay. Pass them on posts:create with --providerSettingsByIntegrationId:openquok posts:create
-c "Main post"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>"
--providerSettingsByIntegrationId "$(jq -nc --arg id "<facebook-page-integration-id>" '
{
($id): {
facebook: {
replies: [
{ message: "First comment on the post", delaySeconds: 60 }
]
}
}
}
')" Follow-up with one image
Upload first, then attach at most one image per reply row (no video):
REPLY_MEDIA=$(openquok upload ./comment-image.jpg | jq -c '[{id: .data.id, path: (.data.path // .data.filePath)}]')
openquok posts:create
-c "Main post"
-s "2026-01-01T12:00:00Z"
-i "<facebook-page-integration-id>"
--providerSettingsByIntegrationId "$(jq -nc
--arg id "<facebook-page-integration-id>"
--argjson media "$REPLY_MEDIA" '
{
($id): {
facebook: {
replies: [
{ message: "See the chart in this comment", delaySeconds: 60, media: $media }
]
}
}
}
')" Follow-up media limits
Each reply supports at most one image — no video. Omit media for text-only comments.
Resolve integration UUID
FB_ID=$(openquok integrations:list | jq -r '.[] | select(.identifier=="facebook") | .id')
openquok integrations:settings "$FB_ID"
openquok analytics:platform "$FB_ID" -d 30 Platform-specific settings
Configure per integration in the web composer Settings panel, or pass flat keys on the CLI with --settings (merged into providerSettingsByIntegrationId).
| Setting | CLI / API key | Web composer (facebook.*) | Values |
|---|---|---|---|
| Post type | post_type | postType | post (feed/Reel) or story |
| Link preview URL | url | url | https://… (text-only feed posts) |
| Follow-up comments | replies (nested under facebook) | replies | [{ "message": "…", "delaySeconds": 60 }] (feed posts only) |