Skip to content

Instantly share code, notes, and snippets.

@christopher-wong
Created July 21, 2020 19:42
Show Gist options
  • Save christopher-wong/20d6e9b182aafd250f02b40f80091471 to your computer and use it in GitHub Desktop.
Save christopher-wong/20d6e9b182aafd250f02b40f80091471 to your computer and use it in GitHub Desktop.
syntax = "proto3";
package proto;
option go_package = ".;proto";
service Badger {
rpc SendPush(SendPushReq) returns (PushResp) {}
rpc SendRawPush(SendRawPushReq) returns (PushResp) {}
rpc Register(RegisterReq) returns (RegisterResp) {}
rpc Unregister(UnregisterReq) returns (UnregisterResp) {}
}
message APNS {
string title = 1;
string body = 2;
string badge = 3;
}
message SendPushReq {
string patient_id = 1;
APNS message = 2;
}
message SendRawPushReq {
string aps_object = 1; // raw APNS json, encoded as a string
}
message PushResp {}
message RegisterReq {
string token = 1;
}
message RegisterResp {
string registration_id = 1;
}
message UnregisterReq {
string registration_id = 1;
}
message UnregisterResp {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment