Skip to content

Instantly share code, notes, and snippets.

@codesword
Last active January 22, 2018 17:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codesword/7398e18ca085f61fe51122572263c2f8 to your computer and use it in GitHub Desktop.
Save codesword/7398e18ca085f61fe51122572263c2f8 to your computer and use it in GitHub Desktop.
Input and Output messages
syntax = "proto3";
package authorization;
message Empty {}
//Input object
message ID {
// Unique identifier for permissions
string id = 1;
}
message Permission {
string id = 1;
string name = 2;
string created_at = 3;
string updated_at = 4;
}
message Permissions {
repeated Permission values = 1;
}
message AlterPermissionsRequest {
repeated string names = 1;
}
message Role {
string id = 1;
string name = 2;
string created_at = 3;
string updated_at = 4;
}
message Roles {
repeated Role values = 1;
}
message PermissionsToRoleRequest {
string role_id = 1;
repeated string permission_ids = 2;
}
message RolesToPermissionRequest {
string permission_id = 1;
repeated string role_ids = 2;
}
message RolesToUserRequest {
string user_id = 1;
repeated string role_ids = 2;
}
message UsersToRoleRequest {
string role_id = 1;
repeated string user_ids = 2;
}
@jon-whit
Copy link

jon-whit commented Jan 22, 2018

@codesword Do you have a link to the Authorization client that you have authored for Andlea? I'm looking to do something very similar to the authentication and authorize service you have worked on, and I was hoping to look at your design as a starting point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment