@apex-inc/mcp-server 0.28.1 → 0.30.0
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/adoption-compose.d.ts +1 -1
- package/dist/adoption-compose.d.ts.map +1 -1
- package/dist/adoption-compose.js +8 -3
- package/dist/adoption-compose.js.map +1 -1
- package/dist/api-client.d.ts +9 -0
- package/dist/api-client.d.ts.map +1 -1
- package/dist/api-client.js +36 -1
- package/dist/api-client.js.map +1 -1
- package/dist/index.js +26 -8
- package/dist/index.js.map +1 -1
- package/dist/live-test-guard.d.ts +45 -0
- package/dist/live-test-guard.d.ts.map +1 -0
- package/dist/live-test-guard.js +78 -0
- package/dist/live-test-guard.js.map +1 -0
- package/dist/setup-catchup-tools.d.ts +633 -0
- package/dist/setup-catchup-tools.d.ts.map +1 -0
- package/dist/setup-catchup-tools.js +506 -0
- package/dist/setup-catchup-tools.js.map +1 -0
- package/dist/tools.d.ts +784 -47
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +253 -18
- package/dist/tools.js.map +1 -1
- package/package.json +1 -1
- package/skills/apex-adoption/SKILL.md +14 -3
- package/skills/apex-communications/SKILL.md +8 -5
- package/skills/apex-experimentation/SKILL.md +3 -0
- package/skills/apex-integration-cookbook/SKILL.md +11 -0
- package/skills/apex-partner-network/SKILL.md +1 -0
package/package.json
CHANGED
|
@@ -32,7 +32,11 @@ Do not say reminder, congratulations, clock, or watch list as names they see.
|
|
|
32
32
|
|
|
33
33
|
## Core idea
|
|
34
34
|
|
|
35
|
-
- A Milestone is
|
|
35
|
+
- A Milestone is **This person** unless they set **Anyone here**. Absent `finish_when` = This person. Existing rows stay This person until they flip them.
|
|
36
|
+
- **This person** — only that person finishes. Their letters stay theirs.
|
|
37
|
+
- **Anyone here** — first person on the same **Account** (`identify({ account: { id } })`) finishes it for the company. Leftover Nudges stop for the others. **Only the person who did it gets the Celebration.** Trait finishes stay This person.
|
|
38
|
+
- Company facts (snippet live, SSO, billing) → Anyone here. Person skills (ran a report, invited a teammate) → This person.
|
|
39
|
+
- `update_adoption_milestone` can flip a live event Milestone. Flipping to Anyone here backfills leftover Nudges for Accounts that already have a doer. A teammate who joins later inherits Done.
|
|
36
40
|
- Hours or days from signup (or the anchor). `0` is right away. 1 hour is not right away.
|
|
37
41
|
- New Milestones default to **from now on** (`enroll_mode: "future"`). Do not publish a short clock on everyone already here (`enroll_mode: "all"`).
|
|
38
42
|
- Each Send gets its **own** Communication. Never reuse `comm-adoption-nudge` or `comm-adoption-celebration`.
|
|
@@ -57,10 +61,12 @@ Name live hosts (`list_workspace_environments` / `set_workspace_environments` or
|
|
|
57
61
|
| `get_adoption_milestone` | Inspect one |
|
|
58
62
|
| `create_adoption_milestone` | Define a Milestone (just-track unless they compose) |
|
|
59
63
|
| `compose_adoption_milestone` | Create a Milestone and stamp **one** Adaptive Journey |
|
|
60
|
-
| `update_adoption_milestone` | Change priority / order / hours or days / on-off |
|
|
64
|
+
| `update_adoption_milestone` | Change priority / order / hours or days / on-off / `finish_when` |
|
|
61
65
|
| `reorder_adoption_milestones` | Sequence for the Path funnel |
|
|
62
66
|
| `delete_adoption_milestone` | Remove a Milestone |
|
|
63
67
|
| `get_adoption_metrics` | Funnel + one lift number |
|
|
68
|
+
| `get_adoption_user_progress` | One person's Path (Not yet / Started / Done) |
|
|
69
|
+
| `get_adoption_account_progress` | One company's Path: who finished, how many are still Not yet |
|
|
64
70
|
| `attach_adoption_milestone_still` | Attach Not yet or Done |
|
|
65
71
|
| `list_adoption_milestone_stills` | List those two pictures |
|
|
66
72
|
| `recapture_adoption_milestone_stills` | Capture from public pages on a named host |
|
|
@@ -81,7 +87,7 @@ Read-only summary: `apex://adoption`.
|
|
|
81
87
|
|
|
82
88
|
Returns one `journey_id` (also `nudge_journey_id` for old callers) and each Send as `{ role, step_id, comm_id }`. `celebration_journey_id` is null on new rows.
|
|
83
89
|
|
|
84
|
-
Params: `action_label`, `gap_hours` or `gap_days`, `nudge_clocks` (each hours or days), `save_not_yet_segment`, `save_done_segment`, `enroll_mode
|
|
90
|
+
Params: `action_label`, `gap_hours` or `gap_days`, `nudge_clocks` (each hours or days), `save_not_yet_segment`, `save_done_segment`, `enroll_mode`, `finish_when` (`this_person` or `anyone_here`; event finishes only).
|
|
85
91
|
|
|
86
92
|
Preview each Communication, then `publish_journey`. Leave the Milestone off until they confirm.
|
|
87
93
|
|
|
@@ -133,6 +139,11 @@ Only when they are not using compose:
|
|
|
133
139
|
### "Just track — no letter"
|
|
134
140
|
1. `compose_adoption_milestone` `scaffold: "none"`.
|
|
135
141
|
|
|
142
|
+
### "First person at the company finishes it for everyone"
|
|
143
|
+
1. Event finish only. Pass `finish_when: "anyone_here"` on compose, or `update_adoption_milestone` on a live row.
|
|
144
|
+
2. Company facts (snippet, SSO, billing) — not person skills.
|
|
145
|
+
3. A flip on a live row backfills leftover Nudges. Use `get_adoption_account_progress` for the company report.
|
|
146
|
+
|
|
136
147
|
### "Save not-yet as a Segment"
|
|
137
148
|
Pass `save_not_yet_segment: true` (and/or `save_done_segment`) on compose. Names: `Not yet: {name}` / `Done: {name}`. Completing drops them from not-yet. The Adaptive Journey watch list stays private if they do not check this.
|
|
138
149
|
|
|
@@ -86,11 +86,10 @@ you did:
|
|
|
86
86
|
|
|
87
87
|
`in_experiment` is a hard stop, not an intent question — the content is a
|
|
88
88
|
treatment mid-measurement. `edit_communication` accepts
|
|
89
|
-
`confirm_live_experiment: true` to override, and that **marks the
|
|
90
|
-
|
|
91
|
-
own initiative. Offer the alternatives first:
|
|
92
|
-
finish, or end it
|
|
93
|
-
is captured.
|
|
89
|
+
`confirm_live_experiment: true` to override, and that **marks the numbers
|
|
90
|
+
untrustworthy: Apex will not call a winner and will not learn from mixed
|
|
91
|
+
counts**. Never pass it on your own initiative. Offer the alternatives first:
|
|
92
|
+
wait for the experiment to finish, or end it so the learning is captured.
|
|
94
93
|
|
|
95
94
|
If you omit `intent` when it's needed, the server returns a 409 that names both
|
|
96
95
|
options. That's a fork in the road, not a failure — read it, ask the user, and
|
|
@@ -219,6 +218,10 @@ Examples:
|
|
|
219
218
|
|
|
220
219
|
When generating communications for a journey, **mention exit rules in the same breath**. The apex-journeys skill has the full pattern.
|
|
221
220
|
|
|
221
|
+
## Sender domain is a hop
|
|
222
|
+
|
|
223
|
+
`start_sender_domain` issues DNS records. That is not green. The shop pastes them at the registrar; you cannot click the registrar for them. Poll `get_sender_domain` until status is verified.
|
|
224
|
+
|
|
222
225
|
## Proactive nudge: missing exit rules
|
|
223
226
|
|
|
224
227
|
When a user generates or creates a marketing journey with `wait` steps and a purchase or activation goal, proactively check whether exit rules exist:
|
|
@@ -164,6 +164,7 @@ Match Apex UI terminology in user-facing copy: e.g. **Adaptive traffic allocatio
|
|
|
164
164
|
- Hiding the page until `/assign` returns (worse LCP; not the React-hook promise).
|
|
165
165
|
- Changing variant implementation mid-flight without versioning (invalidates analysis).
|
|
166
166
|
- Only using p-values without effect size or business context.
|
|
167
|
+
- Shipping onto a live test. Before you edit a page, commit, or push — even if they never said experiment — call `check_live_tests` with the **full file contents**, not the diff hunk. Before you change a letter, Adaptive Journey, or Milestone, call it with `communication_ids`, `journey_ids`, or `milestone_ids`. If something live is on those files or ids, **stop and ask**. Three outs: end the test then ship; wait; or they say this change is not the thing under test (they mark that on the experiment page). Do not edit. Do not commit. Do not pass `confirmLiveExperiment` / `confirmTreatmentChange` / `confirmLiveMilestone` unless they picked an out.
|
|
167
168
|
|
|
168
169
|
## Prove incrementality — "is our growth real?"
|
|
169
170
|
|
|
@@ -190,6 +191,8 @@ Surface specifically: `create_experiment` auto-detects mobile vs web from repo s
|
|
|
190
191
|
|
|
191
192
|
Parameter casing: all tool parameters are **snake_case** (`experiment_id`, `traffic_split`, `primary_metric_event`, `guardrail_event`) — the same convention as event names. camelCase is accepted as a fallback, but snake_case is canonical.
|
|
192
193
|
|
|
194
|
+
Shipping onto a live website, app test, letter, Adaptive Journey, or Milestone: `check_live_tests` (before edit / commit / push / publish). That is a different question from two tests on the same page.
|
|
195
|
+
|
|
193
196
|
Avoiding interaction effects: two experiments on the **same surface/component** contaminate each other. `create_experiment` (preview) and `activate_experiment` auto-run a conflict check and surface an advisory; you can also call `check_experiment_conflicts` yourself. Resolve it by either (a) **mutual exclusion** — `set_experiment_mutex` so no visitor is in both (run concurrently, the scientifically clean default), or (b) **sequencing** — launch the second only after the first concludes. If two experiments share a surface AND the same primary metric, they're usually arms of ONE experiment — add a variant instead of creating a second. Pass `target_component` (e.g. "ProductCard") on create so the guard can detect overlap precisely, especially for mobile/SDK experiments.
|
|
194
197
|
|
|
195
198
|
## Related
|
|
@@ -334,3 +334,14 @@ ad accounts + Stripe in their workspace; per-client spend/revenue/ROI
|
|
|
334
334
|
and the transparent at-risk rule roll up on the agency org
|
|
335
335
|
(`GET /api/agency/clients` — org owner/admin sessions only; it is a
|
|
336
336
|
financial boundary with no API-key lane).
|
|
337
|
+
|
|
338
|
+
## Recipe: Set up Apex from this repo
|
|
339
|
+
|
|
340
|
+
If get_setup_state shows first-run incomplete, name the shop before inventing events.
|
|
341
|
+
|
|
342
|
+
1. Call `get_setup_state`. If the shop has no name, no vertical, or no conversion model, stop.
|
|
343
|
+
2. `update_organization` with the shop's real name. `update_workspace` with `workspace_name`, `vertical`, `conversion_model`, and `website_url` when you know them. The rail finishes from those saves — do not look for a mark-complete tool.
|
|
344
|
+
3. Name Production (and optional Beta) sites with `list_workspace_environments` / `set_workspace_environments` before you trust the Production slice.
|
|
345
|
+
4. Install the snippet or SDK and wire the events the shop actually fires. Do not invent event names to make a step look done.
|
|
346
|
+
5. Finish writable setup with the matching tools (`claim_links_subdomain`, `set_consent_posture`, webhooks, scoring, invitations, engagement, app platforms, attribution, sender domain, push keys, protect auto-pause). Consent answers are not a live-site tap. Sender-domain records issued are not green — poll `get_sender_domain` until verified.
|
|
347
|
+
6. Hop only when the next incomplete step is a hop: `start_integration_install` for GitHub, Stripe, Meta, Google, LinkedIn, or TikTok. Legal acknowledgements stay on the opened page. You cannot click the ad consoles or the DNS registrar for them.
|
|
@@ -188,4 +188,5 @@ Policies:
|
|
|
188
188
|
|
|
189
189
|
- `apex-integration-cookbook` — end-to-end patterns combining partner network + communications + experiments
|
|
190
190
|
- MCP tools: `list_partner_programs`, `create_partner_program`, `invite_partner`, `approve_payouts`, `vouch_for_partner`, `get_effective_fees`
|
|
191
|
+
- Stripe Connect for the shop is a hop: `start_integration_install` with `type: "stripe"`. Legal acknowledgements stay on the opened page.
|
|
191
192
|
- Docs: `/docs/partner-network/` for concept walkthroughs + integration guides
|