ciweimaoapi

package module
v0.0.0-...-6f710c6 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2023 License: MIT Imports: 8 Imported by: 2

README

API 文档

本文档是对 ciweimaoapi 包提供的 API 进行说明。

方法列表

  • RecommendBookIndexApi()
  • RecommendComicIndexApi()
  • FreeRecommendIndexApi()
  • BookListIndexApi(page string)
  • DiscountIndexApi()
  • RecommendExposureBooksApi(moduleName, bookIdList string)
  • BookInfoApi(bookID string)
  • UseGeetestApi(loginName string)
  • GeetestFirstRegisterApi(loginName string) gjson.Result
  • BookGetPriceApi(bookID string)
  • BuyBookApi(bookID, shelfId string)
  • ComicInfoApi(bookID string)
  • BookReviewInfoApi(bookID, page string)
  • BookLongReviewInfoApi(bookID, page string)
  • BookContentReviewNumberInfoApi(chapterId string)
  • BookContentReviewInfoApi(chapterId, paragraphIndex, page string)
  • BookFansListApi(bookID, page string)
  • BookRankListApi(timeType, order, page string)
  • BookOperateListApi(bookID, page string)
  • CatalogInfoApi(bookID string)
  • ContentInfoApi(chapterID, command string)
  • ContentKeyApi(chapterID string)
  • BuyContentApi(chapterID, shelfId string)
  • UserPropInfoApi()
  • UserInfoApi()
  • SignupApi(loginName string, passwd string, validate string, challenge string)
  • ShelfInfoApi()
  • ShelfBookInfoApi(shelfId string)
  • AddBookshelfApi(bookId, shelfId string)
  • DeleteBookshelfApi(bookId, shelfId string)
  • RegisterApi()
  • SearchInfoApi(keyword, status, page, isPaid string, tags ...string)

RecommendBookIndexApi()

主页推荐书籍

func RecommendBookIndexApi() *client.Client

返回值

  • *client.Client - API 请求客户端

RecommendComicIndexApi()

主页推荐漫画

func RecommendComicIndexApi() *client.Client

返回值

  • *client.Client - API 请求客户端

FreeRecommendIndexApi()

主免费页推荐书籍

func FreeRecommendIndexApi() *client.Client

返回值

  • *client.Client - API 请求客户端

BookListIndexApi(page string)

书单推荐列表

func BookListIndexApi(page string) *client.Client

参数

  • page string - 页码

返回值

  • *client.Client - API 请求客户端

DiscountIndexApi()

特扣推荐书籍

func DiscountIndexApi() *client.Client

返回值

  • *client.Client - API 请求客户端

RecommendExposureBooksApi(moduleName, bookIdList string)

推荐书籍曝光

func RecommendExposureBooksApi(moduleName, bookIdList string) *client.Client

参数

  • moduleName string - 模块名称
  • bookIdList string - 书籍 ID 列表

返回值

  • *client.Client - API 请求客户端

BookInfoApi(bookID string)

获取书籍信息

func BookInfoApi(bookID string) *client.Client

参数

  • bookID string - 书籍 ID

返回值

  • *client.Client - API 请求客户端

UseGeetestApi(loginName string)

使用 Geetest 进行验证

func UseGeetestApi(loginName string) *client.Client

参数

  • loginName string - 登录名

返回值

  • *client.Client - API 请求客户端

GeetestFirstRegisterApi(loginName string) gjson.Result

首次 Geetest 注册

func GeetestFirstRegisterApi(loginName string) gjson.Result

参数

  • loginName string - 登录名

返回值

  • gjson.Result - 解析后的 JSON 结果

BookGetPriceApi(bookID string)

获取书籍价格

func BookGetPriceApi(bookID string) *client.Client

参数

  • bookID string - 书籍 ID

返回值

  • *client.Client - API 请求客户端

BuyBookApi(bookID, shelfId string)

购买书籍

func BuyBookApi(bookID, shelfId string) *client.Client

参数

  • bookID string - 书籍 ID
  • shelfId string - 书架 ID

