跳转到: 导航, 搜索
 
(未显示2个用户的17个中间版本)
第4行: 第4行:
 
<div class="wiki_taglist">
 
<div class="wiki_taglist">
 
<ul class="clearfix">
 
<ul class="clearfix">
 +
<li>[[#OAuth2|OAuth 2.0授权接口]]</li>
 
<li>[[#粉丝服务接口|粉丝服务接口]]</li>
 
<li>[[#粉丝服务接口|粉丝服务接口]]</li>
 
                         <li>[[#微博|微博接口]]</li>
 
                         <li>[[#微博|微博接口]]</li>
 
<li>[[#评论|评论接口]]</li>
 
<li>[[#评论|评论接口]]</li>
 
<li>[[#用户|用户接口]]</li>
 
<li>[[#用户|用户接口]]</li>
<li>[[#关系|关系接口]]</li>
 
<li>[[#搜索|搜索接口]]</li>
 
<li>[[#提醒|提醒接口]]</li>
 
<li>[[#短链|短链接口]]</li>
 
<li>[[#公共服务|公共服务接口]]</li>
 
<li>[[#账号|账号接口]]</li>
 
<li>[[#OAuth2|OAuth 2.0授权接口]]</li>
 
 
</ul>
 
</ul>
 
</div>
 
</div>
第43行: 第37行:
 
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
 
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
!colspan="3" scope="col"|<span id="微博">微博</span>
+
!colspan="3" scope="col"|<span id="OAuth2">OAuth2([[授权机制说明|开发指南]])</span>
 
|-
 
|-
|rowspan="19" style="text-align:center;"|读取接口
+
|rowspan="1" style="text-align:center;"|请求授权
|[[2/statuses/public_timeline|statuses/public_timeline]]
+
|[[oauth2/authorize]]
|获取最新的公共微博
+
|请求用户授权Token
 
|-
 
|-
|[[2/statuses/friends_timeline|statuses/friends_timeline]]
+
|rowspan="1" style="text-align:center;"|获取授权
|获取当前登录用户及其所关注用户的最新微博
+
|[[oauth2/access_token|oauth2/access_token]]
 +
|获取授权过的Access Token
 
|-
 
|-
|[[2/statuses/home_timeline|statuses/home_timeline]]
+
|rowspan="1" style="text-align:center;"|授权查询
|获取当前登录用户及其所关注用户的最新微博
+
|[[oauth2/get_token_info]]
 +
|查询用户access_token的授权相关信息 {{Icon_new2}}
 
|-
 
|-
|[[2/statuses/friends_timeline/ids|statuses/friends_timeline/ids]]
+
|rowspan="1" style="text-align:center;"|替换授权
|获取当前登录用户及其所关注用户的最新微博的ID
+
|[[oauth2/get_oauth2_token]]
 +
|OAuth1.0的Access Token更换至OAuth2.0的Access Token
 
|-
 
|-
|[[2/statuses/user_timeline|statuses/user_timeline]]
+
|rowspan="1" style="text-align:center;"|授权回收
|获取用户发布的微博
+
|[[oauth2/revokeoauth2|oauth2/revokeoauth2]]
 +
|授权回收接口,帮助开发者主动取消用户的授权 {{Icon_new2}}
 
|-
 
|-
|[[2/statuses/user_timeline/ids|statuses/user_timeline/ids]]
+
|rowspan="3" style="text-align:center;"|其他接口
|获取用户发布的微博的ID
+
|[[2/account/rate_limit_status|account/rate_limit_status]]
 +
|获取当前授权用户API访问频率限制
 
|-
 
|-
|[[2/statuses/timeline_batch|statuses/timeline_batch]]
+
|[[2/account/get_uid|account/get_uid]]
|批量获取指定的一批用户的微博列表 {{Icon_adv}}
+
|授权之后获取用户的UID
 
|-
 
|-
|[[2/statuses/repost_timeline|statuses/repost_timeline]]
+
|[[2/account/profile/email|account/profile/email]]
|返回一条原创微博的最新转发微博
+
|授权之后获取用户的联系邮箱 {{Icon_adv}} {{Icon_scope}}
 +
|}
 +
 
 +
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 +
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
 +
!colspan="3" scope="col"|<span id="用户">用户</span>
 +
|-
 +
|rowspan="2" style="text-align:center;"|读取接口
 +
|[[2/users/show|users/show]]
 +
|授权之后获取用户信息
 +
|-
 +
|[[2/users/domain_show|users/domain_show]]
 +
|授权之后通过个性域名获取用户信息
 +
|}
 +
 
 +
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 +
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
 +
!colspan="3" scope="col"|<span id="微博">微博</span>
 
|-
 
|-
|[[2/statuses/repost_timeline/ids|statuses/repost_timeline/ids]]
+
|rowspan="8" style="text-align:center;"|读取接口
|获取一条原创微博的最新转发微博的ID
+
|[[2/statuses/home_timeline|statuses/home_timeline]]
 +
|获取当前授权用户及其所关注用户的最新微博
 
|-
 
|-
|[[2/statuses/mentions|statuses/mentions]]
+
|[[2/statuses/user_timeline|statuses/user_timeline]]
|获取@当前用户的最新微博
+
|获取授权用户发布的微博
 
|-
 
|-
|[[2/statuses/mentions/ids|statuses/mentions/ids]]
+
|[[2/statuses/repost_timeline|statuses/repost_timeline]]
|获取@当前用户的最新微博的ID
+
|返回一条原创微博的最新转发微博
 
|-
 
|-
|[[2/statuses/bilateral_timeline|statuses/bilateral_timeline]]
+
|[[2/statuses/mentions|statuses/mentions]]
|获取双向关注用户的最新微博
+
|获取@当前授权用户的最新微博
 
|-
 
|-
 
|[[2/statuses/show|statuses/show]]
 
|[[2/statuses/show|statuses/show]]
 
|根据ID获取单条微博信息
 
|根据ID获取单条微博信息
|-
 
|[[2/statuses/show_batch|statuses/show_batch]]
 
|根据微博ID批量获取微博信息 {{Icon_adv}}
 
|-
 
|[[2/statuses/querymid|statuses/querymid]]
 
|通过id获取mid
 
|-
 
|[[2/statuses/queryid|statuses/queryid]]
 
|通过mid获取id
 
 
|-
 
|-
 
|[[2/statuses/count|statuses/count]]
 
|[[2/statuses/count|statuses/count]]
第103行: 第111行:
 
|获取官方表情
 
|获取官方表情
 
|-
 
|-
|rowspan="6" style="text-align:center;"|写入接口
+
|rowspan="1" style="text-align:center;"|写入接口
 
|[[2/statuses/share|statuses/share]]
 
|[[2/statuses/share|statuses/share]]
 
|第三方分享链接到微博 {{Icon_new2}}
 
|第三方分享链接到微博 {{Icon_new2}}
|-
 
|[[2/statuses/repost|statuses/repost]]
 
|转发一条微博信息 {{Icon_adv}}
 
|-
 
|[[2/statuses/destroy|statuses/destroy]]
 
|删除微博信息 {{Icon_adv}}
 
|-
 
|[[2/statuses/update|statuses/update]]
 
|发布一条微博信息 {{Icon_adv}}
 
|-
 
|[[2/statuses/upload|statuses/upload]]
 
|上传图片并发布一条微博 {{Icon_adv}}
 
|-
 
|[[2/statuses/upload_url_text|statuses/upload_url_text]]
 
|发布一条微博同时指定上传的图片或图片url {{Icon_adv}}
 
 
|}
 
|}
  
第127行: 第120行:
 
!colspan="3" scope="col"|<span id="评论">评论</span>
 
!colspan="3" scope="col"|<span id="评论">评论</span>
 
|-
 
|-
|rowspan="6" style="text-align:center;"|读取接口
+
|rowspan="2" style="text-align:center;"|读取接口
 
|[[2/comments/show|comments/show]]
 
|[[2/comments/show|comments/show]]
 
|获取某条微博的评论列表
 
|获取某条微博的评论列表
|-
 
|[[2/comments/by_me|comments/by_me]]
 
|我发出的评论列表
 
|-
 
|[[2/comments/to_me|comments/to_me]]
 
|我收到的评论列表
 
|-
 
|[[2/comments/timeline|comments/timeline]]
 
|获取用户发送及收到的评论列表
 
 
|-
 
|-
 
|[[2/comments/mentions|comments/mentions]]
 
|[[2/comments/mentions|comments/mentions]]
 
|获取@到我的评论
 
|获取@到我的评论
 
|-
 
|-
|[[2/comments/show_batch|comments/show_batch]]
+
|rowspan="2" style="text-align:center;"|写入接口
|批量获取评论内容
+
|-
+
|rowspan="4" style="text-align:center;"|写入接口
+
 
|[[2/comments/create|comments/create]]
 
|[[2/comments/create|comments/create]]
 
|评论一条微博
 
|评论一条微博
|-
 
|[[2/comments/destroy|comments/destroy]]
 
|删除一条评论
 
|-
 
|[[2/comments/destroy_batch|comments/destroy_batch]]
 
|批量删除评论
 
 
|-
 
|-
 
|[[2/comments/reply|comments/reply]]
 
|[[2/comments/reply|comments/reply]]
|回复一条评论
+
|回复一条我收到的评论
|}
+
 
+
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
+
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
+
!colspan="3" scope="col"|<span id="用户">用户</span>
+
|-
+
|rowspan="3" style="text-align:center;"|读取接口
+
|[[2/users/show|users/show]]
+
|获取用户信息
+
|-
+
|[[2/users/domain_show|users/domain_show]]
+
|通过个性域名获取用户信息
+
|-
+
|[[2/users/counts|users/counts]]
+
|批量获取用户的粉丝数、关注数、微博数
+
|}
+
 
+
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
+
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
+
!colspan="3" scope="col"|<span id="关系">关系</span>
+
|-
+
|rowspan="5" style="text-align:center;"|关注读取接口
+
|[[2/friendships/friends|friendships/friends]]
+
|获取用户的关注列表
+
|-
+
|[[2/friendships/friends/in_common|friendships/friends/in_common]]
+
|获取共同关注人列表
+
|-
+
|[[2/friendships/friends/bilateral|friendships/friends/bilateral]]
+
|获取双向关注列表
+
|-
+
|[[2/friendships/friends/bilateral/ids|friendships/friends/bilateral/ids]]
+
|获取双向关注UID列表
+
|-
+
|[[2/friendships/friends/ids|friendships/friends/ids]]
+
|获取用户关注对象UID列表
+
|-
+
|rowspan="3" style="text-align:center;"|粉丝读取接口
+
|[[2/friendships/followers|friendships/followers]]
+
|获取用户粉丝列表
+
|-
+
|[[2/friendships/followers/ids|friendships/followers/ids]]
+
|获取用户粉丝UID列表
+
|-
+
|[[2/friendships/followers/active|friendships/followers/active]]
+
|获取用户优质粉丝列表
+
|-
+
|rowspan="1" style="text-align:center;"|关系链读取接口
+
|[[2/friendships/friends_chain/followers|friendships/friends_chain/followers]]
+
|获取我的关注人中关注了指定用户的人
+
|-
+
|rowspan="1" style="text-align:center;"|关系读取接口
+
|[[2/friendships/show|friendships/show]]
+
|获取两个用户关系的详细情况
+
|-
+
|rowspan="2" style="text-align:center;"|写入接口
+
|[[2/friendships/create|friendships/create]]
+
|关注某用户 {{Icon_adv}}
+
|-
+
|[[2/friendships/destroy|friendships/destroy]]
+
|取消关注某用户 {{Icon_adv}}
+
|}
+
 
+
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
+
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
+
!colspan="3" scope="col"|<span id="搜索">搜索</span>
+
|-
+
|rowspan="1" style="text-align:center;"|搜索话题接口
+
|[[2/search/topics|search/topics]]
+
|搜索某一话题下的微博 {{Icon_adv}}
+
|}
+
 
+
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
+
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
+
!colspan="3" scope="col"|<span id="提醒">提醒</span>
+
|-
+
|rowspan="1" style="text-align:center;"|读取接口
+
|[[2/remind/unread_count|remind/unread_count]]
+
|获取某个用户的各种消息未读数
+
|-
+
|rowspan="1" style="text-align:center;"|写入接口
+
|[[2/remind/set_count|remind/set_count]]
+
|对当前登录用户某一种消息未读数进行清零 {{Icon_adv}}
+
|}
+
 
+
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
+
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
+
!colspan="3" scope="col"|<span id="短链">短链</span>
+
|-
+
|rowspan="2" style="text-align:center;"|转换接口
+
|[[2/short_url/shorten|short_url/shorten]]
+
|长链转短链
+
|-
+
|[[2/short_url/expand|short_url/expand]]
+
|短链转长链
+
|-
+
|rowspan="2" style="text-align:center;"|数据接口
+
|[[2/short_url/share/counts|short_url/share/counts]]
+
|获取短链接在微博上的微博分享数
+
|-
+
|[[2/short_url/comment/counts|short_url/comment/counts]]
+
|获取短链接在微博上的微博评论数
+
 
|}
 
|}
  
第283行: 第156行:
 
|}
 
|}
  
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
 
!colspan="3" scope="col"|<span id="账号">账号</span>
 
|-
 
|rowspan="3" style="text-align:center;"|读取接口
 
|[[2/account/rate_limit_status|account/rate_limit_status]]
 
|获取当前用户API访问频率限制
 
|-
 
|[[2/account/profile/email|account/profile/email]]
 
|获取用户的联系邮箱 {{Icon_adv}} {{Icon_scope}}
 
|-
 
|[[2/account/get_uid|account/get_uid]]
 
|OAuth授权之后获取用户UID
 
|}
 
 
 
{|width="100%" border="0" cellspacing="0" cellpadding="0" class="wiki_table"
 
<html><colgroup><col class="tbF1"/><col class="tbF2" /><col /></colgroup></html>
 
!colspan="3" scope="col"|<span id="OAuth2">OAuth2([[授权机制说明|开发指南]])</span>
 
|-
 
|rowspan="1" style="text-align:center;"|请求授权
 
|[[oauth2/authorize]]
 
|请求用户授权Token
 
|-
 
|rowspan="1" style="text-align:center;"|获取授权
 
|[[OAuth2/access_token|oauth2/access_token]]
 
|获取授权过的Access Token
 
|-
 
|rowspan="1" style="text-align:center;"|授权查询
 
|[[oauth2/get_token_info]]
 
|查询用户access_token的授权相关信息 {{Icon_new2}}
 
|-
 
|rowspan="1" style="text-align:center;"|替换授权
 
|[[oauth2/get_oauth2_token]]
 
|OAuth1.0的Access Token更换至OAuth2.0的Access Token
 
|-
 
|rowspan="1" style="text-align:center;"|授权回收
 
|[[Oauth2/revokeoauth2|OAuth2/revokeoauth2]]
 
|授权回收接口,帮助开发者主动取消用户的授权 {{Icon_new2}}
 
|}
 
 
 
<p class="tips_txt">如果你还在使用 [[API文档|旧版接口]],请立即升级迁移到V2版接口上,[[V1_To_V2|V1到V2接口迁移指南]] 将帮助你完成迁移。</p>
 
  
  
 
{{#a:nobtns|noheading}}
 
{{#a:nobtns|noheading}}

2020年12月28日 (一) 12:54的最后版本

微博API

标识为 的接口为高级权限接口,需要申请才可以调用,申请方式请见 高级接口申请

标识为 的接口为需要单独向用户提出SCOPE授权请求的接口,用户单独授权后才可以调用,具体使用方法请见 SCOPE


粉丝服务(新手接入指南
读取接口 接收消息 接收用户私信、关注、取消关注、@等消息接口
写入接口 发送消息 向用户回复私信消息接口
生成带参数的二维码 生成带参数的二维码接口
OAuth2(开发指南
请求授权 oauth2/authorize 请求用户授权Token
获取授权 oauth2/access_token 获取授权过的Access Token
授权查询 oauth2/get_token_info 查询用户access_token的授权相关信息
替换授权 oauth2/get_oauth2_token OAuth1.0的Access Token更换至OAuth2.0的Access Token
授权回收 oauth2/revokeoauth2 授权回收接口,帮助开发者主动取消用户的授权
其他接口 account/rate_limit_status 获取当前授权用户API访问频率限制
account/get_uid 授权之后获取用户的UID
account/profile/email 授权之后获取用户的联系邮箱
用户
读取接口 users/show 授权之后获取用户信息
users/domain_show 授权之后通过个性域名获取用户信息
微博
读取接口 statuses/home_timeline 获取当前授权用户及其所关注用户的最新微博
statuses/user_timeline 获取授权用户发布的微博
statuses/repost_timeline 返回一条原创微博的最新转发微博
statuses/mentions 获取@当前授权用户的最新微博
statuses/show 根据ID获取单条微博信息
statuses/count 批量获取指定微博的转发数评论数
statuses/go 根据ID跳转到单条微博页
emotions 获取官方表情
写入接口 statuses/share 第三方分享链接到微博
评论
读取接口 comments/show 获取某条微博的评论列表
comments/mentions 获取@到我的评论
写入接口 comments/create 评论一条微博
comments/reply 回复一条我收到的评论
公共服务
读取接口 common/code_to_location 通过地址编码获取地址名称
common/get_city 获取城市列表
common/get_province 获取省份列表
common/get_country 获取国家列表
common/get_timezone 获取时区配置表



文档更新时间: 2020-12-28