@vendee-cinema/contracts 1.0.8 → 1.1.1

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.
@@ -0,0 +1 @@
1
+ export * from './otp-requested.interface';
@@ -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("./otp-requested.interface"), exports);
@@ -0,0 +1,5 @@
1
+ export interface OtpRequestedEvent {
2
+ identifier: string;
3
+ type: 'phone' | 'email';
4
+ code: string;
5
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1 @@
1
+ export * from './auth';
@@ -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("./auth"), exports);
package/dist/index.d.ts CHANGED
@@ -1 +1,2 @@
1
1
  export * from './proto';
2
+ export * from './events';
package/dist/index.js CHANGED
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./proto"), exports);
18
+ __exportStar(require("./events"), exports);
package/gen/auth.ts CHANGED
@@ -11,9 +11,15 @@ import { Empty } from "./google/protobuf/empty";
11
11
 
12
12
  export const protobufPackage = "auth.v1";
13
13
 
14
+ export enum Type {
15
+ PHONE = 0,
16
+ EMAIL = 1,
17
+ UNRECOGNIZED = -1,
18
+ }
19
+
14
20
  export interface SendOtpRequest {
15
21
  identifier: string;
16
- type: string;
22
+ type: Type;
17
23
  }
18
24
 
19
25
  export interface SendOtpResponse {
@@ -22,7 +28,7 @@ export interface SendOtpResponse {
22
28
 
23
29
  export interface VerifyOtpRequest {
24
30
  identifier: string;
25
- type: string;
31
+ type: Type;
26
32
  code: string;
27
33
  }
28
34
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vendee-cinema/contracts",
3
- "version": "1.0.8",
3
+ "version": "1.1.1",
4
4
  "description": "Protobuf definitions and generated TypeScript types",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
package/proto/auth.proto CHANGED
@@ -17,7 +17,12 @@ service AuthService {
17
17
 
18
18
  message SendOtpRequest {
19
19
  string identifier = 1;
20
- string type = 2;
20
+ Type type = 2;
21
+ }
22
+
23
+ enum Type {
24
+ PHONE = 0;
25
+ EMAIL = 1;
21
26
  }
22
27
 
23
28
  message SendOtpResponse {
@@ -26,7 +31,7 @@ message SendOtpResponse {
26
31
 
27
32
  message VerifyOtpRequest {
28
33
  string identifier = 1;
29
- string type = 2;
34
+ Type type = 2;
30
35
  string code = 3;
31
36
  }
32
37