@calimero-network/mero-js 9.0.0 → 9.0.2

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/dist/index.cjs CHANGED
@@ -1170,7 +1170,12 @@ var AdminApiClient = class {
1170
1170
  return unwrap(await this.httpClient.get(`/admin-api/namespaces/for-application/${applicationId}`));
1171
1171
  }
1172
1172
  async createNamespace(request) {
1173
- return unwrap(await this.httpClient.post("/admin-api/namespaces", request));
1173
+ return unwrap(
1174
+ await this.httpClient.post("/admin-api/namespaces", {
1175
+ upgradePolicy: "LazyOnAccess",
1176
+ ...request
1177
+ })
1178
+ );
1174
1179
  }
1175
1180
  async deleteNamespace(namespaceId, request) {
1176
1181
  return unwrap(
@@ -1251,9 +1256,17 @@ var AdminApiClient = class {
1251
1256
  async removeGroupMembers(groupId, request) {
1252
1257
  await this.httpClient.post(`/admin-api/groups/${groupId}/members/remove`, request);
1253
1258
  }
1259
+ /**
1260
+ * `identity` is the member's ACCOUNT (64 hex), as returned by
1261
+ * {@link listGroupMembers} — not the bs58 signing key that added them.
1262
+ */
1254
1263
  async updateMemberRole(groupId, identity, request) {
1255
1264
  await this.httpClient.put(`/admin-api/groups/${groupId}/members/${identity}/role`, request);
1256
1265
  }
1266
+ /**
1267
+ * `identity` is the member's ACCOUNT (64 hex), as returned by
1268
+ * {@link listGroupMembers} — not the bs58 signing key that added them.
1269
+ */
1257
1270
  async getMemberCapabilities(groupId, identity) {
1258
1271
  return unwrap(
1259
1272
  await this.httpClient.get(
@@ -1261,6 +1274,10 @@ var AdminApiClient = class {
1261
1274
  )
1262
1275
  );
1263
1276
  }
1277
+ /**
1278
+ * `identity` is the member's ACCOUNT (64 hex), as returned by
1279
+ * {@link listGroupMembers} — not the bs58 signing key that added them.
1280
+ */
1264
1281
  async setMemberCapabilities(groupId, identity, request) {
1265
1282
  await this.httpClient.put(`/admin-api/groups/${groupId}/members/${identity}/capabilities`, request);
1266
1283
  }
@@ -1290,6 +1307,10 @@ var AdminApiClient = class {
1290
1307
  async setMemberMetadata(groupId, identity, request) {
1291
1308
  await this.httpClient.put(`/admin-api/groups/${groupId}/members/${identity}/metadata`, request);
1292
1309
  }
1310
+ /**
1311
+ * `identity` is the member's ACCOUNT (64 hex), as returned by
1312
+ * {@link listGroupMembers} — not the bs58 signing key that added them.
1313
+ */
1293
1314
  async getMemberMetadata(groupId, identity) {
1294
1315
  const response = await this.httpClient.get(
1295
1316
  `/admin-api/groups/${groupId}/members/${identity}/metadata`
@@ -1416,7 +1437,10 @@ var AdminApiClient = class {
1416
1437
  /** Create a standalone group (POST /admin-api/groups). */
1417
1438
  async createGroup(request) {
1418
1439
  return unwrap(
1419
- await this.httpClient.post("/admin-api/groups", request)
1440
+ await this.httpClient.post("/admin-api/groups", {
1441
+ upgradePolicy: "LazyOnAccess",
1442
+ ...request
1443
+ })
1420
1444
  );
1421
1445
  }
1422
1446
  /** Leave a group (POST /admin-api/groups/:group_id/leave). */
@@ -1442,7 +1466,13 @@ var AdminApiClient = class {
1442
1466
  request ?? {}
1443
1467
  );
1444
1468
  }
1445
- /** Set a member's auto-follow flag (PUT /admin-api/groups/:group_id/members/:identity/auto-follow). */
1469
+ /**
1470
+ * Set a member's auto-follow flag (PUT
1471
+ * /admin-api/groups/:group_id/members/:identity/auto-follow).
1472
+ *
1473
+ * `identity` is the member's ACCOUNT (64 hex), as returned by
1474
+ * {@link listGroupMembers} — not the bs58 signing key that added them.
1475
+ */
1446
1476
  async setMemberAutoFollow(groupId, identity, request) {
1447
1477
  await this.httpClient.put(`/admin-api/groups/${groupId}/members/${identity}/auto-follow`, request);
1448
1478
  }