2015-10-29 00:47:40 +01:00
|
|
|
<?php
|
|
|
|
$app->group('/user', function () use ($app) {
|
|
|
|
|
2015-10-31 03:20:35 +01:00
|
|
|
$app->get('/get/(:by)/(:value)', function () use ($app) {
|
|
|
|
echo "Returns the user with $by = $value as a json";
|
|
|
|
});
|
|
|
|
|
|
|
|
$app->post('/login', function () use ($app) {
|
|
|
|
// $app->response()->setStatus(400);
|
|
|
|
$app->response()->setBody('{ "response": true }');
|
|
|
|
});
|
|
|
|
|
|
|
|
$app->post('/add', function () use ($app) {
|
2015-10-29 00:47:40 +01:00
|
|
|
echo "You have the new";
|
|
|
|
});
|
|
|
|
});
|