Salesforce Automation Framework

A trigger framework, error logger, and flow template kit, deployed straight from source with the sf CLI.

Introduction

Getting Started

The Salesforce Automation Framework is a trigger framework, error logger, and set of flow templates for building automation on the Salesforce platform. It is not a managed or unlocked package. It deploys straight from source using the sf CLI, so every class ships in your org's namespace and is free to extend.

Installation

Deploy the framework into an org with the sf CLI or a release zip.

Trigger Framework

Custom-metadata-driven trigger pipelines and handlers.

Error Logger

Log exceptions to a queryable Error_Log__c record.

Flow Templates

Before/after-save and before-delete record-triggered flow starting points.


What's included

  • Trigger Framework: a TriggerPipeline entry point plus an ATriggerHandler base class, driven by Trigger_Pipeline__mdt and Trigger_Handler__mdt custom metadata so handlers can be added, removed, or reordered without touching a trigger.
  • Error Logger: a single ErrorLogger.logError() call that writes an Error_Log__c record, ready to page through in a list view or route with a flow.
  • Flow templates: six Record-Triggered Flow templates covering before-save, after-save, and before-delete, each with a with-bypass and without-bypass variant.
  • Bypass permissions: Exclude_Trigger and Exclude_Flow custom permissions, plus an Exclude_User permission set group, so integration users can skip automation without special-casing them in code.

Resources

License

The Salesforce Automation Framework is available as open source under the terms of the MIT License.

Change Log

See the change log for release history.


Getting help

Contributing

Bug reports, feature requests, and pull requests are welcome on GitHub at chiefpansancolt/salesforce-automation-framework. See how to contribute for details.

Join the community

Join the Discord server to ask questions or talk through a trigger pipeline design.