You need to enable JavaScript to run this app.
导航
增加虚拟事件
最近更新时间:2024.06.30 18:36:04首次发布时间:2024.06.30 18:36:04

请求说明

Path:openapi/v1/metadata/<app_id: int>/virtual_events
Method: POST
Content-type: application/json

请求参数

Body:

参数

类型

是否必选

示例值

描述

name

str

aaaaaa-3

事件名

status

int

1

状态信息

  • 0 禁用
  • 1 启用
  • 2 隐藏

description

str

null

描述信息

show_name

str

null

展示信息

dsl_content

object

见下文请求示例

虚拟事件的创建规则

{
        "name": "aaaaaa-3",
        "show_name": "new_show_name",
        "status": 1,
        "dsl_content": {
            "logic": "or",
            "queries": [
                {
                    "event_id": 234913,
                    "event_name": "predefine_pageview",
                    "event_type": "origin",
                    "filters": [],
                    "show_label": "A",
                    "event_indicator": "",
                    "measure_info": {},
                    "indicator_show_name": ""
                }
            ]
        }
            }

返回参数

Response:

{
    "code": 200,
    "message": "success",
    "data": {
        "id": 55345535,
        "app_id": 2174,
        "name": "aaaaaa-3",
        "show_name": "new_show_name",
        "status": 1,
        "dsl_content": {
            "logic": "or",
            "queries": [
                {
                    "event_id": 234913,
                    "event_name": "predefine_pageview",
                    "event_type": "origin",
                    "filters": [],
                    "show_label": "A",
                    "event_indicator": "",
                    "measure_info": {},
                    "indicator_show_name": ""
                }
            ]
        },
        "used_times": 0,
        "used_times_updated_ts": null,
        "creator_id": "213697",
        "updator_id": "213697",
        "created_at": null,
        "updated_at": null,
        "owners": null,
        "event_groups": null,
        "params": null,
        "virtual_params": null,
        "relation_events": null,
        "dsl": {
            "logic": "or",
            "queries": [
                {
                    "event_id": 234913,
                    "event_name": "predefine_pageview",
                    "event_type": "origin",
                    "filters": [],
                    "show_label": "A",
                    "event_indicator": "",
                    "measure_info": {},
                    "indicator_show_name": ""
                }
            ]
        }
    }
}