@zilfu/sdk 0.2.22 → 0.2.23
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 +106 -100
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +547 -530
- package/dist/index.d.ts +547 -530
- package/dist/index.js +106 -100
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1145,6 +1145,108 @@ var Media = class extends HeyApiClient {
|
|
|
1145
1145
|
});
|
|
1146
1146
|
}
|
|
1147
1147
|
};
|
|
1148
|
+
var Invitations = class extends HeyApiClient {
|
|
1149
|
+
/**
|
|
1150
|
+
* List pending invitations for an organization
|
|
1151
|
+
*/
|
|
1152
|
+
list(options) {
|
|
1153
|
+
return (options.client ?? this.client).get({
|
|
1154
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1155
|
+
url: "/organizations/{organization}/invitations",
|
|
1156
|
+
...options
|
|
1157
|
+
});
|
|
1158
|
+
}
|
|
1159
|
+
/**
|
|
1160
|
+
* Send an invitation
|
|
1161
|
+
*/
|
|
1162
|
+
create(options) {
|
|
1163
|
+
return (options.client ?? this.client).post({
|
|
1164
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1165
|
+
url: "/organizations/{organization}/invitations",
|
|
1166
|
+
...options,
|
|
1167
|
+
headers: {
|
|
1168
|
+
"Content-Type": "application/json",
|
|
1169
|
+
...options.headers
|
|
1170
|
+
}
|
|
1171
|
+
});
|
|
1172
|
+
}
|
|
1173
|
+
/**
|
|
1174
|
+
* Revoke a pending invitation
|
|
1175
|
+
*/
|
|
1176
|
+
delete(options) {
|
|
1177
|
+
return (options.client ?? this.client).delete({
|
|
1178
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1179
|
+
url: "/organizations/{organization}/invitations/{invitation}",
|
|
1180
|
+
...options
|
|
1181
|
+
});
|
|
1182
|
+
}
|
|
1183
|
+
/**
|
|
1184
|
+
* Regenerate token + expiry and resend the invitation email
|
|
1185
|
+
*/
|
|
1186
|
+
resend(options) {
|
|
1187
|
+
return (options.client ?? this.client).post({
|
|
1188
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1189
|
+
url: "/organizations/{organization}/invitations/{invitation}/resend",
|
|
1190
|
+
...options
|
|
1191
|
+
});
|
|
1192
|
+
}
|
|
1193
|
+
};
|
|
1194
|
+
var Members = class extends HeyApiClient {
|
|
1195
|
+
/**
|
|
1196
|
+
* List members of an organization
|
|
1197
|
+
*/
|
|
1198
|
+
list(options) {
|
|
1199
|
+
return (options.client ?? this.client).get({
|
|
1200
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1201
|
+
url: "/organizations/{organization}/members",
|
|
1202
|
+
...options
|
|
1203
|
+
});
|
|
1204
|
+
}
|
|
1205
|
+
/**
|
|
1206
|
+
* The authenticated user leaves the organization
|
|
1207
|
+
*/
|
|
1208
|
+
leave(options) {
|
|
1209
|
+
return (options.client ?? this.client).post({
|
|
1210
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1211
|
+
url: "/organizations/{organization}/members/leave",
|
|
1212
|
+
...options
|
|
1213
|
+
});
|
|
1214
|
+
}
|
|
1215
|
+
/**
|
|
1216
|
+
* Remove a member, and with them their access to every space
|
|
1217
|
+
*/
|
|
1218
|
+
delete(options) {
|
|
1219
|
+
return (options.client ?? this.client).delete({
|
|
1220
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1221
|
+
url: "/organizations/{organization}/members/{user}",
|
|
1222
|
+
...options
|
|
1223
|
+
});
|
|
1224
|
+
}
|
|
1225
|
+
/**
|
|
1226
|
+
* Update a member's permissions across the organization
|
|
1227
|
+
*/
|
|
1228
|
+
update(options) {
|
|
1229
|
+
return (options.client ?? this.client).patch({
|
|
1230
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1231
|
+
url: "/organizations/{organization}/members/{user}",
|
|
1232
|
+
...options,
|
|
1233
|
+
headers: {
|
|
1234
|
+
"Content-Type": "application/json",
|
|
1235
|
+
...options.headers
|
|
1236
|
+
}
|
|
1237
|
+
});
|
|
1238
|
+
}
|
|
1239
|
+
};
|
|
1240
|
+
var Organizations = class extends HeyApiClient {
|
|
1241
|
+
_invitations;
|
|
1242
|
+
get invitations() {
|
|
1243
|
+
return this._invitations ??= new Invitations({ client: this.client });
|
|
1244
|
+
}
|
|
1245
|
+
_members;
|
|
1246
|
+
get members() {
|
|
1247
|
+
return this._members ??= new Members({ client: this.client });
|
|
1248
|
+
}
|
|
1249
|
+
};
|
|
1148
1250
|
var Comment = class extends HeyApiClient {
|
|
1149
1251
|
/**
|
|
1150
1252
|
* Attach a follow-up comment to an existing post. If the post has already
|
|
@@ -1399,98 +1501,6 @@ var Spaces = class extends HeyApiClient {
|
|
|
1399
1501
|
});
|
|
1400
1502
|
}
|
|
1401
1503
|
};
|
|
1402
|
-
var Invitations = class extends HeyApiClient {
|
|
1403
|
-
/**
|
|
1404
|
-
* List pending invitations for a space
|
|
1405
|
-
*/
|
|
1406
|
-
list(options) {
|
|
1407
|
-
return (options.client ?? this.client).get({
|
|
1408
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1409
|
-
url: "/spaces/{space}/invitations",
|
|
1410
|
-
...options
|
|
1411
|
-
});
|
|
1412
|
-
}
|
|
1413
|
-
/**
|
|
1414
|
-
* Send an invitation
|
|
1415
|
-
*/
|
|
1416
|
-
create(options) {
|
|
1417
|
-
return (options.client ?? this.client).post({
|
|
1418
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1419
|
-
url: "/spaces/{space}/invitations",
|
|
1420
|
-
...options,
|
|
1421
|
-
headers: {
|
|
1422
|
-
"Content-Type": "application/json",
|
|
1423
|
-
...options.headers
|
|
1424
|
-
}
|
|
1425
|
-
});
|
|
1426
|
-
}
|
|
1427
|
-
/**
|
|
1428
|
-
* Revoke a pending invitation
|
|
1429
|
-
*/
|
|
1430
|
-
delete(options) {
|
|
1431
|
-
return (options.client ?? this.client).delete({
|
|
1432
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1433
|
-
url: "/spaces/{space}/invitations/{invitation}",
|
|
1434
|
-
...options
|
|
1435
|
-
});
|
|
1436
|
-
}
|
|
1437
|
-
/**
|
|
1438
|
-
* Regenerate token + expiry and resend the invitation email
|
|
1439
|
-
*/
|
|
1440
|
-
resend(options) {
|
|
1441
|
-
return (options.client ?? this.client).post({
|
|
1442
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1443
|
-
url: "/spaces/{space}/invitations/{invitation}/resend",
|
|
1444
|
-
...options
|
|
1445
|
-
});
|
|
1446
|
-
}
|
|
1447
|
-
};
|
|
1448
|
-
var Members = class extends HeyApiClient {
|
|
1449
|
-
/**
|
|
1450
|
-
* List members of a space
|
|
1451
|
-
*/
|
|
1452
|
-
list(options) {
|
|
1453
|
-
return (options.client ?? this.client).get({
|
|
1454
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1455
|
-
url: "/spaces/{space}/members",
|
|
1456
|
-
...options
|
|
1457
|
-
});
|
|
1458
|
-
}
|
|
1459
|
-
/**
|
|
1460
|
-
* Remove a member from a space
|
|
1461
|
-
*/
|
|
1462
|
-
delete(options) {
|
|
1463
|
-
return (options.client ?? this.client).delete({
|
|
1464
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1465
|
-
url: "/spaces/{space}/members/{user}",
|
|
1466
|
-
...options
|
|
1467
|
-
});
|
|
1468
|
-
}
|
|
1469
|
-
/**
|
|
1470
|
-
* Update a member's permissions
|
|
1471
|
-
*/
|
|
1472
|
-
update(options) {
|
|
1473
|
-
return (options.client ?? this.client).patch({
|
|
1474
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1475
|
-
url: "/spaces/{space}/members/{user}",
|
|
1476
|
-
...options,
|
|
1477
|
-
headers: {
|
|
1478
|
-
"Content-Type": "application/json",
|
|
1479
|
-
...options.headers
|
|
1480
|
-
}
|
|
1481
|
-
});
|
|
1482
|
-
}
|
|
1483
|
-
/**
|
|
1484
|
-
* The authenticated user leaves the space
|
|
1485
|
-
*/
|
|
1486
|
-
leave(options) {
|
|
1487
|
-
return (options.client ?? this.client).post({
|
|
1488
|
-
security: [{ scheme: "bearer", type: "http" }],
|
|
1489
|
-
url: "/spaces/{space}/members/leave",
|
|
1490
|
-
...options
|
|
1491
|
-
});
|
|
1492
|
-
}
|
|
1493
|
-
};
|
|
1494
1504
|
var Subscription = class extends HeyApiClient {
|
|
1495
1505
|
/**
|
|
1496
1506
|
* Get subscription details
|
|
@@ -1604,6 +1614,10 @@ var ZilfuApi = class _ZilfuApi extends HeyApiClient {
|
|
|
1604
1614
|
get media() {
|
|
1605
1615
|
return this._media ??= new Media({ client: this.client });
|
|
1606
1616
|
}
|
|
1617
|
+
_organizations;
|
|
1618
|
+
get organizations() {
|
|
1619
|
+
return this._organizations ??= new Organizations({ client: this.client });
|
|
1620
|
+
}
|
|
1607
1621
|
_posts;
|
|
1608
1622
|
get posts() {
|
|
1609
1623
|
return this._posts ??= new Posts({ client: this.client });
|
|
@@ -1628,14 +1642,6 @@ var ZilfuApi = class _ZilfuApi extends HeyApiClient {
|
|
|
1628
1642
|
get spaces() {
|
|
1629
1643
|
return this._spaces ??= new Spaces({ client: this.client });
|
|
1630
1644
|
}
|
|
1631
|
-
_invitations;
|
|
1632
|
-
get invitations() {
|
|
1633
|
-
return this._invitations ??= new Invitations({ client: this.client });
|
|
1634
|
-
}
|
|
1635
|
-
_members;
|
|
1636
|
-
get members() {
|
|
1637
|
-
return this._members ??= new Members({ client: this.client });
|
|
1638
|
-
}
|
|
1639
1645
|
_subscription;
|
|
1640
1646
|
get subscription() {
|
|
1641
1647
|
return this._subscription ??= new Subscription({ client: this.client });
|