generated from pkg/go-template
15 lines
373 B
Go
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()
|
|
}
|