Documentation ¶
Index ¶
- func Authorize(redirect string) (string, error)
- func CreateClient(w http.ResponseWriter, body io.ReadCloser) error
- func DeleteClient(w http.ResponseWriter, clientId string) error
- func GetClient(w http.ResponseWriter, clientId string) error
- func GetClients(w http.ResponseWriter, query url.Values) error
- func InitSSO()
- func LogoutLocation(redirect string) string
- func UpdateClient(w http.ResponseWriter, clientId string, body io.ReadCloser) error
- type CallbackOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateClient ¶
func CreateClient(w http.ResponseWriter, body io.ReadCloser) error
func DeleteClient ¶
func DeleteClient(w http.ResponseWriter, clientId string) error
func GetClients ¶
func GetClients(w http.ResponseWriter, query url.Values) error
func LogoutLocation ¶
LogoutLocation return logout location
func UpdateClient ¶
func UpdateClient(w http.ResponseWriter, clientId string, body io.ReadCloser) error
Types ¶
type CallbackOutput ¶
type CallbackOutput struct { Redirect string `json:"redirect"` AccessToken string `json:"accessToken"` User *models.User `json:"user"` Msg string `json:"msg"` }
func Callback ¶
func Callback(code, state string) (*CallbackOutput, error)
Callback 用 code 兑换 accessToken 以及 用户信息,
func (CallbackOutput) String ¶
func (p CallbackOutput) String() string
Click to show internal directories.
Click to hide internal directories.