Base API, and more solid key and check
This commit is contained in:
20
app/src/Controller/API/Base.php
Normal file
20
app/src/Controller/API/Base.php
Normal file
@ -0,0 +1,20 @@
|
||||
<?php
|
||||
namespace Incoviba\Controller\API;
|
||||
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use Psr\Http\Message\ServerRequestInterface;
|
||||
use Incoviba\Common\Ideal\Controller;
|
||||
|
||||
class Base extends Controller
|
||||
{
|
||||
use withJson;
|
||||
|
||||
public function __invoke(ServerRequestInterface $request, ResponseInterface $response): ResponseInterface
|
||||
{
|
||||
$output = [
|
||||
'version' => '2.0.0',
|
||||
'organization' => 'Ingenieria y Construccion Vial Balmaceda Sociedad Anonima'
|
||||
];
|
||||
return $this->withJson($response, $output);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user