mirror of
https://github.com/balzack/databag.git
synced 2025-02-11 19:19:16 +00:00
19 lines
337 B
Go
19 lines
337 B
Go
package databag
|
|
|
|
import (
|
|
"net/http"
|
|
)
|
|
|
|
//GetAccountToken retrieve type of account token
|
|
func GetAccountToken(w http.ResponseWriter, r *http.Request) {
|
|
|
|
accountToken, err := BearerAccountToken(r)
|
|
if err != nil {
|
|
LogMsg("token not found")
|
|
w.WriteHeader(http.StatusNotFound)
|
|
return
|
|
}
|
|
|
|
WriteResponse(w, accountToken.TokenType)
|
|
}
|