Skip to content

3.0.1

Choose a tag to compare

@ilvalerione ilvalerione released this 25 Feb 17:17
· 69 commits to 3.x since this release

Eloquent workflow persistence

Thanks to @jamosaur for PR #497

Create a WorkflowInterrupt model:

class WorkflowInterrupt extends Model
{    
    protected $fillable = ['workflow_id', 'interrupt'];
}

Use it with workflow:

use App\Models\WorkflowInterrupt;
use NeuronAI\Workflow\Persistence\EloquentPersistence;

// Creating a workflow
$workflow = WorkflowAgent(
    persistence: new EloquentPersistence(WorkflowInterrupt::class)
);

Migration script and code snippets in the documentation.