top
关闭

开发者登录

主要使用场景:

1、文章-批量查看文章详情

前置条件

获取接口访问凭证:accessToken

请求说明

url https://opengate.huijiaoyun.com/openapi/post/views?accessToken=******
请求方式 GET
格式 json
是否需要鉴权
请求数限制
接口方向 第三方应用>开放平台

参数说明

序号 字段名 约束 位置 类型 长度 说明

1

ids

必选

Body(json)

string

-

文章编号,多个id以”,”分割

返回说明

序号 字段名 约束 类型 长度 说明

1

code

可选

string

-

返回状态

2

message

可选

string

-

返回消息

3

runtime

可选

string

-

返回速度

4

result

可选

string

-

返回结果

4.1

id

可选

string

-

文章id

4.2

userid

可选

string

-

用户id

4.3

username

可选

string

-

用户昵称

4.4

organizationid

可选

string

-

机构id

4.5

classid

可选

string

-

班级id

4.6

title

可选

string

-

文章标题

4.7

content

可选

string

-

文章内容

4.8

categoryid

可选

string

-

分类id

4.9

article_category_id

可选

string

-

4.10

publishid

可选

string

-

4.11

parentid

可选

string

-

4.12

paperid

可选

string

-

4.13

copyid

可选

string

-

转载文章id

4.14

type

可选

string

-

类型

4.15

external_type

可选

string

-

外部权限

4.16

tags

可选

string

-

标签

4.17

datetime

可选

int

-

发表时间

4.18

updatetime

可选

int

-

更新时间

4.19

searchtime

可选

string

-

最后查看时间

4.20

status

可选

string

-

状态

4.21

copy_status

可选

string

-

转载权限

4.22

comment_status

可选

string

-

评论权限

4.23

comment_count

可选

string

-

评论数

4.24

view_count

可选

string

-

查看次数

4.25

like_count

可选

string

-

喜欢数

4.26

copy_count

可选

string

-

转载数

4.27

favorite_count

可选

string

-

收藏数

4.28

child_count

可选

string

-

4.29

resource

可选

string

-

4.30

istop

可选

string

-

是否置顶

4.31

isdel

可选

string

-

是否删除

4.32

reply_status

可选

string

-

回复状态

4.33

operate

可选

string

-

4.34

issnspost

可选

string

-

4.35

isPrivate

可选

string

-

4.36

credit

可选

string

-

学分

4.37

experience

可选

string

-

经验

4.38

password

可选

string

-

4.39

publisher

可选

string

-

4.40

original_type

可选

string

-

4.41

original_type_url

可选

string

-

4.42

studyphase

可选

string

-

4.43

majorsubjectid

可选

string

-

4.44

majorsubjectname

可选

string

-

4.45

usertype

可选

string

-

用户类型

4.46

platformCode

可选

string

-

平台码

4.47

shareid

可选

string

-

4.48

commendlevel

可选

string

-

4.49

areacode

可选

string

-

区域码

4.50

hasPicture

可选

string

-

是否有图片

4.51

issharepost

可选

string

-

是否是分享的文章

4.52

objectid

可选

string

-

被分享的文章id

4.53

taskId

可选

string

-

4.54

from_type

可选

string

-

来源类型

4.55

from_move

可选

string

-

4.56

has_add_credit

可选

string

-

是否添加学分

4.57

templateid

可选

string

-

模板id

4.58

musicid

可选

string

-

背景音乐id

4.59

cover

可选

string

-

封面

4.60

source

可选

string

-

资源地址

示例

							请求报文:
http://opengate.t.huijiaoyun.com/openapi/post/views?accessToken=******&ids=xxx

