syntax = "proto3"; package s3; import "google/protobuf/empty.proto"; import "google/protobuf/wrappers.proto"; option go_package = "github.com/soardigital/klozr-protobuf/s3"; service UploadFileService { rpc uploadFile(UploadFileRequest) returns (UploadFileResponse); } service DownloadFileService { rpc downloadFile(DownloadFileRequest) returns (DownloadFileResponse); rpc getPresignedUrl(DownloadFileRequest) returns (FileUrlResponse); } service ReadService { rpc readObjectsInBucket(google.protobuf.StringValue) returns (S3ObjectsResponse); } message UploadFileRequest { string bucketName = 1; string s3Name = 2; bytes fileData = 3; string s3Folder = 4; } message UploadFileResponse { google.protobuf.StringValue url = 1; } message DownloadFileRequest { string bucketName = 1; string fileName = 2; } message DownloadFileResponse { bytes file = 1; } message FileUrlResponse { google.protobuf.StringValue url = 1; } message S3ObjectResponse { string key = 1; int64 size = 2; string owner = 3; } message S3ObjectsResponse { repeated S3ObjectResponse objects = 1; }