POST https://lxapi.lexiangla.com/cgi-bin/v1/lives
document
{
"data":{
"type":"live",
"attributes":{
"title":"s2",
"started_at":"2020-02-15 14:00",
"intro":"简介",
"content":"内容",
"push_method":"pc",
"vertical": 0,
"privilege_type":1,
"auto_transfer_class": true,
"class_category_id": "63f009d4da8511e982470242ac180006",
"course_category_id": "22c81ad852c011ea970e0242ac130006"
},
"relationships":{
"streamer":{
"data":[
{
"type":"staff",
"id":"xxx"
}
]
},
"managers":{
"data":[
{
"type":"staff",
"id":"xxx"
},
{
"type":"staff",
"id":"xxx"
}
]
},
"privilege":{
"data":[
{
"type":"staff",
"id":"xxx"
}
]
}
}
}
}
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
live.type | 是 | 无 | 资源对象类型,为live,表示资源为直播 |
live.title | 是 | 无 | 直播的标题 |
live.intro | 否 | 无 | 直播的简介 |
live.content | 否 | 无 | 直播详情 |
live.pic | 否 | 无 | 直播的封面 |
live.push_method | 否 | wechat work | 直播类型(wechat work, pc) |
live.started_at | 是 | 无 | 直播的开始时间 |
live.privilege_type | 否 | 0 | 0表示公开 1表示部分人可见,需要配合 privilege 参数使用 |
live.live_type | 否 | 0 | 0表示直播不对外可访问;1表示直播对外可访问 |
live.vertical | 否 | 0 | 0表示横屏直播;1表示竖屏直播;pc推荐设置横屏直播 |
live.password | 否 | 无 | 允许直播对外可访问时,可以选择设置密码,4位数字类字符串,如"0000" |
live.auto_transfer_class | 否 | false | 是否开启直播回放;为true 表示开启 |
live.class_category_id | 否 | 无 | 当auto_transfer_class 为true 时,需要制定直播的直播所属的课程分类。 |
live.course_category_id | 否 | 无 | 当auto_transfer_class 为true 时,需要制定直播的直播所属的课程素材分类。 |
relationships.managers | 否 | 无 | 直播主持人 |
relationships.streamer | 是 | 无 | 直播讲师 |
relationships.privilege | 否 | 无 | 部分人可见 |
$attributes = [
'title' => '通过开放接口创建的直播',
'started_at' => '2020-02-14 05:20',
'streamer_ids' => ['STAFF_ID1'],
];
$options = [
'intro' => '简介',
'content' => '内容',
'pic' => 'https://lexiangla.com',
'push_method' => 'pc',
'manager_ids' => ['STAFF_ID2', 'STAFF_ID3'],
'privilege' => [
['type' => 'department', 'id' => 1],
['type' => 'contacttag', 'id' => 1],
]
];
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->postLive(StaffID, $attributes, $options);
document
{
"data":{
"type":"live",
"id":"cc2fb1a8554f11eab5940a58ac130e6f",
"links":{
"platform":{
"href":"https://lexiangla.com/lives/cc2fb1a8554f11eab5940a58ac130e6f"
},
"manager":{
"href":"https://lexiangla.com/lives/cc2fb1a8554f11eab5940a58ac130e6f/settings"
}
},
"attributes":{
"title":"s2",
"started_at":"2020-02-15 14:00:00",
"status":"init",
"push_url":"rtmp://livepush.lexiangla.com/live/xxxxxx?txSecret=xxxx&txTime=xx",
"created_at":"2020-02-22 16:46:20",
"updated_at":"2020-02-22 16:46:20",
"visit_count":0,
"push_method":"pc",
"live_type": 0,
"video_duration": 0,
"watch_duration": 0,
"vertical": 0,
"wx_code": "",
"wx_open_code": ""
}
},
"links":{
"self":{
"platform": "https://lexiangla.com/lives/169548aed7c111eaaf3752c8567837af",
"manager": "https://lexiangla.com/lives/169548aed7c111eaaf3752c8567837af/settings",
"qrcodeurl": "https://lexiangla.com/livepush?room_id=169548aed7c111eaaf3752c8567837af&company_from=xxx",
"open": ""
}
}
}
参数 | 说明 |
---|---|
live.type | 资源对象类型,为live,表示资源为直播 |
live.id | 直播实体ID |
title | 直播的标题 |
status | 直播的状态(init:初始化, waiting:等待, pushing:推流状态, finished:完成, forbidden:无权限访问) |
push_method | 直播类型(wechat work, pc) |
push_url | pc推流地址 |
live_type | 是否为公开直播;0表示直播不对外可访问;1表示直播对外可访问 |
vertical | 0表示横屏直播;1表示竖屏直播;pc推荐设置横屏直播 |
wx_code | 小程序码(需要等待一分钟左右通过获取单场直播信息 获取到小程序码,乐享网站及小程序外无用直接使用此小程序码图片地址) |
wx_open_code | 微信公开直播的手机端查看小程序码 (需要等待一分钟左右通过获取单场直播信息 获取到小程序码,乐享网站及小程序外无用直接使用此小程序码图片地址) |
started_at | 直播的开始时间 |
created_at | 直播的创建时间 |
updated_at | 直播的更新时间 |
visit_count | 直播的访问量 |
video_duration | 直播的时长 |
relationships.owner | 直播的创建人 |
relationships.streamer | 直播讲师 |
links.platform | 当前直播的查看地址 |
links.manager | 当前直播的管理地址 |
PATCH https://lxapi.lexiangla.com/cgi-bin/v1/lives/{LiveID}
document
{
"data":{
"type":"live",
"attributes":{
"title":"s2",
"started_at":"2020-02-15 14:00",
"intro":"简介",
"content":"内容",
"push_method":"pc",
"privilege_type":1
},
"relationships":{
"streamer":{
"data":[
{
"type":"staff",
"id":"xxx"
}
]
},
"managers":{
"data":[
{
"type":"staff",
"id":"xxx"
},
{
"type":"staff",
"id":"xxx"
}
]
},
"privilege":{
"data":[
{
"type":"staff",
"id":"xxx"
}
]
}
}
}
}
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
LiveID | 是 | 无 | 资源对象类型为live的资源对象ID,即直播ID |
live.title | 否 | 无 | 直播的标题 |
live.intro | 否 | 无 | 直播的简介 |
live.content | 否 | 无 | 直播详情 |
live.pic | 否 | 无 | 直播的封面 |
live.push_method | 否 | 无 | 直播类型(wechat work, pc) |
live.live_type | 否 | 0 | 0表示直播不对外可访问;1表示直播对外可访问 |
live.vertical | 否 | 0 | 0表示横屏直播;1表示竖屏直播;pc推荐设置横屏直播 |
live.started_at | 否 | 无 | 直播的开始时间 |
live.privilege_type | 否 | 0 | 0表示公开 1表示部分人可见,需要配合 privilege 参数使用 |
relationships.managers | 否 | 无 | 直播主持人 |
relationships.streamer | 否 | 无 | 直播讲师 |
relationships.privilege | 否 | 无 | 部分人可见 |
$options = [
'title' => '通过开放接口创建的直播',
'started_at' => '2020-02-14 05:20',
'streamer_ids' => ['STAFF_ID1'],
'intro' => '简介',
'content' => '内容',
'pic' => 'https://lexiangla.com',
'push_method' => 'pc',
'manager_ids' => ['STAFF_ID2', 'STAFF_ID3'],
'privilege' => [
['type' => 'department', 'id' => 1],
['type' => 'contacttag', 'id' => 1],
]
];
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->patchLive(StaffID, LiveID, $options);
document
{
"data":{
"type":"live",
"id":"cc2fb1a8554f11eab5940a58ac130e6f",
"links":{
"platform":{
"href":"https://lexiangla.com/lives/cc2fb1a8554f11eab5940a58ac130e6f"
},
"manager":{
"href":"https://lexiangla.com/lives/cc2fb1a8554f11eab5940a58ac130e6f/settings"
}
},
"attributes":{
"title":"s2",
"started_at":"2020-02-15 14:00:00",
"status":"init",
"push_url":"rtmp://livepush.lexiangla.com/live/xxxxxx?txSecret=xxxx&txTime=xx",
"created_at":"2020-02-22 16:46:20",
"updated_at":"2020-02-22 16:46:20",
"visit_count":0,
"push_method":"pc",
"video_duration":0,
"watch_duration":0,
"wx_code":""
}
},
"links":{
"self":{
"href":"https://lxapi.lexiangla.com/cgi-bin/v1/lives/cc2fb1a8554f11eab5940a58ac130e6f"
}
}
}
参数 | 说明 |
---|---|
live.type | 资源对象类型,为live,表示资源为直播 |
live.id | 直播实体ID |
title | 直播的标题 |
status | 直播的状态(init:初始化, waiting:等待, pushing:推流状态, finished:完成, forbidden:无权限访问) |
push_method | 直播类型(wechat work, pc) |
push_url | pc推流地址 |
live_type | 是否为公开直播;0表示直播不对外可访问;1表示直播对外可访问 |
vertical | 0表示横屏直播;1表示竖屏直播;pc推荐设置横屏直播 |
wx_code | 小程序码(乐享网站及小程序外无用直接使用此小程序码图片地址) |
started_at | 直播的开始时间 |
created_at | 直播的创建时间 |
updated_at | 直播的更新时间 |
visit_count | 直播的访问量 |
video_duration | 直播的时长 |
relationships.owner | 直播的创建人 |
relationships.streamer | 直播讲师 |
links.platform | 当前直播的查看地址 |
links.open | 微信公开直播的pc端查看地址 |
links.manager | 当前直播的管理地址 |
DELETE https://lxapi.lexiangla.com/cgi-bin/v1/lives/{LiveID}
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
LiveID | 是 | 无 | 资源对象类型为 live 的资源对象ID,即直播ID |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->deleteLive(StaffID, LiveID');
document
GET https://lxapi.lexiangla.com/cgi-bin/v1/lives
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
page | 否 | 1 | 当前页数 |
per_page | 否 | 20 | 每页返回的数量 |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('lives', [
'page'=> 1,
'per_page' => 3,
]);
document
{
"data": [
{
"type": "live",
"id": "34a8a812e28111e9aedd0a58ac130342",
"attributes": {
"title": "测试直播",
"started_at": "2019-09-29 14:18:00",
"status": "init",
"push_method": "pc",
"push_url": "",
"wx_code": "",
"created_at": "2019-09-29 14:20:17",
"updated_at": "2019-09-29 14:20:28",
"visit_count": 2,
"video_duration": 0
},
"relationships": {
"owner": {
"data": {
"type": "staff",
"id": "ThreeZhang"
}
},
"streamer": {
"data": {
"type": "staff",
"id": "FourLee"
}
}
}
}
],
"links": {
"first": "https://lxapi.lexiangla.com/cgi-bin/v1/lives?per_page=1&page=1",
"last": "https://lxapi.lexiangla.com/cgi-bin/v1/lives?per_page=1&page=2",
"prev": null,
"next": "https://lxapi.lexiangla.com/cgi-bin/v1/lives?per_page=1&page=3"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 225,
"path": "https://lxapi.lexiangla.com/cgi-bin/v1/lives",
"per_page": 1,
"to": 1,
"total": 225
},
"included": [
{
"type": "staff",
"id": "ThreeZhang",
"attributes": {
"name": "张三",
"english_name": "ThreeZhang",
"organization": "开发组"
}
},
{
"type": "staff",
"id": "FourLee",
"attributes": {
"name": "李四",
"english_name": "FourLee",
"organization": "开发组"
}
}
]
}
参数 | 说明 |
---|---|
live.type | 资源对象类型,为live,表示资源为直播 |
live.id | 直播实体ID |
title | 直播的标题 |
status | 直播的状态(init:初始化, waiting:等待, pushing:推流状态, finished:完成, forbidden:无权限访问) |
push_method | 直播类型(wechat work, pc) |
push_url | pc推流地址 |
wx_code | 小程序码(乐享网站及小程序外无用直接使用此小程序码图片地址) |
started_at | 直播的开始时间 |
created_at | 直播的创建时间 |
updated_at | 直播的更新时间 |
visit_count | 直播的访问量 |
video_duration | 直播的时长 |
relationships.owner | 直播的创建人 |
relationships.streamer | 直播讲师 |
GET https://lxapi.lexiangla.com/cgi-bin/v1/lives/{liveID}
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
liveID | 是 | 无 | 直播ID |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('lives/254ef3a690d911ea87a68a420c870857');
document
{
"data": {
"type": "live",
"id": "254ef3a690d911ea87a68a420c870857",
"attributes": {
"title": "小程序竖屏-字幕 刚创建的就没聊天室啊",
"started_at": "2020-05-08 11:07:00",
"visit_count": 876026,
"status": "finished",
"push_method": "wechat work",
"push_url": "rtmp://livepush.lexiangla.com/live/254ef3a690d911ea87a68a420c870857?txSecret=123&txTime=123",
"wx_code": "https://lexiang4public-10029162.cos.ap-shanghai.myqcloud.com/123/assets/2020/5/254ef3a690d911ea87a68a420c870857.jpeg",
"created_at": "2020-05-08 11:08:09",
"updated_at": "2020-05-08 15:42:01",
"video_duration": 3716,
"transfer_status": 1
},
"links": {
"platform": "https://lexiangla.com/lives/254ef3a690d911ea87a68a420c870857?company_from=xxx",
"manager": "https://lexiangla.com/lives/254ef3a690d911ea87a68a420c870857/settings?company_from=xxx",
"qrcodeurl": "https://lexiangla.com/livepush?room_id=254ef3a690d911ea87a68a420c870857?company_from=xxx",
"open": "https://lexiangla.com/open-live/lives/032c055acd9411eaa893ee110638af1a?company_from=xxx"
},
"relationships": {
"owner": {
"data": {
"type": "staff",
"id": "ThreeZhang"
}
},
"streamer": {
"data": {
"type": "staff",
"id": "FourLee"
}
},
"clazz": {
"data": {
"type": "clazz",
"id": "d3dc774c90ff11eab5515254008ea09d"
}
}
}
},
"included": [
{
"type": "staff",
"id": "ThreeZhang",
"attributes": {
"name": "张三",
"english_name": null,
"organization": "开发组 "
}
},
{
"type": "staff",
"id": "FourLee",
"attributes": {
"name": "李四",
"english_name": null,
"organization": "测试组"
}
},
{
"type": "clazz",
"id": "d3dc774c90ff11eab5515254008ea09d",
"attributes": {
"title": "直播回放 | 签到直播",
"type": 1,
"cover_img": "",
"participants_count": null
},
"links": {
"platform": "https://lexiangla.com/classes/d3dc774c90ff11eab5515254008ea09d?type=1",
"manager": "https://lexiangla.com/classes/d3dc774c90ff11eab5515254008ea09d/settings?type=1"
}
}
],
"links": {
"self": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/254ef3a690d911ea87a68a420c870857"
}
}
参数 | 说明 |
---|---|
live.type | 资源对象类型,为lives,表示资源为直播 |
live.id | 直播实体ID |
title | 直播的标题 |
status | 直播的状态(init:初始化, waiting:等待, pushing:推流状态, finished:完成, forbidden:无权限访问) |
push_method | 直播类型(wechat work, pc) |
push_url | pc推流地址 |
live_type | 是否为公开直播;0表示直播不对外可访问;1表示直播对外可访问 |
vertical | 是否为竖屏直播;0表示直播为横屏直播;1表示直播为竖屏直播 |
wx_code | 小程序码(乐享网站及小程序外无用直接使用此小程序码图片地址) |
wx_open_code | 微信公开直播的手机端查看小程序码(乐享网站及小程序外无用直接使用此小程序码图片地址) |
started_at | 直播的开始时间 |
created_at | 直播的创建时间 |
updated_at | 直播的更新时间 |
visit_count | 直播的访问量 |
video_duration | 直播的时长 |
relationships.owner | 直播的创建人 |
relationships.streamer | 直播讲师 |
relationships.clazz | 直播回放关联的课程信息 |
links.platform | 当前直播的查看地址 |
links.open | 微信公开直播的pc端查看地址 |
links.manager | 当前直播的管理地址 |
GET https://lxapi.lexiangla.com/cgi-bin/v1/lives/{liveID}/staffs?with_playback={with_playback}
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
page | 否 | 1 | 当前页数 |
per_page | 否 | 20 | 每页返回的数量 |
liveID | 是 | 无 | 直播ID |
with_playback | 否 | 0 | 是否获取回放观看时长 |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('lives/6b096940e0f711e9ae480a58ac1302ce/staffs', [
'page'=> 1,
'per_page' => 3,
'with_playback' => 1,
]);
document
{
"data": [
{
"type": "staff",
"id": "TwoWang",
"attributes": {
"name": "王二",
"english_name": "TwoWang",
"organization": "开发组",
"online_duration": 1090,
"learn_time": 300,
"valid_time": 289
}
}
],
"links": {
"first": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/6b096940e0f711e9ae480a58ac1302ce/staffs?page=1",
"last": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/6b096940e0f711e9ae480a58ac1302ce/staffs?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"path": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/6b096940e0f711e9ae480a58ac1302ce/staffs",
"per_page": 20,
"to": 1,
"total": 1
}
}
参数 | 说明 |
---|---|
name | 员工姓名 |
english_name | 员工英文名 |
organization | 员工部门 |
online_duration | 直播观看时长(单位:s) |
learn_time | 总回放观看时长(单位:s, 仅with_playback=1且回放已生成时返回) |
valid_time | 有效回放观看时长(单位:s, 仅with_playback=1且回放已生成时返回) |
GET https://lxapi.lexiangla.com/cgi-bin/v1/staffs/{staffID}/lives
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
sort | 否 | -created_at | 排序参数,支持按直播的created_at 排序 |
page | 否 | 1 | 当前页数 |
per_page | 否 | 20 | 每页返回的数量 |
staffID | 是 | 无 | 企业微信提供的员工ID |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('/staffs/fewefwe/lives', [
'page'=> 1,
'per_page' => 3,
]);
document
{
"data": [
{
"type": "live",
"id": "5ff26d50dead11e9a0b00a58ac130286",
"attributes": {
"title": "测试统计",
"video_duration": 0,
"online_duration": 586,
"started_at": "2019-09-27 15:21:00",
"created_at": "2019-09-27 15:21:26",
"updated_at": "2019-10-06 11:05:00"
}
}
],
"links": {
"first": "https://lxapi.lexiangla.com/cgi-bin/v1/staffs/ruivenliu/lives?per_page=1&page=1",
"last": "https://lxapi.lexiangla.com/cgi-bin/v1/staffs/ruivenliu/lives?per_page=1&page=24",
"prev": "https://lxapi.lexiangla.com/cgi-bin/v1/staffs/ruivenliu/lives?per_page=1&page=1",
"next": "https://lxapi.lexiangla.com/cgi-bin/v1/staffs/ruivenliu/lives?per_page=1&page=3"
},
"meta": {
"current_page": 2,
"from": 2,
"last_page": 24,
"path": "https://lxapi.lexiangla.com/cgi-bin/v1/staffs/fewefwe/lives",
"per_page": 1,
"to": 2,
"total": 24
}
}
参数 | 说明 |
---|---|
live.type | 资源对象类型,为lives,表示资源为直播 |
live.id | 直播实体ID |
live.title | 直播的标题 |
live.video_duration | 直播时长 |
live.started_at | 直播开始时间 |
live.created_at | 直播创建时间 |
live.updated_at | 直播的更新时间 |
live.online_duration | 直播观看时长 |
GET https://lxapi.lexiangla.com/cgi-bin/v1/lives/{liveID}/checkins
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
page | 否 | 1 | 当前页数 |
per_page | 否 | 20 | 每页返回的数量 |
liveID | 是 | 无 | 直播ID |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('lives/6b096940e0f711e9ae480a58ac1302ce/checkins', [
'page'=> 1,
'per_page' => 3,
]);
document
{
"data": [
{
"type": "live_checkin",
"id": "022164fd3400458bb4cc7837104f360a",
"attributes": {
"title": "第一次签到",
"begin_at": "2020-05-06 10:42:00",
"end_at": "2020-05-06 10:50:00",
"participants_count": 46
},
"relationships": {
"owner": {
"data": {
"type": "staff",
"id": "ThreeZhang"
}
}
}
},
{
"type": "live_checkin",
"id": "9c4586f50cb148419c9b6fa480d51742",
"attributes": {
"title": "第二次签到",
"begin_at": "2020-05-06 10:52:07",
"end_at": "2020-05-06 10:55:00",
"participants_count": 23
},
"relationships": {
"owner": {
"data": {
"type": "staff",
"id": "ThreeZhang"
}
}
}
},
{
"type": "live_checkin",
"id": "8a1b892b5a4946b8a0268494d13314db",
"attributes": {
"title": "第三次签到",
"begin_at": "2020-05-06 11:00:42",
"end_at": "2020-05-06 11:20:00",
"participants_count": 9
},
"relationships": {
"owner": {
"data": {
"type": "staff",
"id": "FourLee"
}
}
}
}
],
"links": {
"first": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins?page=1",
"last": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"path": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins",
"per_page": 20,
"to": 5,
"total": 5
},
"included": [
{
"type": "staff",
"id": "ThreeZhang",
"attributes": {
"name": "张三",
"english_name": null,
"organization": "开发组"
}
},
{
"type": "staff",
"id": "FourLee",
"attributes": {
"name": "李四",
"english_name": null,
"organization": "测试组"
}
}
]
}
参数 | 说明 |
---|---|
live_checkin.title | 签到标题 |
live_checkin.begin_at | 签到开始时间 |
live_checkin.end_at | 签到结束时间 |
live_checkin.participants_count | 签到人数 |
live_checkin.created_at | 签到创建时间 |
relationships.owner | 签到创建者 |
GET https://lxapi.lexiangla.com/cgi-bin/v1/lives/{liveID}/checkins/{checkinID}/staffs
支持分页参数和排序:(通用说明?)
参数 | 是否必须 | 默认值 | 说明 |
---|---|---|---|
page | 否 | 1 | 当前页数 |
per_page | 否 | 20 | 每页返回的数量 |
liveID | 是 | 无 | 直播ID |
checkinID | 是 | 无 | 签到ID |
$Lxapi = new \Lexiangla\Openapi\Api(AppKey, AppSecret);
$response = $Lxapi->get('lives/5a61411e8f4111eabc129eab142eb664/checkins/022164fd3400458bb4cc7837104f360a/staffs', [
'page'=> 1,
'per_page' => 3,
]);
document
{
"data": [
{
"type": "staff",
"id": "ThreeZhang",
"attributes": {
"name": "张三",
"english_name": null,
"organization": "开发组",
"checkin_at": "2020-05-06 10:43:10"
}
},
{
"type": "staff",
"id": "FourLee",
"attributes": {
"name": "李四",
"english_name": null,
"organization": "测试组",
"checkin_at": "2020-05-06 10:42:51"
}
},
{
"type": "staff",
"id": "FiveWang",
"attributes": {
"name": "王五",
"english_name": null,
"organization": "设计组 ",
"checkin_at": "2020-05-06 10:43:04"
}
}
],
"links": {
"first": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins/022164fd3400458bb4cc7837104f360a/staffs?page=1",
"last": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins/022164fd3400458bb4cc7837104f360a/staffs?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"path": "https://lxapi.lexiangla.com/cgi-bin/v1/lives/5a61411e8f4111eabc129eab142eb664/checkins/022164fd3400458bb4cc7837104f360a/staffs",
"per_page": 20,
"to": 3,
"total": 3
}
}
参数 | 说明 |
---|---|
staff.id | 员工ID |
staff.name | 员工姓名 |
staff.english_name | 员工英文名 |
staff.organization | 员工部门 |
staff.checkin_at | 员工签到时间 |