SuperAPI AI Directory

te-analysis

General & other

View repository

Updated 10-16 09:46

About this skill

te-analysis

Prerequisites: Before using this skill, please first read te-shared/SKILL.mdto learn about authentication, global parameters, and security constraints.

The TE analysis domain (te-cli analysis) provides report and dashboard management capabilities, as well as the ability to query data via WebSocket.

Core Scenarios

1. Query Data

  • Report Data Query — via +query-report-data use WebSocket to obtain the computed results of an existing report
  • SQL Query — via +query-sql directly execute SQL queries to flexibly obtain arbitrary data

2. Report Management

  • List Reports — +list-reports get all reports under a project
  • View Report — +get-report get the complete definition of a single report
  • Save Report — +save-report create or modify a report (write operation, confirmation required)

3. Dashboard Management

  • List Dashboards — +list-dashboards get all dashboards under a project
  • View Dashboard — +get-dashboard get dashboard details
  • Create Dashboard — +create-dashboard create a new dashboard (write operation)
  • Update Dashboard — +update-dashboard update the dashboard layout (write operation)
  • Dashboard Report List — +list-dashboard-reports list the reports in a dashboard

Examples

Query Existing Report Data

# 查询报告 ID 为 42 的数据
te-cli analysis +query-report-data -p 1 --report-id 42

# 指定时间范围
te-cli analysis +query-report-data -p 1 --report-id 42 \
  --start-time "2026-01-01 00:00:00" --end-time "2026-01-31 23:59:59"

Free SQL Query

# 按事件分组统计
te-cli analysis +query-sql -p 1 \
  --sql "SELECT event, count(*) FROM ta.v_event_1 GROUP BY event LIMIT 20"

Report Management Workflow

# 列出所有报告
te-cli analysis +list-reports -p 1

# 查看某个报告定义
te-cli analysis +get-report -p 1 --report-id 42

# 创建新报告(write,需确认)
te-cli analysis +save-report -p 1 --report-name "DAU 趋势" \
  --report-model 0 \
  --events '[...]' --event-view '{...}'

Dashboard Management Workflow

# 列出仪表盘
te-cli analysis +list-dashboards -p 1

# 创建新仪表盘
te-cli analysis +create-dashboard -p 1 --dashboard-name "运营日报"

# 向仪表盘添加报告
te-cli analysis +update-dashboard -p 1 --dashboard-id 10 \
  --reports '[{"reportId": 42, "reportWidth": 6, "indexOrder": 0}]'

# 查看仪表盘中的报告
te-cli analysis +list-dashboard-reports -p 1 --dashboard-id 10

Reference Documentation

For detailed command Flags and usage, please see the documentation for each command in the references/ directory.