跳转到内容
View in the app

A better way to browse. Learn more.

彼岸论坛

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
欢迎抵达彼岸 彼岸花开 此处谁在 -彼岸论坛

[程序员] 用 Go 编写的蓝奏云解析工具,提供 API 和终端支持

发表于

🍎 go-lanzou 🍑

🐱 项目地址https://github.com/iuroc/go-lanzou

⬇️ 可执行程序go-lanzou.exe [7.53MB]

已实现功能

  • 获取单个文件(可带密码)的直链
  • 获取文件夹(可带密码)内最新一个文件的直链
  • 获取文件夹(可带密码)内任意页码的文件列表

iMXIhSY.png

作为模块

go get github.com/iuroc/go-lanzou
package main

import (
	"fmt"
	"github.com/iuroc/go-lanzou/lanzou"
)

func main() {
	shareURL := "https://www.lanzoui.com/imcSy2340ssb"
	downloadURL, err := lanzou.GetDownloadURL(shareURL)
	if err != nil {
		fmt.Println("解析失败")
	} else {
		fmt.Println("解析成功:" + downloadURL)
	}
}

API

// 获取文件夹最新的一个文件的信息,包含直链
//
// urlOrId 是文件夹的分享链接或 ID
//
// password 是访问密码
func lanzou.GetLatestFile(shareURL string, password string) (*lanzou.DownloadInfo, error)
// 获取单个文件的信息,包含直链
func lanzou.GetDownloadInfo(shareURL string, password string) (*lanzou.DownloadInfo, error)
// 获取文件夹中指定页码的文件列表
//
// page 的值务必从 0 开始,每次只允许增长 1 ,不可以直接从 0 变为 2 。
//
// 每次换页,务必暂停 1 秒以上。
func lanzou.GetFileList(shareURL string, password string, page int) ([]FileInfo, error)

Featured Replies

No posts to show

创建帐户或登录来提出意见

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.