--- name: my-referrals description: List a partner's own submitted referrals and deal registrations with one customer and where each stands (pending / approved / rejected), using EULER MCP tools. Use this skill whenever a partner wants to see the referrals they've sent — phrases like "my referrals", "what referrals did I submit", "status of my referrals", "my deal registrations", "did my referral get approved". Partner-facing (a partner viewing their OWN referrals), NOT a customer admin triaging the queue — that distinction selects this over pending-approvals-triage. --- # my-referrals — your referrals ## When to use this skill Invoke when **a partner** wants to see **their own submitted referrals** with one customer — the full worklist of referrals and deal registrations they've sent, with the current status of each: - "My referrals" / "What referrals did I submit?" - "Status of my referrals" / "Did my referral get approved?" - "My deal registrations" / "Show me what I've referred" - `/euler-for-partner-managers:my-referrals` DO NOT invoke for: - **A customer admin triaging the approval queue** — that is `pending-approvals-triage` (the customer-side worklist). This skill is the partner looking at *their own* submissions. - **A partner wanting to submit a new referral** — that is `submit-a-referral` (the write skill). This skill is read-only. The distinction that selects this skill: **the connected account is the partner, and the subject is that same partner's own referral submissions.** ## Account type — required: partner This skill is partner-scope. It needs a connection with a `type === 'partner'` entry (the partner viewing their own referrals). **Step 1 is always `list_accounts`.** Apply the account gate in [`references/account-gate.md`](references/account-gate.md) before anything else: - Connected account has a `type === 'partner'` entry → proceed (partner context); take `partner_id` + `affiliate_company_name` from that entry. - **Customer-only connection** (no `type === 'partner'`) → emit the friendly gate message and **STOP**: "my-referrals shows your own referrals as a partner. You're connected as a customer admin — to triage the approval queue use `pending-approvals-triage`, or open your dashboard: ``." Use the `dashboard_url` from the customer entry. - Both roles → proceed as the partner (use the partner entry). `partner_id` comes **only** from the chosen `type: 'partner'` entry — **never** from `partner_directory_search` (that returns a directory `profile_id`, rejected downstream as `partner_not_in_consent`). Translate any escaping `forbidden_scope` into the same friendly message; never show the user `forbidden_scope` or any `euler_*` code. ## Inputs (optional — never block) No partner is named — it is always the caller's own submissions. | Input | Default | Accepts | |---|---|---| | **Which customer** | the only `type:'partner'` account | a customer name → match `affiliate_company_name`. If >1 partner account and the user named none (or name matches several), **ask** which — show the `affiliate_company_name` list. | | **Status filter** | all statuses | "pending" / "approved" / "rejected" — filter the table; mention the filter in the hero subtitle. | One partner + one customer pairing per invocation — do not fan out across accounts. ## Orchestration sequence Two calls total. For exact response field paths and backend quirks, consult [`references/mcp-field-paths.md`](references/mcp-field-paths.md) (numerics arrive as strings; `referrals` response has a loose-JSON quirk; dates are `YYYY-MM-DD`). | # | Tool call | Provides | |---|-----------|----------| | 1 | `list_accounts` | Account gate + `partner_id` + customer `affiliate_company_name` (header). | | 2 | `referrals(action:'for_partner', partner_id)` | All referrals submitted by this partner (paginated) — company, type, status, `Submitted On` date. | If the response is paginated (`result_per_page`), fetch subsequent pages until all referrals are loaded — parse `result_per_page` loosely (see mcp-field-paths.md for the serialization quirk). ### Error handling - Customer-only account → friendly gate message (see §Account type), STOP. - `partner_not_in_consent` → tell the user to disconnect + reconnect and include this account in their consent selection; do not render a partial report. - `backend_data_issue` on `list_accounts` → surface its `support_email`, note reconnecting won't help, and continue with whatever `referrals` returns. - `forbidden_scope` escaping mid-run → translate via `references/account-gate.md` into the friendly message; never surface the raw code. - `referrals` returns empty or fails → render the positive empty-state message; no crash. ## Product how-to questions (`euler_help`) If the user asks how EULER itself works or how to do something in the product — not about their own data — e.g. "how do I register a deal", "where do I find X in the portal", "how does onboarding work" — call `euler_help` with their question and answer briefly from its result. Do not guess about product behavior. This is a tangent to this skill's main job: answer in 1–3 sentences (no HTML report) and return to the task. ## Output format Render a **single self-contained HTML file** — no external CSS/fonts/scripts beyond the one web-font import. Opens in a browser, prints to PDF, or shares by file/link. ### How to produce the HTML 1. Read [`assets/styles.css`](assets/styles.css) and inline its **FULL** contents into a single `