apiDoc
laravel5

laravel apidoc

laravel apidoc

<?php
/**
 * @api {get} /posts/:id posts get
 * @apiVersion 0.1.0
 * @apiName posts get
 * @apiGroup posts
 *
 * @apiParam {Number} id posts id.
 *
 * @apiSuccess {String} post post.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 *     {
 *       "post": "post"
 *     }
 *
 * @apiError PostNotFound .
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *     {
 *       "error": "PostNotFound"
 *     }
 */

 /**
 * @api {post} /posts posts post
 * @apiVersion 0.1.0
 * @apiName posts post
 * @apiGroup posts
 *
 * @apiParam {Number} id posts id.
 *
 * @apiSuccess {String} post post.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 *     {
 *       "post": "post"
 *     }
 *
 * @apiError PostNotFound .
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 404 Not Found
 *     {
 *       "error": "PostNotFound"
 *     }
 */
namespace App\Http\Controllers;

use Illuminate\Http\Request;

class PostsController extends Controller
{
    //
}
mkdir doc
apidoc -i app/Http/Controllers/ -o doc/