Created
November 16, 2020 07:39
-
-
Save asim/31628c6faf61b392b31bcefc79daa289 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
syntax = "proto3"; | |
package posts; | |
service Posts { | |
rpc Save(SaveRequest) returns (SaveResponse) {} | |
rpc Query(QueryRequest) returns (QueryResponse) {} | |
rpc Delete(DeleteRequest) returns (DeleteResponse) {} | |
} | |
message SaveRequest { | |
string id = 1; | |
string title = 2; | |
string slug = 3; | |
string content = 4; | |
int64 timestamp = 5; | |
repeated string tags = 6; | |
} | |
message SaveResponse { | |
string id = 1; | |
} | |
message Post { | |
string id = 1; | |
string title = 2; | |
string slug = 3; | |
string content = 4; | |
int64 created = 5; | |
int64 updated = 6; | |
string author = 7; | |
repeated string tags = 8; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment