Initial commit
This commit is contained in:
commit
12f82e106e
10 changed files with 409 additions and 0 deletions
46
models.go
Normal file
46
models.go
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
package main
|
||||
|
||||
type ChunkReport struct {
|
||||
UploadedChunks int
|
||||
UploadedBytes int64
|
||||
TotalChunks int
|
||||
TotalSize int64
|
||||
}
|
||||
|
||||
type uploadInfo struct {
|
||||
chunkID string
|
||||
filename string
|
||||
totalSize int64
|
||||
contentType string
|
||||
allowedDownloads int
|
||||
expiryDays int
|
||||
password string
|
||||
}
|
||||
|
||||
type UploadResponse struct {
|
||||
Result string `json:"Result"`
|
||||
FileInfo FileInfo `json:"FileInfo"`
|
||||
IncludeFilename bool `json:"IncludeFilename"`
|
||||
}
|
||||
|
||||
type FileInfo struct {
|
||||
ID string `json:"Id"`
|
||||
Name string `json:"Name"`
|
||||
Size string `json:"Size"`
|
||||
HotlinkId string `json:"HotlinkId"`
|
||||
ContentType string `json:"ContentType"`
|
||||
ExpireAtString string `json:"ExpireAtString"`
|
||||
UrlDownload string `json:"UrlDownload"`
|
||||
UrlHotlink string `json:"UrlHotlink"`
|
||||
ExpireAt int64 `json:"ExpireAt"`
|
||||
SizeBytes int64 `json:"SizeBytes"`
|
||||
DownloadsRemaining int `json:"DownloadsRemaining"`
|
||||
DownloadsCount int `json:"DownloadsCount"`
|
||||
UnlimitedDownloads bool `json:"UnlimitedDownloads"`
|
||||
UnlimitedTime bool `json:"UnlimitedTime"`
|
||||
RequiresClientSideDecryption bool `json:"RequiresClientSideDecryption"`
|
||||
IsEncrypted bool `json:"IsEncrypted"`
|
||||
IsEndToEndEncrypted bool `json:"IsEndToEndEncrypted"`
|
||||
IsPasswordProtected bool `json:"IsPasswordProtected"`
|
||||
IsSavedOnLocalStorage bool `json:"IsSavedOnLocalStorage"`
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue