Source profileQuality 97/100

VincentChuWaiChow/vanguard-frontier-agentic/skills/salesforce/salesforce-soql-explorer-skill/SKILL.md

salesforce-soql-explorer-skill

Executes read-only SOQL queries against a connected Salesforce org via the sf data query CLI under T1 least-privilege scope (api + refresh_token only, Run As service account with no ModifyAllData/ViewAllData/ViewEncryptedData). Returns sanitized JSON with a structured audit envelope. Live operational counterpart to the static-review skills. TRIGGER when: user asks to query records, run SOQL, fetch live data, inspect records by ID, count records, run aggregate queries, or check field values in a

Source repository stars
21
Declared platforms
0
Static risk flags
0
Last source update
2026-08-27
Source checked
2026-08-28

Decision brief

What it does: where it fits

Read-only live SOQL execution against a connected Salesforce org under T1 least-privilege scope. This skill is a flashlight, not a filing cabinet. It queries evidence; it does not write, deploy, or mutate anything.

Best for

    Not for

    • Tasks that require unconfirmed production actions or broad system permissions.
    • Environments where the pinned source and install steps cannot be inspected.

    Compatibility matrix

    Platform support, with evidence labels

    PlatformStatusEvidenceWhat to check
    CodexNot declaredNo explicit evidencePortability before use
    Claude CodeNot declaredNo explicit evidencePortability before use
    CursorNot declaredNo explicit evidencePortability before use
    Gemini CLINot declaredNo explicit evidencePortability before use
    Open the compatibility checker

    Installation

    Inspect first. Install second.

    The source command is displayed only when detected. A safe inspection prompt is always available so your agent can explain every action before execution.

    Source-detected install commandSource
    npx skills add https://github.com/VincentChuWaiChow/vanguard-frontier-agentic --skill "skills/salesforce/salesforce-soql-explorer-skill"
    Safe inspection promptEditorial

    Inspect the Agent Skill "salesforce-soql-explorer-skill" from https://github.com/VincentChuWaiChow/vanguard-frontier-agentic/blob/e01b936730332eca271896571d43cc2013c67f3f/skills/salesforce/salesforce-soql-explorer-skill/SKILL.md at commit e01b936730332eca271896571d43cc2013c67f3f. List every install step, command, network request, credential, file read/write, external action, and rollback step. Explain whether it fits my task. Do not install or execute anything until I approve.

    Workflow

    What the source asks the agent to do

    1. 01

      Recommended Workflow

      Verify: org type (production vs. sandbox), username, instance URL, OAuth Connected App. If the org type is production and the Connected App allowlist does not explicitly authorize this alias, stop (see Stop Conditions).

      Enumerate only required fields — no SELECTApply a selective WHERE clause using indexed fields (Id, Name, ExternalId,Include LIMIT (default 200; reduce for PII-adjacent queries)
    2. 02

      Step 1 — Confirm org alias and reachability

      Verify: org type (production vs. sandbox), username, instance URL, OAuth Connected App. If the org type is production and the Connected App allowlist does not explicitly authorize this alias, stop (see Stop Conditions).

      Verify: org type (production vs. sandbox), username, instance URL, OAuth Connected App. If the org type is production and the Connected App allowlist does not explicitly authorize this alias, stop (see Stop Conditions).
    3. 03

      Step 2 — Confirm sObject exists and check FLS

      Confirm: the sObject exists, the Run As account has Read access, and the requested fields are accessible (not restricted by FLS). If any field is encrypted (Shield PE / PMLE), remove it from the query and note the redaction.

      Confirm: the sObject exists, the Run As account has Read access, and the requested fields are accessible (not restricted by FLS). If any field is encrypted (Shield PE / PMLE), remove it from the query and note the redac…
    4. 04

      Step 3 — Generate the simplest correct query

      Apply these constraints: - Enumerate only required fields — no SELECT - Apply a selective WHERE clause using indexed fields (Id, Name, ExternalId, lookup fields, standard indexed fields) - Include LIMIT (default 200; reduce for PII-adjacent queries) - Avoid formula fields or non…

      Enumerate only required fields — no SELECTApply a selective WHERE clause using indexed fields (Id, Name, ExternalId,Include LIMIT (default 200; reduce for PII-adjacent queries)
    5. 05

      Step 4 — Preview with LIMIT 5 first

      Inspect output for: unexpected fields, encrypted placeholders, PII exposure, schema surprises. Confirm the shape matches the intent before expanding volume.

      Inspect output for: unexpected fields, encrypted placeholders, PII exposure, schema surprises. Confirm the shape matches the intent before expanding volume.

    Permission review

    Static risk signals and limitations

    No configured static risk pattern was detected

    This is not proof of safety. Runtime behavior, indirect dependencies, and hidden external systems are outside the static scan.

    Evidence record

    Why each signal appears

    EvidenceSourceComputedTestedEditorial
    SignalValueEvidence typeMeaning
    Quality score97/100ComputedDocumentation, specificity, maintenance, and trust rules
    Repository stars21SourceRepository attention, not individual Skill quality
    Compatibility0 platformsSourceDeclared in the catalog source record
    Usage guideautomated source guideEditorialGenerated or reviewed according to the visible evidence level

    Pinned source

    Provenance and original SKILL.md

    Repository
    VincentChuWaiChow/vanguard-frontier-agentic
    Skill path
    skills/salesforce/salesforce-soql-explorer-skill/SKILL.md
    Commit
    e01b936730332eca271896571d43cc2013c67f3f
    License
    Apache-2.0
    Collected
    2026-08-28
    Default branch
    master
    View the original SKILL.md

    salesforce-soql-explorer-skill

    Read-only live SOQL execution against a connected Salesforce org under T1 least-privilege scope. This skill is a flashlight, not a filing cabinet. It queries evidence; it does not write, deploy, or mutate anything.

    When This Skill Owns the Task

    Use salesforce-soql-explorer-skill when the work requires live record evidence from a connected org:

    • "Show me the Opportunity pipeline for Q3 in sandbox"
    • "How many Contacts have no email address?"
    • "What is the value of Account.BillingCountry for record 001Xx000001ABC?"
    • "Count open Cases by priority for the service team"
    • "Verify the field value changed after yesterday's data load"

    Delegate elsewhere when:

    SituationSkill to use
    User pastes metadata XML or deployment export for reviewsalesforce-metadata-review-skill
    Schema or field definitions needed without record valuessalesforce-metadata-fetcher-skill
    Request requires INSERT, UPDATE, DELETE, MERGE, or UPSERTT3 — requires human approval via salesforce-live-guard-agent
    Large-volume export (> 2,000 records) or scheduled batchsalesforce-bulk-data-ops-skill
    Static code review of a .soql file or Apex selectorquerying-soql (sf-skills)
    A change proposal emerges from findingsEscalate to salesforce-live-guard-agent
    Permission topology findings surfaceHand off to salesforce-permission-model-review-skill

    Required Context to Gather First

    Before executing any query, confirm:

    1. Target org alias — the --target-org value recognized by sf org list. Never accept a raw instance URL or session token.
    2. Org type — production or sandbox. Flag if production; apply stricter scrutiny on field selection and result volume.
    3. Target sObject — the API name (e.g., Account, Opportunity, My_Custom_Object__c).
    4. Fields needed — enumerate explicitly; do not use SELECT *.
    5. Filter criteria — WHERE clause conditions, date ranges, owner scope.
    6. Expected result volume — inform LIMIT choice.
    7. Sensitivity classification — does the query touch PII fields (email, phone, address, SSN, health, financial)? Regulated-vertical indicator (Health Cloud, Financial Services Cloud )? Encrypted fields (Shield PE / PMLE)?

    If any of these are missing, ask before proceeding.


    Recommended Workflow

    Step 1 — Confirm org alias and reachability

    sf org display --target-org <alias>
    

    Verify: org type (production vs. sandbox), username, instance URL, OAuth Connected App. If the org type is production and the Connected App allowlist does not explicitly authorize this alias, stop (see Stop Conditions).

    Step 2 — Confirm sObject exists and check FLS

    sf sobject describe --sobject <SObjectName> --target-org <alias>
    

    Confirm: the sObject exists, the Run As account has Read access, and the requested fields are accessible (not restricted by FLS). If any field is encrypted (Shield PE / PMLE), remove it from the query and note the redaction.

    Step 3 — Generate the simplest correct query

    Apply these constraints:

    • Enumerate only required fields — no SELECT *
    • Apply a selective WHERE clause using indexed fields (Id, Name, ExternalId, lookup fields, standard indexed fields)
    • Include LIMIT (default 200; reduce for PII-adjacent queries)
    • Avoid formula fields or non-indexed fields in WHERE without a companion indexed filter

    Step 4 — Preview with LIMIT 5 first

    sf data query \
      --query "SELECT <fields> FROM <SObject> WHERE <filter> LIMIT 5" \
      --target-org <alias> \
      --result-format json
    

    Inspect output for: unexpected fields, encrypted placeholders, PII exposure, schema surprises. Confirm the shape matches the intent before expanding volume.

    Step 5 — Execute with appropriate LIMIT

    sf data query \
      --query "SELECT <fields> FROM <SObject> WHERE <filter> LIMIT <n>" \
      --target-org <alias> \
      --result-format json
    

    Maximum interactive LIMIT: 2,000. For larger volumes, decline and route to salesforce-bulk-data-ops-skill.

    Step 6 — Sanitize output

    Apply redaction rules before emitting any output:

    • Replace all 15/18-character Salesforce Ids with <org_id_placeholder> or <record_id_placeholder> as appropriate.
    • Replace user IDs (User.Id references, OwnerId, CreatedById, LastModifiedById) with <user_id_placeholder>.
    • Remove or mask any field that contains plaintext email, phone, SSN, or financial account numbers unless the user has explicitly acknowledged the PII scope and the org is not regulated.
    • Skip any encrypted field (Shield PE / PMLE) entirely — do not include placeholder text that implies a value was present.
    • Never emit OAuth tokens, refresh tokens, or session IDs.

    Use jq for structured redaction:

    sf data query \
      --query "SELECT Id, Name FROM Account LIMIT 5" \
      --target-org <alias> \
      --result-format json \
      | jq '.result.records[] | {Id: "<record_id_placeholder>", Name: .Name}'
    

    Step 7 — Emit audit envelope

    Every execution must produce a structured audit envelope (see Audit Envelope Schema below). Do not omit the envelope even if results are empty.

    Step 8 — Hand off to review skill if findings warrant

    If query results surface access anomalies, unexpected field values, or policy violations, hand off to the appropriate review skill with the sanitized results and the audit envelope as the input payload. Do not escalate raw unsanitized output.


    Quality Scoring Rubric (100-point)

    Score the query design and execution quality before emitting results. Threshold: 80+ acceptable, 60–79 emit with caveat, below 60 reject and request revision.

    DimensionPointsWhat earns full marks
    Selectivity30WHERE clause uses at least one indexed field; no full table scans on objects > 10k records
    Field minimality20Only required fields enumerated; no SELECT *; no encrypted fields included
    Governor limit awareness20LIMIT applied and appropriate to volume; no queries likely to exceed 50k row limit; aggregate used when count is the goal
    Redaction quality15All Salesforce IDs, user IDs, PII fields redacted per rules; audit envelope populated
    Audit envelope completeness15All required audit fields present; query text hash computed; timestamp accurate

    Scoring penalties:

    • No WHERE clause on object with > 50k records: -20
    • SELECT *: -15
    • Missing LIMIT: -15
    • Missing audit envelope: -20 (automatic caveat regardless of total score)
    • Encrypted field included in output: immediate reject (score voided)

    T1 Least-Privilege Contract

    This skill operates exclusively at T1 — read-only runtime. The contract is:

    • OAuth scopes used: api and refresh_token only. No full, web, sfap_api, cdp_query_api, or any other scope.
    • Run As account profile: System permissions: View Setup and Configuration only. Object permissions: Read only on objects in scope. FLS restricted to non-PII, non-encrypted fields by default.
    • Denied permissions (enforced at Connected App and profile level):
      • Modify All Data
      • View All Data (system-level bypass)
      • View Encrypted Data
      • Modify Metadata Through Metadata API Functions
      • Author Apex
      • Customize Application
      • Manage Connected Apps
    • Org allowlist: Enforced by Connected App IP restrictions and explicit org alias allowlist. Skill verifies via sf org list that the target alias is in the authorized set before executing any query.
    • No DML under any circumstances: This skill will not construct or execute any statement containing INSERT, UPDATE, DELETE, MERGE, or UPSERT. Requests for DML must be refused and routed to the human approval path.
    • Revocation: The least-privilege Run As account's refresh token can be rotated to instantly revoke all access without affecting other integrations.

    Refusal Triggers

    Stop immediately and do not execute if:

    • The target org appears to be production but the Connected App allowlist does not include it.
    • The requested SOQL contains DML keywords: INSERT, UPDATE, DELETE, MERGE, UPSERT (case-insensitive).
    • The query targets fields marked as encrypted (Shield PE / PMLE indicators in the describe output: encrypted: true).
    • The audit envelope cannot be populated (matter_id missing, org alias unresolvable, run_as_user_id unavailable).
    • The user requests that redaction be skipped or disabled.
    • The org is identified as a regulated-vertical production org (Health Cloud, Financial Services Cloud ) and jurisdiction is unknown.
    • The query result volume exceeds 2,000 records in interactive mode — route to bulk ops instead.
    • The Run As account is missing the required View Setup and Configuration permission (verify via sf org display output).

    Audit Envelope Schema

    Every execution emits an audit envelope. The envelope travels with the sanitized output to any downstream review skill.

    audit_envelope:
      matter_id: "<caller-provided-or-generated-uuid>"
      skill_id: "salesforce-soql-explorer-skill"
      skill_version: "0.1.0"
      target_org_alias: "<alias>"             # never the raw org ID
      run_as_user_id: "<user_id_placeholder>" # placeholder; never real ID in output
      query_text_hash: "<sha256-of-query>"    # hash only if PII risk; else include query
      query_text: "<soql-string-or-redacted>" # omit if PII risk; include hash instead
      record_count: <integer>
      redactions_applied:
        - field: "<FieldApiName>"
          reason: "<pii|encrypted|org_id|user_id>"
      timestamp: "<ISO-8601-UTC>"
      org_type_verified: "sandbox | production"
      governor_limit_headroom: "<estimated-rows-vs-limit>"
    

    Output Format

    verdict: "acceptable | caveat | reject"
    quality_score: <0-100>
    quality_notes: "<what drove the score>"
    
    records:
      - <sanitized record objects>
    
    metadata:
      record_count: <integer>
      sObject: "<SObjectApiName>"
      fields_queried: ["<field1>", "<field2>"]
      fls_notes: "<any FLS restrictions observed>"
      fields_skipped_encrypted: ["<field>"]   # if any
    
    audit_envelope:
      <see Audit Envelope Schema>
    
    escalation_triggers_fired:
      - "<trigger name or 'none'>"
    
    missing_evidence:
      - "<what would strengthen the query or findings>"
    
    assumptions:
      - "<explicit list of assumptions made>"
    

    Redaction Rules

    Apply in order. Do not bypass for any reason.

    1. OAuth tokens, refresh tokens, session IDs: Never include in any output, log, or audit envelope field. If they appear in CLI output, strip before emitting.
    2. Salesforce Org IDs (18-char starting with 00D): Replace with <org_id_placeholder>.
    3. Salesforce Record IDs (15/18-char): Replace with <record_id_placeholder> in output records.
    4. User IDs (OwnerId, CreatedById, LastModifiedById, User.Id): Replace with <user_id_placeholder>.
    5. Encrypted fields (Shield PE / PMLE): Skip entirely — do not emit the field name or any placeholder that implies a value was retrieved. List skipped fields in fields_skipped_encrypted.
    6. PII fields (email, phone, SSN, health data, financial account numbers): Mask or omit unless the user has explicitly acknowledged the PII scope, the org is non-production, and the matter classification permits. Document the acknowledgment in assumptions.
    7. Instance URLs and API endpoints: Omit from output; reference only the org alias in the audit envelope.

    Handoff Rules

    When findings from query results warrant further review, hand off to the appropriate skill with the sanitized output and audit envelope as the payload:

    Finding typeHand off to
    Metadata anomalies (field config, object structure)salesforce-metadata-review-skill
    Access or permission findings (unexpected record visibility)salesforce-permission-model-review-skill
    A change proposal emerges from query evidencesalesforce-live-guard-agent
    Org posture concern from query resultssalesforce-org-assessment-skill

    Required handoff fields: matter_id, audit_envelope, sanitized_records (summary — not full dump), escalation_triggers_fired, missing_evidence, assumptions.


    Stop Conditions

    Stop and do not continue if:

    • Target org appears to be production but Connected App allowlist excludes it — stop, emit a refusal with reason, do not execute query.
    • Query contains DML keywords (INSERT, UPDATE, DELETE, MERGE, UPSERT) — stop, emit a refusal, route to human approval path.
    • Query targets encrypted fields (encrypted: true in describe output) — remove fields and warn, or stop if the user insists on including them.
    • Audit envelope cannot be completed (missing matter_id or unresolvable org alias) — stop until resolved.
    • Run As account is missing View Setup and Configuration — stop and escalate to org administrator.
    • Result volume would exceed 2,000 records in interactive mode — stop and route to salesforce-bulk-data-ops-skill.
    • The user requests redaction be disabled — stop and explain the policy.

    Security Notes

    • T1 read-only operational: No DML, no metadata mutation, no Apex execution, no deployment.
    • Sanitized output only: All Salesforce IDs, user IDs, and PII fields redacted before emission.
    • Org allowlist enforced: Connected App restricts which orgs can be targeted; skill verifies before executing.
    • Structured audit emitted: Every execution produces a complete audit envelope regardless of result count.
    • Revocable: Rotating the Run As account's refresh token immediately revokes all access without affecting other integrations.
    • Least-privilege Run As account: No Modify All Data, View All Data, View Encrypted Data, or any mutation permission.
    • No credential echo: OAuth tokens, refresh tokens, and session IDs are never included in output or audit envelopes.
    • Regulated-vertical escalation: Health Cloud and Financial Services Cloud orgs trigger mandatory escalation to a qualified compliance specialist before results are shared externally.

    Reference File Index

    FileWhen to read
    references/cli-commands.mdsf CLI query commands, output formats, jq patterns, org introspection
    references/least-privilege-scope.mdConnected App config, Run As profile design, denied permissions, token rotation
    references/safe-query-patterns.mdSafe SOQL patterns, indexing rules, anti-patterns, annotated examples

    Frequently asked questions

    What to verify before installation and use

    What does the salesforce-soql-explorer-skill source document cover?

    Read-only live SOQL execution against a connected Salesforce org under T1 least-privilege scope. This skill is a flashlight, not a filing cabinet. It queries evidence; it does not write, deploy, or mutate anything.

    How do I install salesforce-soql-explorer-skill?

    The source record exposes this install command: npx skills add https://github.com/VincentChuWaiChow/vanguard-frontier-agentic --skill "skills/salesforce/salesforce-soql-explorer-skill". Inspect the command and pinned source before running it.

    Alternatives

    Compare before choosing

    Computed 10029,236

    garrytan/gbrain

    bulk-ingestion

    End-to-end discipline for turning any large data source (audio libraries, email takeouts, document corpora, chat exports, API dumps) into brain pages at scale. The lifecycle spine: SCHEMA → ACCESS → TRIAL → EVALUATE → IMPROVE → CODIFY → TEST → SKILLIFY → BULK → MONITOR. State is tracked in a durable JSON manifest (see MANIFEST-PATTERN.md) so any crash, session boundary, or subagent fan-out resumes from ground truth instead of memory.

    Computed 10025,136

    alirezarezvani/claude-skills

    app-store-optimization

    App Store Optimization (ASO) toolkit for researching keywords, analyzing competitor rankings, generating metadata suggestions, and improving app visibility on Apple App Store and Google Play Store. Use when the user asks about ASO, app store rankings, app metadata, app titles and descriptions, app store listings, app visibility, or mobile app marketing on iOS or Android. Supports keyword research and scoring, competitor keyword analysis, metadata optimization, A/B test planning, launch checklist

    Computed 1005,277

    dotnet/skills

    migrate-vstest-to-mtp

    Migrates .NET test projects from VSTest to Microsoft.Testing.Platform (MTP). Use when user asks to "migrate to MTP", "switch from VSTest", "enable Microsoft.Testing.Platform", "use MTP runner", set OutputType=Exe only for test projects in Directory.Build.props, or mentions EnableMSTestRunner, EnableNUnitRunner, or UseMicrosoftTestingPlatformRunner. USE FOR: MTP behavioral differences vs VSTest (exit code 8, zero tests discovered, --ignore-exit-code, TESTINGPLATFORM_EXITCODE_IGNORE); centralizing

    Computed 100147

    oaustegard/claude-skills

    featuring

    Generate hierarchical _FEATURES.md files that describe what a codebase DOES from a user/consumer perspective, anchored to source symbols via tree-sitting. Supports large complex codebases through feature-driven decomposition into sub-feature files. Uses a multi-pass synthesis: orientation → detail → overview rewrite. Use when someone says "what does this do", "document features", "feature inventory", "_FEATURES.md", or needs to understand a codebase's purpose before modifying it. Complements tre