@neo-tickets/contracts 1.12.1 → 1.14.0
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/gen/ts/account.d.ts +63 -0
- package/dist/gen/ts/account.js +40 -0
- package/dist/gen/ts/auth.d.ts +58 -0
- package/dist/gen/ts/auth.js +28 -0
- package/dist/gen/ts/category.d.ts +18 -0
- package/dist/gen/ts/category.js +28 -0
- package/dist/gen/ts/google/protobuf/empty.d.ts +11 -0
- package/dist/gen/ts/google/protobuf/empty.js +7 -0
- package/dist/gen/ts/google/protobuf/timestamp.d.ts +106 -0
- package/dist/gen/ts/google/protobuf/timestamp.js +7 -0
- package/dist/gen/ts/index.account.d.ts +1 -0
- package/dist/gen/ts/index.account.js +42 -0
- package/dist/gen/ts/index.account.v1.d.ts +1 -0
- package/dist/gen/ts/index.account.v1.js +22 -0
- package/dist/gen/ts/index.auth.d.ts +1 -0
- package/dist/gen/ts/index.auth.js +42 -0
- package/dist/gen/ts/index.auth.v1.d.ts +1 -0
- package/dist/gen/ts/index.auth.v1.js +22 -0
- package/dist/gen/ts/index.category.d.ts +1 -0
- package/dist/gen/ts/index.category.js +42 -0
- package/dist/gen/ts/index.category.v1.d.ts +1 -0
- package/dist/gen/ts/index.category.v1.js +22 -0
- package/dist/gen/ts/index.d.ts +8 -0
- package/dist/gen/ts/index.google.d.ts +1 -0
- package/dist/gen/ts/index.google.js +42 -0
- package/dist/gen/ts/index.google.protobuf.d.ts +2 -0
- package/dist/gen/ts/index.google.protobuf.js +23 -0
- package/dist/gen/ts/index.js +49 -0
- package/dist/gen/ts/index.media.d.ts +1 -0
- package/dist/gen/ts/index.media.js +42 -0
- package/dist/gen/ts/index.media.v1.d.ts +1 -0
- package/dist/gen/ts/index.media.v1.js +22 -0
- package/dist/gen/ts/index.movie.d.ts +1 -0
- package/dist/gen/ts/index.movie.js +42 -0
- package/dist/gen/ts/index.movie.v1.d.ts +1 -0
- package/dist/gen/ts/index.movie.v1.js +22 -0
- package/dist/gen/ts/index.theater.d.ts +1 -0
- package/dist/gen/ts/index.theater.js +42 -0
- package/dist/gen/ts/index.theater.v1.d.ts +1 -0
- package/dist/gen/ts/index.theater.v1.js +22 -0
- package/dist/gen/ts/index.users.d.ts +1 -0
- package/dist/gen/ts/index.users.js +42 -0
- package/dist/gen/ts/index.users.v1.d.ts +1 -0
- package/dist/gen/ts/index.users.v1.js +22 -0
- package/dist/gen/ts/media.d.ts +36 -0
- package/dist/gen/ts/media.js +28 -0
- package/dist/gen/ts/movie.d.ts +47 -0
- package/dist/gen/ts/movie.js +28 -0
- package/dist/gen/ts/theater.d.ts +35 -0
- package/dist/gen/ts/theater.js +28 -0
- package/dist/gen/ts/users.d.ts +40 -0
- package/dist/gen/ts/users.js +28 -0
- package/dist/{proto → src/proto}/paths.d.ts +1 -0
- package/dist/{proto → src/proto}/paths.js +1 -0
- package/gen/ts/account.d.ts +63 -0
- package/gen/ts/account.js +40 -0
- package/gen/ts/auth.d.ts +58 -0
- package/gen/ts/auth.js +28 -0
- package/gen/ts/category.d.ts +18 -0
- package/gen/ts/category.js +28 -0
- package/gen/ts/google/protobuf/empty.d.ts +11 -0
- package/gen/ts/google/protobuf/empty.js +7 -0
- package/gen/ts/google/protobuf/timestamp.d.ts +107 -0
- package/gen/ts/google/protobuf/timestamp.js +7 -0
- package/gen/ts/index.account.d.ts +1 -0
- package/gen/ts/index.account.js +42 -0
- package/gen/ts/index.account.v1.d.ts +1 -0
- package/gen/ts/index.account.v1.js +22 -0
- package/gen/ts/index.auth.d.ts +1 -0
- package/gen/ts/index.auth.js +42 -0
- package/gen/ts/index.auth.v1.d.ts +1 -0
- package/gen/ts/index.auth.v1.js +22 -0
- package/gen/ts/index.category.d.ts +1 -0
- package/gen/ts/index.category.js +42 -0
- package/gen/ts/index.category.v1.d.ts +1 -0
- package/gen/ts/index.category.v1.js +22 -0
- package/gen/ts/index.d.ts +8 -0
- package/gen/ts/index.google.d.ts +1 -0
- package/gen/ts/index.google.js +42 -0
- package/gen/ts/index.google.protobuf.d.ts +2 -0
- package/gen/ts/index.google.protobuf.js +23 -0
- package/gen/ts/index.js +49 -0
- package/gen/ts/index.media.d.ts +1 -0
- package/gen/ts/index.media.js +42 -0
- package/gen/ts/index.media.v1.d.ts +1 -0
- package/gen/ts/index.media.v1.js +22 -0
- package/gen/ts/index.movie.d.ts +1 -0
- package/gen/ts/index.movie.js +42 -0
- package/gen/ts/index.movie.v1.d.ts +1 -0
- package/gen/ts/index.movie.v1.js +22 -0
- package/gen/ts/index.theater.d.ts +1 -0
- package/gen/ts/index.theater.js +42 -0
- package/gen/ts/index.theater.ts +8 -0
- package/gen/ts/index.theater.v1.d.ts +1 -0
- package/gen/ts/index.theater.v1.js +22 -0
- package/gen/ts/index.theater.v1.ts +8 -0
- package/gen/ts/index.ts +1 -0
- package/gen/ts/index.users.d.ts +1 -0
- package/gen/ts/index.users.js +42 -0
- package/gen/ts/index.users.v1.d.ts +1 -0
- package/gen/ts/index.users.v1.js +22 -0
- package/gen/ts/media.d.ts +36 -0
- package/gen/ts/media.js +28 -0
- package/gen/ts/movie.d.ts +47 -0
- package/gen/ts/movie.js +28 -0
- package/gen/ts/theater.d.ts +35 -0
- package/gen/ts/theater.js +28 -0
- package/gen/ts/theater.ts +76 -0
- package/gen/ts/users.d.ts +40 -0
- package/gen/ts/users.js +28 -0
- package/package.json +8 -1
- package/proto/theater.proto +38 -0
- /package/dist/{events → src/events}/account/email-changed.inteface.d.ts +0 -0
- /package/dist/{events → src/events}/account/email-changed.inteface.js +0 -0
- /package/dist/{events → src/events}/account/index.d.ts +0 -0
- /package/dist/{events → src/events}/account/index.js +0 -0
- /package/dist/{events → src/events}/account/phone-changed.inteface.d.ts +0 -0
- /package/dist/{events → src/events}/account/phone-changed.inteface.js +0 -0
- /package/dist/{events → src/events}/auth/index.d.ts +0 -0
- /package/dist/{events → src/events}/auth/index.js +0 -0
- /package/dist/{events → src/events}/auth/otp-requested.interface.d.ts +0 -0
- /package/dist/{events → src/events}/auth/otp-requested.interface.js +0 -0
- /package/dist/{events → src/events}/index.d.ts +0 -0
- /package/dist/{events → src/events}/index.js +0 -0
- /package/dist/{index.d.ts → src/index.d.ts} +0 -0
- /package/dist/{index.js → src/index.js} +0 -0
- /package/dist/{proto → src/proto}/index.d.ts +0 -0
- /package/dist/{proto → src/proto}/index.js +0 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { Observable } from "rxjs";
|
|
2
|
+
export declare enum Role {
|
|
3
|
+
USER = 0,
|
|
4
|
+
ADMIN = 1,
|
|
5
|
+
UNRECOGNIZED = -1
|
|
6
|
+
}
|
|
7
|
+
export interface GetAccountRequest {
|
|
8
|
+
id: string;
|
|
9
|
+
}
|
|
10
|
+
export interface GetAccountResponse {
|
|
11
|
+
id: string;
|
|
12
|
+
phone: string;
|
|
13
|
+
email: string;
|
|
14
|
+
isPhoneVerified: boolean;
|
|
15
|
+
isEmailVerified: boolean;
|
|
16
|
+
role: Role;
|
|
17
|
+
}
|
|
18
|
+
export interface InitEmailChangeRequest {
|
|
19
|
+
email: string;
|
|
20
|
+
userId: string;
|
|
21
|
+
}
|
|
22
|
+
export interface InitEmailChangeResponse {
|
|
23
|
+
ok: boolean;
|
|
24
|
+
}
|
|
25
|
+
export interface ConfirmEmailChangeRequest {
|
|
26
|
+
email: string;
|
|
27
|
+
code: string;
|
|
28
|
+
userId: string;
|
|
29
|
+
}
|
|
30
|
+
export interface ConfirmEmailChangeResponse {
|
|
31
|
+
ok: boolean;
|
|
32
|
+
}
|
|
33
|
+
export interface InitPhoneChangeRequest {
|
|
34
|
+
phone: string;
|
|
35
|
+
userId: string;
|
|
36
|
+
}
|
|
37
|
+
export interface InitPhoneChangeResponse {
|
|
38
|
+
ok: boolean;
|
|
39
|
+
}
|
|
40
|
+
export interface ConfirmPhoneChangeRequest {
|
|
41
|
+
phone: string;
|
|
42
|
+
code: string;
|
|
43
|
+
userId: string;
|
|
44
|
+
}
|
|
45
|
+
export interface ConfirmPhoneChangeResponse {
|
|
46
|
+
ok: boolean;
|
|
47
|
+
}
|
|
48
|
+
export interface AccountServiceClient {
|
|
49
|
+
getAccount(request: GetAccountRequest): Observable<GetAccountResponse>;
|
|
50
|
+
initEmailChange(request: InitEmailChangeRequest): Observable<InitEmailChangeResponse>;
|
|
51
|
+
confirmEmailChange(request: ConfirmEmailChangeRequest): Observable<ConfirmEmailChangeResponse>;
|
|
52
|
+
initPhoneChange(request: InitPhoneChangeRequest): Observable<InitPhoneChangeResponse>;
|
|
53
|
+
confirmPhoneChange(request: ConfirmPhoneChangeRequest): Observable<ConfirmPhoneChangeResponse>;
|
|
54
|
+
}
|
|
55
|
+
export interface AccountServiceController {
|
|
56
|
+
getAccount(request: GetAccountRequest): Promise<GetAccountResponse> | Observable<GetAccountResponse> | GetAccountResponse;
|
|
57
|
+
initEmailChange(request: InitEmailChangeRequest): Promise<InitEmailChangeResponse> | Observable<InitEmailChangeResponse> | InitEmailChangeResponse;
|
|
58
|
+
confirmEmailChange(request: ConfirmEmailChangeRequest): Promise<ConfirmEmailChangeResponse> | Observable<ConfirmEmailChangeResponse> | ConfirmEmailChangeResponse;
|
|
59
|
+
initPhoneChange(request: InitPhoneChangeRequest): Promise<InitPhoneChangeResponse> | Observable<InitPhoneChangeResponse> | InitPhoneChangeResponse;
|
|
60
|
+
confirmPhoneChange(request: ConfirmPhoneChangeRequest): Promise<ConfirmPhoneChangeResponse> | Observable<ConfirmPhoneChangeResponse> | ConfirmPhoneChangeResponse;
|
|
61
|
+
}
|
|
62
|
+
export declare function AccountServiceControllerMethods(): (constructor: Function) => void;
|
|
63
|
+
export declare const ACCOUNT_SERVICE_NAME = "AccountService";
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
// source: account.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.ACCOUNT_SERVICE_NAME = exports.Role = void 0;
|
|
9
|
+
exports.AccountServiceControllerMethods = AccountServiceControllerMethods;
|
|
10
|
+
/* eslint-disable */
|
|
11
|
+
const microservices_1 = require("@nestjs/microservices");
|
|
12
|
+
var Role;
|
|
13
|
+
(function (Role) {
|
|
14
|
+
Role[Role["USER"] = 0] = "USER";
|
|
15
|
+
Role[Role["ADMIN"] = 1] = "ADMIN";
|
|
16
|
+
Role[Role["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
17
|
+
})(Role || (exports.Role = Role = {}));
|
|
18
|
+
function AccountServiceControllerMethods() {
|
|
19
|
+
return function (constructor) {
|
|
20
|
+
const grpcMethods = [
|
|
21
|
+
"getAccount",
|
|
22
|
+
"initEmailChange",
|
|
23
|
+
"confirmEmailChange",
|
|
24
|
+
"initPhoneChange",
|
|
25
|
+
"confirmPhoneChange",
|
|
26
|
+
];
|
|
27
|
+
for (const method of grpcMethods) {
|
|
28
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
29
|
+
(0, microservices_1.GrpcMethod)("AccountService", method)(constructor.prototype[method], method, descriptor);
|
|
30
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
31
|
+
}
|
|
32
|
+
const grpcStreamMethods = [];
|
|
33
|
+
for (const method of grpcStreamMethods) {
|
|
34
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
35
|
+
(0, microservices_1.GrpcStreamMethod)("AccountService", method)(constructor.prototype[method], method, descriptor);
|
|
36
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
exports.ACCOUNT_SERVICE_NAME = "AccountService";
|
package/gen/ts/auth.d.ts
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { Observable } from "rxjs";
|
|
2
|
+
import { Empty } from "./google/protobuf/empty";
|
|
3
|
+
export interface SendOtpRequest {
|
|
4
|
+
identifier: string;
|
|
5
|
+
type: string;
|
|
6
|
+
}
|
|
7
|
+
export interface SendOtpResponse {
|
|
8
|
+
ok: boolean;
|
|
9
|
+
}
|
|
10
|
+
export interface VerifyOtpRequest {
|
|
11
|
+
identifier: string;
|
|
12
|
+
type: string;
|
|
13
|
+
code: string;
|
|
14
|
+
}
|
|
15
|
+
export interface VerifyOtpResponse {
|
|
16
|
+
accessToken: string;
|
|
17
|
+
refreshToken: string;
|
|
18
|
+
}
|
|
19
|
+
export interface RefreshTokenRequest {
|
|
20
|
+
refreshToken: string;
|
|
21
|
+
}
|
|
22
|
+
export interface RefreshTokenResponse {
|
|
23
|
+
accessToken: string;
|
|
24
|
+
refreshToken: string;
|
|
25
|
+
}
|
|
26
|
+
export interface TelegramInitResponse {
|
|
27
|
+
url: string;
|
|
28
|
+
}
|
|
29
|
+
export interface TelegramVerifyRequest {
|
|
30
|
+
query: {
|
|
31
|
+
[key: string]: string;
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
export interface TelegramVerifyRequest_QueryEntry {
|
|
35
|
+
key: string;
|
|
36
|
+
value: string;
|
|
37
|
+
}
|
|
38
|
+
export interface TelegramVerifyResponse {
|
|
39
|
+
url?: string | undefined;
|
|
40
|
+
accessToken?: string | undefined;
|
|
41
|
+
refreshToken?: string | undefined;
|
|
42
|
+
}
|
|
43
|
+
export interface AuthServiceClient {
|
|
44
|
+
sendOtp(request: SendOtpRequest): Observable<SendOtpResponse>;
|
|
45
|
+
verifyOtp(request: VerifyOtpRequest): Observable<VerifyOtpResponse>;
|
|
46
|
+
refreshToken(request: RefreshTokenRequest): Observable<RefreshTokenResponse>;
|
|
47
|
+
telegramInit(request: Empty): Observable<TelegramInitResponse>;
|
|
48
|
+
telegramVerify(request: TelegramVerifyRequest): Observable<TelegramVerifyResponse>;
|
|
49
|
+
}
|
|
50
|
+
export interface AuthServiceController {
|
|
51
|
+
sendOtp(request: SendOtpRequest): Promise<SendOtpResponse> | Observable<SendOtpResponse> | SendOtpResponse;
|
|
52
|
+
verifyOtp(request: VerifyOtpRequest): Promise<VerifyOtpResponse> | Observable<VerifyOtpResponse> | VerifyOtpResponse;
|
|
53
|
+
refreshToken(request: RefreshTokenRequest): Promise<RefreshTokenResponse> | Observable<RefreshTokenResponse> | RefreshTokenResponse;
|
|
54
|
+
telegramInit(request: Empty): Promise<TelegramInitResponse> | Observable<TelegramInitResponse> | TelegramInitResponse;
|
|
55
|
+
telegramVerify(request: TelegramVerifyRequest): Promise<TelegramVerifyResponse> | Observable<TelegramVerifyResponse> | TelegramVerifyResponse;
|
|
56
|
+
}
|
|
57
|
+
export declare function AuthServiceControllerMethods(): (constructor: Function) => void;
|
|
58
|
+
export declare const AUTH_SERVICE_NAME = "AuthService";
|
package/gen/ts/auth.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
// source: auth.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.AUTH_SERVICE_NAME = void 0;
|
|
9
|
+
exports.AuthServiceControllerMethods = AuthServiceControllerMethods;
|
|
10
|
+
/* eslint-disable */
|
|
11
|
+
const microservices_1 = require("@nestjs/microservices");
|
|
12
|
+
function AuthServiceControllerMethods() {
|
|
13
|
+
return function (constructor) {
|
|
14
|
+
const grpcMethods = ["sendOtp", "verifyOtp", "refreshToken", "telegramInit", "telegramVerify"];
|
|
15
|
+
for (const method of grpcMethods) {
|
|
16
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
17
|
+
(0, microservices_1.GrpcMethod)("AuthService", method)(constructor.prototype[method], method, descriptor);
|
|
18
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
19
|
+
}
|
|
20
|
+
const grpcStreamMethods = [];
|
|
21
|
+
for (const method of grpcStreamMethods) {
|
|
22
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
23
|
+
(0, microservices_1.GrpcStreamMethod)("AuthService", method)(constructor.prototype[method], method, descriptor);
|
|
24
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
exports.AUTH_SERVICE_NAME = "AuthService";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Observable } from "rxjs";
|
|
2
|
+
import { Empty } from "./google/protobuf/empty";
|
|
3
|
+
export interface GetAllCategoriesResponse {
|
|
4
|
+
categories: Category[];
|
|
5
|
+
}
|
|
6
|
+
export interface Category {
|
|
7
|
+
id: string;
|
|
8
|
+
title: string;
|
|
9
|
+
slug: string;
|
|
10
|
+
}
|
|
11
|
+
export interface CategoryServiceClient {
|
|
12
|
+
getAllCategories(request: Empty): Observable<GetAllCategoriesResponse>;
|
|
13
|
+
}
|
|
14
|
+
export interface CategoryServiceController {
|
|
15
|
+
getAllCategories(request: Empty): Promise<GetAllCategoriesResponse> | Observable<GetAllCategoriesResponse> | GetAllCategoriesResponse;
|
|
16
|
+
}
|
|
17
|
+
export declare function CategoryServiceControllerMethods(): (constructor: Function) => void;
|
|
18
|
+
export declare const CATEGORY_SERVICE_NAME = "CategoryService";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
// source: category.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.CATEGORY_SERVICE_NAME = void 0;
|
|
9
|
+
exports.CategoryServiceControllerMethods = CategoryServiceControllerMethods;
|
|
10
|
+
/* eslint-disable */
|
|
11
|
+
const microservices_1 = require("@nestjs/microservices");
|
|
12
|
+
function CategoryServiceControllerMethods() {
|
|
13
|
+
return function (constructor) {
|
|
14
|
+
const grpcMethods = ["getAllCategories"];
|
|
15
|
+
for (const method of grpcMethods) {
|
|
16
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
17
|
+
(0, microservices_1.GrpcMethod)("CategoryService", method)(constructor.prototype[method], method, descriptor);
|
|
18
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
19
|
+
}
|
|
20
|
+
const grpcStreamMethods = [];
|
|
21
|
+
for (const method of grpcStreamMethods) {
|
|
22
|
+
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
23
|
+
(0, microservices_1.GrpcStreamMethod)("CategoryService", method)(constructor.prototype[method], method, descriptor);
|
|
24
|
+
Object.defineProperty(constructor.prototype, method, descriptor);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
exports.CATEGORY_SERVICE_NAME = "CategoryService";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A generic empty message that you can re-use to avoid defining duplicated
|
|
3
|
+
* empty messages in your APIs. A typical example is to use it as the request
|
|
4
|
+
* or the response type of an API method. For instance:
|
|
5
|
+
*
|
|
6
|
+
* service Foo {
|
|
7
|
+
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
|
|
8
|
+
* }
|
|
9
|
+
*/
|
|
10
|
+
export interface Empty {
|
|
11
|
+
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A Timestamp represents a point in time independent of any time zone or local
|
|
3
|
+
* calendar, encoded as a count of seconds and fractions of seconds at
|
|
4
|
+
* nanosecond resolution. The count is relative to an epoch at UTC midnight on
|
|
5
|
+
* January 1, 1970, in the proleptic Gregorian calendar which extends the
|
|
6
|
+
* Gregorian calendar backwards to year one.
|
|
7
|
+
*
|
|
8
|
+
* All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap
|
|
9
|
+
* second table is needed for interpretation, using a [24-hour linear
|
|
10
|
+
* smear](https://developers.google.com/time/smear).
|
|
11
|
+
*
|
|
12
|
+
* The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By
|
|
13
|
+
* restricting to that range, we ensure that we can convert to and from [RFC
|
|
14
|
+
* 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings.
|
|
15
|
+
*
|
|
16
|
+
* # Examples
|
|
17
|
+
*
|
|
18
|
+
* Example 1: Compute Timestamp from POSIX `time()`.
|
|
19
|
+
*
|
|
20
|
+
* Timestamp timestamp;
|
|
21
|
+
* timestamp.set_seconds(time(NULL));
|
|
22
|
+
* timestamp.set_nanos(0);
|
|
23
|
+
*
|
|
24
|
+
* Example 2: Compute Timestamp from POSIX `gettimeofday()`.
|
|
25
|
+
*
|
|
26
|
+
* struct timeval tv;
|
|
27
|
+
* gettimeofday(&tv, NULL);
|
|
28
|
+
*
|
|
29
|
+
* Timestamp timestamp;
|
|
30
|
+
* timestamp.set_seconds(tv.tv_sec);
|
|
31
|
+
* timestamp.set_nanos(tv.tv_usec * 1000);
|
|
32
|
+
*
|
|
33
|
+
* Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`.
|
|
34
|
+
*
|
|
35
|
+
* FILETIME ft;
|
|
36
|
+
* GetSystemTimeAsFileTime(&ft);
|
|
37
|
+
* UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;
|
|
38
|
+
*
|
|
39
|
+
* // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z
|
|
40
|
+
* // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.
|
|
41
|
+
* Timestamp timestamp;
|
|
42
|
+
* timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));
|
|
43
|
+
* timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));
|
|
44
|
+
*
|
|
45
|
+
* Example 4: Compute Timestamp from Java `System.currentTimeMillis()`.
|
|
46
|
+
*
|
|
47
|
+
* long millis = System.currentTimeMillis();
|
|
48
|
+
*
|
|
49
|
+
* Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)
|
|
50
|
+
* .setNanos((int) ((millis % 1000) * 1000000)).build();
|
|
51
|
+
*
|
|
52
|
+
* Example 5: Compute Timestamp from Java `Instant.now()`.
|
|
53
|
+
*
|
|
54
|
+
* Instant now = Instant.now();
|
|
55
|
+
*
|
|
56
|
+
* Timestamp timestamp =
|
|
57
|
+
* Timestamp.newBuilder().setSeconds(now.getEpochSecond())
|
|
58
|
+
* .setNanos(now.getNano()).build();
|
|
59
|
+
*
|
|
60
|
+
* Example 6: Compute Timestamp from current time in Python.
|
|
61
|
+
*
|
|
62
|
+
* timestamp = Timestamp()
|
|
63
|
+
* timestamp.GetCurrentTime()
|
|
64
|
+
*
|
|
65
|
+
* # JSON Mapping
|
|
66
|
+
*
|
|
67
|
+
* In JSON format, the Timestamp type is encoded as a string in the
|
|
68
|
+
* [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the
|
|
69
|
+
* format is "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z"
|
|
70
|
+
* where {year} is always expressed using four digits while {month}, {day},
|
|
71
|
+
* {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
|
|
72
|
+
* seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
|
|
73
|
+
* are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
|
|
74
|
+
* is required. A ProtoJSON serializer should always use UTC (as indicated by
|
|
75
|
+
* "Z") when printing the Timestamp type and a ProtoJSON parser should be
|
|
76
|
+
* able to accept both UTC and other timezones (as indicated by an offset).
|
|
77
|
+
*
|
|
78
|
+
* For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
|
|
79
|
+
* 01:30 UTC on January 15, 2017.
|
|
80
|
+
*
|
|
81
|
+
* In JavaScript, one can convert a Date object to this format using the
|
|
82
|
+
* standard
|
|
83
|
+
* [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString)
|
|
84
|
+
* method. In Python, a standard `datetime.datetime` object can be converted
|
|
85
|
+
* to this format using
|
|
86
|
+
* [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with
|
|
87
|
+
* the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use
|
|
88
|
+
* the Joda Time's [`ISODateTimeFormat.dateTime()`](
|
|
89
|
+
* http://joda-time.sourceforge.net/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime()
|
|
90
|
+
* ) to obtain a formatter capable of generating timestamps in this format.
|
|
91
|
+
*/
|
|
92
|
+
export interface Timestamp {
|
|
93
|
+
/**
|
|
94
|
+
* Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must
|
|
95
|
+
* be between -62135596800 and 253402300799 inclusive (which corresponds to
|
|
96
|
+
* 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z).
|
|
97
|
+
*/
|
|
98
|
+
seconds: number;
|
|
99
|
+
/**
|
|
100
|
+
* Non-negative fractions of a second at nanosecond resolution. This field is
|
|
101
|
+
* the nanosecond portion of the duration, not an alternative to seconds.
|
|
102
|
+
* Negative second values with fractions must still have non-negative nanos
|
|
103
|
+
* values that count forward in time. Must be between 0 and 999,999,999
|
|
104
|
+
* inclusive.
|
|
105
|
+
*/
|
|
106
|
+
nanos: number;
|
|
107
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * as v1 from "./index.account.v1";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
23
|
+
var ownKeys = function(o) {
|
|
24
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
25
|
+
var ar = [];
|
|
26
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
27
|
+
return ar;
|
|
28
|
+
};
|
|
29
|
+
return ownKeys(o);
|
|
30
|
+
};
|
|
31
|
+
return function (mod) {
|
|
32
|
+
if (mod && mod.__esModule) return mod;
|
|
33
|
+
var result = {};
|
|
34
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
35
|
+
__setModuleDefault(result, mod);
|
|
36
|
+
return result;
|
|
37
|
+
};
|
|
38
|
+
})();
|
|
39
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
+
exports.v1 = void 0;
|
|
41
|
+
/* eslint-disable */
|
|
42
|
+
exports.v1 = __importStar(require("./index.account.v1"));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./account";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
18
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
19
|
+
};
|
|
20
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
+
/* eslint-disable */
|
|
22
|
+
__exportStar(require("./account"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * as v1 from "./index.auth.v1";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
23
|
+
var ownKeys = function(o) {
|
|
24
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
25
|
+
var ar = [];
|
|
26
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
27
|
+
return ar;
|
|
28
|
+
};
|
|
29
|
+
return ownKeys(o);
|
|
30
|
+
};
|
|
31
|
+
return function (mod) {
|
|
32
|
+
if (mod && mod.__esModule) return mod;
|
|
33
|
+
var result = {};
|
|
34
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
35
|
+
__setModuleDefault(result, mod);
|
|
36
|
+
return result;
|
|
37
|
+
};
|
|
38
|
+
})();
|
|
39
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
+
exports.v1 = void 0;
|
|
41
|
+
/* eslint-disable */
|
|
42
|
+
exports.v1 = __importStar(require("./index.auth.v1"));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./auth";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
18
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
19
|
+
};
|
|
20
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
+
/* eslint-disable */
|
|
22
|
+
__exportStar(require("./auth"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * as v1 from "./index.category.v1";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
23
|
+
var ownKeys = function(o) {
|
|
24
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
25
|
+
var ar = [];
|
|
26
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
27
|
+
return ar;
|
|
28
|
+
};
|
|
29
|
+
return ownKeys(o);
|
|
30
|
+
};
|
|
31
|
+
return function (mod) {
|
|
32
|
+
if (mod && mod.__esModule) return mod;
|
|
33
|
+
var result = {};
|
|
34
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
35
|
+
__setModuleDefault(result, mod);
|
|
36
|
+
return result;
|
|
37
|
+
};
|
|
38
|
+
})();
|
|
39
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
+
exports.v1 = void 0;
|
|
41
|
+
/* eslint-disable */
|
|
42
|
+
exports.v1 = __importStar(require("./index.category.v1"));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./category";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
18
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
19
|
+
};
|
|
20
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
+
/* eslint-disable */
|
|
22
|
+
__exportStar(require("./category"), exports);
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * as account from "./index.account";
|
|
2
|
+
export * as google from "./index.google";
|
|
3
|
+
export * as auth from "./index.auth";
|
|
4
|
+
export * as category from "./index.category";
|
|
5
|
+
export * as media from "./index.media";
|
|
6
|
+
export * as movie from "./index.movie";
|
|
7
|
+
export * as theater from "./index.theater";
|
|
8
|
+
export * as users from "./index.users";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * as protobuf from "./index.google.protobuf";
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.12.4
|
|
5
|
+
// protoc v7.36.2
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
+
}
|
|
12
|
+
Object.defineProperty(o, k2, desc);
|
|
13
|
+
}) : (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
o[k2] = m[k];
|
|
16
|
+
}));
|
|
17
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
+
}) : function(o, v) {
|
|
20
|
+
o["default"] = v;
|
|
21
|
+
});
|
|
22
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
23
|
+
var ownKeys = function(o) {
|
|
24
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
25
|
+
var ar = [];
|
|
26
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
27
|
+
return ar;
|
|
28
|
+
};
|
|
29
|
+
return ownKeys(o);
|
|
30
|
+
};
|
|
31
|
+
return function (mod) {
|
|
32
|
+
if (mod && mod.__esModule) return mod;
|
|
33
|
+
var result = {};
|
|
34
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
35
|
+
__setModuleDefault(result, mod);
|
|
36
|
+
return result;
|
|
37
|
+
};
|
|
38
|
+
})();
|
|
39
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
+
exports.protobuf = void 0;
|
|
41
|
+
/* eslint-disable */
|
|
42
|
+
exports.protobuf = __importStar(require("./index.google.protobuf"));
|