-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit c040b0c
Showing
30 changed files
with
29,581 additions
and
0 deletions.
There are no files selected for viewing
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,4 @@ | ||
node_modules | ||
dist/ | ||
.idea | ||
.vscode |
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 @@ | ||
grpc_web_proto_compile --clear_output_dir --verbosity=1 --js_out_options="import_style=commonjs,binary" --grpc_web_out_options="import_style=commonjs+dts,mode=grpcweb" ./proto ./src/grpc-web |
Large diffs are not rendered by default.
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,29 @@ | ||
{ | ||
"name": "grpc-web", | ||
"version": "1.0.0", | ||
"description": "", | ||
"main": "src/index.js", | ||
"types": "src/index.d.ts", | ||
"scripts": { | ||
"test": "ts-node src/index.ts" | ||
}, | ||
"author": "", | ||
"license": "ISC", | ||
"dependencies": { | ||
"google-protobuf": "^3.21.0", | ||
"grpc-web": "1.2.1" | ||
}, | ||
"devDependencies": { | ||
"@types/node": "^18.7.18", | ||
"ts-node": "^10.9.1", | ||
"xhr2": "^0.2.1", | ||
"protobufjs": "^7.1.1" | ||
}, | ||
"files": [ | ||
"index.js", | ||
"index.d.ts", | ||
"package-lock.json", | ||
"tsconfig.json", | ||
"src/**" | ||
] | ||
} |
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,74 @@ | ||
syntax = "proto3"; | ||
|
||
package web.authentication; | ||
|
||
service ClientAuthentication { | ||
rpc viaAuthCode (AuthRequest) returns (AuthResponse) {} | ||
rpc logout (Empty) returns (Empty) {} | ||
} | ||
|
||
message PlayerInfo { | ||
int64 nucleusId = 1; | ||
int64 personaId = 2; | ||
int32 platformId = 3; | ||
} | ||
|
||
enum Platform { | ||
UNKNOWN = 0; | ||
PC = 1; | ||
PS4 = 2; | ||
XBOXONE = 3; | ||
PS5 = 4; | ||
XBSX = 5; | ||
COMMON = 6; | ||
} | ||
|
||
enum Reason { | ||
NONE = 0; | ||
PLAYER = 1; | ||
SYNC = 2; | ||
} | ||
|
||
message AuthRequest { | ||
string authCode = 1; | ||
string redirectUri = 2; | ||
string product = 3; | ||
string firstPartyId = 4; | ||
Platform platform = 5; | ||
} | ||
|
||
message Duration { | ||
int64 seconds = 1; | ||
int32 nanos = 2; | ||
} | ||
|
||
message TimeTravel { | ||
Duration offset = 1; | ||
} | ||
|
||
message ProtocolVersionOverride { | ||
string original = 1; | ||
string overridden = 2; | ||
Reason reason = 3; | ||
} | ||
|
||
enum UserBits { | ||
USER_BIT_UNSPECIFIED = 0; | ||
USER_BIT_ACCEPTED_TOS = 1; | ||
USER_BIT_ENABLE_USERSHARING = 2; | ||
USER_BIT_ENABLE_CRASHREPORTS = 3; | ||
USER_BIT_COMPLETED_TUTORIAL = 4; | ||
USER_BIT_CLIENT_ENABLE_USAGESHARING = 5; | ||
} | ||
|
||
message Empty { | ||
} | ||
|
||
message AuthResponse { | ||
string sessionId = 1; | ||
PlayerInfo player = 3; | ||
repeated UserBits userBits = 4; | ||
TimeTravel timeTravel = 5; | ||
ProtocolVersionOverride protocolVersionOverride = 6; | ||
} | ||
|
Oops, something went wrong.