bluebeetle/api-toolkit

JSON:API compliant toolkit for building REST APIs with Laravel.
3,954 14
Install
composer require bluebeetle/api-toolkit
Latest Version:v0.8.3
PHP:^8.4
License:MIT
Last Updated:Sep 14, 2026
Links: GitHub  ·  Packagist
Maintainer: brunogaspar

API Toolkit

Tests Code Analysis License

JSON:API compliant toolkit for building REST APIs with Laravel.

Installation

composer require bluebeetle/api-toolkit

Quick Start

Define a resource:

final class ProductResource extends Resource
{
    protected string $model = Product::class;

    public function attributes(Product $product): array
    {
        return [
            'name' => $product->name,
            'code' => $product->code,
        ];
    }
}

Use it in a controller:

final class ListController
{
    public function __invoke(Request $request)
    {
        return QueryBuilder::for(Product::class, $request)
            ->fromResource(ProductResource::class)
            ->paginate();
    }
}

Documentation

Full documentation is available at bluebeetle.pt/open-source/docs/api-toolkit.

Testing

composer test

Credits

License

Licensed under the MIT license.

Related Packages

cloudcreativity/laravel-json-api

JSON API (jsonapi.org) support for Laravel applications.

1,100,385 785
threesquared/laravel-wp-api

Laravel package for the Wordpress JSON REST API

10,364 13
pixelpeter/laravel5-woocommerce-api-client

Laravel 5 wrapper for the Woocommerce REST API

106,676 123
marcelgwerder/laravel-api-handler

Package providing helper functions for a Laravel REST-API

94,344 155
sdv/laravel-endpoint

Laravel Endpoint is a CRUD REST API package for Laravel.

18,791 11