diff --git a/mengyastore-backend-go/internal/auth/sproutgate.go b/mengyastore-backend-go/internal/auth/sproutgate.go index 1958d1b..c10780f 100644 --- a/mengyastore-backend-go/internal/auth/sproutgate.go +++ b/mengyastore-backend-go/internal/auth/sproutgate.go @@ -12,6 +12,7 @@ import ( const defaultAuthAPIURL = "https://auth.api.shumengya.top" + type SproutGateClient struct { apiURL string httpClient *http.Client @@ -30,6 +31,8 @@ type SproutGateUser struct { Email string `json:"email"` } + + func NewSproutGateClient(apiURL string) *SproutGateClient { if apiURL == "" { apiURL = defaultAuthAPIURL