Skip to main content
Business logic is organized into service objects under app/services/. This keeps controllers thin and models focused on data.

Service organization

Key service categories

Brands (/brands/)

Critical: Always use Brands::PipelineStatusChange to change brand status:

Campaigns (/campaigns/)

Creators (/creators/)

Rejection flow:

Metrics (/metrics/)

Ingestion flow:

Chat (/chat/)

Notifications (/notifications/)

Notification dispatch:

Integrations (/integrations/)

Service patterns

Single responsibility

Each service handles one operation:

Transaction safety

Services wrap mutations in transactions:

Return values

Services return meaningful results:

Calling services

From controllers:
From jobs:

Testing services

Services have dedicated tests in test/services/: