generate_api_resource
Create a Laravel API Resource class with relationships, meta, pagination, and conditional field loading.
Instructions
Generate a Laravel 13 API Resource with relationships, meta, pagination, and conditional loading.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fields | No | ||
| withMeta | No | ||
| modelClass | Yes | Full model class e.g. 'App\Models\Post' | |
| resourceName | Yes | Resource name e.g. 'PostResource' | |
| relationships | No | ||
| withPagination | No |