The Technical Playbook: Wiring Archetypes to Agent Actions

Bridging the Gap Between Intent and the Ledger

An Archetype is just a blueprint. To make it functional, we must give the Agentforce LLM the "hands" to execute it. In an agent-first architecture, we do not build UI wizards; we build headless OmniStudio Integration Procedures (IPs) and register them as Agent Actions.

Here is the exact technical sequence for turning a Commercial Archetype into an autonomous AI execution pathway.

Step 1: Build the Headless Engine (OmniStudio)

The LLM cannot update databases directly; it can only format text and pass JSON. You must build an OmniStudio Integration Procedure (IP) or Invocable Apex class to handle the actual API chaining, DML operations, and system integrations.

Architectural Component Role in the Agent-First Framework
The Input Schema The exact JSON structure the IP requires. This perfectly mirrors the required parameters of your chosen Commercial Archetype (e.g., Start Date, Term Length, Product ID).
The Execution Logic The sequential API calls. The IP receives the JSON, hits the RLM Pricing Procedure, creates the Quote object, and generates the line items.
The Output Payload The success or failure response passed back to the LLM. (e.g., "Success: Quote Q-00123 generated with a Net Total of $5,000.")

Step 2: Register the Agent Action

Once the headless IP is built, you must expose it to the Agentforce brain. You register the IP as a standard Agent Action. The critical component here is the Action Description—this is how the LLM knows when to use it.

Archetype Example The LLM Action Description (The Trigger)
Hardware Upgrade Archetype "Use this action when a user explicitly asks to upgrade, add, or replace a physical hardware node. Requires AccountId, Quantity, and Shipping Region."
Usage-Based Archetype "Use this action when a user wants to purchase a metered consumption or telemetry plan. Requires Base Tier, Projected Volume, and Overage Rate."

Step 3: Grounding the Payload (Matrix Integration)

Before the LLM is allowed to fire the Action, it must check the Commercial Matrix to ensure the user's request is legally and mathematically sound.