@twin.org/node 0.0.3-next.16 → 0.0.3-next.18

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.
@@ -38,8 +38,7 @@
38
38
  "tenantAdminComponentNotRegistered": "Multi-tenant support must be enabled to use this command."
39
39
  },
40
40
  "tenantUpdate": {
41
- "tenantAdminComponentNotRegistered": "Multi-tenant support must be enabled to use this command.",
42
- "tenantNotFound": "The tenant with ID \"{notFoundId}\" was not found in the system."
41
+ "tenantAdminComponentNotRegistered": "Multi-tenant support must be enabled to use this command."
43
42
  },
44
43
  "userCreate": {
45
44
  "passwordTooShort": "The password provided is too short, it must be at least {minLength} characters long.",
@@ -49,7 +48,6 @@
49
48
  "vaultKeyAlreadyExists": "The vault key with ID already exists and overwriteMode is set to \"error\"."
50
49
  },
51
50
  "nodeSetTenant": {
52
- "tenantNotFound": "The tenant with ID \"{notFoundId}\" was not found in the system.",
53
51
  "tenantAdminComponentNotRegistered": "Multi-tenant support must be enabled to use this command."
54
52
  },
55
53
  "nodeSetIdentity": {
@@ -63,6 +61,8 @@
63
61
  "entityStorageAuthenticationAdminService": {
64
62
  "userExists": "The user with the specified e-mail already exists",
65
63
  "createUserFailed": "Creating the user failed",
64
+ "getUserFailed": "Getting the user failed",
65
+ "updateUserFailed": "Updating the user failed",
66
66
  "removeUserFailed": "Removing the user failed",
67
67
  "updatePasswordFailed": "Updating the user's password failed",
68
68
  "passwordTooShort": "The password is too short, it must be at least {minLength} characters long",
@@ -73,7 +73,8 @@
73
73
  "missing": "The JSON Web token could not be found in the authorization header",
74
74
  "payloadMissingSubject": "The JSON Web token payload does not contain a subject",
75
75
  "payloadMissingOrganization": "The JSON Web token payload does not contain an organization",
76
- "expired": "The JSON Web token has expired"
76
+ "expired": "The JSON Web token has expired",
77
+ "insufficientScopes": "The JSON Web token does not have the required scopes to access this resource"
77
78
  },
78
79
  "authHeaderProcessor": {
79
80
  "tenantIdMismatch": "The tenant ID in the token does not match the tenant ID in the context"
@@ -293,7 +294,8 @@
293
294
  "apiKeyNotFound": "No node tenant found for API key \"{key}\"."
294
295
  },
295
296
  "tenantAdminService": {
296
- "apiKeyAlreadyInUse": "The provided API key is already in use by another tenant."
297
+ "apiKeyAlreadyInUse": "The provided API key is already in use by another tenant.",
298
+ "tenantNotFound": "Tenant with ID \"{notFoundId}\" not found."
297
299
  },
298
300
  "commands": {
299
301
  "common": {
@@ -871,30 +873,47 @@
871
873
  "notAuthorizedToQuery": "Not authorized to query asset type \"{assetType}\"",
872
874
  "notAuthorizedToGet": "Not authorized to get asset type \"{assetType}\" with id \"{id}\""
873
875
  },
876
+ "odrlPolicyHelper": {
877
+ "policyMissingAssignee": "The {policyType} with id \"{policyId}\" is missing an assignee.",
878
+ "policyMissingAssigner": "The {policyType} with id \"{policyId}\" is missing an assigner."
879
+ },
874
880
  "trustHelper": {
875
881
  "trustVerifyFailed": "Trust verification failed for action \"{action}\""
876
882
  },
877
883
  "policyAdministrationPointService": {
878
884
  "namespaceMismatch": "The namespace in the urn \"{id}\" does not match the namespace of the rights management components \"{namespace}\"",
879
- "policyNotFound": "Policy not found with id: \"{notFoundId}\""
885
+ "policyNotFound": "Policy not found with id: \"{notFoundId}\"",
886
+ "agreementNotFound": "Agreement not found with id: \"{notFoundId}\"",
887
+ "agreementTypeMismatch": "The policy with id: \"{agreementId}\" is not of type Agreement, it is of type: \"{type}\".",
888
+ "offerNotFound": "Offer not found with id: \"{notFoundId}\"",
889
+ "offerTypeMismatch": "The policy with id: \"{offerId}\" is not of type Offer, it is of type: \"{type}\".",
890
+ "setNotFound": "Set not found with id: \"{notFoundId}\"",
891
+ "setTypeMismatch": "The policy with id: \"{setId}\" is not of type Set, it is of type: \"{type}\"."
880
892
  },
881
893
  "policyDecisionPointService": {
882
- "decidingFailed": "Deciding on policies for locator \"{locator}\" failed in arbiter with id: \"{arbiterId}\"",
883
- "noSupportedArbiters": "No arbiters found that support the given locator: \"{locator}\""
894
+ "decidingFailed": "Deciding on policies for policy id \"{policyId}\" failed in arbiter with id: \"{arbiterId}\"",
895
+ "noArbiters": "No policy arbiters are registered in the system."
884
896
  },
885
897
  "policyEnforcementPointService": {
886
- "processingFailed": "Failed to process information using processor with id: \"{processorId}\", locator: \"{locator}\""
898
+ "noProcessors": "No processors available to process information",
899
+ "processingFailed": "Failed to process information using processor with id: \"{processorId}\", policy id: \"{policyId}\"",
900
+ "noPoliciesFound": "No policies found for locator: \"{locator}\"",
901
+ "multiplePoliciesFound": "Multiple policies found for locator: \"{locator}\""
887
902
  },
888
903
  "policyInformationPointService": {
889
- "sourceRetrieveFailed": "Failed to retrieve information from source with id: \"{sourceId}\", locator: \"{locator}\""
904
+ "sourceRetrieveFailed": "Failed to retrieve information from source with id: \"{sourceId}\", for policy: \"{policyId}\""
890
905
  },
891
906
  "identityPolicyInformationSource": {
892
- "identityRetrievalFailed": "Failed to retrieve identity information for locator: \"{locator}\""
907
+ "identityRetrievalFailed": "Failed to retrieve identity \"{id}\" information for policy id: \"{policyId}\""
908
+ },
909
+ "defaultPolicyEnforcementProcessor": {
910
+ "targetNotJsonPath": "The policy decision target \"{target}\" is not a valid JSON-path string, it should be a minimum of $.",
911
+ "replaceValueMissing": "The policy decision replaceValue was not provided for target \"{target}\"."
893
912
  },
894
913
  "policyNegotiationPointService": {
895
914
  "noOfferFound": "No offer found with id: \"{offerId}\"",
896
915
  "noNegotiatorFound": "No negotiator found which support offer id: \"{offerId}\"",
897
- "noRequesterFound": "No requester found with id: \"{requesterId}\"",
916
+ "noRequesterFound": "No requester found with type: \"{notFoundId}\"",
898
917
  "negotiationFailed": "Negotiation failed for offer id: \"{offerId}\"",
899
918
  "agreementMissing": "The agreement is missing",
900
919
  "negotiationNotFound": "No negotiation found with id: \"{notFoundId}\"",
@@ -908,7 +927,7 @@
908
927
  "policyNotFound": "Policy with id: \"{notFoundId}\" not found"
909
928
  },
910
929
  "policyExecutionPointService": {
911
- "actionExecutionFailed": "Action execution failed for id: \"{actionId}\", at stage \"{stage}\", with locator: \"{locator}\""
930
+ "actionExecutionFailed": "Action execution failed for id: \"{actionId}\", at stage \"{stage}\", policy id: \"{policyId}\""
912
931
  },
913
932
  "policyNegotiationPointRestClient": {
914
933
  "notSupportedOnClient": "The method \"{methodName}\" is not supported on the REST client, it can only be used on a server side component"
@@ -1096,6 +1115,9 @@
1096
1115
  "description": "Bootstrap in legacy mode for backwards compatibility, **will be deprecated in future versions**",
1097
1116
  "example": "bootstrap-legacy --load-env=\"./.env.bootstrap-legacy\"",
1098
1117
  "params": {
1118
+ "env-prefix": {
1119
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1120
+ },
1099
1121
  "load-env": {
1100
1122
  "description": "Comma separated list of paths to .env files to read input parameters from."
1101
1123
  }
@@ -1120,6 +1142,9 @@
1120
1142
  "description": "Create an identity",
1121
1143
  "example": "identity-create --mnemonic=\"...\" --fund-wallet=true",
1122
1144
  "params": {
1145
+ "env-prefix": {
1146
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1147
+ },
1123
1148
  "mnemonic": {
1124
1149
  "description": "The mnemonic phrase to use for the identity. If not provided, a random mnemonic will be generated."
1125
1150
  },
@@ -1171,6 +1196,9 @@
1171
1196
  "description": "Import an identity",
1172
1197
  "example": "identity-import --identity=\"did:iota:...\" --mnemonic=\"...\"",
1173
1198
  "params": {
1199
+ "env-prefix": {
1200
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1201
+ },
1174
1202
  "identity": {
1175
1203
  "description": "The DID of the identity to import."
1176
1204
  },
@@ -1190,6 +1218,9 @@
1190
1218
  "description": "Create a verifiable credential",
1191
1219
  "example": "identity-verifiable-credential-create --identity=\"did:iota:....\" --verification-method-id=\"my-id\" --subject-json=\"./subject.json\"",
1192
1220
  "params": {
1221
+ "env-prefix": {
1222
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1223
+ },
1193
1224
  "identity": {
1194
1225
  "description": "The DID of the identity to use to create the credential."
1195
1226
  },
@@ -1231,6 +1262,9 @@
1231
1262
  "description": "Import an identity verification method",
1232
1263
  "example": "identity-verification-method-import --identity=\"did:iota:....\" --verification-method-type=\"verificationMethod\" --verification-method-id=\"my-key-1\" ----private-key-hex=\"15...a2\"",
1233
1264
  "params": {
1265
+ "env-prefix": {
1266
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1267
+ },
1234
1268
  "identity": {
1235
1269
  "description": "The DID of the identity to import the verification method to."
1236
1270
  },
@@ -1260,6 +1294,9 @@
1260
1294
  "description": "Create an identity verification method",
1261
1295
  "example": "identity-verification-method-create --identity=\"did:iota:....\" --verification-method-type=\"verificationMethod\" --verification-method-id=\"my-key-1\" --controller=\"did:iota:....\"",
1262
1296
  "params": {
1297
+ "env-prefix": {
1298
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1299
+ },
1263
1300
  "identity": {
1264
1301
  "description": "The DID of the identity to add the verification method to."
1265
1302
  },
@@ -1308,6 +1345,9 @@
1308
1345
  "description": "Set the node identity",
1309
1346
  "example": "node-set-identity --identity=\"did:iota...\"",
1310
1347
  "params": {
1348
+ "env-prefix": {
1349
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1350
+ },
1311
1351
  "identity": {
1312
1352
  "description": "The identity to set in the node."
1313
1353
  },
@@ -1324,6 +1364,9 @@
1324
1364
  "description": "Create a tenant with associated api key",
1325
1365
  "example": "tenant-create --tenant-id=\"0011..aabb\" --api-key=\"aabb..0099\" --label=\"My Tenant\" --public-origin=\"https://example.com:1234\"",
1326
1366
  "params": {
1367
+ "env-prefix": {
1368
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1369
+ },
1327
1370
  "tenant-id": {
1328
1371
  "description": "The tenant ID to add. If not provided a random tenant id will be generated."
1329
1372
  },
@@ -1361,6 +1404,9 @@
1361
1404
  "description": "Import a tenant with associated api key",
1362
1405
  "example": "tenant-import --tenant-id=\"0011..aabb\" --api-key=\"aabb..0099\" --label=\"My Tenant\" --public-origin=\"https://example.com:1234\"",
1363
1406
  "params": {
1407
+ "env-prefix": {
1408
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1409
+ },
1364
1410
  "tenant-id": {
1365
1411
  "description": "The tenant ID to import."
1366
1412
  },
@@ -1386,6 +1432,9 @@
1386
1432
  "description": "Update a tenant with associated api key",
1387
1433
  "example": "tenant-update --tenant-id=\"0011..aabb\" --api-key=\"aabb..0099\" --label=\"My Tenant\" --public-origin=\"https://example.com:1234\"",
1388
1434
  "params": {
1435
+ "env-prefix": {
1436
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1437
+ },
1389
1438
  "tenant-id": {
1390
1439
  "description": "The tenant ID to update."
1391
1440
  },
@@ -1411,6 +1460,9 @@
1411
1460
  "description": "Set the node tenant",
1412
1461
  "example": "node-set-tenant --tenant-id=\"0011..aabb\"",
1413
1462
  "params": {
1463
+ "env-prefix": {
1464
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1465
+ },
1414
1466
  "tenant-id": {
1415
1467
  "description": "The tenant ID to add. If not provided a random tenant id will be generated."
1416
1468
  },
@@ -1424,8 +1476,11 @@
1424
1476
  },
1425
1477
  "user-create": {
1426
1478
  "description": "Create a user",
1427
- "example": "user-create --user-identity=\"did:iota:....\" --organization-identity=\"did:iota:....\" --email=\"bob@examples.com\" --password=\"pass1234\" --givenName=\"Bob\" --familyName=\"Smith\"",
1479
+ "example": "user-create --user-identity=\"did:iota:....\" --organization-identity=\"did:iota:....\" --email=\"bob@examples.com\" --password=\"pass1234\" --scope=\"tenant-admin\" --givenName=\"Bob\" --familyName=\"Smith\"",
1428
1480
  "params": {
1481
+ "env-prefix": {
1482
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1483
+ },
1429
1484
  "user-identity": {
1430
1485
  "description": "The DID to associate the user with."
1431
1486
  },
@@ -1438,6 +1493,9 @@
1438
1493
  "password": {
1439
1494
  "description": "The password for the user."
1440
1495
  },
1496
+ "scope": {
1497
+ "description": "List of scopes to associate with the user, comma separated."
1498
+ },
1441
1499
  "given-name": {
1442
1500
  "description": "The given name of the user."
1443
1501
  },
@@ -1466,13 +1524,54 @@
1466
1524
  "storingProfile": "Storing profile",
1467
1525
  "userCreated": "User created",
1468
1526
  "skipping": "The user with ID already exists, skipping creation",
1469
- "overwriting": "Overwriting existing user with ID"
1527
+ "overwriting": "Overwriting existing user with ID",
1528
+ "email": "Email",
1529
+ "password": "Password"
1530
+ }
1531
+ },
1532
+ "user-update": {
1533
+ "description": "Update a user",
1534
+ "example": "user-update --email=\"bob@examples.com\" --user-identity=\"did:iota:....\" --organization-identity=\"did:iota:....\" --scope=\"tenant-admin\" --givenName=\"Bob\" --familyName=\"Smith\"",
1535
+ "params": {
1536
+ "env-prefix": {
1537
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1538
+ },
1539
+ "user-identity": {
1540
+ "description": "The DID to associate the user with."
1541
+ },
1542
+ "organization-identity": {
1543
+ "description": "The organization DID to associate the user with."
1544
+ },
1545
+ "email": {
1546
+ "description": "The email address of the user."
1547
+ },
1548
+ "scope": {
1549
+ "description": "List of scopes to associate with the user, comma separated."
1550
+ },
1551
+ "given-name": {
1552
+ "description": "The given name of the user."
1553
+ },
1554
+ "family-name": {
1555
+ "description": "The family name of the user."
1556
+ },
1557
+ "load-env": {
1558
+ "description": "Comma separated list of paths to .env files to read input parameters from."
1559
+ }
1560
+ },
1561
+ "labels": {
1562
+ "updating": "Updating user",
1563
+ "storingUser": "Storing user",
1564
+ "storingProfile": "Storing profile",
1565
+ "userUpdated": "User updated"
1470
1566
  }
1471
1567
  },
1472
1568
  "vault-key-create": {
1473
1569
  "description": "Create a vault key for an identity",
1474
1570
  "example": "vault-key-create --identity=\"did:iota:....\" --key-id=\"my-key\" --type=\"Ed25519\"",
1475
1571
  "params": {
1572
+ "env-prefix": {
1573
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1574
+ },
1476
1575
  "identity": {
1477
1576
  "description": "The DID to associate the key with."
1478
1577
  },
@@ -1515,6 +1614,9 @@
1515
1614
  "description": "Import a vault key for an identity",
1516
1615
  "example": "vault-key-import --identity=\"did:iota:....\" --key-id=\"my-key\" --key-type=Ed25519 --private-key-hex=\"15...a2\"",
1517
1616
  "params": {
1617
+ "env-prefix": {
1618
+ "description": "Prefix to use for standard .env files e.g. TWIN_."
1619
+ },
1518
1620
  "identity": {
1519
1621
  "description": "The DID to associate the key with."
1520
1622
  },
@@ -1782,27 +1884,46 @@
1782
1884
  "contractReady": "Contract ready for use"
1783
1885
  },
1784
1886
  "policyEnforcementPointService": {
1785
- "processing": "Processing information using processor with id: \"{processorId}\", locator: \"{locator}\"",
1786
- "intercepting": "Intercepting information for locator: \"{locator}\""
1887
+ "processing": "Processing information using processor with id: \"{processorId}\", policy id: \"{policyId}\"",
1888
+ "intercepting": "Intercepting information for policy id: \"{policyId}\""
1787
1889
  },
1788
1890
  "identityPolicyInformationSource": {
1789
- "identityRetrieving": "Retrieving identity information for locator: \"{locator}\""
1891
+ "identityRetrieving": "Retrieving identity \"{id}\" information for policy id: \"{policyId}\""
1790
1892
  },
1791
1893
  "staticPolicyInformationSource": {
1792
- "staticRetrieving": "Retrieving static policy information for locator \"{locator}\" with access mode: \"{accessMode}\"",
1793
- "staticRetrieved": "Retrieved static policy information for locator: \"{locator}\" with access mode: \"{accessMode}\", item count: {itemCount}"
1894
+ "staticRetrieving": "Retrieving static policy information for policy id: \"{policyId}\" with access mode: \"{accessMode}\"",
1895
+ "staticRetrieved": "Retrieved static policy information for policy id: \"{policyId}\" with access mode: \"{accessMode}\", item count: {itemCount}"
1794
1896
  },
1795
1897
  "loggingPolicyExecutionAction": {
1796
- "policyActionExecutedBefore": "Policy executed for locator: \"{locator}\", stage: \"{stage}\", data: \"{data}\", policies: \"{policies}\"",
1797
- "policyActionExecutedAfter": "Policy executed for locator: \"{locator}\", stage: \"{stage}\", data: \"{data}\", policies: \"{policies}\", decisions: \"{decisions}\""
1898
+ "policyActionExecutedBefore": "Policy executed for policyId: \"{policyId}\", stage: \"{stage}\", data: \"{data}\", policy: \"{policy}\", decisions: \"{decisions}\"",
1899
+ "policyActionExecutedAfter": "Policy executed for policyId: \"{policyId}\", stage: \"{stage}\", data: \"{data}\", policy: \"{policy}\", decisions: \"{decisions}\""
1900
+ },
1901
+ "passThroughPolicyEnforcementProcessor": {
1902
+ "processingPolicy": "Processing policy enforcement for policy id: \"{policyId}\""
1903
+ },
1904
+ "defaultPolicyEnforcementProcessor": {
1905
+ "processingPolicy": "Processing policy enforcement for policy id: \"{policyId}\""
1906
+ },
1907
+ "passThroughPolicyArbiter": {
1908
+ "decidingPolicy": "Deciding policy for policy id: \"{policyId}\""
1909
+ },
1910
+ "passThroughPolicyNegotiator": {
1911
+ "handlingOffer": "Handling offer negotiation for offer id: \"{offerId}\"",
1912
+ "createAgreement": "Creating agreement for policy id: \"{offerId}\""
1913
+ },
1914
+ "passThroughPolicyRequester": {
1915
+ "offer": "Logging offer request for offer id: \"{offerId}\", negotiation id: \"{negotiationId}\"",
1916
+ "agreement": "Logging agreement request for agreement id: \"{agreementId}\", negotiation id: \"{negotiationId}\"",
1917
+ "finalised": "Logging finalised request for negotiation id: \"{negotiationId}\"",
1918
+ "terminated": "Logging terminated request for negotiation id: \"{negotiationId}\""
1798
1919
  },
1799
1920
  "policyManagementPointService": {
1800
1921
  "retrieving": "Retrieving policies for locator \"locator\"",
1801
1922
  "retrieved": "Retrieved {count} policies for locator \"locator\"."
1802
1923
  },
1803
1924
  "policyExecutionPointService": {
1804
- "executingActions": "Executing actions for stage: \"{stage}\", locator: \"{locator}\"",
1805
- "executingAction": "Executing action for stage: \"{stage}\", locator: \"{locator}\""
1925
+ "executingActions": "Executing actions for stage: \"{stage}\", policy id: \"{policyId}\"",
1926
+ "executingAction": "Executing action for stage: \"{stage}\", policy id: \"{policyId}\""
1806
1927
  },
1807
1928
  "changeSetHelper": {
1808
1929
  "changeSetApplyingChange": "Applying remote sync change with operation id \"{operation}\" for item with id \"{id}\"",
package/docs/changelog.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # @twin.org/node - Changelog
2
2
 
3
+ ## [0.0.3-next.18](https://github.com/twinfoundation/node/compare/node-v0.0.3-next.17...node-v0.0.3-next.18) (2026-02-04)
4
+
5
+
6
+ ### Features
7
+
8
+ * env-prefix option and user-update cli command ([#83](https://github.com/twinfoundation/node/issues/83)) ([fc48efa](https://github.com/twinfoundation/node/commit/fc48efa7ad72173def048170c3afb5eeb9f1b292))
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @twin.org/node-core bumped from 0.0.3-next.17 to 0.0.3-next.18
16
+
17
+ ## [0.0.3-next.17](https://github.com/twinfoundation/node/compare/node-v0.0.3-next.16...node-v0.0.3-next.17) (2026-02-02)
18
+
19
+
20
+ ### Features
21
+
22
+ * update rights management ([5c992c6](https://github.com/twinfoundation/node/commit/5c992c6b0d72f3eeaa39ee267e096d9a3f477f4e))
23
+
24
+
25
+ ### Dependencies
26
+
27
+ * The following workspace dependencies were updated
28
+ * dependencies
29
+ * @twin.org/node-core bumped from 0.0.3-next.16 to 0.0.3-next.17
30
+
3
31
  ## [0.0.3-next.16](https://github.com/twinfoundation/node/compare/node-v0.0.3-next.15...node-v0.0.3-next.16) (2026-01-28)
4
32
 
5
33
 
package/docs/examples.md CHANGED
@@ -142,7 +142,7 @@ twin-node identity-verification-method-create --load-env="node-identity.env,orga
142
142
  twin-node vault-key-create --load-env="organization-identity.env" --identity=!ORGANIZATION_DID --key-id=!TWIN_BLOB_STORAGE_ENCRYPTION_KEY_ID --key-type=ChaCha20Poly1305 --output-json="organization-blob-encryption.json" --output-env="organization-blob-encryption.env"
143
143
  ```
144
144
 
145
- ### Create a user identity associated with the organization
145
+ ### Create an identity associated with the organization
146
146
 
147
147
  ```shell
148
148
  twin-node identity-create --load-env="organization-identity.env" --controller=!ORGANIZATION_DID --output-json="user-identity.json" --output-env="user-identity.env" --output-env-prefix=user
@@ -151,5 +151,11 @@ twin-node identity-create --load-env="organization-identity.env" --controller=!O
151
151
  ### Create a user login associated with the user identity
152
152
 
153
153
  ```shell
154
- twin-node user-create --load-env="organization-identity.env,user-identity.env,node-tenant.env" --user-identity=!USER_DID --organization-identity=!ORGANIZATION_DID --tenant-id=!NODE_TENANT_ID --email="admin@node" --output-json="user-account-admin.json" --output-env="user-account-admin.env" --output-env-prefix=admin
154
+ twin-node user-create --load-env="organization-identity.env,user-identity.env,node-tenant.env" --user-identity=!USER_DID --organization-identity=!ORGANIZATION_DID --email="admin@node" --scope="tenant-admin" --output-json="user-account-admin.json" --output-env="user-account-admin.env" --output-env-prefix=admin
155
+ ```
156
+
157
+ ### Update a user login associated with the user identity
158
+
159
+ ```shell
160
+ twin-node user-update --load-env="organization-identity.env,user-identity.env,node-tenant.env" --email="admin@node" --scope="tenant-admin,foo"
155
161
  ```
@@ -12779,6 +12779,42 @@
12779
12779
  "Policy Administration Point"
12780
12780
  ],
12781
12781
  "parameters": [
12782
+ {
12783
+ "name": "assigner",
12784
+ "description": "The assigner to filter by.",
12785
+ "in": "query",
12786
+ "required": false,
12787
+ "schema": {
12788
+ "type": "string"
12789
+ }
12790
+ },
12791
+ {
12792
+ "name": "assignee",
12793
+ "description": "The assignee to filter by.",
12794
+ "in": "query",
12795
+ "required": false,
12796
+ "schema": {
12797
+ "type": "string"
12798
+ }
12799
+ },
12800
+ {
12801
+ "name": "action",
12802
+ "description": "The action to filter by.",
12803
+ "in": "query",
12804
+ "required": false,
12805
+ "schema": {
12806
+ "type": "string"
12807
+ }
12808
+ },
12809
+ {
12810
+ "name": "target",
12811
+ "description": "The target to filter by.",
12812
+ "in": "query",
12813
+ "required": false,
12814
+ "schema": {
12815
+ "type": "string"
12816
+ }
12817
+ },
12782
12818
  {
12783
12819
  "name": "conditions",
12784
12820
  "description": "The condition for the query.",
@@ -12823,22 +12859,19 @@
12823
12859
  },
12824
12860
  "examples": {
12825
12861
  "papQueryResponseExample": {
12826
- "value": {
12827
- "cursor": "next-page-cursor",
12828
- "policies": [
12829
- {
12830
- "@context": "http://www.w3.org/ns/odrl.jsonld",
12831
- "@type": "Set",
12832
- "uid": "urn:rights-management:abc123def456",
12833
- "permission": [
12834
- {
12835
- "target": "http://example.com/asset/1",
12836
- "action": "use"
12837
- }
12838
- ]
12839
- }
12840
- ]
12841
- }
12862
+ "value": [
12863
+ {
12864
+ "@context": "http://www.w3.org/ns/odrl.jsonld",
12865
+ "@type": "Set",
12866
+ "uid": "urn:rights-management:abc123def456",
12867
+ "permission": [
12868
+ {
12869
+ "target": "http://example.com/asset/1",
12870
+ "action": "use"
12871
+ }
12872
+ ]
12873
+ }
12874
+ ]
12842
12875
  }
12843
12876
  }
12844
12877
  }
@@ -13215,6 +13248,345 @@
13215
13248
  }
13216
13249
  }
13217
13250
  },
13251
+ "/rights-management/policy/admin/agreement/{id}": {
13252
+ "get": {
13253
+ "operationId": "papGetAgreement",
13254
+ "summary": "Get a policy agreement",
13255
+ "tags": [
13256
+ "Policy Administration Point"
13257
+ ],
13258
+ "parameters": [
13259
+ {
13260
+ "name": "id",
13261
+ "description": "The ID of the agreement to get.",
13262
+ "in": "path",
13263
+ "required": true,
13264
+ "schema": {
13265
+ "type": "string"
13266
+ },
13267
+ "style": "simple",
13268
+ "example": "urn:rights-management:abc123def456"
13269
+ }
13270
+ ],
13271
+ "security": [
13272
+ {
13273
+ "jwtBearerAuthScheme": []
13274
+ }
13275
+ ],
13276
+ "responses": {
13277
+ "200": {
13278
+ "description": "The response structure for getting an agreement.",
13279
+ "content": {
13280
+ "application/json": {
13281
+ "schema": {
13282
+ "$ref": "https://schema.twindev.org/w3c-odrl/OdrlAgreement"
13283
+ },
13284
+ "examples": {
13285
+ "papGetResponseExample": {
13286
+ "value": {
13287
+ "@context": "http://www.w3.org/ns/odrl.jsonld",
13288
+ "@type": "Agreement",
13289
+ "uid": "urn:rights-management:abc123def456",
13290
+ "permission": [
13291
+ {
13292
+ "target": "http://example.com/asset/1",
13293
+ "action": "use"
13294
+ }
13295
+ ],
13296
+ "assignee": "did:example:receiver",
13297
+ "assigner": "did:example:sender"
13298
+ }
13299
+ }
13300
+ }
13301
+ }
13302
+ }
13303
+ },
13304
+ "400": {
13305
+ "description": "The server cannot process the request, see the content for more details.",
13306
+ "content": {
13307
+ "application/json": {
13308
+ "schema": {
13309
+ "$ref": "#/components/schemas/Error"
13310
+ },
13311
+ "examples": {
13312
+ "exampleResponse": {
13313
+ "value": {
13314
+ "name": "GeneralError",
13315
+ "message": "errorMessage",
13316
+ "properties": {
13317
+ "foo": "bar"
13318
+ }
13319
+ }
13320
+ }
13321
+ }
13322
+ }
13323
+ }
13324
+ },
13325
+ "401": {
13326
+ "description": "You are not authorized to use the API or no credentials were supplied, see the content for more details.",
13327
+ "content": {
13328
+ "application/json": {
13329
+ "schema": {
13330
+ "$ref": "#/components/schemas/Error"
13331
+ },
13332
+ "examples": {
13333
+ "exampleResponse": {
13334
+ "value": {
13335
+ "name": "UnauthorizedError",
13336
+ "message": "errorMessage"
13337
+ }
13338
+ }
13339
+ }
13340
+ }
13341
+ }
13342
+ },
13343
+ "500": {
13344
+ "description": "The server has encountered a situation it does not know how to handle, see the content for more details.",
13345
+ "content": {
13346
+ "application/json": {
13347
+ "schema": {
13348
+ "$ref": "#/components/schemas/Error"
13349
+ },
13350
+ "examples": {
13351
+ "exampleResponse": {
13352
+ "value": {
13353
+ "name": "InternalServerError",
13354
+ "message": "errorMessage"
13355
+ }
13356
+ }
13357
+ }
13358
+ }
13359
+ }
13360
+ }
13361
+ }
13362
+ }
13363
+ },
13364
+ "/rights-management/policy/admin/offer/{id}": {
13365
+ "get": {
13366
+ "operationId": "papGetOffer",
13367
+ "summary": "Get a policy offer",
13368
+ "tags": [
13369
+ "Policy Administration Point"
13370
+ ],
13371
+ "parameters": [
13372
+ {
13373
+ "name": "id",
13374
+ "description": "The ID of the offer to get.",
13375
+ "in": "path",
13376
+ "required": true,
13377
+ "schema": {
13378
+ "type": "string"
13379
+ },
13380
+ "style": "simple",
13381
+ "example": "urn:rights-management:abc123def456"
13382
+ }
13383
+ ],
13384
+ "security": [
13385
+ {
13386
+ "jwtBearerAuthScheme": []
13387
+ }
13388
+ ],
13389
+ "responses": {
13390
+ "200": {
13391
+ "description": "The response structure for getting an offer.",
13392
+ "content": {
13393
+ "application/json": {
13394
+ "schema": {
13395
+ "$ref": "https://schema.twindev.org/w3c-odrl/OdrlOffer"
13396
+ },
13397
+ "examples": {
13398
+ "papGetResponseExample": {
13399
+ "value": {
13400
+ "@context": "http://www.w3.org/ns/odrl.jsonld",
13401
+ "@type": "Offer",
13402
+ "uid": "urn:rights-management:abc123def456",
13403
+ "permission": [
13404
+ {
13405
+ "target": "http://example.com/asset/1",
13406
+ "action": "use"
13407
+ }
13408
+ ],
13409
+ "assignee": "did:example:receiver",
13410
+ "assigner": "did:example:sender"
13411
+ }
13412
+ }
13413
+ }
13414
+ }
13415
+ }
13416
+ },
13417
+ "400": {
13418
+ "description": "The server cannot process the request, see the content for more details.",
13419
+ "content": {
13420
+ "application/json": {
13421
+ "schema": {
13422
+ "$ref": "#/components/schemas/Error"
13423
+ },
13424
+ "examples": {
13425
+ "exampleResponse": {
13426
+ "value": {
13427
+ "name": "GeneralError",
13428
+ "message": "errorMessage",
13429
+ "properties": {
13430
+ "foo": "bar"
13431
+ }
13432
+ }
13433
+ }
13434
+ }
13435
+ }
13436
+ }
13437
+ },
13438
+ "401": {
13439
+ "description": "You are not authorized to use the API or no credentials were supplied, see the content for more details.",
13440
+ "content": {
13441
+ "application/json": {
13442
+ "schema": {
13443
+ "$ref": "#/components/schemas/Error"
13444
+ },
13445
+ "examples": {
13446
+ "exampleResponse": {
13447
+ "value": {
13448
+ "name": "UnauthorizedError",
13449
+ "message": "errorMessage"
13450
+ }
13451
+ }
13452
+ }
13453
+ }
13454
+ }
13455
+ },
13456
+ "500": {
13457
+ "description": "The server has encountered a situation it does not know how to handle, see the content for more details.",
13458
+ "content": {
13459
+ "application/json": {
13460
+ "schema": {
13461
+ "$ref": "#/components/schemas/Error"
13462
+ },
13463
+ "examples": {
13464
+ "exampleResponse": {
13465
+ "value": {
13466
+ "name": "InternalServerError",
13467
+ "message": "errorMessage"
13468
+ }
13469
+ }
13470
+ }
13471
+ }
13472
+ }
13473
+ }
13474
+ }
13475
+ }
13476
+ },
13477
+ "/rights-management/policy/admin/set/{id}": {
13478
+ "get": {
13479
+ "operationId": "papGetSet",
13480
+ "summary": "Get a policy set",
13481
+ "tags": [
13482
+ "Policy Administration Point"
13483
+ ],
13484
+ "parameters": [
13485
+ {
13486
+ "name": "id",
13487
+ "description": "The ID of the set to get.",
13488
+ "in": "path",
13489
+ "required": true,
13490
+ "schema": {
13491
+ "type": "string"
13492
+ },
13493
+ "style": "simple",
13494
+ "example": "urn:rights-management:abc123def456"
13495
+ }
13496
+ ],
13497
+ "security": [
13498
+ {
13499
+ "jwtBearerAuthScheme": []
13500
+ }
13501
+ ],
13502
+ "responses": {
13503
+ "200": {
13504
+ "description": "The response structure for getting a set.",
13505
+ "content": {
13506
+ "application/json": {
13507
+ "schema": {
13508
+ "$ref": "https://schema.twindev.org/w3c-odrl/OdrlSet"
13509
+ },
13510
+ "examples": {
13511
+ "papGetResponseExample": {
13512
+ "value": {
13513
+ "@context": "http://www.w3.org/ns/odrl.jsonld",
13514
+ "@type": "Set",
13515
+ "uid": "urn:rights-management:abc123def456",
13516
+ "permission": [
13517
+ {
13518
+ "target": "http://example.com/asset/1",
13519
+ "action": "use"
13520
+ }
13521
+ ],
13522
+ "assignee": "did:example:receiver",
13523
+ "assigner": "did:example:sender"
13524
+ }
13525
+ }
13526
+ }
13527
+ }
13528
+ }
13529
+ },
13530
+ "400": {
13531
+ "description": "The server cannot process the request, see the content for more details.",
13532
+ "content": {
13533
+ "application/json": {
13534
+ "schema": {
13535
+ "$ref": "#/components/schemas/Error"
13536
+ },
13537
+ "examples": {
13538
+ "exampleResponse": {
13539
+ "value": {
13540
+ "name": "GeneralError",
13541
+ "message": "errorMessage",
13542
+ "properties": {
13543
+ "foo": "bar"
13544
+ }
13545
+ }
13546
+ }
13547
+ }
13548
+ }
13549
+ }
13550
+ },
13551
+ "401": {
13552
+ "description": "You are not authorized to use the API or no credentials were supplied, see the content for more details.",
13553
+ "content": {
13554
+ "application/json": {
13555
+ "schema": {
13556
+ "$ref": "#/components/schemas/Error"
13557
+ },
13558
+ "examples": {
13559
+ "exampleResponse": {
13560
+ "value": {
13561
+ "name": "UnauthorizedError",
13562
+ "message": "errorMessage"
13563
+ }
13564
+ }
13565
+ }
13566
+ }
13567
+ }
13568
+ },
13569
+ "500": {
13570
+ "description": "The server has encountered a situation it does not know how to handle, see the content for more details.",
13571
+ "content": {
13572
+ "application/json": {
13573
+ "schema": {
13574
+ "$ref": "#/components/schemas/Error"
13575
+ },
13576
+ "examples": {
13577
+ "exampleResponse": {
13578
+ "value": {
13579
+ "name": "InternalServerError",
13580
+ "message": "errorMessage"
13581
+ }
13582
+ }
13583
+ }
13584
+ }
13585
+ }
13586
+ }
13587
+ }
13588
+ }
13589
+ },
13218
13590
  "/rights-management/negotiations/{id}": {
13219
13591
  "get": {
13220
13592
  "operationId": "pnpGetNegotiation",
@@ -14599,17 +14971,14 @@
14599
14971
  },
14600
14972
  "examples": {
14601
14973
  "pnapQueryResponseExample": {
14602
- "value": {
14603
- "items": [
14604
- {
14605
- "id": "pid",
14606
- "correlationId": "cid",
14607
- "dateCreated": "2025-09-03T00:00:00.000Z",
14608
- "state": "REQUESTED"
14609
- }
14610
- ],
14611
- "cursor": "next-cursor"
14612
- }
14974
+ "value": [
14975
+ {
14976
+ "id": "pid",
14977
+ "correlationId": "cid",
14978
+ "dateCreated": "2025-09-03T00:00:00.000Z",
14979
+ "state": "REQUESTED"
14980
+ }
14981
+ ]
14613
14982
  }
14614
14983
  }
14615
14984
  }
@@ -18954,45 +19323,17 @@
18954
19323
  "description": "The body of the request - the policy to create (uid will be auto-generated)."
18955
19324
  },
18956
19325
  "PapQueryResponse": {
18957
- "type": "object",
18958
- "properties": {
18959
- "cursor": {
18960
- "type": "string",
18961
- "description": "The cursor for the next page of results, if there are more results available."
18962
- },
18963
- "policies": {
18964
- "type": "array",
18965
- "items": {
18966
- "$ref": "https://schema.twindev.org/w3c-odrl/OdrlPolicy"
18967
- },
18968
- "description": "The policies matching the query."
18969
- }
19326
+ "type": "array",
19327
+ "items": {
19328
+ "$ref": "https://schema.twindev.org/w3c-odrl/OdrlPolicy"
18970
19329
  },
18971
- "required": [
18972
- "policies"
18973
- ],
18974
- "additionalProperties": false,
18975
19330
  "description": "The body of the response."
18976
19331
  },
18977
19332
  "PnapQueryResponse": {
18978
- "type": "object",
18979
- "properties": {
18980
- "items": {
18981
- "type": "array",
18982
- "items": {
18983
- "$ref": "#/components/schemas/PolicyNegotiation"
18984
- },
18985
- "description": "The list of policy negotiations."
18986
- },
18987
- "cursor": {
18988
- "type": "string",
18989
- "description": "The cursor for pagination."
18990
- }
19333
+ "type": "array",
19334
+ "items": {
19335
+ "$ref": "#/components/schemas/PolicyNegotiation"
18991
19336
  },
18992
- "required": [
18993
- "items"
18994
- ],
18995
- "additionalProperties": false,
18996
19337
  "description": "The body of the response."
18997
19338
  },
18998
19339
  "PnpContractNegotiationResponse": {
@@ -19006,39 +19347,9 @@
19006
19347
  ],
19007
19348
  "description": "The state of the policy or an error."
19008
19349
  },
19009
- "PolicyInformation": {
19010
- "type": "object",
19011
- "additionalProperties": {
19012
- "$ref": "#/components/schemas/PolicyInformationItems"
19013
- },
19014
- "description": "Interface describing a Policy Information."
19015
- },
19016
- "PolicyInformationItems": {
19017
- "type": "array",
19018
- "items": {
19019
- "$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
19020
- },
19021
- "description": "Interface describing a Policy Information."
19022
- },
19023
19350
  "PolicyNegotiation": {
19024
19351
  "type": "object",
19025
19352
  "properties": {
19026
- "assignee": {
19027
- "type": "string",
19028
- "description": "The assignee for the locator."
19029
- },
19030
- "action": {
19031
- "type": "string",
19032
- "description": "The action for the locator."
19033
- },
19034
- "assetType": {
19035
- "type": "string",
19036
- "description": "The asset type for the locator."
19037
- },
19038
- "resourceId": {
19039
- "type": "string",
19040
- "description": "A resource identifier for the locator."
19041
- },
19042
19353
  "id": {
19043
19354
  "type": "string",
19044
19355
  "description": "The primary id used by the provider."
@@ -19072,8 +19383,8 @@
19072
19383
  "agreement": {
19073
19384
  "$ref": "https://schema.twindev.org/w3c-odrl/OdrlAgreement"
19074
19385
  },
19075
- "information": {
19076
- "$ref": "#/components/schemas/PolicyInformation"
19386
+ "trustVerificationInfo": {
19387
+ "$ref": "#/components/schemas/TrustVerificationInfo"
19077
19388
  },
19078
19389
  "code": {
19079
19390
  "type": "string",
@@ -19564,6 +19875,27 @@
19564
19875
  "additionalProperties": false,
19565
19876
  "description": "The response payload."
19566
19877
  },
19878
+ "TrustVerificationInfo": {
19879
+ "type": "object",
19880
+ "properties": {
19881
+ "identity": {
19882
+ "type": "string",
19883
+ "description": "The identity associated with the payload."
19884
+ },
19885
+ "data": {
19886
+ "type": "object",
19887
+ "additionalProperties": {
19888
+ "$ref": "https://schema.twindev.org/json-ld/JsonLdNodeObject"
19889
+ },
19890
+ "description": "Additional JSON-LD node objects associated with the verification."
19891
+ }
19892
+ },
19893
+ "required": [
19894
+ "identity"
19895
+ ],
19896
+ "additionalProperties": false,
19897
+ "description": "Interface describing a trust verifier information."
19898
+ },
19567
19899
  "UpdatePasswordRequest": {
19568
19900
  "type": "object",
19569
19901
  "properties": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twin.org/node",
3
- "version": "0.0.3-next.16",
3
+ "version": "0.0.3-next.18",
4
4
  "description": "TWIN Node serving APIs using the specified configuration",
5
5
  "repository": {
6
6
  "type": "git",
@@ -14,7 +14,7 @@
14
14
  "node": ">=20.0.0"
15
15
  },
16
16
  "dependencies": {
17
- "@twin.org/node-core": "0.0.3-next.16"
17
+ "@twin.org/node-core": "0.0.3-next.18"
18
18
  },
19
19
  "bugs": {
20
20
  "url": "git+https://github.com/twinfoundation/node/issues"