@thinkingai/ae-cli 6.0.38 → 6.0.39
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/README.md +25 -3
- package/README.zh.md +25 -3
- package/dist/{auth-56Z45UVR.js → auth-GDV3H5I4.js} +18 -8
- package/dist/{auth-ENM3FE6L.js → auth-NN55553T.js} +3 -3
- package/dist/{capability-2H6PAOA3.js → capability-TPORIKRQ.js} +19 -15
- package/dist/{capability-YPOQX6PL.js → capability-VQNC5CF7.js} +19 -15
- package/dist/chunk-4NN5IWVN.js +26 -0
- package/dist/{chunk-DB4Q3ANU.js → chunk-6A2FUCIS.js} +3 -3
- package/dist/{chunk-PVBYJWC2.js → chunk-7KQWSBSL.js} +4 -4
- package/dist/{chunk-24BAVOX3.js → chunk-AXDXJTPC.js} +3 -1
- package/dist/{chunk-CPVTECJ3.js → chunk-DT6Y3TD7.js} +5 -5
- package/dist/{chunk-EGEIXA2Z.js → chunk-DWO43OIB.js} +0 -248
- package/dist/{chunk-V6FR6WTW.js → chunk-GJJA4CQZ.js} +34 -2
- package/dist/{chunk-RGXCNC4N.js → chunk-GS2P7LFD.js} +50 -17
- package/dist/{chunk-LYVNONC4.js → chunk-JHENBQ5B.js} +35 -0
- package/dist/{chunk-3P3562ZX.js → chunk-MVDZ7DBQ.js} +5 -5
- package/dist/{chunk-LCXU3AAT.js → chunk-NBPKWKRA.js} +2 -2
- package/dist/{chunk-HQ2A7ITL.js → chunk-RBNKI5ZW.js} +50 -17
- package/dist/{chunk-LHVM35J4.js → chunk-TS6BUGUY.js} +4 -4
- package/dist/chunk-TUKQZTMI.js +250 -0
- package/dist/{chunk-J7MZHDHQ.js → chunk-VKD5WQKN.js} +5 -5
- package/dist/{chunk-3KI3RRXX.js → chunk-VTXHDCBW.js} +3 -3
- package/dist/{chunk-KTYR3U6D.js → chunk-YTG6Q75E.js} +10 -6
- package/dist/{chunk-IR4ZLVPW.js → chunk-YV52FB5G.js} +25 -3
- package/dist/{chunk-E7UXXHO3.js → chunk-Z3OXWCIA.js} +3 -3
- package/dist/{cli-token-4SBMXAUK.js → cli-token-GL5MS5FK.js} +4 -4
- package/dist/{client-PP5FETMW.js → client-DAIPF7XN.js} +4 -4
- package/dist/{community-report-client-KK2QBANO.js → community-report-client-M2RW4MXD.js} +2 -2
- package/dist/config-4VZNLBKF.js +489 -0
- package/dist/index.js +96 -37
- package/dist/memory-RWJW4XFO.js +892 -0
- package/dist/memory-VO2ZJCRT.js +892 -0
- package/dist/{metadata-JIQ77HFY.js → metadata-YGTHR2XJ.js} +8 -8
- package/dist/{metadata-AN3YFZEV.js → metadata-ZRN2GHPN.js} +8 -8
- package/dist/{model-JASQVOFD.js → model-CLUIK3K5.js} +7 -5
- package/dist/{raw-XJCAT3HX.js → raw-52B4UKO4.js} +8 -7
- package/dist/sync-3REDHGY6.js +10259 -0
- package/dist/{te-agent-JHUG6DVV.js → te-agent-XNPELAKX.js} +580 -84
- package/dist/{te-analysis-ITKTO6JS.js → te-analysis-GJI5FZUL.js} +1152 -13
- package/dist/{te-analysis-RAC67YYD.js → te-analysis-N2BRDJZ5.js} +1152 -13
- package/dist/{te-community-QOYIYEJI.js → te-community-SQXKE5OO.js} +7 -7
- package/dist/{te-community-UFKI6ONP.js → te-community-TYSNU3NQ.js} +7 -7
- package/dist/{te-dataops-PZQ5NQLY.js → te-dataops-5TM7WZDI.js} +370 -189
- package/dist/{te-dataops-XTWVTJCA.js → te-dataops-OWIADNSM.js} +370 -189
- package/dist/{te-engage-NLZUPSBK.js → te-engage-F7V55KVW.js} +333 -105
- package/dist/{te-engage-E7F4HTXU.js → te-engage-FMYAYCNV.js} +333 -105
- package/dist/{te-kb-E7NSCBRB.js → te-kb-VRMEY3D4.js} +6 -6
- package/dist/{te-meta-GBDTMPEL.js → te-meta-53BVXPFI.js} +7 -7
- package/dist/{te-meta-ZTLTSHXC.js → te-meta-TOCBPBXI.js} +7 -7
- package/dist/{te-system-AH7DMCAQ.js → te-system-XGS5EQIQ.js} +4 -4
- package/dist/{te-team-BQ3SKSZV.js → te-team-BZRDV2CM.js} +7 -7
- package/dist/{update-DKG6UXEM.js → update-HEDXGOJH.js} +8 -6
- package/package.json +4 -1
- package/skills/ae-agent/SKILL.md +178 -16
- package/skills/ae-agent/references/add-skill.md +22 -10
- package/skills/ae-agent/references/edit-skill.md +24 -14
- package/skills/ae-agent/references/find-archived-conversations.md +82 -0
- package/skills/ae-agent/references/restore-conversation.md +54 -0
- package/skills/ae-agent/references/upload-skill.md +24 -14
- package/skills/ae-analysis/SKILL.md +1 -1
- package/skills/ae-analysis/references/command_index.md +104 -42
- package/skills/ae-analysis/references/entity_id_import_options.md +1 -1
- package/skills/ae-analysis/references/project_access_detail_get.md +3 -3
- package/skills/ae-analysis/references/project_data_power_delete.md +3 -3
- package/skills/ae-analysis/references/project_data_power_get.md +3 -3
- package/skills/ae-analysis/references/project_data_power_list.md +3 -3
- package/skills/ae-analysis/references/project_data_power_upsert.md +3 -3
- package/skills/ae-analysis/references/project_entity_create.md +3 -3
- package/skills/ae-analysis/references/project_entity_delete.md +3 -3
- package/skills/ae-analysis/references/project_entity_event_list.md +3 -3
- package/skills/ae-analysis/references/project_entity_get.md +3 -3
- package/skills/ae-analysis/references/project_entity_list.md +3 -3
- package/skills/ae-analysis/references/project_entity_update.md +3 -3
- package/skills/ae-analysis/references/project_function_list.md +3 -3
- package/skills/ae-analysis/references/project_info_create.md +25 -0
- package/skills/ae-analysis/references/project_info_delete.md +24 -0
- package/skills/ae-analysis/references/project_info_get.md +3 -3
- package/skills/ae-analysis/references/project_info_list.md +3 -3
- package/skills/ae-analysis/references/project_info_update.md +3 -3
- package/skills/ae-analysis/references/project_mark_time_create.md +3 -3
- package/skills/ae-analysis/references/project_mark_time_delete.md +3 -3
- package/skills/ae-analysis/references/project_mark_time_list.md +3 -3
- package/skills/ae-analysis/references/project_mark_time_update.md +3 -3
- package/skills/ae-analysis/references/project_member_add.md +3 -3
- package/skills/ae-analysis/references/project_member_batch_update.md +3 -3
- package/skills/ae-analysis/references/project_member_candidate_list.md +3 -3
- package/skills/ae-analysis/references/project_member_handover_export.md +3 -3
- package/skills/ae-analysis/references/project_member_handover_run.md +3 -3
- package/skills/ae-analysis/references/project_member_import.md +3 -3
- package/skills/ae-analysis/references/project_member_list.md +3 -3
- package/skills/ae-analysis/references/project_member_receiver_list.md +3 -3
- package/skills/ae-analysis/references/project_member_remove.md +3 -3
- package/skills/ae-analysis/references/project_member_update.md +3 -3
- package/skills/ae-analysis/references/project_owner_update.md +3 -3
- package/skills/ae-analysis/references/project_permission_binding_list.md +3 -3
- package/skills/ae-analysis/references/project_receive_status_update.md +3 -3
- package/skills/ae-analysis/references/project_role_delete.md +3 -3
- package/skills/ae-analysis/references/project_role_function_list.md +3 -3
- package/skills/ae-analysis/references/project_role_get.md +3 -3
- package/skills/ae-analysis/references/project_role_list.md +3 -3
- package/skills/ae-analysis/references/project_role_upsert.md +3 -3
- package/skills/ae-analysis/references/project_role_user_list.md +3 -3
- package/skills/ae-analysis/references/project_space_list.md +1 -1
- package/skills/ae-analysis/references/project_timezone_get.md +3 -3
- package/skills/ae-analysis/references/project_timezone_overview.md +3 -3
- package/skills/ae-analysis/references/project_timezone_update.md +3 -3
- package/skills/ae-analysis/references/project_user_id_items_update.md +3 -3
- package/skills/ae-analysis/references/system_admin_function_list.md +22 -0
- package/skills/ae-analysis/references/system_admin_function_update.md +26 -0
- package/skills/ae-analysis/references/system_admin_list.md +21 -0
- package/skills/ae-analysis/references/system_admin_remove.md +25 -0
- package/skills/ae-analysis/references/system_admin_upsert.md +25 -0
- package/skills/ae-analysis/references/system_function_list.md +21 -0
- package/skills/ae-analysis/references/system_member_add.md +25 -0
- package/skills/ae-analysis/references/system_member_candidate_list.md +22 -0
- package/skills/ae-analysis/references/system_member_delete.md +25 -0
- package/skills/ae-analysis/references/system_member_list.md +24 -0
- package/skills/ae-analysis/references/system_member_mfa_unbind.md +25 -0
- package/skills/ae-analysis/references/system_member_password_reset.md +32 -0
- package/skills/ae-analysis/references/system_member_project_batch_update.md +27 -0
- package/skills/ae-analysis/references/system_member_status_update.md +26 -0
- package/skills/ae-analysis/references/system_member_update.md +23 -0
- package/skills/ae-analysis/references/system_mfa_get.md +21 -0
- package/skills/ae-analysis/references/system_mfa_update.md +25 -0
- package/skills/ae-analysis/references/system_node_monitor_list.md +24 -0
- package/skills/ae-analysis/references/system_oauth2_update.md +22 -0
- package/skills/ae-analysis/references/system_ops_alert_contact_delete.md +25 -0
- package/skills/ae-analysis/references/system_ops_alert_contact_list.md +23 -0
- package/skills/ae-analysis/references/system_ops_alert_contact_test.md +29 -0
- package/skills/ae-analysis/references/system_ops_alert_contact_upsert.md +39 -0
- package/skills/ae-analysis/references/system_preference_get.md +21 -0
- package/skills/ae-analysis/references/system_preference_update.md +22 -0
- package/skills/ae-analysis/references/system_project_usage_list.md +28 -0
- package/skills/ae-analysis/references/system_query_alert_rule_list.md +21 -0
- package/skills/ae-analysis/references/system_query_alert_rule_update.md +26 -0
- package/skills/ae-analysis/references/system_query_monitor_overview.md +26 -0
- package/skills/ae-analysis/references/system_query_task_cancel.md +25 -0
- package/skills/ae-analysis/references/system_query_task_export.md +49 -0
- package/skills/ae-analysis/references/system_query_task_get.md +23 -0
- package/skills/ae-analysis/references/system_query_task_list.md +35 -0
- package/skills/ae-analysis/references/system_query_task_options.md +27 -0
- package/skills/ae-analysis/references/system_receiver_address_delete.md +26 -0
- package/skills/ae-analysis/references/system_receiver_address_overview.md +21 -0
- package/skills/ae-analysis/references/system_receiver_address_project_list.md +21 -0
- package/skills/ae-analysis/references/system_receiver_address_promote.md +24 -0
- package/skills/ae-analysis/references/system_receiver_address_upsert.md +27 -0
- package/skills/ae-analysis/references/system_receiver_detection_get.md +22 -0
- package/skills/ae-analysis/references/system_receiver_detection_run.md +22 -0
- package/skills/ae-analysis/references/system_receiver_detection_update.md +25 -0
- package/skills/ae-analysis/references/system_role_delete.md +26 -0
- package/skills/ae-analysis/references/system_role_function_list.md +22 -0
- package/skills/ae-analysis/references/system_role_get.md +22 -0
- package/skills/ae-analysis/references/system_role_list.md +24 -0
- package/skills/ae-analysis/references/system_role_upsert.md +27 -0
- package/skills/ae-analysis/references/system_role_user_list.md +22 -0
- package/skills/ae-analysis/references/system_seat_list.md +25 -0
- package/skills/ae-analysis/references/system_seat_update.md +26 -0
- package/skills/ae-analysis/references/system_smtp_delete.md +24 -0
- package/skills/ae-analysis/references/system_smtp_get.md +21 -0
- package/skills/ae-analysis/references/system_smtp_test.md +22 -0
- package/skills/ae-analysis/references/system_smtp_upsert.md +31 -0
- package/skills/ae-analysis/references/system_third_party_login_disable.md +25 -0
- package/skills/ae-analysis/references/system_third_party_login_list.md +21 -0
- package/skills/ae-analysis/references/system_third_party_login_upsert.md +33 -0
- package/skills/ae-analysis/references/system_usage_overview.md +21 -0
- package/skills/ae-analysis/references/system_usage_trend_export.md +44 -0
- package/skills/ae-analysis/references/system_usage_trend_query.md +28 -0
- package/skills/ae-dataops/SKILL.md +1 -1
- package/skills/ae-dataops/references/dataops-flow-create.md +51 -16
- package/skills/ae-engage/SKILL.md +56 -26
- package/skills/ae-engage/references/activity-activity.md +3 -0
- package/skills/ae-engage/references/activity-approval.md +12 -4
- package/skills/ae-engage/references/activity-task.md +21 -6
- package/skills/ae-engage/references/activity-topic.md +31 -13
- package/skills/ae-engage/references/add-channel.md +170 -41
- package/skills/ae-engage/references/build-task-save-guide.md +40 -27
- package/skills/ae-engage/references/channel-update-config.md +3 -2
- package/skills/ae-engage/references/common-metric.md +48 -120
- package/skills/ae-engage/references/flow-detail.md +13 -0
- package/skills/ae-engage/references/preset-event.md +12 -32
- package/skills/ae-engage/references/save-flow.md +127 -64
- package/skills/ae-engage/references/save-task.md +197 -59
- package/skills/ae-engage/references/scene-config-metric.md +3 -0
- package/skills/ae-engage/references/scene-preset-metric.md +8 -37
- package/skills/ae-engage/references/scene-strategy-audience.md +51 -643
- package/skills/ae-engage/references/scene-strategy.md +6 -6
- package/skills/ae-engage/references/task-detail.md +10 -0
- package/skills/ae-engage/references/task-submit-approval.md +45 -0
- package/skills/ae-engage/references/validate-flow-node-config.md +1 -1
- package/skills/ae-generate-tracking-code/SKILL.md +2 -2
- package/skills/ae-metadata/SKILL.md +1 -1
- package/dist/config-BSSALXEN.js +0 -128
- package/dist/sync-QFP4XFN3.js +0 -485
|
@@ -24,9 +24,9 @@ ae-cli engage-scene strategy update --project-id <project_id> \
|
|
|
24
24
|
# Query a strategy's log
|
|
25
25
|
ae-cli engage-scene strategy log --project-id <project_id> --strategy-uuid <uuid>
|
|
26
26
|
|
|
27
|
-
# Predict custom-audience size
|
|
27
|
+
# Predict custom-audience size
|
|
28
28
|
ae-cli engage-scene strategy predict --project-id <project_id> \
|
|
29
|
-
--
|
|
29
|
+
--definition-request '{"type":"condition","conditions":{...}}' \
|
|
30
30
|
--zone-offset 8 \
|
|
31
31
|
[--strategy-uuid <uuid>]
|
|
32
32
|
|
|
@@ -48,7 +48,7 @@ ae-cli engage-scene strategy manage --project-id <project_id> --config-id <confi
|
|
|
48
48
|
| create | `--project-id`, `--payload` | payload = `ConfigStrategyAddDTO`. |
|
|
49
49
|
| update | `--project-id`, `--payload` | payload = `ConfigStrategyModifyDTO` (`strategyUuid` + fields). |
|
|
50
50
|
| log | `--project-id`, `--strategy-uuid` | read. |
|
|
51
|
-
| predict | `--project-id`, `--
|
|
51
|
+
| predict | `--project-id`, `--definition-request`, `--zone-offset` | Optional `--strategy-uuid`, `--request-id`. read. |
|
|
52
52
|
| batch-copy | `--project-id`, `--config-id`, `--strategy-ids` | `--op-mode` optional (default `batch`). |
|
|
53
53
|
| manage | `--project-id`, `--config-id`, `--action` | Lifecycle actions require `--strategy-uuid-list`; review actions require `--strategy-list`; write. |
|
|
54
54
|
|
|
@@ -67,10 +67,10 @@ ae-cli engage-scene strategy manage --project-id <project_id> --config-id <confi
|
|
|
67
67
|
- Discover real strategy UUIDs / config IDs first; never invent IDs.
|
|
68
68
|
- **Custom audience (`targetClusterType=1`)** — follow [`scene-strategy-audience.md`](scene-strategy-audience.md) end-to-end:
|
|
69
69
|
1. Preflight every **用户满足** user property and **用户行为** event via `analysis-meta property get` / `event get`; if missing, **stop** and list available properties — never invent or drop.
|
|
70
|
-
2.
|
|
71
|
-
3.
|
|
70
|
+
2. Build an Analysis-compatible semantic condition in `payload.definitionRequest`.
|
|
71
|
+
3. Reuse the same definition with `strategy predict --definition-request`.
|
|
72
72
|
4. **Do not** call `analysis user-cluster create` unless the user explicitly asks for an existing/named cluster.
|
|
73
|
-
-
|
|
73
|
+
- Semantic contract and examples: [`scene-strategy-audience.md`](scene-strategy-audience.md).
|
|
74
74
|
- **`create` requires an enabled template** on the same config item. Enable workflow: `config-param batch-add` → `template create` → `template update` (non-empty `config[]` with real `paramId`) → `template update-status --status 1`. Otherwise `create` returns `TEMPLATE_ENABLE`.
|
|
75
75
|
- `create` output field is `data.strategy_uuid` (not `strategy_id`).
|
|
76
76
|
- `manage` supports `online`, `offline`, `suspend`, `delete`, `approve`, `deny`, and `cancel`; it is a write operation.
|
|
@@ -5,6 +5,16 @@ Query the details of a single task.
|
|
|
5
5
|
|
|
6
6
|
Mapped command: `ae-cli engage-task task get`
|
|
7
7
|
|
|
8
|
+
For a custom target audience, the response hides persisted `qp` and returns:
|
|
9
|
+
|
|
10
|
+
- `definition_status`: `AVAILABLE`, `UNAVAILABLE`, or `NOT_APPLICABLE`
|
|
11
|
+
- `definition_request`: the Analysis-compatible semantic audience definition when available
|
|
12
|
+
- `definition_unavailable_reason`: present only when a historical QP cannot be reversed
|
|
13
|
+
|
|
14
|
+
Reuse `definition_request` as `req.targetConfig.definitionRequest` when updating a task.
|
|
15
|
+
Soft-deleted tasks are treated as unavailable and return `TASK_NOT_FOUND`, matching task-list
|
|
16
|
+
visibility.
|
|
17
|
+
|
|
8
18
|
## Flags
|
|
9
19
|
|
|
10
20
|
| Flag | Type | Required | Description |
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# engage-task task submit-approval
|
|
2
|
+
|
|
3
|
+
Submit an existing draft engagement task for approval. The legacy full save-and-submit request remains supported.
|
|
4
|
+
This is a regular write operation.
|
|
5
|
+
|
|
6
|
+
> Capability id: `engage-task.task.submit-approval` · Domain: `engage`.
|
|
7
|
+
|
|
8
|
+
```bash
|
|
9
|
+
ae-cli engage-task task submit-approval --project-id <project_id> --task-id <task_id>
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Parameters
|
|
13
|
+
|
|
14
|
+
| Flag | Required | Notes |
|
|
15
|
+
|---|---|---|
|
|
16
|
+
| `--project-id` / `-p` | yes | Numeric project ID. |
|
|
17
|
+
| `--task-id` | conditional | Existing draft task ID. Recommended after `task save`. |
|
|
18
|
+
| `--request` | conditional | Legacy `ApprovalSaveAndSubmitDTO` / `OperationTaskOpDTO` JSON (camelCase or snake_case). |
|
|
19
|
+
|
|
20
|
+
Provide exactly one of `--task-id` or `--request`.
|
|
21
|
+
|
|
22
|
+
## Output
|
|
23
|
+
|
|
24
|
+
- `data.task_id`
|
|
25
|
+
|
|
26
|
+
## Request notes
|
|
27
|
+
|
|
28
|
+
- Prefer `task save` followed by `submit-approval --task-id`. The server loads the persisted draft, validates its
|
|
29
|
+
trigger rule, and reuses the existing save-and-submit approval workflow.
|
|
30
|
+
- Do not reconstruct or pass `trigger_rule`. It is an internal persisted field.
|
|
31
|
+
- The legacy `--request` mode remains available for existing callers.
|
|
32
|
+
- Required body fields (server validates): `task_name`, `channel_type`, `channel_id`, `group_content_list`, `target_cluster_type`, `trigger_type`, `completion_indicator_def`, `frequency_limits`, `enable_channel_touch_limits`, `group_id`, `trigger_time_strategy`.
|
|
33
|
+
- Missing `expConfig` is auto-filled as `{"enableExp":false}` (same as activity task create/update).
|
|
34
|
+
- TEXT channel params missing `config` are auto-filled with Slate.js JSON from `value`.
|
|
35
|
+
- For schedule-single (`triggerType=0`), include a future `triggerTime` (and `tzOffset` / `triggerTimeStrategy` as needed).
|
|
36
|
+
- Prefer save → submit by task ID; do not invent `taskId` / `channelId`.
|
|
37
|
+
|
|
38
|
+
## Common Errors
|
|
39
|
+
|
|
40
|
+
| code | when |
|
|
41
|
+
|---|---|
|
|
42
|
+
| `APPROVAL_INPUT_INVALID` | neither or both of `task_id` and `request` supplied |
|
|
43
|
+
| `REQUEST_REQUIRED` | `--request` missing or not an object |
|
|
44
|
+
| `REQUEST_FIELDS_REQUIRED` | required body fields absent/blank |
|
|
45
|
+
| `CAPABILITY_EXECUTION_FAILED` | unmapped domain failure; check `invocation_id` / Hermes logs |
|
|
@@ -30,7 +30,7 @@ Use `--operation-mode save_flow` for the current exposed MCP protocol. Use `save
|
|
|
30
30
|
Important current rules:
|
|
31
31
|
|
|
32
32
|
- `event_trigger` / `event_judge` A segment: use `periodStart`, `periodEnd`, `periodTimeSymbol`; do not use branch-style `delayTime`.
|
|
33
|
-
- `event_split_flow` branch segment: use `delayTime`, `delayTimeSymbol`, `targetClusterType`; omit `
|
|
33
|
+
- `event_split_flow` branch segment: use `delayTime`, `delayTimeSymbol`, `targetClusterType`; omit `triggerDefinition` on default branches.
|
|
34
34
|
- `event_trigger targetUserType=2` is invalid.
|
|
35
35
|
- Push `OBJ_ARRAY.value` must be a JSON array, not a stringified array.
|
|
36
36
|
- Push `contentList[].content` should be a JSON array, but a JSON-stringified array is accepted for compatibility.
|
|
@@ -91,12 +91,12 @@ First, check if `.ae-cli/draft.json` exists and read existing configuration:
|
|
|
91
91
|
**⚠️ Key: SERVER_URL and APP_ID are independent config items. Even if draft.json has project_id and host, you MUST resolve and confirm them. `project_id` ≠ `APP_ID`, `host` ≠ `SERVER_URL`.**
|
|
92
92
|
|
|
93
93
|
1. **APP_ID** — Prefer automatic lookup before asking:
|
|
94
|
-
- If `meta.project_id` is known, run `ae-cli
|
|
94
|
+
- If `meta.project_id` is known, run `ae-cli project info list` once for the current host.
|
|
95
95
|
- Find the project whose `projectId` matches `meta.project_id`.
|
|
96
96
|
- If the matched project has `appId`, ask: **"I found APP_ID `<appId>` for project `<projectId>`. Use it? yes / enter new value"**
|
|
97
97
|
- If the project is missing, ambiguous, or has no `appId`, ask the user to copy APP_ID from AE Admin → "Project Settings" → "Integration Config".
|
|
98
98
|
2. **SERVER_URL** — Data ingestion endpoint (**different from web URL**; go to AE Admin → "Project Settings" → "Integration Config" → fill in "Public URL")
|
|
99
|
-
- If `meta.project_id` is known, you may try `ae-cli
|
|
99
|
+
- If `meta.project_id` is known, you may try `ae-cli project info get --project-id <project_id>` once.
|
|
100
100
|
- Use the returned value only if the response explicitly contains a receiver URL field such as `serverUrl`, `pushUrl`, `push_url`, `receiverUrl`, `publicUrl`, `publicReceiverAddress`, `privateReceiverAddress`, or equivalent ingestion endpoint field.
|
|
101
101
|
- If both `publicReceiverAddress` and `privateReceiverAddress` are present, prefer `publicReceiverAddress` as `SERVER_URL` for generated snippets unless the user explicitly needs an internal/private-network receiver.
|
|
102
102
|
- If a value is found, ask: **"I found SERVER_URL `<url>` for project `<projectId>`. Use it? yes / enter new value"**
|
|
@@ -53,7 +53,7 @@ ae-cli metadata property <dimension-table-action> [options]
|
|
|
53
53
|
|
|
54
54
|
## PROJECT_ID_GATE
|
|
55
55
|
|
|
56
|
-
Same rules as `ae-analysis`: reuse verified project context in one conversation; otherwise `ae-cli
|
|
56
|
+
Same rules as `ae-analysis`: reuse verified project context in one conversation; otherwise `ae-cli project info list` (or `ae-analysis` skill) to resolve `project_id`.
|
|
57
57
|
|
|
58
58
|
## Commands (10)
|
|
59
59
|
|
package/dist/config-BSSALXEN.js
DELETED
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
GLOBAL_QUERY_CONFIG_KEY,
|
|
3
|
-
getAnalysisMappingPathForClusterMode,
|
|
4
|
-
getClusterInfoFilePath,
|
|
5
|
-
isGlobalQueryModeEnabled,
|
|
6
|
-
setGlobalQueryModeEnabled
|
|
7
|
-
} from "./chunk-LCXU3AAT.js";
|
|
8
|
-
import {
|
|
9
|
-
printError,
|
|
10
|
-
printOutput
|
|
11
|
-
} from "./chunk-KTYR3U6D.js";
|
|
12
|
-
import "./chunk-E7UXXHO3.js";
|
|
13
|
-
import "./chunk-IR4ZLVPW.js";
|
|
14
|
-
import {
|
|
15
|
-
addHost,
|
|
16
|
-
loadConfig,
|
|
17
|
-
normalizeUrl,
|
|
18
|
-
setActiveHost
|
|
19
|
-
} from "./chunk-V6FR6WTW.js";
|
|
20
|
-
import "./chunk-LYVNONC4.js";
|
|
21
|
-
|
|
22
|
-
// src/commands/config.ts
|
|
23
|
-
function registerConfig(program) {
|
|
24
|
-
const configCmd = program.command("config").description("AE host and environment configuration").action(() => {
|
|
25
|
-
printError("config", "Missing subcommand.", "Run: ae-cli config --help");
|
|
26
|
-
process.exit(1);
|
|
27
|
-
});
|
|
28
|
-
configCmd.command("list").description("List configured AE environments").action(async () => {
|
|
29
|
-
await printConfigList(program);
|
|
30
|
-
});
|
|
31
|
-
configCmd.command("current").description("Show the active AE environment").action(async () => {
|
|
32
|
-
await printCurrentConfig(program);
|
|
33
|
-
});
|
|
34
|
-
configCmd.command("use <env>").description("Switch active AE environment by exact URL or unique label").action(async (env) => {
|
|
35
|
-
await useConfigEnv(program, env);
|
|
36
|
-
});
|
|
37
|
-
configCmd.command("set-host <url>").description("Set the active AE host non-interactively (adds it if not already configured)").option("--label <label>", "Display label for this host (defaults to the host URL)").action(async (url, opts) => {
|
|
38
|
-
const normalized = normalizeUrl(url);
|
|
39
|
-
const label = opts.label || normalized;
|
|
40
|
-
addHost(normalized, label);
|
|
41
|
-
setActiveHost(normalized);
|
|
42
|
-
await printOutput({ activeHost: normalized, label }, program.opts().format || "json");
|
|
43
|
-
});
|
|
44
|
-
const clusterMode = configCmd.command("cluster-mode").description("Manage local multi-cluster analysis MCP mode").action(async () => {
|
|
45
|
-
await printClusterModeStatus(program);
|
|
46
|
-
});
|
|
47
|
-
clusterMode.command("status").description("Show local multi-cluster analysis MCP mode").action(async () => {
|
|
48
|
-
await printClusterModeStatus(program);
|
|
49
|
-
});
|
|
50
|
-
clusterMode.command("enable").description("Enable local multi-cluster analysis MCP mode").action(async () => {
|
|
51
|
-
setGlobalQueryModeEnabled(true);
|
|
52
|
-
await printClusterModeStatus(program);
|
|
53
|
-
});
|
|
54
|
-
clusterMode.command("disable").description("Disable local multi-cluster analysis MCP mode").action(async () => {
|
|
55
|
-
setGlobalQueryModeEnabled(false);
|
|
56
|
-
await printClusterModeStatus(program);
|
|
57
|
-
});
|
|
58
|
-
}
|
|
59
|
-
async function printClusterModeStatus(program) {
|
|
60
|
-
const enabled = isGlobalQueryModeEnabled();
|
|
61
|
-
await printOutput({
|
|
62
|
-
[GLOBAL_QUERY_CONFIG_KEY]: enabled,
|
|
63
|
-
path: getClusterInfoFilePath(),
|
|
64
|
-
analysisMappingPath: getAnalysisMappingPathForClusterMode(enabled)
|
|
65
|
-
}, program.opts().format || "json", program.opts().jq);
|
|
66
|
-
}
|
|
67
|
-
function readHostViews() {
|
|
68
|
-
const config = loadConfig();
|
|
69
|
-
const hosts = Object.entries(config.hosts).map(([url, entry]) => ({
|
|
70
|
-
url,
|
|
71
|
-
label: entry.label,
|
|
72
|
-
active: url === config.activeHost
|
|
73
|
-
}));
|
|
74
|
-
return { activeHost: config.activeHost, hosts };
|
|
75
|
-
}
|
|
76
|
-
async function printConfigList(program) {
|
|
77
|
-
const { activeHost, hosts } = readHostViews();
|
|
78
|
-
await printOutput({ activeHost, hosts }, program.opts().format || "json", program.opts().jq);
|
|
79
|
-
}
|
|
80
|
-
async function printCurrentConfig(program) {
|
|
81
|
-
const { activeHost, hosts } = readHostViews();
|
|
82
|
-
const current = hosts.find((h) => h.url === activeHost);
|
|
83
|
-
if (!current) {
|
|
84
|
-
failConfig("No active AE environment configured.", "Run: ae-cli config use <env> or ae-cli config list");
|
|
85
|
-
return;
|
|
86
|
-
}
|
|
87
|
-
await printOutput({ activeHost: current.url, label: current.label }, program.opts().format || "json", program.opts().jq);
|
|
88
|
-
}
|
|
89
|
-
async function useConfigEnv(program, env) {
|
|
90
|
-
const target = resolveHost(env);
|
|
91
|
-
if (target.status === "not-found") {
|
|
92
|
-
failConfig(
|
|
93
|
-
`No AE environment matched: ${env}`,
|
|
94
|
-
target.hosts.length > 0 ? `Available environments: ${formatHostOptions(target.hosts)}` : "Run: ae-cli config list"
|
|
95
|
-
);
|
|
96
|
-
return;
|
|
97
|
-
}
|
|
98
|
-
if (target.status === "duplicate-label") {
|
|
99
|
-
failConfig(
|
|
100
|
-
`Duplicate label: ${env}`,
|
|
101
|
-
`Rename duplicate labels first. Run: ae-cli config list \u2014 ${formatHostOptions(target.matches)}`
|
|
102
|
-
);
|
|
103
|
-
return;
|
|
104
|
-
}
|
|
105
|
-
setActiveHost(target.host.url);
|
|
106
|
-
await printOutput({ activeHost: target.host.url, label: target.host.label }, program.opts().format || "json", program.opts().jq);
|
|
107
|
-
}
|
|
108
|
-
function resolveHost(env) {
|
|
109
|
-
const raw = env.trim();
|
|
110
|
-
const selector = raw.startsWith("http://") || raw.startsWith("https://") ? normalizeUrl(raw) : raw;
|
|
111
|
-
const { hosts } = readHostViews();
|
|
112
|
-
const byUrl = hosts.find((h) => h.url === selector);
|
|
113
|
-
if (byUrl) return { status: "found", host: byUrl };
|
|
114
|
-
const byLabel = hosts.filter((h) => h.label === raw);
|
|
115
|
-
if (byLabel.length === 1) return { status: "found", host: byLabel[0] };
|
|
116
|
-
if (byLabel.length > 1) return { status: "duplicate-label", matches: byLabel };
|
|
117
|
-
return { status: "not-found", hosts };
|
|
118
|
-
}
|
|
119
|
-
function formatHostOptions(hosts) {
|
|
120
|
-
return hosts.map((h) => `${h.label} (${h.url})`).join(", ");
|
|
121
|
-
}
|
|
122
|
-
function failConfig(message, hint) {
|
|
123
|
-
printError("config", message, hint);
|
|
124
|
-
process.exitCode = 1;
|
|
125
|
-
}
|
|
126
|
-
export {
|
|
127
|
-
registerConfig
|
|
128
|
-
};
|