-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: more gRPC endpoints and refactor of HTTP
- Loading branch information
1 parent
f0b6bd9
commit 44ae79c
Showing
37 changed files
with
564 additions
and
648 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
|
||
DATABASE_URL="postgresql://postgres:vzr3XyG4pxJK7y8D@localhost:5432/authcore" |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
syntax = "proto3"; | ||
|
||
package authcore.auth.basic; | ||
|
||
message RegisterRequest { | ||
string email = 3; | ||
string password = 2; | ||
string application_id = 4; | ||
} | ||
|
||
message RegisterResponse { | ||
string user_id = 1; | ||
} | ||
|
||
enum ErrorCode { | ||
EmailFormat = 0; | ||
PasswordFormat = 1; | ||
AlreadyExists = 2; | ||
ApplicationDoesNotExist = 3; | ||
InternalServerError = 4; | ||
} | ||
|
||
service BasicAuth { | ||
rpc Register(RegisterRequest) returns (RegisterResponse); | ||
} |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
syntax = "proto3"; | ||
|
||
package authcore.error; | ||
|
||
message DetailedError { | ||
string code = 1; | ||
string message = 2; | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
syntax = "proto3"; | ||
|
||
package authcore.session; | ||
|
||
message ValidateRequest { | ||
string refreshToken = 1; | ||
} | ||
|
||
message ValidateResponse {} | ||
|
||
message InvalidateRequest { | ||
string accessToken = 1; | ||
} | ||
|
||
message InvalidateResponse {} | ||
|
||
service Session { | ||
rpc Validate(ValidateRequest) returns (ValidateResponse) {} | ||
rpc Invalidate(InvalidateRequest) returns (InvalidateResponse) {} | ||
} |
Oops, something went wrong.