返回值

  • *client.Client - API 请求客户端

ComicInfoApi(bookID string)

获取漫画信息

func ComicInfoApi(bookID string) *client.Client

参数

  • bookID string - 漫画 ID

返回值

  • *client.Client - API 请求客户端

BookReviewInfoApi(bookID, page string)

获取书籍评论信息

func BookReviewInfoApi(bookID, page string) *client.Client

参数

  • bookID string - 书籍 ID
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

BookLongReviewInfoApi(bookID, page string)

获取长评列表

func BookLongReviewInfoApi(bookID, page string) *client.Client

参数

  • bookID string - 书籍 ID
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

BookContentReviewNumberInfoApi(chapterId string)

获取内容评论数量信息

func BookContentReviewNumberInfoApi(chapterId string) *client.Client

参数

  • chapterId string - 章节 ID

返回值

  • *client.Client - API 请求客户端

BookContentReviewInfoApi(chapterId, paragraphIndex, page string)

获取内容评论信息

func BookContentReviewInfoApi(chapterId, paragraphIndex, page string) *client.Client

参数

  • chapterId string - 章节 ID
  • paragraphIndex string - 段落索引
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

BookFansListApi(bookID, page string)

获取书籍粉丝列表

func BookFansListApi(bookID, page string) *client.Client

参数

  • bookID string - 书籍 ID
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

BookRankListApi(timeType, order, page string)

获取书籍排行榜列表

func BookRankListApi(timeType, order, page string) *client.Client

参数

  • timeType string - 时间类型
  • order string - 排序方式
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

BookOperateListApi(bookID, page string)

获取书籍操作记录列表

func BookOperateListApi(bookID, page string) *client.Client

参数

  • bookID string - 书籍 ID
  • page string - 页码

返回值

  • *client.Client - API 请求客户端

CatalogInfoApi(bookID string)

获取目录信息

func CatalogInfoApi(bookID string) *client.Client

参数

  • bookID string - 书籍 ID

返回值

  • *client.Client - API 请求客户端

ContentInfoApi(chapterID, command string)

获取内容信息

func ContentInfoApi(chapterID, command string) *client.Client

参数

  • chapterID string - 章节 ID
  • command string - 命令

返回值

  • *client.Client - API 请求客户端

ContentKeyApi(chapterID string)

获取内容密钥

func ContentKeyApi(chapterID string) *client.Client

参数

  • chapterID string - 章节 ID

返回值

  • *client.Client - API 请求客户端

BuyContentApi(chapterID, shelfId string)

购买内容

func BuyContentApi(chapterID, shelfId string) *client.Client

参数

  • chapterID string - 章节 ID
  • shelfId string - 书架 ID

返回值

  • *client.Client - API 请求客户端

UserPropInfoApi()

获取用户道具信息

func UserPropInfoApi() *client.Client

返回值

  • *client.Client - API 请求客户端

UserInfoApi()

获取用户信息

func UserInfoApi() *client.Client

返回值

  • *client.Client - API 请求客户端 抱歉,API 文档中断了。以下是继续的部分:

SignupApi(loginName string, passwd string, validate string, challenge string)

注册用户

func SignupApi(loginName string, passwd string, validate string, challenge string) *client.Client

参数

  • loginName string - 登录名
  • passwd string - 密码
  • validate string - 验证码
  • challenge string - 验证难度参数

返回值

  • *client.Client - API 请求客户端

ShelfInfoApi()

获取书架信息

func ShelfInfoApi() *client.Client

返回值

  • *client.Client - API 请求客户端

ShelfBookInfoApi(shelfId string)

获取书架的书籍信息

func ShelfBookInfoApi(shelfId string) *client.Client

参数

  • shelfId string - 书架 ID

返回值

  • *client.Client - API 请求客户端

AddBookshelfApi(bookId, shelfId string)

添加书籍到书架

func AddBookshelfApi(bookId, shelfId string) *client.Client

参数

  • bookId string - 书籍 ID
  • shelfId string - 书架 ID

