Publer API
by @gjeka
Use this skill whenever the user wants to interact with the Publer API — including managing social media posts (create, schedule, update, delete, approve), b...
clawhub install publer-api📖 About This Skill
name: publer-api description: > Use this skill whenever the user wants to interact with the Publer API — including managing social media posts (create, schedule, update, delete, approve), browsing or uploading media, viewing workspaces and connected social accounts, or retrieving analytics. Trigger this skill any time the user mentions Publer, wants to schedule or manage posts across social platforms via Publer, asks about Publer analytics or insights, needs to work with the Publer media library, or wants to analyze competitors or hashtag performance via Publer. Also trigger when the user asks to automate social media workflows that involve Publer, even if they don't explicitly say "Publer API".
Publer API Skill
This skill enables you to interact with all Publer API endpoints.
Business plan required. The Publer API is only available to Business plan users.
Setup
Base URL: https://app.publer.com/api/v1
Required headers on almost every request:
Authorization: Bearer-API YOUR_API_KEY
Publer-Workspace-Id: YOUR_WORKSPACE_ID
Content-Type: application/json
Note: Bearer-API (not Bearer) is the correct format.
If the user hasn't provided their API key, ask for it before making any calls. Never hardcode or expose API keys.
API key scopes: workspaces, accounts, posts, media, analytics
Quick Reference: All Endpoints
| Area | Method | Endpoint |
|---|---|---|
| Users | GET | /users/me |
| Workspaces | GET | /workspaces |
| Accounts | GET | /accounts |
| Posts | GET | /posts |
| Posts — Schedule/Draft | POST | /posts/schedule |
| Posts — Publish Now | POST | /posts/schedule/publish |
| Posts — Update | PUT | /posts/{id} |
| Posts — Delete | DELETE | /posts |
| Job Status | GET | /job_status/{job_id} |
| Media — List | GET | /media |
| Media — Direct Upload | POST | /media |
| Media — URL Upload | POST | /media/from-url |
| Media Options | GET | /workspaces/{workspace_id}/media_options |
| Analytics — Charts List | GET | /analytics/charts |
| Analytics — Chart Data | GET | /analytics/:account_id/chart_data |
| Analytics — Post Insights | GET | /analytics/:account_id/post_insights |
| Analytics — Hashtag Insights | GET | /analytics/:account_id/hashtag_insights |
| Analytics — Hashtag Posts | GET | /analytics/:account_id/hashtag_performing_posts |
| Analytics — Best Times | GET | /analytics/:account_id/best_times |
| Analytics — Members | GET | /analytics/members |
| Competitors — List | GET | /competitors/:account_id |
| Competitors — Analytics | GET | /competitors/:account_id/analytics |
For full request/response shapes, read references/api-reference.md.
Workflow
1. Identify the intent
Map the user's request to one or more API calls from the table above.2. Gather required parameters
GET /workspaces first.GET /accounts.scheduled_at must be ISO 8601 with timezone, at least 1 minute in the future.from/to date range (YYYY-MM-DD). They are co-required./media or /media/from-url, then referenced by ID in posts.3. Make the API call
Use the correct HTTP method and headers. POST/PUT useContent-Type: application/json. Media direct upload uses multipart/form-data.4. Handle async operations
Post creation and URL media uploads are asynchronous:{ "success": true, "data": { "job_id": "..." } }GET /job_status/{job_id} until status is "complete" or "failed"payload.failures even on "complete" — partial failures are possible5. Interpret the response
Bearer-API format.Publer-Workspace-Id header is present.errors[] array to user and ask them to correct input.X-RateLimit-Reset, use exponential backoff.Common Workflows
Schedule a post
1. If workspace/account IDs unknown:GET /workspaces then GET /accounts
2. POST /posts/schedule with state: "scheduled", network content, and scheduled_at per account
3. Poll GET /job_status/{job_id} until complete
4. Confirm back: platform(s), scheduled time, text previewPublish immediately
Same as above but usePOST /posts/schedule/publish and omit scheduled_at.Cross-post with platform-specific content
Use multiple keys undernetworks with per-platform text/type:
"networks": {
"facebook": { "type": "status", "text": "Longer Facebook copy..." },
"twitter": { "type": "status", "text": "Short tweet #hashtag" },
"linkedin": { "type": "status", "text": "Professional LinkedIn copy..." }
}
Upload and attach media
1.POST /media (multipart) for direct upload, or POST /media/from-url for URL import
2. Check validity object in response for network compatibility
3. Reference media.id in the media[] array inside the network object when creating postList and review scheduled posts
1.GET /posts?state=scheduled
2. Display as readable list: date, network, text preview
3. Offer to edit (PUT /posts/{id}) or delete (DELETE /posts?post_ids[]=...) on requestFetch analytics
1. For account-level charts:GET /analytics/charts to get available IDs, then GET /analytics/:account_id/chart_data?chart_ids[]=...&from=...&to=...
2. For per-post performance: GET /analytics/:account_id/post_insights?from=...&to=...
3. For hashtag performance: GET /analytics/:account_id/hashtag_insights
4. For best posting times: GET /analytics/:account_id/best_times?from=...&to=...Competitor analysis
1.GET /competitors/:account_id to list competitors
2. GET /competitors/:account_id/analytics for aggregate metrics
3. Use competitors=true&competitor_id=... on post insights and best times endpoints for deeper comparisonKey Notes & Edge Cases
Bearer-API YOUR_KEY — not BearerPubler-Workspace-Id header. Exception: GET /workspaces/{workspace_id}/media_options uses workspace ID in the path./users/me and /workspaces do not require the workspace header.page param throughout. Post insights and hashtag insights return 10 per page.default network key: Use "default" as the network to apply same content to all accounts.sort_type: Lowercase asc/desc — unlike post/hashtag insights which use ASC/DESC.reach field: May be omitted in members analytics and competitor analytics for unsupported networks — handle gracefully.Reference Files
references/api-reference.md — Full endpoint docs with all request/response shapes, field enums, media specs, daily post limits, and error handling. Read this when you need exact field names, response shapes, or need to handle a case not covered above.⚙️ Configuration
Base URL: https://app.publer.com/api/v1
Required headers on almost every request:
Authorization: Bearer-API YOUR_API_KEY
Publer-Workspace-Id: YOUR_WORKSPACE_ID
Content-Type: application/json
Note: Bearer-API (not Bearer) is the correct format.
If the user hasn't provided their API key, ask for it before making any calls. Never hardcode or expose API keys.
API key scopes: workspaces, accounts, posts, media, analytics