oauth

package
v1.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package oauth 授权相关

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AccessToken

func AccessToken(ctx context.Context, clt *core.SDKClient, req *oauth.AccessTokenRequest) (*oauth.AccessToken, error)

AccessToken 获取Token 利用授权码 auth_code,请求小红书服务器,获取 access_token 和 refresh_token 及当前账户的广告主 ID。

func RefreshToken

func RefreshToken(ctx context.Context, clt *core.SDKClient, req *oauth.RefreshTokenRequest) (*oauth.AccessToken, error)

RefreshToken 刷新Token 请求小红书服务器,刷新 access_token 和 refresh_token 及 token 过期时间。

func URL

func URL(ctx context.Context, clt *core.SDKClient, req *oauth.URLRequest) string

URL 生成oauth授权链接

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL