Skip to main content
Version: 1.0.0

Getting Started

Guardrails plugs a human approval layer into your Laravel app so risky actions pause until the right people sign off.

Install

  1. Register provider in config/app.php:
OVAC\\Guardrails\\GuardrailsServiceProvider::class,
  1. Publish and migrate:
php artisan vendor:publish --provider="OVAC\\Guardrails\\GuardrailsServiceProvider" --tag=guardrails-config
php artisan vendor:publish --provider="OVAC\\Guardrails\\GuardrailsServiceProvider" --tag=guardrails-migrations
php artisan migrate
  1. Optional: publish views and docs
php artisan vendor:publish --provider="OVAC\\Guardrails\\GuardrailsServiceProvider" --tag=guardrails-views
php artisan vendor:publish --provider="OVAC\\Guardrails\\GuardrailsServiceProvider" --tag=guardrails-docs

Configure

Edit config/guardrails.php to set API prefixes, middleware, and policy names. Guardrails defaults to your app’s auth.defaults.guard (typically web). Set GUARDRAILS_AUTH_GUARD if approvals should use another guard such as sanctum.

UI

Visit /\{page_prefix\} (default guardrails) for a minimal review UI.