Download the PHP package whilesmart/eloquent-webhooks without Composer
On this page you can find all versions of the php package whilesmart/eloquent-webhooks. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download whilesmart/eloquent-webhooks
More information about whilesmart/eloquent-webhooks
Files in whilesmart/eloquent-webhooks
Package eloquent-webhooks
Short Description Webhook management package for Laravel applications
License MIT
Informations about the package eloquent-webhooks
Eloquent Webhooks
A comprehensive webhook management package for Laravel applications. Easily manage, track, and process incoming webhooks with built-in support for workspace and project scoping.
Features
- Webhook Management: Complete CRUD operations for webhooks.
- Secure Ingress: Automatic token generation for secure, unique webhook endpoints.
- Event Tracking: Logs all incoming webhook payloads, headers, and processing status.
- Scoped by Default: Built-in support for User, Workspace, and Project scoping.
- Flexible Integration: Seamlessly integrates with other WhileSmart packages like
eloquent-workspaces,projects, andactivities. - API Ready: Comes with pre-configured controllers and routes for rapid development.
Installation
You can install the package via composer:
You should publish and run the migrations with:
You can publish the config file with:
This is the contents of the published config file:
Usage
Managing Webhooks
The package provides a Webhook model that you can use to manage your webhooks.
Webhook Ingress
Incoming webhooks are sent to a unique URL containing a secure token. When a webhook is triggered:
- The token is validated.
- The
trigger_countandlast_triggered_atfields are updated. - A
WebhookEventis recorded containing the payload and headers. - If
whilesmart/activitiesis installed, an activity log is automatically created.
API Endpoints
By default, the package registers the following routes (protected by auth:sanctum):
Management Routes
GET /webhooks: List all webhooks for the authenticated user.POST /webhooks: Create a new webhook.GET /webhooks/{id}: Get webhook details.PATCH /webhooks/{id}: Update a webhook (or regenerate its token).DELETE /webhooks/{id}: Soft delete a webhook.GET /webhooks/{id}/events: List event history for a webhook.
Workspace-Scoped Routes
GET /workspaces/{workspaceId}/webhooksPOST /workspaces/{workspaceId}/webhooks- ... (and other CRUD operations prefixed with workspace)
Testing
Changelog
Please see CHANGELOG for more information on what has changed recently.
License
The MIT License (MIT). Please see License File for more information.
All versions of eloquent-webhooks with dependencies
laravel/framework Version ^12.0
whilesmart/eloquent-workspaces Version ^1.0
whilesmart/eloquent-projects Version dev-main