api

package
v0.0.0-...-bdae2e2 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2021 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Info

func Info(typ, mid string) ([]model.Song, error)

Info 根据类型和媒体ID获取信息

Types

type AlbumResponse

type AlbumResponse struct {
	Code int `json:"code"`
	Data struct {
		GetSongInfo []model.Song `json:"getSongInfo"`
	} `json:"data"`
}

AlbumResponse 专辑信息响应

type MP3

type MP3 struct {
	Singer      string
	Title       string
	DownloadURL string
}

MP3 mp3结构体,包含下载链接、文件名

func Prepare

func Prepare(songs []model.Song) ([]MP3, error)

Prepare 为下载做准备,组装下载URL

type SongInfoResponse

type SongInfoResponse struct {
	Code int          `json:"code"`
	Data []model.Song `json:"data"`
}

SongInfoResponse 歌曲信息响应

type SongURLResponse

type SongURLResponse struct {
	Code int `json:"code"`
	Req0 struct {
		Data struct {
			MidURLInfo []struct {
				Purl string `json:"purl"`
			} `json:"midurlinfo"`
		} `json:"data"`
	} `json:"req0"`
}

SongURLResponse 请求歌曲下载要用的URL的响应结构体

Jump to

Keyboard shortcuts

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