[英]How to connect supabase with my golang for jwt token verification API from supabase?
沒有任何關於此的專門視頻或文章。
我真的需要這個解決方案。
導入(“github.com/nedpals/supabase-go”)
func verifyTokenSupabase(token string) (*supabase.User, error) {
supabase := supabase.CreateClient(supabaseUrl,supabaseAnonKey)
ctx := context.Background()
ctx, _ = context.WithTimeout(ctx, 60000*time.Millisecond)
fmt.Println(ctx)
user, err := supabase.Auth.User(ctx, token)
if err != nil {
return user, err
}
return user, nil
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.