@restorecommerce/protos 0.6.6 → 0.6.9

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/CHANGELOG.md CHANGED
@@ -3,6 +3,36 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [0.6.9](https://github.com/restorecommerce/libs/compare/@restorecommerce/protos@0.6.8...@restorecommerce/protos@0.6.9) (2022-05-09)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **protos:** add get token grpc endpoint to oauth ([965701b](https://github.com/restorecommerce/libs/commit/965701b5192c73060bf0377bc2f81d33a2ea4bd8))
12
+
13
+
14
+
15
+
16
+
17
+ ## [0.6.8](https://github.com/restorecommerce/libs/compare/@restorecommerce/protos@0.6.7...@restorecommerce/protos@0.6.8) (2022-04-25)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * **protos:** updated user proto read rpc to return the Roles associated with the user ([ce87ee1](https://github.com/restorecommerce/libs/commit/ce87ee1998061d0addaa9f191174a18138fc2a05))
23
+
24
+
25
+
26
+
27
+
28
+ ## [0.6.7](https://github.com/restorecommerce/libs/compare/@restorecommerce/protos@0.6.6...@restorecommerce/protos@0.6.7) (2022-04-20)
29
+
30
+ **Note:** Version bump only for package @restorecommerce/protos
31
+
32
+
33
+
34
+
35
+
6
36
  ## [0.6.6](https://github.com/restorecommerce/libs/compare/@restorecommerce/protos@0.6.5...@restorecommerce/protos@0.6.6) (2022-04-05)
7
37
 
8
38
  **Note:** Version bump only for package @restorecommerce/protos
@@ -18,6 +18,16 @@ service Service {
18
18
  rpc Delete (io.restorecommerce.resourcebase.DeleteRequest) returns (io.restorecommerce.resourcebase.DeleteResponse);
19
19
  rpc Update (InvoiceList) returns (InvoiceListResponse);
20
20
  rpc Upsert (InvoiceList) returns (InvoiceListResponse);
21
+ rpc GenerateInvoiceNumber(RequestInvoiceNumber) returns (InvoiceNumberResponse);
22
+ }
23
+
24
+ message RequestInvoiceNumber {
25
+ google.protobuf.Any context = 1;
26
+ io.restorecommerce.auth.Subject subject = 3;
27
+ }
28
+
29
+ message InvoiceNumberResponse {
30
+ string invoice_no = 1;
21
31
  }
22
32
 
23
33
  message Deleted {
@@ -77,11 +87,14 @@ message InvoicePositions {
77
87
  io.restorecommerce.organization.Organization recipient_organization = 6;
78
88
  io.restorecommerce.organization.Organization sender_organization = 7;
79
89
  google.protobuf.Any payment_method_details = 8;
90
+ string invoice_no = 9; // optional invoice number if not it will be generated by service
91
+ double from_date = 10; // value performance from date
92
+ double to_date = 11; // value performance to date
80
93
  }
81
94
 
82
95
  message RecipientCustomer {
83
96
  string id = 1; // customer id - used to store the resource in DB
84
- string customer_number = 2; // displayed in invoice - auto generated per customer
97
+ string customer_number = 2; // displayed in invoice
85
98
  }
86
99
 
87
100
  message BillingAddress {
@@ -111,6 +124,7 @@ message InvoiceRow {
111
124
  uint32 quantity = 3;
112
125
  string vat = 4;
113
126
  double amount = 5;
127
+ double contract_start_date = 6; // if there is any contract associated with product
114
128
  }
115
129
 
116
130
  message InvoicePrice {
@@ -4,12 +4,14 @@ package io.restorecommerce.oauth;
4
4
 
5
5
  import "io/restorecommerce/auth.proto";
6
6
  import "io/restorecommerce/user.proto";
7
+ import "io/restorecommerce/status.proto";
7
8
  import "google/protobuf/empty.proto";
8
9
 
9
10
  service Service {
10
11
  rpc AvailableServices(google.protobuf.Empty) returns (ServicesResponse);
11
12
  rpc GenerateLinks(google.protobuf.Empty) returns (GenerateLinksResponse);
12
13
  rpc ExchangeCode(ExchangeCodeRequest) returns (ExchangeCodeResponse);
14
+ rpc GetToken(GetTokenRequest) returns (GetTokenResponse);
13
15
  }
14
16
 
15
17
  message ServicesResponse {
@@ -31,3 +33,13 @@ message ExchangeCodeResponse {
31
33
  string email = 2;
32
34
  io.restorecommerce.auth.Tokens token = 3;
33
35
  }
36
+
37
+ message GetTokenRequest {
38
+ io.restorecommerce.auth.Subject subject = 1;
39
+ string service = 2;
40
+ }
41
+
42
+ message GetTokenResponse {
43
+ io.restorecommerce.status.Status status = 1;
44
+ optional string token = 2;
45
+ }
@@ -9,12 +9,13 @@ import "io/restorecommerce/attribute.proto";
9
9
  import "io/restorecommerce/image.proto";
10
10
  import "io/restorecommerce/status.proto";
11
11
  import "google/protobuf/any.proto";
12
+ import "io/restorecommerce/role.proto";
12
13
 
13
14
  /**
14
15
  * The microservice for the user resource.
15
16
  */
16
17
  service Service {
17
- rpc Read (io.restorecommerce.resourcebase.ReadRequest) returns (UserListResponse);
18
+ rpc Read (io.restorecommerce.resourcebase.ReadRequest) returns (UserListWithRoleResponse);
18
19
  rpc Create (UserList) returns (UserListResponse);
19
20
  rpc Delete (io.restorecommerce.resourcebase.DeleteRequest) returns (io.restorecommerce.resourcebase.DeleteResponse);
20
21
  rpc Update (UserList) returns (UserListResponse);
@@ -203,6 +204,17 @@ message UserList {
203
204
  io.restorecommerce.auth.Subject subject = 3;
204
205
  }
205
206
 
207
+ message UserListWithRoleResponse {
208
+ repeated UserRoleResponse items = 1;
209
+ uint32 total_count = 2;
210
+ io.restorecommerce.status.OperationStatus operation_status = 3;
211
+ }
212
+
213
+ message UserRoleResponse {
214
+ UserRole payload = 1;
215
+ io.restorecommerce.status.Status status = 2;
216
+ }
217
+
206
218
  message UserListResponse {
207
219
  repeated UserResponse items = 1;
208
220
  uint32 total_count = 2;
@@ -258,3 +270,36 @@ message User {
258
270
  double last_access = 25;
259
271
  google.protobuf.Any data = 26; /// additional data
260
272
  }
273
+
274
+ /**
275
+ * A User resource with role
276
+ */
277
+ message UserRole {
278
+ string id = 1; /// User ID, unique, key
279
+ io.restorecommerce.meta.Meta meta = 2;
280
+ string name = 3; // The name of the user, can be used for login
281
+ string first_name = 4;
282
+ string last_name = 5;
283
+ string email = 6; /// Email address, can be used for login
284
+ string new_email = 7; /// New email address; set by `requestEmailChange` and overrides actual email upon `confirmEmailChange`
285
+ bool active = 8; /// If the user was activated via the activation process
286
+ string activation_code = 9; /// Activation code used in the activation process
287
+ string password = 10; /// Raw password, not stored
288
+ string password_hash = 11; /// Encrypted password, stored
289
+ repeated io.restorecommerce.auth.RoleAssociation role_associations = 12; // A user can have multiple roles and different attributes coupled with each role
290
+ string timezone_id = 13; // timezone_id specifications
291
+ string locale_id = 14; // locale specifications
292
+ string default_scope = 15; // default hierarchical scope
293
+ bool unauthenticated = 16; // true in case in case of `register`; set to false after activation
294
+ bool guest = 17; /// Is the user a guest. A guest is a automatically generated user which can later be turned in a non-guest user.
295
+ io.restorecommerce.image.Image image = 18;
296
+ UserType user_type = 19;
297
+ bool invite = 20; // For user invitation
298
+ string invited_by_user_name = 21; // user who is inviting
299
+ string invited_by_user_first_name = 22; // First name of user inviting
300
+ string invited_by_user_last_name = 23; // Last name of user inviting
301
+ repeated io.restorecommerce.auth.Tokens tokens = 24;
302
+ double last_access = 25;
303
+ google.protobuf.Any data = 26; /// additional data
304
+ repeated io.restorecommerce.role.Role role = 27;
305
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@restorecommerce/protos",
3
- "version": "0.6.6",
3
+ "version": "0.6.9",
4
4
  "description": "Protobuf descriptors for Restorecommerce services",
5
5
  "author": "n-fuse GmbH",
6
6
  "repository": {
@@ -15,5 +15,5 @@
15
15
  "protobufs"
16
16
  ],
17
17
  "scripts": {},
18
- "gitHead": "93ec5c59ff01e0292c56bb5161f63bb0df7e027b"
18
+ "gitHead": "23f3b0cf04a484cf83b5f4c816d0f98cc18488b9"
19
19
  }