Every API here is available over the APIs.io API and to AI agents over MCP.
openapi: 3.2.0
info:
description: 'Get API Key
## Blog2Social API
### One API 25+ Social Platforms
Connect, manage and publish content across 25+ social media, blogging and community platforms through a single integration. Instead of building and maintaining separate integrations for every platform, Blog2Social provides one centralized API for publishing text, links, images and videos at scale. Whether you are building a SaaS platform, CMS, marketing automation solution, agency dashboard, e-commerce platform or enterprise application, Blog2Social helps you automate social media publishing while reducing development effort and maintenance costs. ### Key Benefits
- One integration for 25+ social media and publishing platforms
- Publish content across multiple networks simultaneously
- Connect profiles, pages and groups through one API
- Support for text, links, images and videos
- Retrieve social media insights and performance metrics
- Automate publishing workflows and content distribution
- Scale from a single user to thousands of connected accounts
## Supported Platforms
Schedule, publish and manage content across social media, blogging, business and community platforms through a single API. Connect accounts, publish content, upload media, retrieve insights and automate social media distribution from one centralized interface. | Platform | Post Types | Media |
|-----------|-----------|-----------|
| Facebook | Posts, Reels | Links, Images, Videos |
| X | Posts | Links, Images, Videos |
| LinkedIn | Posts | Links, Images, Videos |
| Instagram | Posts | Images, Videos |
| Pinterest | Pins, Boards | Images, Videos |
| Reddit | Posts, Subreddits | Links, Images |
| Tumblr | Posts | Links, Images, Videos |
| Medium | Articles | Images |
| Telegram | Messages | Links, Images |
| TikTok | Posts | Images, Videos |
| YouTube | Videos, Shorts, Playlists | Videos |
| Vimeo | Videos | Videos |
| Bluesky | Posts | Links, Images |
| Threads | Posts | Links, Images, Videos |
| Mastodon | Posts | Links, Images, Videos |
| Discord | Messages | Images, Videos |
| Google Business Profile | Business Posts | Images |
| VK (VKontakte) | Posts | Links, Images |
| Xing | Posts | Links, Images |
| Blogger | Articles | Images |
| DEV.to | Articles | Images, Videos |
| Flickr | Media Posts | Images, Videos |
| Diigo | Bookmarks | Links |
| Bloglovin | Blog Posts | Images |
| Torial | Articles | Images |
| Ravelry | Posts | Images |
| Instapaper | Saved Content | Links |
| Band | Posts | Images |
| HumHub | Posts | Images |
The Blog2Social API provides a unified interface for publishing content across social media networks, blogging platforms, business networks, video platforms and community platforms. ---
### Platform Features
- Multi-network publishing
- Link, image and video publishing
- Profiles, pages and groups
- Boards, playlists and categories
- Post insights and analytics
- Video upload support
- Automated publishing workflows
---
# Quick Start Guide
Get your first social media post published in less than 5 minutes. ## Authentication Model
The API uses a two-layer authentication model:
service_token = your application
access_token = your user
Think of the service_token as your app key and the access_token as the user''s session token. Most API requests require both tokens. ## Prerequisites
- A free Blog2Social API account to get started. ## Step 1: Get Your API Key
Navigate to the My Apps section in your Blog2Social API Console and click Create App. Once the application has been created, copy the generated service_token and store it securely. The service_token uniquely identifies your application and is required for all API requests. ## Step 2: Authenticate User
POST /user/auth
Request:
```json
{
"service_token": "YOUR_SERVICE_TOKEN"
}
```
Response:
```json
{
"access_token": "USER_ACCESS_TOKEN",
"refresh_token": "REFRESH_TOKEN"
}
```
Save the access_token for all future API requests.'
version: 1.0.0
title: Blog2Social Share API
x-logo:
url: assets/image/b2slogo.png
backgroundColor: '#FFFFFF'
altText: Blog2Social API
servers:
- url: https://api.blog2social.com/rest/v1.0
tags:
- name: Share
paths:
/network/post/create:
post:
tags:
- Share
summary: Share to Network
operationId: create
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- service_token
- access_token
- client_user_network_id
- b2s_posts
properties:
service_token:
type: string
description: The token for your service
access_token:
type: string
description: The access token for the authenticated user.
client_user_network_id:
type: integer
description: The ID of the user's connected social media account authorization.
b2s_posts:
$ref: '#/components/schemas/PostObject'
description: List of posts to publish.
example:
service_token: YOUR_SERVICE_TOKEN
access_token: YOUR_ACCESS_TOKEN
client_user_network_id: 3241
b2s_posts:
- client_user_network_id: 3241
title: My first API post
message: Hello from the Blog2Social API
postFormat: 0
customUrl: https://example.com
x-codeSamples:
- lang: cURL
source: "curl -X POST https://api.blog2social.com/rest/v1.0/network/post/create \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"service_token\": \"YOUR_SERVICE_TOKEN\",\n \"access_token\": \"YOUR_ACCESS_TOKEN\",\n \"client_user_network_id\": YOUR_CLIENT_USER_NETWORK_ID,\n \"b2s_posts\": [\n {\n \"client_user_network_id\": 3241,\\n \"title\": \"My first API post\",\\n \"message\": \"Hello from the Blog2Social API\",\\n \"postFormat\": 0,\\n \"customUrl\": \"https://example.com\"\n }\n ]\n}'"
- lang: PHP
source: "<?php\n\n$payload = [\n 'service_token' => 'YOUR_SERVICE_TOKEN',\n 'access_token' => 'YOUR_ACCESS_TOKEN',\n 'client_user_network_id' => YOUR_CLIENT_USER_NETWORK_ID,\n 'b2s_posts' => [\n [\n 'client_user_network_id' => 3241,\n 'title' => 'My first API post',\n 'message' => 'Hello from the Blog2Social API',\n 'postFormat' => 0,\n 'customUrl' => 'https://example.com',\n ],\n ],\n];\n\n$curl = curl_init('https://api.blog2social.com/rest/v1.0/network/post/create');\n\ncurl_setopt_array($curl, [\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_POST => true,\n CURLOPT_HTTPHEADER => [\n 'Content-Type: application/json',\n ],\n CURLOPT_POSTFIELDS => json_encode($payload),\n]);\n\n$response = curl_exec($curl);\n$error = curl_error($curl);\n\n$curl = null;\n\nif ($response === false) {\n throw new RuntimeException($error);\n}\n\necho $response;"
responses:
'200':
description: OK
content:
application/json:
schema:
type: array
items:
type: object
properties:
error:
type: integer
type:
type: string
publish_url:
type: string
network_post_id:
type: string
b2s_error_code:
type: string
description: One of <br>DEFAULT - The network could not publish your post<br>TOKEN - Your authorization has expired<br>CONTENT - The content of your post could not be approved by the network<br>RIGHT - We don't have the permission to publish your post<br>LOGIN - The connection to your social media account is interrupted<br>LIMIT - Your daily limit has been reached<br>IMAGE - Your post could not be posted, because your image is not available or the image source does not allow to publish<br>VIDEO - Your post could not be posted, because your video is not available or the video source does not allow to publish<br>PROTECT - The network has blocked your account<br>IMAGE_LIMIT - The number of images is reached<br>RATE_LIMIT - Your daily limit for this network has been reached<br>INVALID_CONTENT - The network can not publish special characters such as Emoji<br>EXISTS_CONTENT - Your post is a duplicate<br>URL_CONTENT - The network requires a public url<br>GROUP_CONTENT - Your group can not be found by the network<br>NO_DATA - Your data are not complete<br>BLOGPOST_NOT_PUBLISHED - Your blog post was not available for the network at the time of publishing
extra:
type: object
properties:
expired:
type: integer
description: return only when the authorisation is expired (value 1)
post_id:
type: integer
example:
- error: 0
type: 0
publish_url: https://x.com/12345
network_post_id: YOUR_CLIENT_USER_NETWORK_ID
post_id: 1
- error: 1
type: 0
b2s_error_code: DEFAULT | TOKEN | CONTENT | RIGHT | LOGIN | LIMIT | IMAGE | VIDEO | PROTECT | IMAGE_LIMIT | RATE_LIMIT | INVALID_CONTENT | EXISTS_CONTENT | URL_CONTENT | GROUP_CONTENT | NO_DATA | BLOGPOST_NOT_PUBLISHED
extra:
expired: 1
post_id: 2
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/error_1002'
'401':
description: Unauthorized
content:
application/json:
schema:
oneOf:
- $ref: '#/components/schemas/error_401'
- $ref: '#/components/schemas/error_1001'
- $ref: '#/components/schemas/error_1003'
'500':
description: Interal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/error_500'
/network/post/remove:
post:
tags:
- Share
summary: Remove from Network
description: 'Remove content from a Network
A response of 200 OK only means, that we could request to the network without any error. Please check the response result for further information.'
operationId: remove
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- service_token
- access_token
- client_user_network_id
- b2s_posts
properties:
service_token:
type: string
description: The token for your service
example: YOUR_SERVICE_TOKEN
access_token:
type: string
description: The access token for the authenticated user.
example: YOUR_ACCESS_TOKEN
client_user_network_id:
type: integer
description: The id of the network authorization (required for single posts only / not for bulk)
example: YOUR_CLIENT_USER_NETWORK_ID
b2s_posts:
type: array
description: List of posts you want to remove
items:
type: object
properties:
client_user_network_id:
type: integer
description: User network auth ID to which the post belongs
example: YOUR_CLIENT_USER_NETWORK_ID
post_id:
type: integer
description: The ID of the Post you want to remove
example: 1234
publish_link:
type: string
description: Required to extract the media ID (Google Business Profile only)
example: https://google.com/YOUR_CLIENT_USER_NETWORK_ID
required:
- client_user_network_id
- post_id
example:
service_token: YOUR_SERVICE_TOKEN
access_token: YOUR_ACCESS_TOKEN
client_user_network_id: YOUR_CLIENT_USER_NETWORK_ID
b2s_posts:
- client_user_network_id: YOUR_CLIENT_USER_NETWORK_ID
post_id: 1234
publish_link: https://example.com/published-post
x-codeSamples:
- lang: cURL
source: "curl -X POST https://api.blog2social.com/rest/v1.0/network/post/remove \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"service_token\": \"YOUR_SERVICE_TOKEN\",\n \"access_token\": \"YOUR_ACCESS_TOKEN\",\n \"client_user_network_id\": YOUR_CLIENT_USER_NETWORK_ID,\n \"b2s_posts\": [\n {\n \"client_user_network_id\": YOUR_CLIENT_USER_NETWORK_ID,\n \"post_id\": 1234,\n \"publish_link\": \"https://example.com/published-post\"\n }\n ]\n}'"
- lang: PHP
source: "<?php\n\n$payload = [\n 'service_token' => 'YOUR_SERVICE_TOKEN',\n 'access_token' => 'YOUR_ACCESS_TOKEN',\n 'client_user_network_id' => YOUR_CLIENT_USER_NETWORK_ID,\n 'b2s_posts' => [\n [\n 'client_user_network_id' => YOUR_CLIENT_USER_NETWORK_ID,\n 'post_id' => 1234,\n 'publish_link' => 'https://example.com/published-post',\n ],\n ],\n];\n\n$curl = curl_init('https://api.blog2social.com/rest/v1.0/network/post/remove');\n\ncurl_setopt_array($curl, [\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_POST => true,\n CURLOPT_HTTPHEADER => [\n 'Content-Type: application/json',\n ],\n CURLOPT_POSTFIELDS => json_encode($payload),\n]);\n\n$response = curl_exec($curl);\n$error = curl_error($curl);\n\n$curl = null;\n\nif ($response === false) {\n throw new RuntimeException($error);\n}\n\necho $response;"
responses:
'200':
description: OK
content:
application/json:
schema:
type: array
items:
type: object
properties:
error:
type: integer
example: 0
client_user_network_id:
type: integer
example: YOUR_CLIENT_USER_NETWORK_ID
deleted_publish_link:
type: string
example: https://google.com/YOUR_CLIENT_USER_NETWORK_ID
extra:
type: object
properties:
expired:
type: integer
description: Return only when the authorization is expired (value 1)
example: 1
example:
- error: 0
client_user_network_id: YOUR_CLIENT_USER_NETWORK_ID
deleted_publish_link: https://google.com/YOUR_CLIENT_USER_NETWORK_ID
extra: []
'400':
description: Bad Request
content:
application/json:
schema:
$ref: '#/components/schemas/error_1002'
'401':
description: Unauthorized
content:
application/json:
schema:
oneOf:
- $ref: '#/components/schemas/error_401'
- $ref: '#/components/schemas/error_1001'
- $ref: '#/components/schemas/error_1003'
'500':
description: Internal Server Error
content:
application/json:
schema:
$ref: '#/components/schemas/error_500'
components:
schemas:
ShareSettingsTikTok:
title: TikTok share settings
type: object
description: TikTok-specific sharing settings. The fields status_privacy, allow_comment, promotion_option_organic, and promotion_option_branded are required when direct publishing is enabled.
properties:
mode:
type: integer
description: 'Share mode: 0 = draft, 1 = direct publish.'
enum:
- 0
- 1
default: 0
status_privacy:
type: string
description: Privacy status of the post. Required when direct publishing is enabled.
enum:
- PUBLIC_TO_EVERYONE
- FOLLOWER_OF_CREATOR
- MUTUAL_FOLLOW_FRIENDS
- SELF_ONLY
allow_comment:
type: integer
description: Whether comments are allowed. Required when direct publishing is enabled.
enum:
- 0
- 1
promotion_option_organic:
type: integer
description: Enable the organic promotion option. Required when direct publishing is enabled.
enum:
- 0
- 1
promotion_option_branded:
type: integer
description: Enable the branded promotion option. Required when direct publishing is enabled.
enum:
- 0
- 1
additionalProperties: false
example:
mode: 1
status_privacy: PUBLIC_TO_EVERYONE
allow_comment: 1
promotion_option_organic: 0
promotion_option_branded: 0
error_1002:
type: object
properties:
error_code:
type: integer
example: 1002
error_message:
type: string
example: required parameter missing {PARAMETER}
ShareSettings:
oneOf:
- $ref: '#/components/schemas/ShareSettingsTikTok'
- $ref: '#/components/schemas/ShareSettingsMedium'
description: Network-specific sharing settings. Use the schema that matches the network identified by client_user_network_id. TikTok values must match the TikTok account settings.
error_1003:
type: object
properties:
error_code:
type: integer
example: 1003
error_message:
type: string
example: access token invalid
error_1001:
type: object
properties:
error_code:
type: integer
example: 1001
error_message:
type: string
example: access token required
ShareSettingsMedium:
title: Medium share settings
type: object
description: Medium-specific sharing settings.
properties:
notify_followers:
type: integer
description: Enable follower notifications.
enum:
- 0
- 1
publish_status:
type: string
description: Publish status of the post.
default: public
enum:
- public
- draft
- unlisted
additionalProperties: false
example:
notify_followers: 1
publish_status: public
error_500:
description: Internal Server Error
type: object
properties:
error_code:
type: integer
example: 500
error_message:
type: string
example: interal server error
error_401:
description: Unauthorized
type: object
properties:
error_code:
type: integer
example: 401
error_message:
type: string
example: unauthorized
PostObject:
type: array
items:
type: object
properties:
client_user_network_id:
type: integer
description: User network auth id to wich the post should go
title:
type: string
description: Set post title
message:
type: string
description: Set post message
postFormat:
type: integer
description: Set post format (Link: 0; Image: 1; Video: 2)
enum:
- 0
- 1
- 2
customUrl:
type: string
description: Set post url content
noCache:
type: integer
description: If the link shoud get a no_cache parameter
enum:
- 0
- 1
tags:
type: array
description: Tags to post
items:
type: string
board:
type: string
description: Pinterest board to post to
mediaObjects:
type: array
description: List of Media Objects to add to the post (For Facebook and X you can add up to 4 images, for Instagram up to 10 and for LinkedIn up to 9. Every other Network will only post the first image in the list)
items:
type: object
properties:
type:
type: string
description: Image or Video
enum:
- IMAGE
- VIDEO
url:
type: string
description: URL to the file
alt:
type: string
description: Alternative text for the media
media_is_ai_generated:
type: integer
description: Indicates whether the image/video was AI-generated
enum:
- 0
- 1
is_retweet:
type: integer
description: Indicator, if the post should be a retweet
enum:
- 0
- 1
network_post_id:
type: string
description: The id of the post you want to retweet
post_id:
type: integer
description: Identifier that will be returned with the Post Result Object, so you can pair it up with your request.
make_threads:
type: integer
description: The post message gets cut and added as comments to the post if a message exceeds the character limit (X only)
default: 0
enum:
- 0
- 1
ignore_link:
type: integer
description: If enabled, the link URL won't be added to the end of the post message
default: 0
enum:
- 0
- 1
comment:
type: string
description: First comment to add to the post. Support is subject to network-specific limitations; verify supported networks before publishing.
share_settings:
$ref: '#/components/schemas/ShareSettings'
text_is_ai_generated:
type: integer
description: Indicates whether the text was AI-generated
enum:
- 0
- 1