A few features need a permission that a network grants only after it reviews Reelspan's app: editing and deleting YouTube videos, deleting Threads posts, changing Facebook Page details, first comments on Facebook, Instagram and YouTube, LinkedIn company pages, and the full Reddit post list. They are built and in the API now, each behind a switch. Reelspan turns a switch on once the network approves. GET /v1/permissions tells you where each one stands.
List the permissions
curl https://api.reelspan.com/v1/permissions \
-H "Authorization: Bearer $REELSPAN_API_KEY"import { Reelspan } from 'reelspan';
const reelspan = new Reelspan();
const { permissions } = await reelspan.request('GET', '/v1/permissions');
const live = new Set(permissions.filter((p) => p.status === 'live').map((p) => p.id));from reelspan import Reelspan
reelspan = Reelspan()
permissions = reelspan.request("GET", "/v1/permissions")["permissions"]
live = {p["id"] for p in permissions if p["status"] == "live"}The answer has one entry per permission, always in the same order. Two of them:
{
"success": true,
"permissions": [
{
"id": "youtube_manage",
"platform": "youtube",
"unlocks": "Edit and delete published videos, upload subtitles, post first comments",
"approval": "Google OAuth verification (sensitive scope youtube.force-ssl)",
"scopes": ["https://www.googleapis.com/auth/youtube.force-ssl"],
"status": "pending"
},
{
"id": "linkedin_organizations",
"platform": "linkedin",
"unlocks": "List LinkedIn company pages, choose one, and post as it",
"approval": "LinkedIn Community Management API",
"scopes": ["r_organization_admin", "w_organization_social", "r_organization_social"],
"status": "pending"
}
]
}idnames the switch. Branch on it, not onunlocks, which is text for people.scopesare the permissions the network's sign-in asks for once the switch is on.statusispendinguntil the network approves, thenlive.
Any API key can read the list; it needs no particular scope.
What each switch gates
id |
Network | What waits for it | While pending |
|---|---|---|---|
youtube_manage |
YouTube | Edit and unpublish a video | 403 permission_pending |
Subtitles sent with the video (youtube_subtitle_*) |
The video is published; the result has a warning that the subtitles weren't added | ||
| The first comment | The video is published; the result has first_comment: "failed" and a warning |
||
threads_delete |
Threads | Unpublish a post | 403 permission_pending |
facebook_page_metadata |
PATCH /v1/facebook/page-info |
403 permission_pending (validate_only works already) |
|
facebook_engagement |
The first comment | The post is published; the result has first_comment: "failed" and a warning |
|
instagram_comments |
The first comment | The post is published; the result has first_comment: "failed" and a warning |
|
linkedin_organizations |
GET /v1/linkedin/pages, POST /v1/linkedin/page, and reposting as a page |
403 permission_pending |
|
Posting as a page (target_linkedin_page_id) |
The LinkedIn result fails with error_code: "permission_pending"; other networks of the post are not affected |
||
reddit_history |
Every post of the account in GET /v1/reddit/posts |
No error: the list has source: "reelspan", only the posts Reelspan published |
Everything else in the API works without these switches. Posting as the LinkedIn member, first comments on the other networks, YouTube thumbnails and reposts on Threads don't depend on them.
The permission_pending answer
A call that needs a switch that is still off answers 403:
{
"success": false,
"message": "This needs a permission Reelspan is still waiting for (Meta App Review: threads_delete). It switches on once approved.",
"error_code": "permission_pending"
}It means the feature exists but the network hasn't approved Reelspan yet. Nothing about your key, plan or account is wrong, and nothing you send changes the answer.
Handling it
- Don't retry in a loop. The answer stays the same until the switch is on, which takes days or weeks of network review, not seconds.
- Check before you offer the feature. Read
GET /v1/permissionswhen your app starts (or once a day) and hide or disable the gated actions whosestatusispending. Treat apermission_pendinganswer as a sign your copy of the list is out of date. - Keep posting. Inside a post, a pending permission never stops the other networks, and on YouTube, Facebook and Instagram the post itself still goes out. Read
warningsandfirst_commentin the result (see Post status). - Reconnect once it is live. When a switch turns
live, accounts connected before then don't have the new permission yet, and the network refuses the call until the account is reconnected.GET /v1/linkedin/pagessays so with 409permission_reconnect. Send the account's owner a connect link if the account isn't yours.
import { Reelspan, ReelspanError } from 'reelspan';
const reelspan = new Reelspan();
try {
await reelspan.request('POST', '/v1/posts/unpublish', { json: { platform: 'threads', user: 'my-brand', post_id: '18034…' } });
} catch (err) {
if (err instanceof ReelspanError && err.code === 'permission_pending') {
// not available yet: tell the user, don't retry
} else throw err;
}from reelspan import Reelspan, ReelspanError
reelspan = Reelspan()
try:
reelspan.request("POST", "/v1/posts/unpublish", json_body={"platform": "threads", "user": "my-brand", "post_id": "18034…"})
except ReelspanError as err:
if err.code != "permission_pending":
raise
# not available yet: tell the user, don't retrySee Connecting accounts for the approval each network needs.