应答报文:
{"code":"000000","message":"请求成功","runtime":"0.08345","result":[{"_id":{"$id":"5507def54d4a13d8618b4587"},"id":1611612785,"userid":"eab92753997b41d49032fa104b78c6a6","username":"滕老师","organizationid":"cbaa19e76e524c48a0cc10173205137f","classid":null,"title":"初三物理理论知识","content":"

\"image\"初三物理理论知识,概念介绍;
<\/p>","categoryid":2597959,"article_category_id":null,"publishid":0,"parentid":null,"paperid":0,"copyid":null,"type":"post","external_type":"public","tags":"学无止","datetime":1426579188,"updatetime":1486707652,"searchtime":"2018-07-18 10:13:50","status":"publish","copy_status":"close","comment_status":"close","comment_count":0,"view_count":39,"like_count":1,"copy_count":null,"favorite_count":0,"child_count":null,"resource":"","istop":1472026683,"isdel":null,"reply_status":null,"operate":null,"issnspost":null,"isPrivate":null,"credit":0,"experience":0,"password":"","publisher":null,"original_type":null,"original_type_url":null,"studyphase":"0","majorsubjectid":"jcsub30","majorsubjectname":"劳动技术","usertype":"1","platformCode":"888888","shareid":null,"commendlevel":null,"areacode":"420106","hasPicture":null,"issharepost":null,"objectid":null,"taskId":null,"from_type":null,"from_move":null,"has_add_credit":null,"templateid":null,"musicid":null,"cover":null,"source":null}]}                                              
						

参数说明

请求参数消息体-文本类
序号 字段名 约束 类型 长度 说明

1

msgType

必选

String

10

消息类型,此时固定为:text

1.1

text

必选

Json

-

text消息体

1.1.1

content

必选

String

消息内容

示例

{
	"msgtype": "text",
	"text": {
		"content": "zhxy msg text test 12"
	}
}
											

参数说明

请求参数消息体-link类
序号 字段名 约束 类型 长度 说明

1

msgType

必选

String

10

消息类型,此时固定为:link

2

link

必选

Json

-

link消息体

2.1

pcUrl

必选

String

PC端消息点击链接地址

2.2

appUrl

必选

String

移动客户端点击消息时跳转到的H5地址

2.3

title

必选

String

消息标题

2.4

busiId

必选

String

对应业务的id

2.5

content

必选

String

消息描述

2.6

picUrl

必选

String

图文消息的图片链接,支持JPG、PNG格式,较好的效果为大图640*320,小图80*80。如不填,在客户端不显示图片

示例

{
	"msgtype": "link",
	"link": {
		"pcUrl": "http://www.baidu.com",
		"appUrl": "http://www.baidu.com",
		"picUrl": "http://xxx.yyy.com/zzz.jpg",
		"content": "百度一下",
		"title": "百度",
		"busiId":"AQWER1234"
	}
}
											

参数说明

请求参数消息体-oa类
序号 字段名 约束 类型 长度 说明

1

msgType

必选

String

10

消息类型,此时固定为:oa

2

busiId

必选

String

-

该条oa消息在业务系统对应的id

3

pcUrl

必选

String

消息点击链接地址

4

appUrl

必选

String

移动客户端点击消息时跳转到的H5地址

5

oa

必选

Json

-

oa类型消息体

5.1

head

必选

Json

255

消息头部Json

5.1.1

text

必选

String

255

消息的头部标题

5.1.2

bgColor

可选

String

消息头部的背景颜色。长度限制为8个英文字符,其中前2为表示透明度,后6位表示颜色值。不要添加0x。默认值:FFCC0000

5.2

body

可选

Json

消息体

5.2.1

title

可选

String

消息体的标题

5.2.2

content

可选

String

消息体的正文

5.2.3

imageUrl

可选

String

消息体中的图片url

5.2.4

fileCount

可选

String

自定义的附件数目。此数字仅供显示,不作验证

5.2.5

author

可选

String

自定义的作者名字

5.2.6

form

可选

Json数组

消息体的表单,最多6个

5.2.7

key

可选

String

消息体的关键字

5.2.8

value

可选

String

消息体的关键字对应的值