@usteam/contracts 1.0.1 → 1.0.3
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/dist/index.d.ts +1 -0
- package/dist/index.js +17 -0
- package/dist/proto/index.d.ts +1 -0
- package/dist/proto/index.js +17 -0
- package/dist/proto/paths.d.ts +3 -0
- package/dist/proto/paths.js +7 -0
- package/gen/auth.ts +10 -0
- package/package.json +9 -1
- package/proto/auth.proto +2 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './proto';
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./proto"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './paths';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./paths"), exports);
|
package/gen/auth.ts
CHANGED
|
@@ -54,6 +54,11 @@ export interface AuthServiceClient {
|
|
|
54
54
|
|
|
55
55
|
sendOtp(request: SendOtpRequest): Observable<SendOtpResponse>;
|
|
56
56
|
|
|
57
|
+
/**
|
|
58
|
+
* VerifyOtp веривицирует одноразовый пароль.
|
|
59
|
+
* отправляет токены.
|
|
60
|
+
*/
|
|
61
|
+
|
|
57
62
|
verifyOtp(request: VerifyOtpRequest): Observable<VerifyOtpResponse>;
|
|
58
63
|
}
|
|
59
64
|
|
|
@@ -70,6 +75,11 @@ export interface AuthServiceController {
|
|
|
70
75
|
|
|
71
76
|
sendOtp(request: SendOtpRequest): Promise<SendOtpResponse> | Observable<SendOtpResponse> | SendOtpResponse;
|
|
72
77
|
|
|
78
|
+
/**
|
|
79
|
+
* VerifyOtp веривицирует одноразовый пароль.
|
|
80
|
+
* отправляет токены.
|
|
81
|
+
*/
|
|
82
|
+
|
|
73
83
|
verifyOtp(request: VerifyOtpRequest): Promise<VerifyOtpResponse> | Observable<VerifyOtpResponse> | VerifyOtpResponse;
|
|
74
84
|
}
|
|
75
85
|
|
package/package.json
CHANGED
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@usteam/contracts",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
|
+
"main": "./dist/index.js",
|
|
5
|
+
"types": "./dist/index.d.ts",
|
|
4
6
|
"scripts": {
|
|
7
|
+
"build": "tsc -p tsconfig.build.json",
|
|
5
8
|
"generate": "npx protoc -I ./proto ./proto/*.proto --ts_proto_out=./gen --ts_proto_opt=nestJs=true,package=omit"
|
|
6
9
|
},
|
|
7
10
|
"files": [
|
|
11
|
+
"dist",
|
|
8
12
|
"proto",
|
|
9
13
|
"gen"
|
|
10
14
|
],
|
|
@@ -16,5 +20,9 @@
|
|
|
16
20
|
"@nestjs/microservices": "^11.1.11",
|
|
17
21
|
"rxjs": "^7.8.2",
|
|
18
22
|
"ts-proto": "^2.10.1"
|
|
23
|
+
},
|
|
24
|
+
"devDependencies": {
|
|
25
|
+
"@types/node": "^25.1.0",
|
|
26
|
+
"typescript": "^5.9.3"
|
|
19
27
|
}
|
|
20
28
|
}
|
package/proto/auth.proto
CHANGED
|
@@ -8,6 +8,8 @@ service AuthService {
|
|
|
8
8
|
// SendOtp отправляет одноразовый пароль (OTP) на указанный идентификатор.
|
|
9
9
|
// Может быть email, телефон или другой тип.
|
|
10
10
|
rpc SendOtp (SendOtpRequest) returns (SendOtpResponse);
|
|
11
|
+
// VerifyOtp веривицирует одноразовый пароль.
|
|
12
|
+
// отправляет токены.
|
|
11
13
|
rpc VerifyOtp (VerifyOtpRequest) returns (VerifyOtpResponse);
|
|
12
14
|
}
|
|
13
15
|
|