aboutsummaryrefslogtreecommitdiffhomepage
path: root/api/Posts/routes.php
blob: c3b90e46c023da78dc4029146be347709f465478 (plain) (blame)
1
2
3
4
5
6
7
<?php
// type [text, media] as get parameter (/posts?type=media,text) 
$router->get('/posts', 'PostController@getAll');
$router->get('/posts/{id}', 'PostController@getById');
$router->post('/posts', 'PostController@create');
$router->put('/posts/{id}', 'PostController@update');
$router->delete('/posts/{id}', 'PostController@delete');