Headline Open Interface

The opening interface of the headline article needs to be called through the user's authorization access_token.


To open the headline article interface, the third party needs to be an entity such as government, media, and institutions. Individuals cannot access it for the time being. Qualified microblog accounts should be authenticated as developers on the microblog open platform, and then contact their corresponding blue V customer service or government operations for consultation and discussion. After passing, the interface can be opened.


Headline publishing interface

Publish a headline

Interface address

https://api.weibo.com/proxy/article/publish.json


Request mode

POST


Request Parameters

Parameter name type Required describe
title string yes Article title, limited to 32 Chinese and English characters
content string yes Body content, limited to 90000 Chinese and English characters, urlencode is required
cover string yes Address url of article cover image
rip string yes The real IP address of the operating user reported by the developer, such as 211.156.0.1, please pass the real and valid IP address of the operating user
summary string no Introduction
text string yes It is bound to short microblog content, which is limited to 1900 Chinese and English characters
access_token string yes Authentication token

Note: The parameters that need urlencode use PHP's rawurlencode function, that is, the space will be encoded as% 20


Return Field Description

Parameter name type describe
code string Return code, 100000 if successful, other if unsuccessful
msg string The default value is blank. If the code is not 100000, an error message is returned. See the Error Comparison Table for error descriptions
data json Result data, return on success, return blank on failure
|__ object_id string Object id
|__ url string Article url
|__ mid string Short microblog object id


Other instructions

1. The URL for viewing articles on the PC side is: https://weibo.com/ttarticle/p/show?id= {id}

2. The URL address of the article viewed on the mobile terminal is: https://media.weibo.cn/article?id= {id}


DEMO Example

Demo address: https://github.com/weiboeditor/open


Error code correspondence table

Error code error message describe
ten thousand and one system error System error
ten thousand and eight param xxx invalid Parameter xxx does not meet the requirements
eleven thousand and one sass check error Release too frequently
eleven thousand and two create statuses error Failed to send microblog
eleven thousand and three bind error Failed to associate the article with Weibo





Document update time: 2022-11-29