assistant-skills/update-salesforce-tech-validation/SKILL.md

119 lines
6.4 KiB
Markdown

---
name: update-salesforce-tech-validation
description: |
Edit and run the SE Radar report in Salesforce to add columns, view SE notes, and manage technical validation data.
Triggers when user mentions:
- "update the SE radar report"
- "add a column to the SE report"
- "edit the vNotes report"
- "run the SE radar report"
- "update salesforce tech validation report"
---
## Overview
This skill automates editing and running the **SE Radar: SE vNotes and TVSs IC** report in Salesforce. It covers adding columns, re-running the report, and reading the results. More workflows (e.g., filtering, grouping, saving changes) will be added as needed.
## Prerequisites
- Chrome browser with an active Salesforce session (authenticated via Okta SSO at verkada.okta.com)
- Access to the SE Radar report
## Report URL
```
https://verkada.lightning.force.com/lightning/r/Report/00OUu000004gR9ZMAU/view
```
## Workflow: Add a Column and Re-Run
### Step 1: Open the Report
Navigate to the report URL. Wait for the page to load (look for "Total Records" and the report table). If Salesforce doesn't load via browser automation (SSO issues), ask the user to open it manually first.
### Step 2: Enter Edit Mode
1. Take a snapshot to find the **"Edit"** button inside the Report Viewer iframe
2. Click **"Edit"**
3. Wait for the Report Builder to load (look for "Fields" panel, "Undo"/"Redo" buttons, and "Run" button)
### Step 3: Add a Column
1. The **Fields** panel on the left contains a tree of all available fields grouped by object (e.g., "Opportunities", "SE Deal Management", "vNotes", "SE User")
2. Locate the desired field in the tree. If the list is long, use the **"Search Fields"** searchbox at the top of the panel
3. Click the field name to select it (it will show as `selected` in the accessibility tree)
4. The page will display: "1 selected. To add new fields as detail columns, press Enter"
5. Press **Enter** to add the field as a new column
After adding, the **Undo** button becomes enabled, confirming the change was registered. The preview area may show "To see the latest edits, refresh the preview."
### Step 4: Run the Report
1. Click the **"Run"** button (top of the report builder)
2. The page navigates back to the report view with the new column included
3. Wait for "Total Records" to appear confirming the data has loaded
### Step 5: Verify the New Column
Take a snapshot of the report view and confirm the new column header appears in the table.
## Known Columns in the Report
As of the initial skill creation, the report includes these columns:
| Column | Object |
|--------|--------|
| Opportunity ID | Opportunities |
| Opp Name And Link | Opportunities |
| Solutions Engineer: Full Name | Opportunities |
| VNote: VNote Name | vNotes |
| Technical Validation Stage | SE Deal Management |
| POC Documentation Link | SE Deal Management |
| POC Stage | SE Deal Management |
| Solutions Engineer: Team | SE User |
| SE Notes | Opportunities (added via this workflow) |
## Workflow: Find Blank SE Notes and Look Up from Notes Directory
After adding the SE Notes column and running the report, use this workflow to identify opportunities missing SE Notes and find the corresponding notes in the local notes repo.
### Step 1: Identify Blank SE Notes
1. Scroll through the full report to see all rows (Salesforce lazy-loads rows; click "Load more widgets" or scroll to the bottom of the iframe body)
2. For each row, check the SE Notes cell. Blank entries show as a single dash: `-`
3. Build a list of all opportunities with blank SE Notes, noting the opportunity name and the account name
### Step 2: Look Up SE Notes from Account Notes
For each account with a blank SE Notes entry:
1. **Find the account note file** in `/Users/connor.rhodes/code/notes/` (e.g., `San Antonio ISD.md`, `AR Dept of Transportation.md`)
2. **Find the relevant wip file**:
- Account notes link to wip files under a `## WIP` section or similar
- Look for a wip file that matches the specific opportunity (e.g., `wip/ardot phase 2.md`)
- If no opportunity-specific wip file exists, use a **general expansion** wip file if one is linked (e.g., `wip/general saisd expansion.md` for any SAISD expansion opportunity)
3. **Extract the SE Note content**:
- Open the wip file and look for a header matching `SE Notes` or `SE Note` (case insensitive, any header level)
- Return the content under that header, but not the header itself
- If no SE Notes header exists in the wip file, report that no SE note was found
### Step 3: Present Results to the User
Group results by account. For each opportunity:
- If an SE note was found, show the opportunity name and the SE note content (header omitted)
- If no SE note was found, say so
Note: Multiple opportunities for the same account can share the same general expansion SE note. This is expected behavior (e.g., all SAISD expansion opps use `wip/general saisd expansion.md`).
## Common Gotchas
- **Salesforce loads in an iframe**: The report content lives inside an iframe called "Report Viewer" (view mode) or "Report Builder" (edit mode). Snapshots and interactions must target elements within this iframe.
- **Ephemeral UIDs**: Salesforce Lightning re-renders frequently. Element UIDs change between snapshots. Always take a fresh snapshot before clicking.
- **Progressive loading**: The report builder shows "Previewing a limited number of records" while loading. Use `wait_for` with text like "Columns" or "Run" before interacting.
- **Lazy-loaded rows**: The report view only renders ~12 rows initially. Scroll the iframe body or click "Load more widgets" to see the rest.
- **SSO session expiry**: If the session has expired, the page will redirect to Okta login. Ask the user to re-authenticate manually.
- **Field tree is large**: The Opportunities object alone has 400+ fields. Use the "Search Fields" searchbox to find specific fields quickly rather than scrolling.
- **"Run" vs "Save"**: Clicking "Run" re-runs the report with the new columns but does not persist the change to the report definition. Use "Save" if the column should be permanent.
- **General expansion wip files**: When no opportunity-specific wip file exists, check for a general expansion wip file linked from the account note. This is the catch-all SE note for all expansion opportunities under that account.
- **Wip files may not exist on disk**: Some wip files linked from account notes may have been deleted or never created. Check for the file before trying to read it.