icechen d247aded23
All checks were successful
continuous-integration/drone/push Build is passing
feat: service-lark
2022-01-12 01:44:10 +08:00

15 lines
373 B
Go

package lark
import (
"context"
"github.com/larksuite/oapi-sdk-go/core"
authen "github.com/larksuite/oapi-sdk-go/service/authen/v1"
)
func (l Lark) Auth(code string) (*authen.UserAccessTokenInfo, error) {
return l.userService.Authens.AccessToken(core.WrapContext(context.Background()), &authen.AuthenAccessTokenReqBody{
GrantType: "",
Code: code,
}).Do()
}