@barumetric/contracts 1.4.4 → 1.4.6

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.
@@ -87,6 +87,8 @@ export interface DeleteListingResponse {
87
87
  export interface GetListingsByUserRequest {
88
88
  userId: string;
89
89
  status?: ListingStatus | undefined;
90
+ take?: number | undefined;
91
+ skip?: number | undefined;
90
92
  }
91
93
 
92
94
  export interface GetListingsByCategoryRequest {
@@ -101,6 +103,7 @@ export interface GetListingResponse {
101
103
 
102
104
  export interface GetListingsByUserResponse {
103
105
  listings: Listing[];
106
+ total: number;
104
107
  }
105
108
 
106
109
  export interface GetListingsByCategoryResponse {
@@ -143,7 +146,7 @@ export interface ListingsServiceClient {
143
146
 
144
147
  createListing(request: CreateListingRequest): Observable<CreateListingResponse>;
145
148
 
146
- updateListing(request: CreateListingRequest): Observable<CreateListingResponse>;
149
+ updateListing(request: UpdateListingRequest): Observable<UpdateListingResponse>;
147
150
 
148
151
  deleteListing(request: DeleteListingRequest): Observable<DeleteListingResponse>;
149
152
  }
@@ -166,8 +169,8 @@ export interface ListingsServiceController {
166
169
  ): Promise<CreateListingResponse> | Observable<CreateListingResponse> | CreateListingResponse;
167
170
 
168
171
  updateListing(
169
- request: CreateListingRequest,
170
- ): Promise<CreateListingResponse> | Observable<CreateListingResponse> | CreateListingResponse;
172
+ request: UpdateListingRequest,
173
+ ): Promise<UpdateListingResponse> | Observable<UpdateListingResponse> | UpdateListingResponse;
171
174
 
172
175
  deleteListing(
173
176
  request: DeleteListingRequest,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@barumetric/contracts",
3
- "version": "1.4.4",
3
+ "version": "1.4.6",
4
4
  "description": "Protobuf definitions and generated TypeScript types",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -11,7 +11,7 @@ service ListingsService {
11
11
  rpc GetListingsByCategory (GetListingsByCategoryRequest) returns (GetListingsByCategoryResponse);
12
12
 
13
13
  rpc CreateListing (CreateListingRequest) returns (CreateListingResponse);
14
- rpc UpdateListing (CreateListingRequest) returns (CreateListingResponse);
14
+ rpc UpdateListing (UpdateListingRequest) returns (UpdateListingResponse);
15
15
  rpc DeleteListing (DeleteListingRequest) returns (DeleteListingResponse);
16
16
  }
17
17
 
@@ -66,6 +66,8 @@ message DeleteListingResponse {
66
66
  message GetListingsByUserRequest {
67
67
  string user_id = 1;
68
68
  optional ListingStatus status = 2;
69
+ optional int32 take = 3;
70
+ optional int32 skip = 4;
69
71
  }
70
72
 
71
73
  message GetListingsByCategoryRequest {
@@ -80,6 +82,7 @@ message GetListingResponse {
80
82
 
81
83
  message GetListingsByUserResponse {
82
84
  repeated Listing listings = 1;
85
+ int32 total = 2;
83
86
  }
84
87
 
85
88
  message GetListingsByCategoryResponse {