作者 何书鹏
1 个管道 的构建 通过 耗费 3 秒

检查token是否过期

@@ -15,8 +15,20 @@ class Token extends Api @@ -15,8 +15,20 @@ class Token extends Api
15 protected $noNeedRight = '*'; 15 protected $noNeedRight = '*';
16 16
17 /** 17 /**
18 - * 检测Token是否过期  
19 - * 18 + * @ApiWeigh (99)
  19 + * @ApiTitle (检测Token是否过期)
  20 + * @ApiSummary (检测Token是否过期)
  21 + * @ApiMethod (GET)
  22 + * @ApiHeaders (name="token", type="string", required=true, description="请求的Token")
  23 + * @ApiReturn({
  24 + "code": 1,
  25 + "msg": "",
  26 + "time": "1621402970",
  27 + "data": {
  28 + "token": "545eed64-39c4-437e-8285-ac94c03e4921", //token
  29 + "expires_in": 2591951 //剩余有效时间
  30 + }
  31 + })
20 */ 32 */
21 public function check() 33 public function check()
22 { 34 {
@@ -26,8 +38,20 @@ class Token extends Api @@ -26,8 +38,20 @@ class Token extends Api
26 } 38 }
27 39
28 /** 40 /**
29 - * 刷新Token  
30 - * 41 + * @ApiWeigh (97)
  42 + * @ApiTitle (刷新Token)
  43 + * @ApiSummary (刷新Token)
  44 + * @ApiMethod (GET)
  45 + * @ApiHeaders (name="token", type="string", required=true, description="请求的Token")
  46 + * @ApiReturn({
  47 + "code": 1,
  48 + "msg": "",
  49 + "time": "1621403556",
  50 + "data": {
  51 + "token": "175c6d84-42af-4c59-bce0-ad8a66eb5f3f", //token
  52 + "expires_in": 2592000 //剩余有效时间
  53 + }
  54 + })
31 */ 55 */
32 public function refresh() 56 public function refresh()
33 { 57 {
@@ -15,8 +15,20 @@ class Token extends Api @@ -15,8 +15,20 @@ class Token extends Api
15 protected $noNeedRight = '*'; 15 protected $noNeedRight = '*';
16 16
17 /** 17 /**
18 - * 检测Token是否过期  
19 - * 18 + * @ApiWeigh (99)
  19 + * @ApiTitle (检测Token是否过期)
  20 + * @ApiSummary (检测Token是否过期)
  21 + * @ApiMethod (GET)
  22 + * @ApiHeaders (name="token", type="string", required=true, description="请求的Token")
  23 + * @ApiReturn({
  24 + "code": 1,
  25 + "msg": "",
  26 + "time": "1621402970",
  27 + "data": {
  28 + "token": "545eed64-39c4-437e-8285-ac94c03e4921", //token
  29 + "expires_in": 2591951 //剩余有效时间
  30 + }
  31 + })
20 */ 32 */
21 public function check() 33 public function check()
22 { 34 {
@@ -26,8 +38,20 @@ class Token extends Api @@ -26,8 +38,20 @@ class Token extends Api
26 } 38 }
27 39
28 /** 40 /**
29 - * 刷新Token  
30 - * 41 + * @ApiWeigh (97)
  42 + * @ApiTitle (刷新Token)
  43 + * @ApiSummary (刷新Token)
  44 + * @ApiMethod (GET)
  45 + * @ApiHeaders (name="token", type="string", required=true, description="请求的Token")
  46 + * @ApiReturn({
  47 + "code": 1,
  48 + "msg": "",
  49 + "time": "1621403556",
  50 + "data": {
  51 + "token": "175c6d84-42af-4c59-bce0-ad8a66eb5f3f", //token
  52 + "expires_in": 2592000 //剩余有效时间
  53 + }
  54 + })
31 */ 55 */
32 public function refresh() 56 public function refresh()
33 { 57 {
@@ -7223,7 +7223,24 @@ @@ -7223,7 +7223,24 @@
7223 <div class="panel panel-default"> 7223 <div class="panel panel-default">
7224 <div class="panel-heading"><strong>Headers</strong></div> 7224 <div class="panel-heading"><strong>Headers</strong></div>
7225 <div class="panel-body"> 7225 <div class="panel-body">
7226 - 7226 + <table class="table table-hover">
  7227 + <thead>
  7228 + <tr>
  7229 + <th>名称</th>
  7230 + <th>类型</th>
  7231 + <th>必选</th>
  7232 + <th>描述</th>
  7233 + </tr>
  7234 + </thead>
  7235 + <tbody>
  7236 + <tr>
  7237 + <td>token</td>
  7238 + <td>string</td>
  7239 + <td></td>
  7240 + <td>请求的Token</td>
  7241 + </tr>
  7242 + </tbody>
  7243 + </table>
7227 </div> 7244 </div>
7228 </div> 7245 </div>
7229 <div class="panel panel-default"> 7246 <div class="panel panel-default">
@@ -7243,9 +7260,20 @@ @@ -7243,9 +7260,20 @@
7243 <div class="row"> 7260 <div class="row">
7244 <div class="col-md-12"> 7261 <div class="col-md-12">
7245 <div class="panel panel-default"> 7262 <div class="panel panel-default">
  7263 + <div class="panel-heading"><strong>Headers</strong></div>
  7264 + <div class="panel-body">
  7265 + <div class="headers">
  7266 + <div class="form-group">
  7267 + <label class="control-label" for="token">token</label>
  7268 + <input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
  7269 + </div>
  7270 + </div>
  7271 + </div>
  7272 + </div>
  7273 + <div class="panel panel-default">
7246 <div class="panel-heading"><strong>参数</strong></div> 7274 <div class="panel-heading"><strong>参数</strong></div>
7247 <div class="panel-body"> 7275 <div class="panel-body">
7248 - <form enctype="application/x-www-form-urlencoded" role="form" action="/api/v2.token/check" method="get" name="form87" id="form87"> 7276 + <form enctype="application/x-www-form-urlencoded" role="form" action="/api/v2.token/check" method="GET" name="form87" id="form87">
7249 <div class="form-group"> 7277 <div class="form-group">
7250 7278
7251 </div> 7279 </div>
@@ -7280,7 +7308,15 @@ @@ -7280,7 +7308,15 @@
7280 <div class="tab-pane" id="sample87"> 7308 <div class="tab-pane" id="sample87">
7281 <div class="row"> 7309 <div class="row">
7282 <div class="col-md-12"> 7310 <div class="col-md-12">
7283 - <pre id="sample_response87"></pre> 7311 + <pre id="sample_response87">{
  7312 + "code": 1,
  7313 + "msg": "",
  7314 + "time": "1621402970",
  7315 + "data": {
  7316 + "token": "545eed64-39c4-437e-8285-ac94c03e4921", //token
  7317 + "expires_in": 2591951 //剩余有效时间
  7318 + }
  7319 + }</pre>
7284 </div> 7320 </div>
7285 </div> 7321 </div>
7286 </div><!-- #sample --> 7322 </div><!-- #sample -->
@@ -7315,7 +7351,24 @@ @@ -7315,7 +7351,24 @@
7315 <div class="panel panel-default"> 7351 <div class="panel panel-default">
7316 <div class="panel-heading"><strong>Headers</strong></div> 7352 <div class="panel-heading"><strong>Headers</strong></div>
7317 <div class="panel-body"> 7353 <div class="panel-body">
7318 - 7354 + <table class="table table-hover">
  7355 + <thead>
  7356 + <tr>
  7357 + <th>名称</th>
  7358 + <th>类型</th>
  7359 + <th>必选</th>
  7360 + <th>描述</th>
  7361 + </tr>
  7362 + </thead>
  7363 + <tbody>
  7364 + <tr>
  7365 + <td>token</td>
  7366 + <td>string</td>
  7367 + <td></td>
  7368 + <td>请求的Token</td>
  7369 + </tr>
  7370 + </tbody>
  7371 + </table>
7319 </div> 7372 </div>
7320 </div> 7373 </div>
7321 <div class="panel panel-default"> 7374 <div class="panel panel-default">
@@ -7335,9 +7388,20 @@ @@ -7335,9 +7388,20 @@
7335 <div class="row"> 7388 <div class="row">
7336 <div class="col-md-12"> 7389 <div class="col-md-12">
7337 <div class="panel panel-default"> 7390 <div class="panel panel-default">
  7391 + <div class="panel-heading"><strong>Headers</strong></div>
  7392 + <div class="panel-body">
  7393 + <div class="headers">
  7394 + <div class="form-group">
  7395 + <label class="control-label" for="token">token</label>
  7396 + <input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
  7397 + </div>
  7398 + </div>
  7399 + </div>
  7400 + </div>
  7401 + <div class="panel panel-default">
7338 <div class="panel-heading"><strong>参数</strong></div> 7402 <div class="panel-heading"><strong>参数</strong></div>
7339 <div class="panel-body"> 7403 <div class="panel-body">
7340 - <form enctype="application/x-www-form-urlencoded" role="form" action="/api/v2.token/refresh" method="get" name="form88" id="form88"> 7404 + <form enctype="application/x-www-form-urlencoded" role="form" action="/api/v2.token/refresh" method="GET" name="form88" id="form88">
7341 <div class="form-group"> 7405 <div class="form-group">
7342 7406
7343 </div> 7407 </div>
@@ -7372,7 +7436,15 @@ @@ -7372,7 +7436,15 @@
7372 <div class="tab-pane" id="sample88"> 7436 <div class="tab-pane" id="sample88">
7373 <div class="row"> 7437 <div class="row">
7374 <div class="col-md-12"> 7438 <div class="col-md-12">
7375 - <pre id="sample_response88"></pre> 7439 + <pre id="sample_response88">{
  7440 + "code": 1,
  7441 + "msg": "",
  7442 + "time": "1621403556",
  7443 + "data": {
  7444 + "token": "175c6d84-42af-4c59-bce0-ad8a66eb5f3f", //token
  7445 + "expires_in": 2592000 //剩余有效时间
  7446 + }
  7447 + }</pre>
7376 </div> 7448 </div>
7377 </div> 7449 </div>
7378 </div><!-- #sample --> 7450 </div><!-- #sample -->
@@ -15765,7 +15837,24 @@ @@ -15765,7 +15837,24 @@
15765 <div class="panel panel-default"> 15837 <div class="panel panel-default">
15766 <div class="panel-heading"><strong>Headers</strong></div> 15838 <div class="panel-heading"><strong>Headers</strong></div>
15767 <div class="panel-body"> 15839 <div class="panel-body">
15768 - 15840 + <table class="table table-hover">
  15841 + <thead>
  15842 + <tr>
  15843 + <th>名称</th>
  15844 + <th>类型</th>
  15845 + <th>必选</th>
  15846 + <th>描述</th>
  15847 + </tr>
  15848 + </thead>
  15849 + <tbody>
  15850 + <tr>
  15851 + <td>token</td>
  15852 + <td>string</td>
  15853 + <td></td>
  15854 + <td>请求的Token</td>
  15855 + </tr>
  15856 + </tbody>
  15857 + </table>
15769 </div> 15858 </div>
15770 </div> 15859 </div>
15771 <div class="panel panel-default"> 15860 <div class="panel panel-default">
@@ -15785,9 +15874,20 @@ @@ -15785,9 +15874,20 @@
15785 <div class="row"> 15874 <div class="row">
15786 <div class="col-md-12"> 15875 <div class="col-md-12">
15787 <div class="panel panel-default"> 15876 <div class="panel panel-default">
  15877 + <div class="panel-heading"><strong>Headers</strong></div>
  15878 + <div class="panel-body">
  15879 + <div class="headers">
  15880 + <div class="form-group">
  15881 + <label class="control-label" for="token">token</label>
  15882 + <input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
  15883 + </div>
  15884 + </div>
  15885 + </div>
  15886 + </div>
  15887 + <div class="panel panel-default">
15788 <div class="panel-heading"><strong>参数</strong></div> 15888 <div class="panel-heading"><strong>参数</strong></div>
15789 <div class="panel-body"> 15889 <div class="panel-body">
15790 - <form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/check" method="get" name="form24" id="form24"> 15890 + <form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/check" method="GET" name="form24" id="form24">
15791 <div class="form-group"> 15891 <div class="form-group">
15792 15892
15793 </div> 15893 </div>
@@ -15822,7 +15922,15 @@ @@ -15822,7 +15922,15 @@
15822 <div class="tab-pane" id="sample24"> 15922 <div class="tab-pane" id="sample24">
15823 <div class="row"> 15923 <div class="row">
15824 <div class="col-md-12"> 15924 <div class="col-md-12">
15825 - <pre id="sample_response24"></pre> 15925 + <pre id="sample_response24">{
  15926 + "code": 1,
  15927 + "msg": "",
  15928 + "time": "1621402970",
  15929 + "data": {
  15930 + "token": "545eed64-39c4-437e-8285-ac94c03e4921", //token
  15931 + "expires_in": 2591951 //剩余有效时间
  15932 + }
  15933 + }</pre>
15826 </div> 15934 </div>
15827 </div> 15935 </div>
15828 </div><!-- #sample --> 15936 </div><!-- #sample -->
@@ -15857,7 +15965,24 @@ @@ -15857,7 +15965,24 @@
15857 <div class="panel panel-default"> 15965 <div class="panel panel-default">
15858 <div class="panel-heading"><strong>Headers</strong></div> 15966 <div class="panel-heading"><strong>Headers</strong></div>
15859 <div class="panel-body"> 15967 <div class="panel-body">
15860 - 15968 + <table class="table table-hover">
  15969 + <thead>
  15970 + <tr>
  15971 + <th>名称</th>
  15972 + <th>类型</th>
  15973 + <th>必选</th>
  15974 + <th>描述</th>
  15975 + </tr>
  15976 + </thead>
  15977 + <tbody>
  15978 + <tr>
  15979 + <td>token</td>
  15980 + <td>string</td>
  15981 + <td></td>
  15982 + <td>请求的Token</td>
  15983 + </tr>
  15984 + </tbody>
  15985 + </table>
15861 </div> 15986 </div>
15862 </div> 15987 </div>
15863 <div class="panel panel-default"> 15988 <div class="panel panel-default">
@@ -15877,9 +16002,20 @@ @@ -15877,9 +16002,20 @@
15877 <div class="row"> 16002 <div class="row">
15878 <div class="col-md-12"> 16003 <div class="col-md-12">
15879 <div class="panel panel-default"> 16004 <div class="panel panel-default">
  16005 + <div class="panel-heading"><strong>Headers</strong></div>
  16006 + <div class="panel-body">
  16007 + <div class="headers">
  16008 + <div class="form-group">
  16009 + <label class="control-label" for="token">token</label>
  16010 + <input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
  16011 + </div>
  16012 + </div>
  16013 + </div>
  16014 + </div>
  16015 + <div class="panel panel-default">
15880 <div class="panel-heading"><strong>参数</strong></div> 16016 <div class="panel-heading"><strong>参数</strong></div>
15881 <div class="panel-body"> 16017 <div class="panel-body">
15882 - <form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/refresh" method="get" name="form25" id="form25"> 16018 + <form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/refresh" method="GET" name="form25" id="form25">
15883 <div class="form-group"> 16019 <div class="form-group">
15884 16020
15885 </div> 16021 </div>
@@ -15914,7 +16050,15 @@ @@ -15914,7 +16050,15 @@
15914 <div class="tab-pane" id="sample25"> 16050 <div class="tab-pane" id="sample25">
15915 <div class="row"> 16051 <div class="row">
15916 <div class="col-md-12"> 16052 <div class="col-md-12">
15917 - <pre id="sample_response25"></pre> 16053 + <pre id="sample_response25">{
  16054 + "code": 1,
  16055 + "msg": "",
  16056 + "time": "1621403556",
  16057 + "data": {
  16058 + "token": "175c6d84-42af-4c59-bce0-ad8a66eb5f3f", //token
  16059 + "expires_in": 2592000 //剩余有效时间
  16060 + }
  16061 + }</pre>
15918 </div> 16062 </div>
15919 </div> 16063 </div>
15920 </div><!-- #sample --> 16064 </div><!-- #sample -->
@@ -19477,7 +19621,7 @@ @@ -19477,7 +19621,7 @@
19477 19621
19478 <div class="row mt0 footer"> 19622 <div class="row mt0 footer">
19479 <div class="col-md-6" align="left"> 19623 <div class="col-md-6" align="left">
19480 - Generated on 2021-05-18 11:34:22 </div> 19624 + Generated on 2021-05-19 13:58:47 </div>
19481 <div class="col-md-6" align="right"> 19625 <div class="col-md-6" align="right">
19482 <a href="./" target="_blank">My Website</a> 19626 <a href="./" target="_blank">My Website</a>
19483 </div> 19627 </div>