From c83a2a0925d50e12c4a1d57d5a20586fcb860875 Mon Sep 17 00:00:00 2001 From: astaxie Date: Thu, 28 Aug 2014 10:21:32 +0800 Subject: [PATCH] modify the comments --- plugins/apiauth/apiauth.go | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/plugins/apiauth/apiauth.go b/plugins/apiauth/apiauth.go index 2cdbe96a..bbae7def 100644 --- a/plugins/apiauth/apiauth.go +++ b/plugins/apiauth/apiauth.go @@ -13,6 +13,7 @@ // limitations under the License. // Package apiauth provides handlers to enable apiauth support. +// // Simple Usage: // import( // "github.com/astaxie/beego" @@ -29,24 +30,26 @@ // // func getAppSecret(appid string) string { // // get appsecret by appid -// // maybe store in configure, maybe in database +// // maybe store in configure, maybe in database // } // // beego.InsertFilter("*", beego.BeforeRouter,apiauth.APIAuthWithFunc(getAppSecret, 360)) // -// in the request user should include these params in the query +// Infomation: // -// 1. appid +// In the request user should include these params in the query +// +// 1. appid // // appid is asigned to the application // -// 2. signature +// 2. signature // -// get the signature use apiauth.Signature() +// get the signature use apiauth.Signature() // -// >>> should use url.QueryEscape() +// when you send to server remember use url.QueryEscape() // -// 3. timestamp: +// 3. timestamp: // // send the request time, the format is yyyy-mm-dd HH:ii:ss //