Initial baseline: LaraBlog core with plugin commerce surface.
Captures the current working tree after theme slots, ArticleAccess, and the payment / paid-content plugins so subsequent work has a reviewable git history.
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\Http\Controllers\Api\V1;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Settings\GeneralSettings;
|
||||
use App\Settings\SeoSettings;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
|
||||
class MetaController extends Controller
|
||||
{
|
||||
public function show(GeneralSettings $general, SeoSettings $seo): JsonResponse
|
||||
{
|
||||
return response()->json([
|
||||
'name' => $general->site_name,
|
||||
'url' => $general->site_url,
|
||||
'description' => $general->site_description,
|
||||
'theme' => $general->active_theme,
|
||||
'seo' => [
|
||||
'default_description' => $seo->default_description,
|
||||
'default_keywords' => $seo->default_keywords,
|
||||
'robots_index' => $seo->robots_index,
|
||||
],
|
||||
'api' => [
|
||||
'version' => 'v1',
|
||||
'openapi' => url('/docs/api/openapi.yaml'),
|
||||
],
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user