Salesforce Decode
Salesforcedecode
Back to questions
AgentforceAdvancedversioningcicdagent-actionsdeployment

Implement agent action versioning with safe rollback in production

Real World Scenario

A loyalty points redemption action was updated Friday evening; by Saturday morning agents double-credited thousands of accounts. Leadership requires versioned actions with instant rollback.

Expected Answer

• Version agent actions and invocable Apex with semantic versioning stored in custom metadata • Deploy action changes through sandbox regression suites tied to specific agent topic versions • Support blue-green agent configs: route small traffic percentage to new action version before full cutover • Implement idempotency keys on all write actions so retries and rollbacks do not duplicate effects • Maintain action changelog with owner, approval record, and linked test run IDs • Rollback agent config to prior snapshot without redeploying Apex when issue is prompt-only • Alert on anomalous action error rates and business metric spikes within minutes of deploy

Follow-Up Questions & Answers

Click to expand — each follow-up includes a direct, interview-ready answer

Direct answer: Version agent actions and invocable Apex with semantic versioning stored in custom metadata Also consider: Deploy action changes through sandbox regression suites tied to specific agent topic versions In practice: Support blue-green agent configs: route small traffic percentage to new action version before full cutover Optimize for scale and operational observability.

Architect Perspective

Agent actions are production APIs with probabilistic callers. Apply the same release discipline as payment services—versioned contracts, canary traffic, and compensating transactions.