yapi/static/doc/api.html
2017-08-11 16:16:16 +08:00

4446 lines
174 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta name="format-detection" content="telephone=no,email=no" />
<meta http-equiv="X-UA-Compatible" content="ie=edge, chrome=1">
<meta name="description" content="description of your site">
<meta name="author" content="author of the site">
<title>YApi </title>
<link rel="stylesheet" href="source/main.css" />
</head>
<body>
<div class="ydoc">
<header class="ydoc-header">
<div class="ydoc-header-area">
<a href="http://ued.qunar.com/ymfe/" class="navbar-brand">YMFE</a>
<button class="ydocIcon navbar-toggle">&#xf020;</button>
<nav class="ydoc-nav">
<ul class="navbar-left">
<li class="">
<a href="index.html">首页</a>
</li>
<li class="">
<a href="interface.html">接口管理</a>
</li>
<li class="">
<a href="mock.html">Mock功能</a>
</li>
<li class="active">
<a href="api.html"></a>
</li>
</ul>
</nav>
</div>
</header>
<!-- <header style="height:20px"></header> -->
<!-- Docs page layout -->
<div class="ydoc-banner-bg">
<div class="ydoc-banner ">
<div class="ydoc-banner-area">
<h1 >api</h1>
<p class="desc ">api文档</p>
</div>
</div>
<div class="ydoc-container">
<div class="ydoc-container-content ">
<div class="content-left staticsidenav" role="complementary">
<nav class="docs-sidebar hidden-print hidden-xs hidden-sm">
<ul class="nav docs-sidenav">
<!-- <li > -->
<li >
<a href="#group">group</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-group-add">/group/add</a>
</li>
<li >
<a href="#-group-list">/group/list</a>
</li>
<li >
<a href="#-group-del">/group/del</a>
</li>
<li >
<a href="#-group-up">/group/up</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#user">user</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-user-login">/user/login</a>
</li>
<li >
<a href="#-user-logout">/user/logout</a>
</li>
<li >
<a href="#-user-change_password">/user/change_password</a>
</li>
<li >
<a href="#-user-reg">/user/reg</a>
</li>
<li >
<a href="#-user-list">/user/list</a>
</li>
<li >
<a href="#-user-find">/user/find</a>
</li>
<li >
<a href="#-user-del">/user/del</a>
</li>
<li >
<a href="#-user-update">/user/update</a>
</li>
<li >
<a href="#-user-upload_avatar">/user/upload_avatar</a>
</li>
<li >
<a href="#-user-avatar">/user/avatar</a>
</li>
<li >
<a href="#-user-search">/user/search</a>
</li>
<li >
<a href="#-user-project">/user/project</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#project">project</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-project-add">/project/add</a>
</li>
<li >
<a href="#-project-add_member">/project/add_member</a>
</li>
<li >
<a href="#-project-del_member">/project/del_member</a>
</li>
<li >
<a href="#-project-get_member_list">/project/get_member_list</a>
</li>
<li >
<a href="#-project-get">/project/get</a>
</li>
<li >
<a href="#-project-list">/project/list</a>
</li>
<li >
<a href="#-project-del">/project/del</a>
</li>
<li >
<a href="#-project-up">/project/up</a>
</li>
<li >
<a href="#-project-search">/project/search</a>
</li>
<li >
<a href="#-project-download">/project/download</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#interface">interface</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-interface-add">/interface/add</a>
</li>
<li >
<a href="#-interface-get">/interface/get</a>
</li>
<li >
<a href="#-interface-list">/interface/list</a>
</li>
<li >
<a href="#-interface-up">/interface/up</a>
</li>
<li >
<a href="#-interface-del">/interface/del</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#follow">follow</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-follow-list">/follow/list</a>
</li>
<li >
<a href="#-follow-list">/follow/list</a>
</li>
<li >
<a href="#-follow-list">/follow/list</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#col">col</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-col-list">/col/list</a>
</li>
<li >
<a href="#-col-add_col">/col/add_col</a>
</li>
<li >
<a href="#-col-case_list">/col/case_list</a>
</li>
<li >
<a href="#-col-add_case">/col/add_case</a>
</li>
<li >
<a href="#-col-case">/col/case</a>
</li>
<li >
<a href="#-col-up_col">/col/up_col</a>
</li>
<li >
<a href="#-col-up_col_index">/col/up_col_index</a>
</li>
<li >
<a href="#-col-del_col">/col/del_col</a>
</li>
</ul>
<!-- <li > -->
<li >
<a href="#log">log</a>
</li>
<ul class="nav docs-sidenav-extend" >
<li >
<a href="#-log-list">/log/list</a>
</li>
</ul>
</ul>
</nav>
</div>
<div class="content-right markdown-body use-sidebar" role="main">
<div class="docs-section">
<h2 id="group" class="page-header subject">group<a class="hashlink" href="#group">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-group-add" class="page-header subject">
/group/add
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-group-add">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/group.js.html#11" target="_blank">./server/controllers/group.js:11</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>group_name</td>
<td>String</td>
<td>项目分组名称,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>group_desc</td>
<td>String</td>
<td>项目分组描述</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>owner_uid</td>
<td>String</td>
<td>组长uid</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">4</span><span class="token punctuation">,</span>
<span class="token string">"group_name"</span><span class="token punctuation">:</span> <span class="token string">"大数据5"</span><span class="token punctuation">,</span>
<span class="token string">"group_desc"</span><span class="token punctuation">:</span> <span class="token string">"大数据5"</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-group-list" class="page-header subject">
/group/list
<span class="ui-badge">get</span>
<a class="hashlink" href="#-group-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取项目分组列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/group.js.html#184" target="_blank">./server/controllers/group.js:184</a>
</p>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"group_name"</span><span class="token punctuation">:</span> <span class="token string">"大数据2"</span><span class="token punctuation">,</span>
<span class="token string">"group_desc"</span><span class="token punctuation">:</span> <span class="token string">"大数据2"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499244581</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499244581</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">2</span><span class="token punctuation">,</span>
<span class="token string">"group_name"</span><span class="token punctuation">:</span> <span class="token string">"大数据3"</span><span class="token punctuation">,</span>
<span class="token string">"group_desc"</span><span class="token punctuation">:</span> <span class="token string">"大数据3"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499244588</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499244588</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">3</span><span class="token punctuation">,</span>
<span class="token string">"group_name"</span><span class="token punctuation">:</span> <span class="token string">"大数据4"</span><span class="token punctuation">,</span>
<span class="token string">"group_desc"</span><span class="token punctuation">:</span> <span class="token string">"大数据4"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499244652</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499244652</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">4</span><span class="token punctuation">,</span>
<span class="token string">"group_name"</span><span class="token punctuation">:</span> <span class="token string">"大数据5"</span><span class="token punctuation">,</span>
<span class="token string">"group_desc"</span><span class="token punctuation">:</span> <span class="token string">"大数据5"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499328065</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499328065</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-group-del" class="page-header subject">
/group/del
<span class="ui-badge">post</span>
<a class="hashlink" href="#-group-del">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
删除项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/group.js.html#203" target="_blank">./server/controllers/group.js:203</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>String</td>
<td>项目分组id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-group-up" class="page-header subject">
/group/up
<span class="ui-badge">post</span>
<a class="hashlink" href="#-group-up">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
更新项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/group.js.html#240" target="_blank">./server/controllers/group.js:240</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>String</td>
<td>项目分组id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>group_name</td>
<td>String</td>
<td>项目分组名称</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>group_desc</td>
<td>String</td>
<td>项目分组描述</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"nModified"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<h2 id="user" class="page-header subject">user<a class="hashlink" href="#user">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-login" class="page-header subject">
/user/login
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-login">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
用户登录接口
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#18" target="_blank">./server/controllers/user.js:18</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>email</td>
<td>String</td>
<td>email名称不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>password</td>
<td>String</td>
<td>密码,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"logout success..."</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"email"</span><span class="token punctuation">:</span> <span class="token string">"admin@admin.com"</span><span class="token punctuation">,</span>
<span class="token string">"username"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499762848</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499762848</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-logout" class="page-header subject">
/user/logout
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-logout">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
退出登录接口
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#64" target="_blank">./server/controllers/user.js:64</a>
</p>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token string">"ok"</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-change_password" class="page-header subject">
/user/change_password
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-change_password">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
修改用户密码
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#162" target="_blank">./server/controllers/user.js:162</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td>Number</td>
<td>用户ID</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>old_password</td>
<td>Number</td>
<td>旧密码, 非admin用户必须传</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>password</td>
<td>Number</td>
<td>新密码</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" ><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"nModified"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span>
</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-reg" class="page-header subject">
/user/reg
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-reg">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
用户注册接口
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#227" target="_blank">./server/controllers/user.js:227</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>email</td>
<td>String</td>
<td>email名称不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>password</td>
<td>String</td>
<td>密码,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>username</td>
<td>String</td>
<td>用户名</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"logout success..."</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"email"</span><span class="token punctuation">:</span> <span class="token string">"admin@admin.com"</span><span class="token punctuation">,</span>
<span class="token string">"username"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499762848</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499762848</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-list" class="page-header subject">
/user/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取用户列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#300" target="_blank">./server/controllers/user.js:300</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>page</td>
<td>Number</td>
<td>分页页码</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>limit</td>
<td>Number</td>
<td>分页大小,默认为10条</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-find" class="page-header subject">
/user/find
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-find">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取用户个人信息
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#328" target="_blank">./server/controllers/user.js:328</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td></td>
<td>用户uid</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-del" class="page-header subject">
/user/del
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-del">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
删除用户,只有admin用户才有此权限
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#366" target="_blank">./server/controllers/user.js:366</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td></td>
<td>用户uid</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-update" class="page-header subject">
/user/update
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-update">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
更新用户个人信息
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#397" target="_blank">./server/controllers/user.js:397</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td></td>
<td>用户uid</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>role</td>
<td></td>
<td>用户角色,只有管理员有权限修改</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>username</td>
<td></td>
<td>String</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>email</td>
<td></td>
<td>String</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-upload_avatar" class="page-header subject">
/user/upload_avatar
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-user-upload_avatar">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
上传用户头像
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#452" target="_blank">./server/controllers/user.js:452</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>basecode</td>
<td>*</td>
<td>base64编码通过h5 api传给后端</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-avatar" class="page-header subject">
/user/avatar
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-avatar">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
根据用户uid头像
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#495" target="_blank">./server/controllers/user.js:495</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td>*</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-search" class="page-header subject">
/user/search
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-search">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
模糊搜索用户名或者email
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#527" target="_blank">./server/controllers/user.js:527</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>q</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"ok"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"email"</span><span class="token punctuation">:</span> <span class="token string">"admin@admin.com"</span><span class="token punctuation">,</span>
<span class="token string">"role"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"username"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"addTime"</span><span class="token punctuation">:</span> <span class="token number">1499936103</span><span class="token punctuation">,</span>
<span class="token string">"upTime"</span><span class="token punctuation">:</span> <span class="token number">1499936103</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-user-project" class="page-header subject">
/user/project
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-user-project">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
根据路由id初始化项目数据
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/user.js.html#572" target="_blank">./server/controllers/user.js:572</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>type</td>
<td>String</td>
<td>可选group|interface|project</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>id</td>
<td>Number</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<h2 id="project" class="page-header subject">project<a class="hashlink" href="#project">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-add" class="page-header subject">
/project/add
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-project-add">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#37" target="_blank">./server/controllers/project.js:37</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>name</td>
<td>String</td>
<td>项目名称,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>basepath</td>
<td>String</td>
<td>项目基本路径,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>prd_host</td>
<td>String</td>
<td>项目线上域名不能为空。可通过配置的域名访问到mock数据</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>protocol</td>
<td>String</td>
<td>线上域名协议,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>group_id</td>
<td>Number</td>
<td>项目分组id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td>项目描述</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">8</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"project_a2"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"tttttt"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"project.a2.cc"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"/a1"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499331387</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499331387</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token number">0</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-add_member" class="page-header subject">
/project/add_member
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-project-add_member">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#126" target="_blank">./server/controllers/project.js:126</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>member_uid</td>
<td>String</td>
<td>项目成员uid,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-del_member" class="page-header subject">
/project/del_member
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-project-del_member">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#169" target="_blank">./server/controllers/project.js:169</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>uid</td>
<td>member_uid</td>
<td>项目成员uid,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-get_member_list" class="page-header subject">
/project/get_member_list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-project-get_member_list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取项目成员列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#222" target="_blank">./server/controllers/project.js:222</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"email"</span><span class="token punctuation">:</span> <span class="token string">"admin@admin.com"</span><span class="token punctuation">,</span>
<span class="token string">"role"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499932673</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499932673</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-get" class="page-header subject">
/project/get
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-project-get">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#247" target="_blank">./server/controllers/project.js:247</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">7</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"project_a1"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"tttttt"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"project.a1.cc"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"/a1"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499331378</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499331378</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token number">0</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-list" class="page-header subject">
/project/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-project-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取项目列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#271" target="_blank">./server/controllers/project.js:271</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>group_id</td>
<td>Number</td>
<td>项目group_id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"total"</span><span class="token punctuation">:</span> <span class="token number">2</span><span class="token punctuation">,</span>
<span class="token string">"list"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">529</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"yapi"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"aaa"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://www.yapi.com"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"/a/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500465369</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500522419</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">558</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"12"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"21\n"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://11/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"12/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500466250</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500466250</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">626</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"1233"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"123"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://1234/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"1234/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500471230</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500471230</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">665</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"222"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"222"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://222/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"222/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500471668</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500471668</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">704</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"333"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"222333"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://333/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"333/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500471674</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500471674</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">743</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"444"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"444"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"https://444/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"444/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500471695</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500471695</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">763</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"122333"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"3/"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://33/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"33/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500481743</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500481743</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">778</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"555"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"555"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"https://555/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"555/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500519203</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500519203</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">823</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"5"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"5"</span><span class="token punctuation">,</span>
<span class="token string">"prd_host"</span><span class="token punctuation">:</span> <span class="token string">"http://5/"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"5/"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"group_id"</span><span class="token punctuation">:</span> <span class="token number">181</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500519769</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500519769</span><span class="token punctuation">,</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"107"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"userinfo"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"107"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">107</span><span class="token punctuation">,</span>
<span class="token string">"username"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"email"</span><span class="token punctuation">:</span> <span class="token string">"admin@admin.com"</span><span class="token punctuation">,</span>
<span class="token string">"role"</span><span class="token punctuation">:</span> <span class="token string">"admin"</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1500280333</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1500373530</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-del" class="page-header subject">
/project/del
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-project-del">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
删除项目
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#312" target="_blank">./server/controllers/project.js:312</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-up" class="page-header subject">
/project/up
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-project-up">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
编辑项目
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#372" target="_blank">./server/controllers/project.js:372</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>name</td>
<td>String</td>
<td>项目名称,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>basepath</td>
<td>String</td>
<td>项目基本路径,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>prd_host</td>
<td>String</td>
<td>项目线上域名不能为空。可通过配置的域名访问到mock数据</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td>项目描述</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>env</td>
<td>Array</td>
<td>项目环境配置</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>env[].name</td>
<td>String</td>
<td>环境名称</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>env[].domain</td>
<td>String</td>
<td>环境域名</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code">
<span class="token comment" spellcheck="true">//请求示例</span>
<span class="token punctuation">{</span>
<span class="token string">"id"</span><span class="token punctuation">:</span> <span class="token number">8</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">{</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"本地开发环境"</span><span class="token punctuation">,</span>
<span class="token string">"domain"</span><span class="token punctuation">:</span> <span class="token string">"http://api.quar.com"</span>
<span class="token punctuation">}</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"yapi项目"</span>
<span class="token punctuation">}</span>
<span class="token comment" spellcheck="true">//返回示例</span>
<span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-search" class="page-header subject">
/project/search
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-project-search">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
模糊搜索项目名称或者组名称
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#463" target="_blank">./server/controllers/project.js:463</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>q</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"ok"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"project"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"qav_project"</span><span class="token punctuation">,</span>
<span class="token string">"prdHost"</span><span class="token punctuation">:</span> <span class="token string">"xxx.qunar.com:8080"</span><span class="token punctuation">,</span>
<span class="token string">"basepath"</span><span class="token punctuation">:</span> <span class="token string">"/qav/"</span><span class="token punctuation">,</span>
<span class="token string">"addTime"</span><span class="token punctuation">:</span> <span class="token number">1500013365</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">101</span><span class="token punctuation">,</span>
<span class="token string">"upTime"</span><span class="token punctuation">:</span> <span class="token number">1500013365</span><span class="token punctuation">,</span>
<span class="token string">"env"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span><span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"members"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token string">"101"</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"group"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">193</span><span class="token punctuation">,</span>
<span class="token string">"groupName"</span><span class="token punctuation">:</span> <span class="token string">"qav"</span><span class="token punctuation">,</span>
<span class="token string">"groupDesc"</span><span class="token punctuation">:</span> <span class="token string">"project qav"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"addTime"</span><span class="token punctuation">:</span> <span class="token number">1500013066</span><span class="token punctuation">,</span>
<span class="token string">"upTime"</span><span class="token punctuation">:</span> <span class="token number">1500013066</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-project-download" class="page-header subject">
/project/download
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-project-download">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
下载项目的 Mock 数据
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/project.js.html#518" target="_blank">./server/controllers/project.js:518</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>project_id</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<h2 id="interface" class="page-header subject">interface<a class="hashlink" href="#interface">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-interface-add" class="page-header subject">
/interface/add
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-interface-add">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interface.js.html#10" target="_blank">./server/controllers/interface.js:10</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>project_id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>title</td>
<td>String</td>
<td>接口标题,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>path</td>
<td>String</td>
<td>接口请求路径,不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>method</td>
<td>String</td>
<td>请求方式</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_headers</td>
<td>Array</td>
<td>请求的header信息</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].name</td>
<td>String</td>
<td>请求的header信息名</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].value</td>
<td>String</td>
<td>请求的header信息值</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].required</td>
<td>Boolean</td>
<td>是否是必须,默认为否</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].desc</td>
<td>String</td>
<td>header描述</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_type</td>
<td>String</td>
<td>请求参数方式,有["form", "json", "text", "xml"]四种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form</td>
<td>Mixed</td>
<td>请求参数,如果请求方式是form参数是Array数组其他格式请求参数是字符串</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].name</td>
<td>String</td>
<td>请求参数名</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].value</td>
<td>String</td>
<td>请求参数值可填写生成规则mock。如@email随机生成一条email</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].type</td>
<td>String</td>
<td>请求参数类型,有["text", "file"]两种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_other</td>
<td>String</td>
<td>非form类型的请求参数可保存到此字段</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>res_body_type</td>
<td>String</td>
<td>相应信息的数据格式,有["json", "text", "xml"]三种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>res_body</td>
<td>String</td>
<td>响应信息可填写任意字符串如果res_body_type是json,则会调用mock功能</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td>接口描述</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code">
<span class="token comment" spellcheck="true">//请求 /interface/add</span>
<span class="token comment" spellcheck="true">//header Content-Type:application/json</span>
<span class="token punctuation">{</span>
<span class="token string">"title"</span><span class="token punctuation">:</span> <span class="token string">"testapi"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"api"</span><span class="token punctuation">,</span>
<span class="token string">"method"</span><span class="token punctuation">:</span> <span class="token string">"post"</span><span class="token punctuation">,</span>
<span class="token string">"path"</span><span class="token punctuation">:</span> <span class="token string">"/testapi"</span><span class="token punctuation">,</span>
<span class="token string">"project_id"</span><span class="token punctuation">:</span> <span class="token number">8</span><span class="token punctuation">,</span>
<span class="token string">"req_headers"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"key"</span><span class="token punctuation">:</span> <span class="token string">"h"</span><span class="token punctuation">,</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token string">"t"</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"req_params_type"</span><span class="token punctuation">:</span> <span class="token string">"form"</span><span class="token punctuation">,</span>
<span class="token string">"req_params"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"uid"</span><span class="token punctuation">,</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token number">100</span><span class="token punctuation">,</span>
<span class="token string">"type"</span><span class="token punctuation">:</span> <span class="token string">"text"</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"gid"</span><span class="token punctuation">,</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token number">1001</span><span class="token punctuation">,</span>
<span class="token string">"type"</span><span class="token punctuation">:</span> <span class="token string">"text"</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"res_body_type"</span><span class="token punctuation">:</span> <span class="token string">"json"</span><span class="token punctuation">,</span>
<span class="token string">"res_body"</span><span class="token punctuation">:</span> <span class="token string">"{\"tt\": 222}"</span>
<span class="token punctuation">}</span>
<span class="token comment" spellcheck="true">//返回结果</span>
<span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"__v"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token number">422</span><span class="token punctuation">,</span>
<span class="token string">"title"</span><span class="token punctuation">:</span> <span class="token string">"testapi"</span><span class="token punctuation">,</span>
<span class="token string">"project_id"</span><span class="token punctuation">:</span> <span class="token number">8</span><span class="token punctuation">,</span>
<span class="token string">"path"</span><span class="token punctuation">:</span> <span class="token string">"/testapi"</span><span class="token punctuation">,</span>
<span class="token string">"desc"</span><span class="token punctuation">:</span> <span class="token string">"api"</span><span class="token punctuation">,</span>
<span class="token string">"method"</span><span class="token punctuation">:</span> <span class="token string">"post"</span><span class="token punctuation">,</span>
<span class="token string">"req_params_type"</span><span class="token punctuation">:</span> <span class="token string">"form"</span><span class="token punctuation">,</span>
<span class="token string">"res_body"</span><span class="token punctuation">:</span> <span class="token string">"{\"tt\": 222}"</span><span class="token punctuation">,</span>
<span class="token string">"res_body_type"</span><span class="token punctuation">:</span> <span class="token string">"json"</span><span class="token punctuation">,</span>
<span class="token string">"uid"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"add_time"</span><span class="token punctuation">:</span> <span class="token number">1499658569</span><span class="token punctuation">,</span>
<span class="token string">"up_time"</span><span class="token punctuation">:</span> <span class="token number">1499658569</span><span class="token punctuation">,</span>
<span class="token string">"req_params_form"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"uid"</span><span class="token punctuation">,</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token string">"100"</span><span class="token punctuation">,</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token string">"5962f94940a7a5767088fcc0"</span>
<span class="token punctuation">}</span><span class="token punctuation">,</span>
<span class="token punctuation">{</span>
<span class="token string">"name"</span><span class="token punctuation">:</span> <span class="token string">"gid"</span><span class="token punctuation">,</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token string">"1001"</span><span class="token punctuation">,</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token string">"5962f94940a7a5767088fcbf"</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span><span class="token punctuation">,</span>
<span class="token string">"req_headers"</span><span class="token punctuation">:</span> <span class="token punctuation">[</span>
<span class="token punctuation">{</span>
<span class="token string">"value"</span><span class="token punctuation">:</span> <span class="token string">"t"</span><span class="token punctuation">,</span>
<span class="token string">"_id"</span><span class="token punctuation">:</span> <span class="token string">"5962f94940a7a5767088fcc1"</span>
<span class="token punctuation">}</span>
<span class="token punctuation">]</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-interface-get" class="page-header subject">
/interface/get
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-interface-get">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加项目分组
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interface.js.html#99" target="_blank">./server/controllers/interface.js:99</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>接口id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">.</span><span class="token operator">/</span>api<span class="token operator">/</span><span class="token keyword">interface</span><span class="token operator">/</span><span class="token keyword">get</span><span class="token punctuation">.</span>json</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-interface-list" class="page-header subject">
/interface/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-interface-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
接口列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interface.js.html#124" target="_blank">./server/controllers/interface.js:124</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>project_id</td>
<td>Number</td>
<td>项目id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">.</span><span class="token operator">/</span>api<span class="token operator">/</span><span class="token keyword">interface</span><span class="token operator">/</span>list<span class="token punctuation">.</span>json</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-interface-up" class="page-header subject">
/interface/up
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-interface-up">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
编辑接口
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interface.js.html#149" target="_blank">./server/controllers/interface.js:149</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>接口id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>path</td>
<td>String</td>
<td>接口请求路径</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>method</td>
<td>String</td>
<td>请求方式</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers</td>
<td>Array</td>
<td>请求的header信息</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].name</td>
<td>String</td>
<td>请求的header信息名</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].value</td>
<td>String</td>
<td>请求的header信息值</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].required</td>
<td>Boolean</td>
<td>是否是必须,默认为否</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_headers[].desc</td>
<td>String</td>
<td>header描述</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_type</td>
<td>String</td>
<td>请求参数方式,有["form", "json", "text", "xml"]四种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form</td>
<td>Mixed</td>
<td>请求参数,如果请求方式是form参数是Array数组其他格式请求参数是字符串</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].name</td>
<td>String</td>
<td>请求参数名</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].value</td>
<td>String</td>
<td>请求参数值可填写生成规则mock。如@email随机生成一条email</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_form[].type</td>
<td>String</td>
<td>请求参数类型,有["text", "file"]两种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>req_params_other</td>
<td>String</td>
<td>非form类型的请求参数可保存到此字段</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>res_body_type</td>
<td>String</td>
<td>相应信息的数据格式,有["json", "text", "xml"]三种</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>res_body</td>
<td>String</td>
<td>响应信息可填写任意字符串如果res_body_type是json,则会调用mock功能</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td>接口描述</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"nModified"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-interface-del" class="page-header subject">
/interface/del
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-interface-del">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
删除接口
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interface.js.html#250" target="_blank">./server/controllers/interface.js:250</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>接口id不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token punctuation">{</span>
<span class="token string">"errcode"</span><span class="token punctuation">:</span> <span class="token number">0</span><span class="token punctuation">,</span>
<span class="token string">"errmsg"</span><span class="token punctuation">:</span> <span class="token string">"success"</span><span class="token punctuation">,</span>
<span class="token string">"data"</span><span class="token punctuation">:</span> <span class="token punctuation">{</span>
<span class="token string">"n"</span><span class="token punctuation">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
<span class="token string">"ok"</span><span class="token punctuation">:</span> <span class="token number">1</span>
<span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
</div>
<h2 id="follow" class="page-header subject">follow<a class="hashlink" href="#follow">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-follow-list" class="page-header subject">
/follow/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-follow-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取关注项目列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/follow.js.html#24" target="_blank">./server/controllers/follow.js:24</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td>Number</td>
<td>用户id 不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>page</td>
<td>Number</td>
<td>分页页码</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>limit</td>
<td>Number</td>
<td>分页大小</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token operator">/</span>follow<span class="token operator">/</span>list</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-follow-list" class="page-header subject">
/follow/list
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-follow-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
取消关注
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/follow.js.html#60" target="_blank">./server/controllers/follow.js:60</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id</td>
<td>Number</td>
<td>关注id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token operator">/</span>follow<span class="token operator">/</span>del</code></pre>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-follow-list" class="page-header subject">
/follow/list
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-follow-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
添加关注
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/follow.js.html#86" target="_blank">./server/controllers/follow.js:86</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td>Number</td>
<td>用户id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>projectid</td>
<td>Number</td>
<td>项目id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>projectname</td>
<td>String</td>
<td>项目名</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>icon</td>
<td>String</td>
<td>项目icon</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token operator">/</span>follow<span class="token operator">/</span>add</code></pre>
</div>
<h2 id="col" class="page-header subject">col<a class="hashlink" href="#col">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-list" class="page-header subject">
/col/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-col-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取所有接口集
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#12" target="_blank">./server/controllers/interfaceCol.js:12</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>project_id</td>
<td>String</td>
<td>email名称不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-add_col" class="page-header subject">
/col/add_col
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-col-add_col">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
增加接口集
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#33" target="_blank">./server/controllers/interfaceCol.js:33</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>project_id</td>
<td>Number</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>name</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-case_list" class="page-header subject">
/col/case_list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-col-case_list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取一个接口集下的所有的接口用例
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#77" target="_blank">./server/controllers/interfaceCol.js:77</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>col_id</td>
<td>String</td>
<td>接口集id</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-add_case" class="page-header subject">
/col/add_case
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-col-add_case">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
增加一个接口用例
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#99" target="_blank">./server/controllers/interfaceCol.js:99</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>casename</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>col_id</td>
<td>Number</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>project_id</td>
<td>Number</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>env</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>domain</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>path</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>method</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_query</td>
<td>Object</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_headers</td>
<td>Object</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_body_type</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_body_form</td>
<td>Array</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>req_body_other</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-case" class="page-header subject">
/col/case
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-col-case">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取一个接口用例详情
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#164" target="_blank">./server/controllers/interfaceCol.js:164</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>caseid</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-up_col" class="page-header subject">
/col/up_col
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-col-up_col">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
更新一个接口集name或描述
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#185" target="_blank">./server/controllers/interfaceCol.js:185</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>name</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>desc</td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-up_col_index" class="page-header subject">
/col/up_col_index
<span class="ui-badge">POST</span>
<a class="hashlink" href="#-col-up_col_index">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
更新多个接口case index
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#211" target="_blank">./server/controllers/interfaceCol.js:211</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>id, index</td>
<td>Array</td>
<td></td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-col-del_col" class="page-header subject">
/col/del_col
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-col-del_col">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
删除一个接口集
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/interfaceCol.js.html#243" target="_blank">./server/controllers/interfaceCol.js:243</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td></td>
<td>String</td>
<td></td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
</table>
</div>
</div>
<h2 id="log" class="page-header subject">log<a class="hashlink" href="#log">#</a></h2>
<div class="con-list-item">
<blockquote class="api">
<h3 id="-log-list" class="page-header subject">
/log/list
<span class="ui-badge">GET</span>
<a class="hashlink" href="#-log-list">#</a>
</h3>
</blockquote>
<p>
<small class="text-muted">描述:</small>
获取动态列表
</p>
<p>
<small class="text-muted">源码位置:</small>
<a href="./static/server/controllers/log.js.html#28" target="_blank">./server/controllers/log.js:28</a>
</p>
<p>
<small class="text-muted">参数:</small>
</p>
<div class="docs-table">
<table class="yo-table yo-table-border">
<colgroup>
<col class="c1">
<col class="c2">
<col class="c3">
<col class="c4">
</colgroup>
<thead>
<tr class="active">
<th>参数名</th>
<th>类型</th>
<th>描述</th>
<th>必选</th>
<th>支持版本</th>
</tr>
</thead>
<tr>
<td>uid</td>
<td>Number</td>
<td>用户id 不能为空</td>
<td>
<i class="yo-ico glyphicon glyphicon-ok text-success"></i>
</td>
<td></td>
</tr>
<tr>
<td>page</td>
<td>Number</td>
<td>分页页码</td>
<td>
</td>
<td></td>
</tr>
<tr>
<td>limit</td>
<td>Number</td>
<td>分页大小</td>
<td>
</td>
<td></td>
</tr>
</table>
</div>
<div>示例:</div>
<pre class="ydoc-example" data-foldnumber=10><code class="js-code"><span class="token operator">/</span>log<span class="token operator">/</span>list</code></pre>
</div>
</div>
</div>
</div>
</div>
</div>
<footer class="footer">
<div class="copyright">
&copy; 2016 <a href="http://ued.qunar.com/ymfe/">YMFE</a> Team. Build by <a href="http://ued.qunar.com/ydoc/">ydoc</a>.
</div>
</footer>
</div>
<div class="open-panel"></div>
<div class="mask"></div>
<script src="source/main.js"></script>
<script src="source/app.js"></script>
<script>
var lineHeight = 17.4;
var EXAMPLE_MAX_HEIGHT;
function fold() {
// 折叠code
$('.markdown-body pre').css({
"line-height": lineHeight + "px"
});
$('.markdown-body pre').map(function(i, item) {
var $item = $(item);
var foldnumber = $item.data('foldnumber');
EXAMPLE_MAX_HEIGHT = lineHeight * (foldnumber || 6);
if ($item.height() > EXAMPLE_MAX_HEIGHT) {
$item.css({
"padding-bottom": 30
});
$item.find('code').height(EXAMPLE_MAX_HEIGHT);
$item.append('<span class="extend">展开更多……</span>');
};
});
$('.ydoc-example').delegate('.extend', 'click', function() {
var $this = $(this);
$this.removeClass('extend').addClass('fold');
$this.html('折叠代码');
$this.parent().children('.js-code').height('auto');
$this.parent().height('auto');
});
$('.ydoc-example').delegate('.fold', 'click', function() {
var $this = $(this);
var foldnumber = $this.parent().data('foldnumber');
EXAMPLE_MAX_HEIGHT = lineHeight * (foldnumber || 6);
$this.removeClass('fold').addClass('extend');
$this.parent().height(EXAMPLE_MAX_HEIGHT); // pre
$this.parent().children('.js-code').height(EXAMPLE_MAX_HEIGHT); // code
$this.html("展开更多……");
});
}
$(document).ready(fold);
</script>
</body>
</html>