-
Notifications
You must be signed in to change notification settings - Fork 1
/
gog.protocols.pb.proto
40 lines (37 loc) · 1.1 KB
/
gog.protocols.pb.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
syntax = "proto2";
package gog.protocols.pb;
/**
* Header used for all Galaxy messages.
*/
message Header {
required uint32 sort = 1; // Subprotocol
required uint32 type = 2; // Message type
optional uint32 size = 3 [default = 0]; // Payload size
optional uint32 oseq = 4; // Sequence number
extensions 100 to max;
}
/**
* Header extensions for response messages. Not instanciated on its own, only
* provides extension IDs for the Header message.
*/
message Response {
enum Status {
UNKNOWN_RESPONSE = 0;
OK = 200;
ACCEPTED = 202;
BAD_REQUEST = 400;
UNAUTHORIZED = 401;
FORBIDDEN = 403;
NOT_FOUND = 404;
CONFLICT = 409;
INTERNAL_ERROR = 500;
NOT_IMPLEMENTED = 501;
UNAVAILABLE = 503;
}
extend Header {
optional uint32 rseq = 100; // Sequence number of message responded to
optional Status code = 101 [default = OK]; // Status code
optional string description = 102; // Error description
optional uint32 retry_after = 103; // Time to retry after in seconds
}
}