wash-service-sdk 1.0.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.
@@ -0,0 +1,86 @@
1
+ // @generated by protobuf-ts 2.11.1 with parameter client_grpc1
2
+ // @generated from protobuf file "user.proto" (package "user", syntax proto3)
3
+ // tslint:disable
4
+ import { UserService } from "./user";
5
+ import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
6
+ import type { BinaryReadOptions } from "@protobuf-ts/runtime";
7
+ import type { RegisterV1Response } from "./user";
8
+ import type { RegisterV1Request } from "./user";
9
+ import type { ResponseFCMToken } from "./user";
10
+ import type { RequestFCMToken } from "./user";
11
+ import type { WithdrawResponse } from "./user";
12
+ import type { WithdrawRequest } from "./user";
13
+ import type { RegisterResponse } from "./user";
14
+ import type { PutRequest } from "./user";
15
+ import * as grpc from "@grpc/grpc-js";
16
+ /**
17
+ * @generated from protobuf service user.UserService
18
+ */
19
+ export interface IUserServiceClient {
20
+ /**
21
+ * @generated from protobuf rpc: PutUser
22
+ */
23
+ putUser(input: PutRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: RegisterResponse) => void): grpc.ClientUnaryCall;
24
+ putUser(input: PutRequest, metadata: grpc.Metadata, callback: (err: grpc.ServiceError | null, value?: RegisterResponse) => void): grpc.ClientUnaryCall;
25
+ putUser(input: PutRequest, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: RegisterResponse) => void): grpc.ClientUnaryCall;
26
+ putUser(input: PutRequest, callback: (err: grpc.ServiceError | null, value?: RegisterResponse) => void): grpc.ClientUnaryCall;
27
+ /**
28
+ * @generated from protobuf rpc: WithdrawUser
29
+ */
30
+ withdrawUser(input: WithdrawRequest, metadata: grpc.Metadata, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: WithdrawResponse) => void): grpc.ClientUnaryCall;
31
+ withdrawUser(input: WithdrawRequest, metadata: grpc.Metadata, callback: (err: grpc.ServiceError | null, value?: WithdrawResponse) => void): grpc.ClientUnaryCall;
32
+ withdrawUser(input: WithdrawRequest, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: WithdrawResponse) => void): grpc.ClientUnaryCall;
33
+ withdrawUser(input: WithdrawRequest, callback: (err: grpc.ServiceError | null, value?: WithdrawResponse) => void): grpc.ClientUnaryCall;
34
+ /**
35
+ * @generated from protobuf rpc: RequestFcmToken
36
+ */
37
+ requestFcmToken(input: RequestFCMToken, metadata: grpc.Metadata, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: ResponseFCMToken) => void): grpc.ClientUnaryCall;
38
+ requestFcmToken(input: RequestFCMToken, metadata: grpc.Metadata, callback: (err: grpc.ServiceError | null, value?: ResponseFCMToken) => void): grpc.ClientUnaryCall;
39
+ requestFcmToken(input: RequestFCMToken, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: ResponseFCMToken) => void): grpc.ClientUnaryCall;
40
+ requestFcmToken(input: RequestFCMToken, callback: (err: grpc.ServiceError | null, value?: ResponseFCMToken) => void): grpc.ClientUnaryCall;
41
+ /**
42
+ * @generated from protobuf rpc: Register
43
+ */
44
+ register(input: RegisterV1Request, metadata: grpc.Metadata, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: RegisterV1Response) => void): grpc.ClientUnaryCall;
45
+ register(input: RegisterV1Request, metadata: grpc.Metadata, callback: (err: grpc.ServiceError | null, value?: RegisterV1Response) => void): grpc.ClientUnaryCall;
46
+ register(input: RegisterV1Request, options: grpc.CallOptions, callback: (err: grpc.ServiceError | null, value?: RegisterV1Response) => void): grpc.ClientUnaryCall;
47
+ register(input: RegisterV1Request, callback: (err: grpc.ServiceError | null, value?: RegisterV1Response) => void): grpc.ClientUnaryCall;
48
+ }
49
+ /**
50
+ * @generated from protobuf service user.UserService
51
+ */
52
+ export class UserServiceClient extends grpc.Client implements IUserServiceClient {
53
+ private readonly _binaryOptions: Partial<BinaryReadOptions & BinaryWriteOptions>;
54
+ constructor(address: string, credentials: grpc.ChannelCredentials, options: grpc.ClientOptions = {}, binaryOptions: Partial<BinaryReadOptions & BinaryWriteOptions> = {}) {
55
+ super(address, credentials, options);
56
+ this._binaryOptions = binaryOptions;
57
+ }
58
+ /**
59
+ * @generated from protobuf rpc: PutUser
60
+ */
61
+ putUser(input: PutRequest, metadata: grpc.Metadata | grpc.CallOptions | ((err: grpc.ServiceError | null, value?: RegisterResponse) => void), options?: grpc.CallOptions | ((err: grpc.ServiceError | null, value?: RegisterResponse) => void), callback?: ((err: grpc.ServiceError | null, value?: RegisterResponse) => void)): grpc.ClientUnaryCall {
62
+ const method = UserService.methods[0];
63
+ return this.makeUnaryRequest<PutRequest, RegisterResponse>(`/${UserService.typeName}/${method.name}`, (value: PutRequest): Buffer => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value: Buffer): RegisterResponse => method.O.fromBinary(value, this._binaryOptions), input, (metadata as any), (options as any), (callback as any));
64
+ }
65
+ /**
66
+ * @generated from protobuf rpc: WithdrawUser
67
+ */
68
+ withdrawUser(input: WithdrawRequest, metadata: grpc.Metadata | grpc.CallOptions | ((err: grpc.ServiceError | null, value?: WithdrawResponse) => void), options?: grpc.CallOptions | ((err: grpc.ServiceError | null, value?: WithdrawResponse) => void), callback?: ((err: grpc.ServiceError | null, value?: WithdrawResponse) => void)): grpc.ClientUnaryCall {
69
+ const method = UserService.methods[1];
70
+ return this.makeUnaryRequest<WithdrawRequest, WithdrawResponse>(`/${UserService.typeName}/${method.name}`, (value: WithdrawRequest): Buffer => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value: Buffer): WithdrawResponse => method.O.fromBinary(value, this._binaryOptions), input, (metadata as any), (options as any), (callback as any));
71
+ }
72
+ /**
73
+ * @generated from protobuf rpc: RequestFcmToken
74
+ */
75
+ requestFcmToken(input: RequestFCMToken, metadata: grpc.Metadata | grpc.CallOptions | ((err: grpc.ServiceError | null, value?: ResponseFCMToken) => void), options?: grpc.CallOptions | ((err: grpc.ServiceError | null, value?: ResponseFCMToken) => void), callback?: ((err: grpc.ServiceError | null, value?: ResponseFCMToken) => void)): grpc.ClientUnaryCall {
76
+ const method = UserService.methods[2];
77
+ return this.makeUnaryRequest<RequestFCMToken, ResponseFCMToken>(`/${UserService.typeName}/${method.name}`, (value: RequestFCMToken): Buffer => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value: Buffer): ResponseFCMToken => method.O.fromBinary(value, this._binaryOptions), input, (metadata as any), (options as any), (callback as any));
78
+ }
79
+ /**
80
+ * @generated from protobuf rpc: Register
81
+ */
82
+ register(input: RegisterV1Request, metadata: grpc.Metadata | grpc.CallOptions | ((err: grpc.ServiceError | null, value?: RegisterV1Response) => void), options?: grpc.CallOptions | ((err: grpc.ServiceError | null, value?: RegisterV1Response) => void), callback?: ((err: grpc.ServiceError | null, value?: RegisterV1Response) => void)): grpc.ClientUnaryCall {
83
+ const method = UserService.methods[3];
84
+ return this.makeUnaryRequest<RegisterV1Request, RegisterV1Response>(`/${UserService.typeName}/${method.name}`, (value: RegisterV1Request): Buffer => Buffer.from(method.I.toBinary(value, this._binaryOptions)), (value: Buffer): RegisterV1Response => method.O.fromBinary(value, this._binaryOptions), input, (metadata as any), (options as any), (callback as any));
85
+ }
86
+ }