syntax = "proto3"; import "google/protobuf/empty.proto"; import "google/protobuf/wrappers.proto"; package cognito; option go_package = "github.com/hub1989/jc-protobuf/cognito"; service UserService { rpc createUser(CreateUserRequest) returns (UserResponse); rpc confirmRegistration(google.protobuf.StringValue) returns (google.protobuf.Empty); rpc getUserByUsername(google.protobuf.StringValue) returns (UserResponse); rpc getAllUsers(google.protobuf.Empty) returns (UsersResponse); rpc getAllUsersByFilter(ListUsersRequest) returns (UsersResponse); rpc getUsersByPattern(google.protobuf.StringValue) returns (UsersResponse); rpc updateUser(UpdateUserRequest) returns (google.protobuf.Empty); rpc deleteUsersWithExemptions(StringsRequest) returns (BooleanResponses); rpc deleteUsersMatching(google.protobuf.StringValue) returns (BooleanResponses); rpc deleteUser(google.protobuf.StringValue) returns (google.protobuf.BoolValue); } service PasswordService { rpc forgotPassword(google.protobuf.StringValue) returns (google.protobuf.BoolValue); rpc resetPassword(ResetPasswordRequest) returns (google.protobuf.BoolValue); } service GroupService { rpc getGroup(google.protobuf.StringValue) returns (GroupResponse); rpc getAllGroups(google.protobuf.Empty) returns (GroupsResponse); rpc createGroup(CreateGroupRequest) returns (GroupResponse); rpc addUserToGroup(AddUserToGroupRequest) returns (google.protobuf.BoolValue); rpc getUsersInGroup(google.protobuf.StringValue) returns (UsersResponse); } service AuthenticationService { rpc Authenticate(AuthenticationRequest) returns (AuthenticationResponse); } message AuthenticationRequest { string username = 1; string password = 2; } message AuthenticationResponse { google.protobuf.StringValue accessToken = 1; google.protobuf.StringValue tokenType = 2; google.protobuf.StringValue refreshToken = 3; google.protobuf.StringValue idToken = 4; int32 expiresIn = 5; } message ListUsersRequest { google.protobuf.StringValue filter = 1; } message BooleanResponses { repeated bool responses = 1; } message StringResponses { repeated string responses = 1; } message StringsRequest { repeated string requests = 1; } message CreateUserRequest { map attributes = 1; google.protobuf.StringValue password = 2; string username = 3; repeated google.protobuf.StringValue desiredDeliveryMediumList = 4; google.protobuf.StringValue messageActionType = 5; } message UpdateUserRequest { map attributes = 1; string username = 2; } message UserResponse { map attributes = 1; google.protobuf.StringValue userCreateDate = 2; google.protobuf.StringValue username = 3; bool enabled = 4; google.protobuf.StringValue userStatus = 5; } message UsersResponse { repeated UserResponse users = 1; } message ResetPasswordRequest { string username = 1; string confirmationCode = 2; string newPassword = 3; } message CreateGroupRequest { string groupName = 1; google.protobuf.StringValue description = 2; google.protobuf.StringValue roleArn = 3; google.protobuf.Int32Value precedence = 4; } message GroupsResponse { repeated GroupResponse groups = 1; } message GroupResponse { google.protobuf.StringValue groupName = 1; google.protobuf.StringValue userPoolId = 2; google.protobuf.StringValue description = 3; google.protobuf.StringValue roleArn = 4; google.protobuf.Int32Value precedence = 5; google.protobuf.StringValue lastModifiedDate = 6; google.protobuf.StringValue creationDate = 7; } message AddUserToGroupRequest { string groupName = 1; string username = 2; } service ComponentHealthService { rpc showDetails(google.protobuf.Empty) returns (InternalHealthResponse); } message InternalHealthResponse { string status = 1; string description = 2; map details = 3; string lastSeen = 4; string ipAddress = 5; }