@sakura-skytree/leaf-eats-contracts 1.1.2 → 1.1.4

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.
@@ -1,4 +1,5 @@
1
1
  export declare const PROTO_PATHS: {
2
2
  readonly AUTH: string;
3
3
  readonly SESSION: string;
4
+ readonly PROFILE: string;
4
5
  };
@@ -4,5 +4,6 @@ exports.PROTO_PATHS = void 0;
4
4
  const path_1 = require("path");
5
5
  exports.PROTO_PATHS = {
6
6
  AUTH: (0, path_1.join)(__dirname, '../../proto/auth.proto'),
7
- SESSION: (0, path_1.join)(__dirname, '../../proto/session.proto')
7
+ SESSION: (0, path_1.join)(__dirname, '../../proto/session.proto'),
8
+ PROFILE: (0, path_1.join)(__dirname, '../../proto/profile.proto')
8
9
  };
package/gen/profile.ts ADDED
@@ -0,0 +1,69 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v2.12.0
4
+ // protoc v7.35.1
5
+ // source: profile.proto
6
+
7
+ /* eslint-disable */
8
+ import { GrpcMethod, GrpcStreamMethod } from "@nestjs/microservices";
9
+ import { Observable } from "rxjs";
10
+
11
+ export const protobufPackage = "profile.v1";
12
+
13
+ export interface GetProfileRequest {
14
+ accountId: string;
15
+ }
16
+
17
+ export interface GetProfileResponse {
18
+ profile: Profile | undefined;
19
+ }
20
+
21
+ export interface UpdateProfileRequest {
22
+ accountId: string;
23
+ name?: string | undefined;
24
+ address?: string | undefined;
25
+ }
26
+
27
+ export interface UpdateProfileResponse {
28
+ profile: Profile | undefined;
29
+ }
30
+
31
+ export interface Profile {
32
+ name: string;
33
+ address: string;
34
+ }
35
+
36
+ export const PROFILE_V1_PACKAGE_NAME = "profile.v1";
37
+
38
+ export interface ProfileServiceClient {
39
+ getProfile(request: GetProfileRequest): Observable<GetProfileResponse>;
40
+
41
+ updateProfile(request: UpdateProfileRequest): Observable<UpdateProfileResponse>;
42
+ }
43
+
44
+ export interface ProfileServiceController {
45
+ getProfile(
46
+ request: GetProfileRequest,
47
+ ): Promise<GetProfileResponse> | Observable<GetProfileResponse> | GetProfileResponse;
48
+
49
+ updateProfile(
50
+ request: UpdateProfileRequest,
51
+ ): Promise<UpdateProfileResponse> | Observable<UpdateProfileResponse> | UpdateProfileResponse;
52
+ }
53
+
54
+ export function ProfileServiceControllerMethods() {
55
+ return function (constructor: Function) {
56
+ const grpcMethods: string[] = ["getProfile", "updateProfile"];
57
+ for (const method of grpcMethods) {
58
+ const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
59
+ GrpcMethod("ProfileService", method)(constructor.prototype[method], method, descriptor);
60
+ }
61
+ const grpcStreamMethods: string[] = [];
62
+ for (const method of grpcStreamMethods) {
63
+ const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
64
+ GrpcStreamMethod("ProfileService", method)(constructor.prototype[method], method, descriptor);
65
+ }
66
+ };
67
+ }
68
+
69
+ export const PROFILE_SERVICE_NAME = "ProfileService";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sakura-skytree/leaf-eats-contracts",
3
- "version": "1.1.2",
3
+ "version": "1.1.4",
4
4
  "description": "",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/",
@@ -17,8 +17,9 @@ message GetProfileResponse{
17
17
  }
18
18
 
19
19
  message UpdateProfileRequest{
20
- optional string name = 1;
21
- optional string address = 2;
20
+ string account_id = 1;
21
+ optional string name = 2;
22
+ optional string address = 3;
22
23
  }
23
24
 
24
25
  message UpdateProfileResponse{