Resource API Generator
Generate APIs from your Filament resource using single line of code
Author:
Fady Mondy
Documentation

Generate APIs from your filament resource using single line of code
#Installation
make sure that you have SQLite3 Driver installed on your PHP config, because this package required it for caching.
composer require tomatophp/filament-api
if you want to use API Resource to list your generated APIs you can register the plugin on /app/Providers/Filament/AdminPanelProvider.php
->plugin(\TomatoPHP\FilamentApi\FilamentAPIPlugin::make())
#Screenshots

#Usage
you can generate API by add this trait to your resource pages
use TomatoPHP\FilamentApi\Traits\InteractWithAPI;
use \Filament\Resources\Pages\ListRecords;
class ListPosts extends ListRecords
{
use InteractWithAPI;
}
and that's it you can now access your API by /api/{slug}
we provide 5 methods:
- GET
/api/{slug}to list all recordssupport searching by use search= - GET
/api/{slug}/{id}to get single record - POST
/api/{slug}to create new record - PUT
/api/{slug}/{id}to update record - DELETE
/api/{slug}/{id}to delete record
#Custom your API
you can customize your api by override this methods
// Use to return API JSON Resource on Index/Show/Store/Update
public static function getFilamentAPIResource(): ?string
{
return null;
}
// Use To Custom Your Route Middleware
public static function getFilamentAPIMiddleware(): array
{
return config('filament-api.default_middleware');
}
// Use To Change the Endpoint Slug
public static function getFilamentAPISlug(): ?string
{
return null;
}
#Publish Assets
you can publish config file by use this command
php artisan vendor:publish --tag="filament-api-config"
#Other Filament Packages
checkout our Awesome TomatoPHP
The author
Generate APIs from your Filament resource using single line of code
From the same author
Discord Notifications
Send notifications to a Discord channel using the native FilamentPHP Notification Facade class
Author:
Fady Mondy
Tenancy Multi-database
Tenancy multi-database integration for FilamentPHP
Author:
Fady Mondy
Menu Generator
Menu view generator using view component
Author:
Fady Mondy
Translations Manager
Manage your translation with DB and cache, you can scan an collect translation strings like `trans()` and `__()`, and translate them using UI
Author:
Fady Mondy
Featured Plugins
A selection of plugins curated by the Filament team
Custom Dashboards
Let your users build and share their own dashboards with a drag-and-drop interface. Define your data sources in PHP and let them do the rest.
Filament
Data Lens
Advanced Data Visualization for Laravel Filament - a premium reporting solution enabling custom column creation, sophisticated filtering, and enterprise-grade data insights within admin panels.
Padmission
Advanced Tables (formerly Filter Sets)
Supercharge your tables with powerful features like user-customizable views, quick filters, multi-column sorting, advanced table searching, convenient view management, and more. Compatible with Resource Panel Tables, Relation Managers, Table Widgets, and Table Builder!
Kenneth Sese