Icons API is a Laravel application that exposes a public, read-only endpoint for browsing an icon library — searching by keyword and filtering by icon library or brand status.
Public, unauthenticated, CORS-enabled for any origin. Returns a paginated list of icons.
Query parameters
| Parameter | Description |
|---|---|
keyword |
Full-text search against each icon's name and keywords. |
filters[i][name] |
Column to filter by — library or is_brand. |
filters[i][value] |
Value to filter by. |
filters[i][active] |
Set to true to apply the filter. |
per_page |
Results per page (capped at 100). |
sortField / sortDirection |
Field and direction (asc/desc) to sort by. |
Example
GET /api/icons?keyword=home&filters[0][name]=library&filters[0][value]=fontawesome&filters[0][active]=true&per_page=20
Response
{
"status": 200,
"message": "1 items found",
"data": {
"countItems": 1,
"result": {
"data": [
{
"id": 1,
"slug": "fontawesome.home",
"library": "fontawesome",
"is_brand": false,
"name": "home",
"tag": "dile-fontawesome-icon-home",
"import": "@dile/iconlib/fontawesome-icons/home.js",
"svg": "<svg ...></svg>",
"keywords": ["house", "residence"]
}
]
}
}
}Each icon includes its raw svg markup alongside descriptive metadata (library, is_brand, name, tag, import, keywords).
- Laravel 13, PHP 8.3+
- MySQL, with a
FULLTEXTindex powering keyword search escuelait/laravel-api-kitfor listing, filtering, and paginationnegartarh/apiwrapperfor the standardized JSON response envelope
composer install
cp .env.example .env
php artisan key:generateConfigure your database credentials in .env, then run:
php artisan migrateIf you're using Laravel Sail:
./vendor/bin/sail up -d
./vendor/bin/sail artisan migratephp artisan test