返回值

  • *client.Client - API 请求客户端

DeleteBookshelfApi(bookId, shelfId string)

从书架删除书籍

func DeleteBookshelfApi(bookId, shelfId string) *client.Client

参数

  • bookId string - 书籍 ID
  • shelfId string - 书架 ID

返回值

  • *client.Client - API 请求客户端

RegisterApi()

用户注册

func RegisterApi() *client.Client

返回值

  • *client.Client - API 请求客户端

SearchInfoApi(keyword, status, page, isPaid string, tags ...string)

搜索书籍信息

func SearchInfoApi(keyword, status, page, isPaid string, tags ...string) *client.Client

参数

  • keyword string - 搜索关键词
  • status string - 书籍状态
  • page string - 页码
  • isPaid string - 是否付费
  • tags ...string - 标签列表

返回值

  • *client.Client - API 请求客户端

以上是 ciweimaoapi 包提供的 API 方法列表。请根据需要选择合适的方法进行使用。

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RankPeriod = struct {
	Week  string // 周榜
	Month string // 月榜
	Total string // 总榜
}{Week: "week", Month: "month", Total: "total"}
View Source
var RankType = struct {
	NoVipClick string // 点击
	FansValue  string // 畅销
	Yp         string // 月票
	YpNew      string // 新书
	Favor      string // 收藏
	Recommend  string // 推荐
	Blade      string // 刀片
	WordCount  string // 更新
	Tsukkomi   string // 吐槽
	Complet    string // 完本
	TrackRead  string // 追读
}{
	NoVipClick: "no_vip_click",
	FansValue:  "fans_value",
	Yp:         "yp",
	YpNew:      "yp_new",
	Favor:      "favor",
	Recommend:  "recommend",
	Blade:      "blade",
	WordCount:  "word_count",
	Tsukkomi:   "tsukkomi",
	Complet:    "complet",
	TrackRead:  "track_read",
}
View Source
var SearchType = struct {
	Free string // 免费
	Paid string // 付费
}{Free: "free", Paid: "paid"}

Functions

func AddBookshelf

func AddBookshelf(bookId, shelfId string) *structure.AddBookToBookShelfStructure

func ChaptersYield

func ChaptersYield(bookId string) chan structure.ChapterStructure

func DeleteBookshelf

func DeleteBookshelf(bookId, shelfId string) *structure.DelBookFromBookShelfStructure

func DownloadBookYield

func DownloadBookYield(bookId string) chan *structure.ContentStructure

func GetBookContentReview

func GetBookContentReview(chapterId string) chan structure.TsukkomiListStructure

func GetBookFans

func GetBookFans(bookId, page string) *structure.BookFansStructure

func GetBookInfo

func GetBookInfo(bookId string) *structure.BookInfoStructure

func GetBookLongReviewInfo

func GetBookLongReviewInfo(bookId, page string) *structure.ReviewLongStructure

func GetBookOperate

func GetBookOperate(bookId, page string) *structure.BookOperateStructure

func GetBookReviewInfo

func GetBookReviewInfo(bookId, page string) *structure.ReviewStructure

func GetBookshelfInfo

func GetBookshelfInfo() []structure.BookShelfBookInfoStructure

func GetCatalog

func GetCatalog(bookId string) *structure.ChapterListStructure

func GetContent

func GetContent(chapterId string) *structure.ContentStructure

func GetRankInfo

func GetRankInfo(period, rankType, page string) *structure.RankInfoStructure

func GetRecommendIndex

func GetRecommendIndex() *structure.RecommendIndexStructure

func GetRegister

func GetRegister() *structure.RegisterStructure

func GetSearchInfo

func GetSearchInfo(keyword, status, page, isPaid string) *structure.SearchStructure

func GetUserInfo

func GetUserInfo() *structure.UserStructure

func SetciweimaoAuthentication

func SetciweimaoAuthentication(token, account string) error

Types

This section is empty.

Directories

Path Synopsis
ciweimao
api

Jump to

Keyboard shortcuts

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