多维表格字段变更
事件
基本 | |
---|---|
事件类型 | drive.file.bitable_field_changed_v1 |
支持的应用类型 | 自建应用商店应用 |
权限要求 开启任一权限即可 | 查看、评论、编辑和管理多维表格查看、评论、编辑和管理云空间中所有文件 |
字段权限要求 | 该接口返回体中存在下列敏感字段,仅当开启对应的权限后才会返回;如果无需获取这些字段,则不建议申请获取用户 user ID仅自建应用 |
推送方式 | Webhook |
事件体
名称收起子列表 | 类型 | 描述 |
---|---|---|
schema | string | 事件模式 |
header | event_header | 事件头 |
event_id | string | 事件 ID |
event_type | string | 事件类型 |
create_time | string | 事件创建时间戳(单位:毫秒) |
token | string | 事件 Token |
app_id | string | 应用 ID |
tenant_key | string | 租户 Key |
event | - | - |
file_type | string | 文档类型 |
file_token | string | 文档token |
table_id | string | 多维表格数据表ID |
operator_id | user_id | 用户 ID |
union_id | string | 用户的 union id |
user_id | string | 用户的 user id字段权限要求:获取用户 user ID仅自建应用 |
open_id | string | 用户的 open id |
action_list | bitable.table.field_action[] | 字段变更操作列表 |
action | string | 操作类型 |
field_id | string | 字段 ID |
before_value | bitable.table.field_action.value | 操作前的字段值 |
id | string | 字段 ID |
name | string | 字段名字 |
type | int | 字段类型 |
description | string | 字段描述 |
property | bitable.table.field_action.value.property | 字段属性 |
formatter | string | 数字、公式字段的显示格式 |
date_formatter | string | 日期、创建时间、最后更新时间字段的显示格式 |
auto_fill | boolean | 日期字段中新纪录自动填写创建时间 |
multiple | boolean | 人员字段中允许添加多个成员,单向关联、双向关联中允许添加多个记录 |
table_id | string | 单向关联、双向关联字段中关联的数据表的ID |
table_name | string | 单向关联、双向关联字段中关联的数据表的名字 |
back_field_name | string | 双向关联字段中关联的数据表中对应的双向关联字段的名字 |
input_type | string | 地理位置输入限制 |
back_field_id | string | 双向关联字段中关联的数据表中对应的双向关联字段的id |
auto_serial | bitable.table.field_action.value.property.auto_serial | 自动编号类型 |
type | string | 自动编号类型 |
options | bitable.table.field_action.value.property.auto_serial.options[] | 自动编号规则列表 |
type | string | 自动编号的可选规则项类型 |
value | string | 与类型相对应的取值 |
options | bitable.table.field_action.value.property.option[] | 单选、多选字段的选项信息 |
name | string | 选项名 |
id | string | 选项ID |
color | int | 选项颜色 |
formula_expression | string | 公式字段的公式表达式 |
after_value | bitable.table.field_action.value | 操作后的字段值 |
id | string | 字段 ID |
name | string | 字段名字 |
type | int | 字段类型 |
description | string | 字段描述 |
property | bitable.table.field_action.value.property | 字段属性 |
formatter | string | 数字、公式字段的显示格式 |
date_formatter | string | 日期、创建时间、最后更新时间字段的显示格式 |
auto_fill | boolean | 日期字段中新纪录自动填写创建时间 |
multiple | boolean | 人员字段中允许添加多个成员,单向关联、双向关联中允许添加多个记录 |
table_id | string | 单向关联、双向关联字段中关联的数据表的ID |
table_name | string | 单向关联、双向关联字段中关联的数据表的名字 |
back_field_name | string | 双向关联字段中关联的数据表中对应的双向关联字段的名字 |
input_type | string | 地理位置输入限制 |
back_field_id | string | 双向关联字段中关联的数据表中对应的双向关联字段的id |
auto_serial | bitable.table.field_action.value.property.auto_serial | 自动编号类型 |
type | string | 自 动编号类型 |
options | bitable.table.field_action.value.property.auto_serial.options[] | 自动编号规则列表 |
type | string | 自动编号的可选规则项类型 |
value | string | 与类型相对应的取值 |
options | bitable.table.field_action.value.property.option[] | 单选、多选字段的选项信息 |
name | string | 选项名 |
id | string | 选项ID |
color | int | 选项颜色 |
formula_expression | string | 公式字段的公式表达式 |
revision | int | 多维表格数据表的版本号 |
subscriber_id_list | user_id[] | 订阅用户id列表 |
union_id | string | union id |
user_id | string | user id |
open_id | string | open id |
update_time | int | 字段变更时间 |
事件体示例
{
"schema": "2.0",
"header": {
"event_id": "5e3702a84e847582be8db7fb73283c02",
"event_type": "drive.file.bitable_field_changed_v1",
"create_time": "1608725989000",
"token": "rvaYgkND1GOiu5MM0E1rncYC6PLtF7JV",
"app_id": "cli_9f5343c580712544",
"tenant_key": "2ca1d211f64f6438"
},
"event": {
"file_type": "bitable",
"file_token": "bascntUPmnoH9kZbGJ8RWeabcef",
"table_id": "tblWXe2d0I0abcef",
"operator_id": {
"union_id": "on_8ed6aa67826108097d9ee143816345",
"user_id": "e33ggbyz",
"open_id": "ou_84aad35d084aa403a838cf73ee18467"
},
"action_list": [
{
"action": "field_edited",
"field_id": "fldmj5qNii",
"before_value": {
"id": "fldmj5qNii",
"name": "field name",
"type": 20,
"description": "description",
"property": {
"formatter": "1,000",
"date_formatter": "yyyyMMdd",
"auto_fill": true,
"multiple": true,
"table_id": "tblIniLz0Ic8oXyN",
"table_name": "table name",
"back_field_name": "field name",
"input_type": "only_mobile",
"back_field_id": "fldmj5qNii",
"auto_serial": {
"type": "custom",
"options": [
{
"type": "created_time",
"value": "yyyyMMdd"
}
]
},
"options": [
{
"name": "option name",
"id": "optabcef",
"color": 3
}
],
"formula_expression": "bitable::$table[tblIniLz0Ic8oXyN].$field[fldqatAwxx]*6+333"
}
},
"after_value": {
"id": "fldmj5qNii",
"name": "field name",
"type": 20,
"description": "description",
"property": {
"formatter": "1,000",
"date_formatter": "yyyyMMdd",
"auto_fill": true,
"multiple": true,
"table_id": "tblIniLz0Ic8oXyN",
"table_name": "table name",
"back_field_name": "field name",
"input_type": "only_mobile",
"back_field_id": "fldmj5qNii",
"auto_serial": {
"type": "custom",
"options": [
{
"type": "created_time",
"value": "yyyyMMdd"
}
]
},
"options": [
{
"name": "option name",
"id": "optabcef",
"color": 3
}
],
"formula_expression": "bitable::$table[tblIniLz0Ic8oXyN].$field[fldqatAwxx]*6+333"
}
}
}
],
"revision": 10,
"subscriber_id_list": [
{
"union_id": "on_876b570a984d02ab1c0906a49e4a9d04",
"user_id": "638474b8",
"open_id": "ou_9bc587355789fc049904ae7c73619b89"
}
],
"update_time": 1663727688
}
}
修改于 2023-01-13 06:08:07