hbookerapi

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HbookerDecode

func HbookerDecode(content string, encryptKey string) []byte

HbookerDecode 入口函数

func SHA256

func SHA256(data []byte) []byte

SHA256 sha256 编码

Types

type API

type API struct {
	HttpClient HttpsClient
}

func (*API) GetAutoSignAPI

func (hbooker *API) GetAutoSignAPI(device string) (*hbookermodel.LoginData, error)

func (*API) GetBookInfo

func (hbooker *API) GetBookInfo(bookId string) (*hbookermodel.BookInfo, error)

func (*API) GetBookShelfIndexesInfoAPI

func (hbooker *API) GetBookShelfIndexesInfoAPI(shelfId string) ([]hbookermodel.ShelfBookList, error)

func (*API) GetBookShelfInfoAPI

func (hbooker *API) GetBookShelfInfoAPI() ([]hbookermodel.ShelfList, error)

func (*API) GetBuyChapterAPI

func (hbooker *API) GetBuyChapterAPI(chapterId, shelfId string) (*hbookermodel.ContentBuy, error)

func (*API) GetChapterContentAPI

func (hbooker *API) GetChapterContentAPI(chapterId, chapterKey string) (*hbookermodel.ChapterInfo, error)

func (*API) GetChapterKey added in v0.0.8

func (hbooker *API) GetChapterKey(chapterId string) (string, error)

func (*API) GetDivisionListByBookId

func (hbooker *API) GetDivisionListByBookId(bookId string) ([]hbookermodel.VolumeList, error)

func (*API) GetGeetestRegisterAPI

func (hbooker *API) GetGeetestRegisterAPI(UserID string) (*hbookermodel.GeetestFirstRegisterStruct, error)

func (*API) GetSearchBooksAPI

func (hbooker *API) GetSearchBooksAPI(keyword string, page any) ([]hbookermodel.BookInfo, error)

func (*API) GetUseGeetestAPI

func (hbooker *API) GetUseGeetestAPI(loginName string) (*hbookermodel.GeetestData, error)

func (*API) GetUserInfo added in v0.1.2

func (hbooker *API) GetUserInfo() (*hbookermodel.UserInfoData, error)

func (*API) MySignLogin deprecated added in v0.1.2

func (hbooker *API) MySignLogin(username, password, validate, challenge string) (*hbookermodel.LoginData, error)

Deprecated: MySignLogin is deprecated, hbooker has joined login verification, so this method is no longer available

type HttpsClient

type HttpsClient struct {
	Version       string
	APIBaseURL    string
	UserAgent     string
	AndroidApiKey string
	DeviceToken   string
	LoginToken    string
	Account       string
	Debug         bool
	OutputDebug   bool
	ProxyURL      string
	ProxyURLArray []string
}

func (*HttpsClient) Get

func (httpsClient *HttpsClient) Get(path string, params map[string]string, model any) (*req.Response, error)

func (*HttpsClient) NewDefault

func (httpsClient *HttpsClient) NewDefault() *req.Client

func (*HttpsClient) Post

func (httpsClient *HttpsClient) Post(path string, params map[string]string, model any) (*req.Response, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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