@mearl/client 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/commands.js CHANGED
@@ -9,7 +9,7 @@ export const COMMANDS = [
9
9
  {
10
10
  name: 'source',
11
11
  type: '"mtop" | "requests"',
12
- description: '强制指定来源,不填时使用 panel 当前模式',
12
+ description: '数据来源,不填时默认 mtop',
13
13
  },
14
14
  { name: 'filter', type: 'string', description: '按 URL 或 API 名称过滤,支持正则' },
15
15
  { name: 'includeBody', type: 'boolean', description: '是否包含请求/响应体,默认 true' },
@@ -31,15 +31,23 @@ export const COMMANDS = [
31
31
  },
32
32
  {
33
33
  name: 'get_events',
34
- description: '获取 RUM/aplus 埋点事件',
34
+ description: '获取 RUM/aplus/ARMS 埋点事件',
35
35
  params: [
36
- { name: 'source', type: '"rum" | "aplus" | "all"', description: '数据来源,默认 all' },
36
+ { name: 'tabId', type: 'number', description: '目标标签页 ID,从 tab_list 获取' },
37
+ {
38
+ name: 'source',
39
+ type: '"rum" | "aplus" | "arms" | "all"',
40
+ description: '数据来源,默认 all',
41
+ },
37
42
  { name: 'event_type', type: 'string', description: '按事件类型过滤,支持正则,如 CLK/PV' },
38
43
  { name: 'filter', type: 'string', description: '按 name 或 url 过滤,支持正则' },
39
44
  { name: 'since', type: 'number', description: '只返回最近 N 秒内的事件' },
40
45
  { name: 'limit', type: 'number', description: '返回条数,默认 20' },
41
46
  ],
42
- examples: [`get_events --payload '{"source":"aplus","event_type":"CLK","limit":10}'`],
47
+ examples: [
48
+ `get_events --payload '{"source":"aplus","event_type":"CLK","limit":10}'`,
49
+ `get_events --payload '{"tabId":12345,"source":"all","limit":20}'`,
50
+ ],
43
51
  },
44
52
  {
45
53
  name: 'get_api_schema',
package/dist/index.d.ts CHANGED
@@ -38,7 +38,8 @@ export interface GetLogsParams {
38
38
  }
39
39
  export declare function getLogs(params?: GetLogsParams): Promise<any>;
40
40
  export interface GetEventsParams {
41
- source?: 'rum' | 'aplus' | 'all';
41
+ tabId?: number;
42
+ source?: 'rum' | 'aplus' | 'arms' | 'all';
42
43
  event_type?: string;
43
44
  filter?: string;
44
45
  since?: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mearl/client",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "Client SDK & CLI for Mearl — communicate with Chrome Extension via Unix Socket",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",