Allow restricting file download
This commit is contained in:
@@ -21,6 +21,9 @@ message File {
|
||||
google.protobuf.Timestamp uploaded_on = 1;
|
||||
google.protobuf.Timestamp expires_on = 2;
|
||||
string original_filename = 3;
|
||||
string passcode = 4;
|
||||
int64 current_views = 5;
|
||||
int64 max_views = 6;
|
||||
};
|
||||
|
||||
Metadata metadata = 3;
|
||||
@@ -33,6 +36,8 @@ message UploadFileRequest {
|
||||
bytes data = 1;
|
||||
string original_filename = 2;
|
||||
google.protobuf.Timestamp expires_on = 3;
|
||||
int64 max_views = 4;
|
||||
bool with_passcode = 5;
|
||||
}
|
||||
message UploadFileResponse {
|
||||
string id = 1;
|
||||
@@ -42,6 +47,7 @@ message UploadFileResponse {
|
||||
// Get
|
||||
message GetFileRequest {
|
||||
string id = 1;
|
||||
string passcode = 2;
|
||||
}
|
||||
message GetFileResponse {
|
||||
File file = 1;
|
||||
|
Reference in New Issue
Block a user