chore: 更新 SproutGate 认证集成
This commit is contained in:
@@ -12,6 +12,7 @@ import (
|
|||||||
|
|
||||||
const defaultAuthAPIURL = "https://auth.api.shumengya.top"
|
const defaultAuthAPIURL = "https://auth.api.shumengya.top"
|
||||||
|
|
||||||
|
|
||||||
type SproutGateClient struct {
|
type SproutGateClient struct {
|
||||||
apiURL string
|
apiURL string
|
||||||
httpClient *http.Client
|
httpClient *http.Client
|
||||||
@@ -30,6 +31,8 @@ type SproutGateUser struct {
|
|||||||
Email string `json:"email"`
|
Email string `json:"email"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
func NewSproutGateClient(apiURL string) *SproutGateClient {
|
func NewSproutGateClient(apiURL string) *SproutGateClient {
|
||||||
if apiURL == "" {
|
if apiURL == "" {
|
||||||
apiURL = defaultAuthAPIURL
|
apiURL = defaultAuthAPIURL
|
||||||
|
|||||||
Reference in New Issue
Block a user