@barumetric/contracts 1.3.14 → 1.3.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/gen/ts/auth.ts +22 -38
- package/package.json +1 -1
- package/proto/auth.proto +23 -37
package/gen/ts/auth.ts
CHANGED
|
@@ -92,48 +92,18 @@ export interface TelegramConsumeResponse {
|
|
|
92
92
|
sessionToken: string;
|
|
93
93
|
}
|
|
94
94
|
|
|
95
|
-
export interface SessionMetadata {
|
|
96
|
-
location: LocationInfo | undefined;
|
|
97
|
-
device: DeviceInfo | undefined;
|
|
98
|
-
ip: string;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
export interface LocationInfo {
|
|
102
|
-
country: string;
|
|
103
|
-
city: string;
|
|
104
|
-
latidute: number;
|
|
105
|
-
longitude: number;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
export interface DeviceInfo {
|
|
109
|
-
browser: string;
|
|
110
|
-
os: string;
|
|
111
|
-
type: string;
|
|
112
|
-
}
|
|
113
|
-
|
|
114
95
|
export interface VkInitResponse {
|
|
115
96
|
url: string;
|
|
116
97
|
}
|
|
117
98
|
|
|
118
99
|
export interface VkVerifyRequest {
|
|
119
|
-
|
|
120
|
-
|
|
100
|
+
code: string;
|
|
101
|
+
state: string;
|
|
102
|
+
deviceId: string;
|
|
121
103
|
metadata: SessionMetadata | undefined;
|
|
122
104
|
}
|
|
123
105
|
|
|
124
106
|
export interface VkVerifyResponse {
|
|
125
|
-
sessionId?: string | undefined;
|
|
126
|
-
accessToken?: string | undefined;
|
|
127
|
-
refreshToken?: string | undefined;
|
|
128
|
-
sessionToken?: string | undefined;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
export interface VkConsumeRequest {
|
|
132
|
-
sessionId: string;
|
|
133
|
-
metadata: SessionMetadata | undefined;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
export interface VkConsumeResponse {
|
|
137
107
|
accessToken: string;
|
|
138
108
|
refreshToken: string;
|
|
139
109
|
sessionToken: string;
|
|
@@ -154,6 +124,25 @@ export interface GoogleVerifyResponse {
|
|
|
154
124
|
sessionToken: string;
|
|
155
125
|
}
|
|
156
126
|
|
|
127
|
+
export interface SessionMetadata {
|
|
128
|
+
location: LocationInfo | undefined;
|
|
129
|
+
device: DeviceInfo | undefined;
|
|
130
|
+
ip: string;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export interface LocationInfo {
|
|
134
|
+
country: string;
|
|
135
|
+
city: string;
|
|
136
|
+
latidute: number;
|
|
137
|
+
longitude: number;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export interface DeviceInfo {
|
|
141
|
+
browser: string;
|
|
142
|
+
os: string;
|
|
143
|
+
type: string;
|
|
144
|
+
}
|
|
145
|
+
|
|
157
146
|
export const AUTH_V1_PACKAGE_NAME = "auth.v1";
|
|
158
147
|
|
|
159
148
|
export interface AuthServiceClient {
|
|
@@ -177,8 +166,6 @@ export interface AuthServiceClient {
|
|
|
177
166
|
|
|
178
167
|
vkVerify(request: VkVerifyRequest): Observable<VkVerifyResponse>;
|
|
179
168
|
|
|
180
|
-
vkConsume(request: VkConsumeRequest): Observable<VkConsumeResponse>;
|
|
181
|
-
|
|
182
169
|
googleInit(request: Empty): Observable<GoogleInitResponse>;
|
|
183
170
|
|
|
184
171
|
googleVerify(request: GoogleVerifyRequest): Observable<GoogleVerifyResponse>;
|
|
@@ -211,8 +198,6 @@ export interface AuthServiceController {
|
|
|
211
198
|
|
|
212
199
|
vkVerify(request: VkVerifyRequest): Promise<VkVerifyResponse> | Observable<VkVerifyResponse> | VkVerifyResponse;
|
|
213
200
|
|
|
214
|
-
vkConsume(request: VkConsumeRequest): Promise<VkConsumeResponse> | Observable<VkConsumeResponse> | VkConsumeResponse;
|
|
215
|
-
|
|
216
201
|
googleInit(request: Empty): Promise<GoogleInitResponse> | Observable<GoogleInitResponse> | GoogleInitResponse;
|
|
217
202
|
|
|
218
203
|
googleVerify(
|
|
@@ -233,7 +218,6 @@ export function AuthServiceControllerMethods() {
|
|
|
233
218
|
"telegramConsume",
|
|
234
219
|
"vkInit",
|
|
235
220
|
"vkVerify",
|
|
236
|
-
"vkConsume",
|
|
237
221
|
"googleInit",
|
|
238
222
|
"googleVerify",
|
|
239
223
|
];
|
package/package.json
CHANGED
package/proto/auth.proto
CHANGED
|
@@ -17,7 +17,6 @@ service AuthService {
|
|
|
17
17
|
|
|
18
18
|
rpc VkInit (google.protobuf.Empty) returns (VkInitResponse);
|
|
19
19
|
rpc VkVerify (VkVerifyRequest) returns (VkVerifyResponse);
|
|
20
|
-
rpc VkConsume (VkConsumeRequest) returns (VkConsumeResponse);
|
|
21
20
|
|
|
22
21
|
rpc GoogleInit (google.protobuf.Empty) returns (GoogleInitResponse);
|
|
23
22
|
rpc GoogleVerify (GoogleVerifyRequest) returns (GoogleVerifyResponse);
|
|
@@ -102,50 +101,18 @@ message TelegramConsumeResponse {
|
|
|
102
101
|
string session_token = 3;
|
|
103
102
|
}
|
|
104
103
|
|
|
105
|
-
message SessionMetadata {
|
|
106
|
-
LocationInfo location = 1;
|
|
107
|
-
DeviceInfo device = 2;
|
|
108
|
-
string ip = 3;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
message LocationInfo {
|
|
112
|
-
string country = 1;
|
|
113
|
-
string city = 2;
|
|
114
|
-
int32 latidute = 3;
|
|
115
|
-
int32 longitude = 4;
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
message DeviceInfo {
|
|
119
|
-
string browser = 1;
|
|
120
|
-
string os = 2;
|
|
121
|
-
string type = 3;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
104
|
message VkInitResponse {
|
|
125
105
|
string url = 1;
|
|
126
106
|
}
|
|
127
107
|
|
|
128
108
|
message VkVerifyRequest {
|
|
129
|
-
string
|
|
130
|
-
string
|
|
131
|
-
|
|
109
|
+
string code = 1;
|
|
110
|
+
string state = 2;
|
|
111
|
+
string device_id = 3;
|
|
112
|
+
SessionMetadata metadata = 4;
|
|
132
113
|
}
|
|
133
114
|
|
|
134
115
|
message VkVerifyResponse {
|
|
135
|
-
oneof result {
|
|
136
|
-
string session_id = 1;
|
|
137
|
-
string access_token = 2;
|
|
138
|
-
string refresh_token = 3;
|
|
139
|
-
string session_token = 4;
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
message VkConsumeRequest {
|
|
144
|
-
string session_id = 1;
|
|
145
|
-
SessionMetadata metadata = 2;
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
message VkConsumeResponse {
|
|
149
116
|
string access_token = 1;
|
|
150
117
|
string refresh_token = 2;
|
|
151
118
|
string session_token = 3;
|
|
@@ -165,3 +132,22 @@ message GoogleVerifyResponse {
|
|
|
165
132
|
string refresh_token = 2;
|
|
166
133
|
string session_token = 3;
|
|
167
134
|
}
|
|
135
|
+
|
|
136
|
+
message SessionMetadata {
|
|
137
|
+
LocationInfo location = 1;
|
|
138
|
+
DeviceInfo device = 2;
|
|
139
|
+
string ip = 3;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
message LocationInfo {
|
|
143
|
+
string country = 1;
|
|
144
|
+
string city = 2;
|
|
145
|
+
int32 latidute = 3;
|
|
146
|
+
int32 longitude = 4;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
message DeviceInfo {
|
|
150
|
+
string browser = 1;
|
|
151
|
+
string os = 2;
|
|
152
|
+
string type = 3;
|
|
153
|
+
}
|