Địa chỉ gốc
Gửi mọi yêu cầu đến địa chỉ này. PostNimbo tự lưu trữ thì dùng địa chỉ backend của riêng nó.
https://postnimbo.com/api/public/v1
Xác thực
Đặt thông tin xác thực nguyên trạng vào header Authorization, không có tiền tố Bearer. Có hai loại dùng được:
- Khóa API, lấy trong Cài đặt > Tác nhân / Dev. Khóa hoạt động với tư cách cả không gian làm việc và truy cập được mọi route bên dưới.
- Access token OAuth (bắt đầu bằng pos_), lấy từ một ứng dụng OAuth. Token hoạt động với tư cách thành viên đã chấp thuận nó, chỉ thấy thương hiệu và kênh của người đó, và bị giới hạn trong các scope họ đã chấp thuận.
curl https://postnimbo.com/api/public/v1/me \ -H "Authorization: <api key or pos_ token>"
Thiếu hoặc sai thông tin xác thực sẽ trả về 401. Route mà token chưa được chấp thuận sẽ trả về 403. Lỗi có trường msg hoặc message.
Giới hạn tần suất
- 120 yêu cầu mỗi phút cho mỗi khóa API hoặc token, tính trên mọi route.
- Việc tạo bài đăng còn bị giới hạn theo không gian làm việc mỗi giờ (mặc định 90).
- Khi vượt giới hạn, phản hồi là 429 kèm header Retry-After tính bằng giây. Hãy chờ đúng chừng đó rồi mới thử lại.
Máy chủ tự lưu trữ đặt giới hạn riêng bằng PUBLIC_API_RATE_LIMIT, PUBLIC_API_RATE_TTL và API_LIMIT.
Endpoint
Cột scope là quyền mà token OAuth cần. Khóa API truy cập được mọi route.
Account
- GET
/public/v1/meThe workspace the credential belongs to, and for an OAuth token the member who approved it.
Phạm viMọi token - GET
/public/v1/is-connectedCheck that the credential works.
Phạm viMọi token - GET
/public/v1/groupsThe brands (customers) the credential can see.
Phạm viMọi token - GET
/public/v1/countsPosts waiting for approval and unread open inbox conversations.
Phạm viposts:readinbox:readĐầu vàoquery: brandId?
Channels
- GET
/public/v1/integrationsThe connected channels, with their ids and networks.
Phạm viposts:readĐầu vàoquery: group? (a brand id) - GET
/public/v1/integration-settings/:idThe rules of a channel: character limits, media rules and the settings a post needs.
Phạm viKhóa API hoặc token toàn quyền - GET
/public/v1/find-slot/:idThe next free posting slot of a channel.
Phạm viposts:read - GET
/public/v1/social/:integrationThe sign-in link that connects a new channel of a network (for example linkedin).
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: refresh? (a channel id to reconnect) - DELETE
/public/v1/integrations/:idDisconnect a channel.
Phạm viKhóa API hoặc token toàn quyền - POST
/public/v1/integration-trigger/:idRun a lookup a network offers (for example the playlists of a YouTube channel).
Phạm viKhóa API hoặc token toàn quyềnĐầu vàobody: { methodName, data }
Posts
- GET
/public/v1/postsThe posts between two dates.
Phạm viposts:readĐầu vàoquery: startDate, endDate (ISO 8601), customer? - POST
/public/v1/postsCreate a draft, schedule a post or publish now, on one or more channels.
Phạm viposts:scheduleĐầu vàobody: { type: draft|schedule|now, date, shortLink, tags, posts: [{ integration: { id }, value: [{ content, image? }], settings? }] } - PUT
/public/v1/posts/:id/settingsChange the network settings of a post.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàobody: { settings } - PUT
/public/v1/posts/:id/statusMove a post between draft and scheduled.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàobody: { status: draft|schedule } - GET
/public/v1/posts/:id/missingFor a post the network accepted without returning its id: the recent posts of the channel to pick it from.
Phạm viKhóa API hoặc token toàn quyền - PUT
/public/v1/posts/:id/release-idLink a post to the network post it became.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàobody: { releaseId } - DELETE
/public/v1/posts/:idDelete a post.
Phạm viKhóa API hoặc token toàn quyền - DELETE
/public/v1/posts/group/:groupDelete every post of a group (one post sent to several channels).
Phạm viKhóa API hoặc token toàn quyền
Media
- POST
/public/v1/uploadUpload a file to the media library.
Phạm vimedia:writeĐầu vàomultipart: file, adjust? - POST
/public/v1/upload-from-urlAdd a file from a public https address.
Phạm vimedia:writeĐầu vàobody: { url, adjust? } - GET
/public/v1/mediaThe media library, a page at a time.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: page?, search?, folder? - GET
/public/v1/media/:id/statusWhether an uploaded video finished processing.
Phạm viKhóa API hoặc token toàn quyền
Ideas
- POST
/public/v1/ideasSave an idea to the Ideas board.
Phạm viideas:writeĐầu vàobody: { title, content? } - DELETE
/public/v1/ideas/:idRemove an idea the credential saved.
Phạm viideas:write
Analytics
- GET
/public/v1/performanceA summary of the last 7 days: posts, reach and engagement.
Phạm vianalytics:readĐầu vàoquery: brandId?, tz? - GET
/public/v1/best-times/nextThe next best times to post, from your own results.
Phạm viposts:readĐầu vàoquery: integrationId?, brandId?, tz?, goal?: engagement|reach|views, count? (1-20) - GET
/public/v1/analytics/:integrationThe analytics of a channel.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: date (days back) - GET
/public/v1/analytics/post/:postIdThe analytics of one published post.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: date (days back)
AI
- POST
/public/v1/ai/draftDraft a post about a web page with PostNimbo AI.
Phạm viai:useĐầu vàobody: { url, title?, selection?, mode: summary|captions } - POST
/public/v1/ai/replyDraft a reply to a comment or message.
Phạm viai:useĐầu vàobody: { text, url? }
Link in bio
- GET
/public/v1/link-in-bioThe link-in-bio pages of the workspace.
Phạm vilink-in-bio:write - POST
/public/v1/link-in-bio/:id/linksAdd a link to a link-in-bio page.
Phạm vilink-in-bio:writeĐầu vàobody: { label, url }
Video and clipping
- POST
/public/v1/generate-videoGenerate a video with one of the AI video tools.
Phạm viKhóa API hoặc token toàn quyền - POST
/public/v1/video/functionLoad the options of a video tool (voices, avatars).
Phạm viKhóa API hoặc token toàn quyền - POST
/public/v1/clippingCut a long video into short clips.
Phạm viKhóa API hoặc token toàn quyền - GET
/public/v1/clippingThe clipping jobs, a page at a time.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: page - GET
/public/v1/clipping/:idOne clipping job and its clips.
Phạm viKhóa API hoặc token toàn quyền
Notifications
- GET
/public/v1/notificationsThe workspace notifications, a page at a time.
Phạm viKhóa API hoặc token toàn quyềnĐầu vàoquery: page?
Webhooks
- GET
/public/v1/webhooks/eventsThe events a webhook is sent, with a sample payload of each.
Phạm viMọi token - GET
/public/v1/webhooksThe webhooks of the workspace, without their addresses; ?url= finds the webhooks of one address.
Phạm viwebhooks:writeĐầu vàoquery: url? - POST
/public/v1/webhooksSubscribe an address to events (how Zapier, Make and n8n triggers switch on).
Phạm viwebhooks:writeĐầu vàobody: { url, events?, integrations? (channel ids), name? } - DELETE
/public/v1/webhooks/:idRemove a webhook (how a trigger switches off).
Phạm viwebhooks:write
