merchant

package
v0.1.12 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UploadImage

func UploadImage(req *UploadReq, mchID, serialNo, sign string) (*uploadRes, error)

func UploadVideo

func UploadVideo(req *UploadReq, mchID, serialNo, sign string) (*uploadRes, error)

==================== 上传视频 ====================

Types

type UploadReq

type UploadReq struct {
	File bytes.Buffer `json:"file"`
	/*图片文件		是	body
	将媒体图片进行二进制转换,得到的媒体图片二进制内容,在请求body中上传此二进制内容。
	媒体图片只支持JPG、BMP、PNG格式,文件大小不能超过2M。
	示例值:pic1

	视频文件 是 body
	将媒体视频进行二进制转换,得到的媒体视频二进制内容,在请求body中上传此二进制内容。
	媒体视频只支持avi、wmv、mpeg、mp4、mov、mkv、flv、f4v、m4v、rmvb格式,文件大小不能超过5M。
	示例值:pic1
	*/
	Meta metaData `json:"meta"` //媒体文件元信息	是	body 媒体文件元信息,使用json表示,包含两个对象:filename、sha256。
}

==================== 上传图片 ====================

Jump to

Keyboard shortcuts

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