shred-api-client 2.6.3 → 2.6.5
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.d.ts +158 -5
- package/dist/index.js +13 -7
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1511,24 +1511,27 @@ declare const TenantSchema: z.ZodObject<{
|
|
|
1511
1511
|
reportViewers?: string[] | undefined;
|
|
1512
1512
|
}>;
|
|
1513
1513
|
declare const MemberSchema: z.ZodObject<{
|
|
1514
|
+
id: z.ZodString;
|
|
1514
1515
|
name: z.ZodString;
|
|
1515
1516
|
email: z.ZodString;
|
|
1516
1517
|
pictureUrl: z.ZodString;
|
|
1517
1518
|
isActive: z.ZodBoolean;
|
|
1518
1519
|
}, "strip", z.ZodTypeAny, {
|
|
1519
1520
|
email: string;
|
|
1521
|
+
id: string;
|
|
1520
1522
|
pictureUrl: string;
|
|
1521
1523
|
name: string;
|
|
1522
1524
|
isActive: boolean;
|
|
1523
1525
|
}, {
|
|
1524
1526
|
email: string;
|
|
1527
|
+
id: string;
|
|
1525
1528
|
pictureUrl: string;
|
|
1526
1529
|
name: string;
|
|
1527
1530
|
isActive: boolean;
|
|
1528
1531
|
}>;
|
|
1529
1532
|
declare enum Action {
|
|
1530
|
-
ADD = "
|
|
1531
|
-
REMOVE = "
|
|
1533
|
+
ADD = "ADD",
|
|
1534
|
+
REMOVE = "REMOVE"
|
|
1532
1535
|
}
|
|
1533
1536
|
declare const ReportViewerUpdateSchema: z.ZodObject<{
|
|
1534
1537
|
userId: z.ZodString;
|
|
@@ -1540,7 +1543,154 @@ declare const ReportViewerUpdateSchema: z.ZodObject<{
|
|
|
1540
1543
|
userId: string;
|
|
1541
1544
|
action: Action;
|
|
1542
1545
|
}>;
|
|
1546
|
+
declare const TenantUpdateSchema: z.ZodObject<{
|
|
1547
|
+
preferences: z.ZodOptional<z.ZodObject<{
|
|
1548
|
+
iconUrl: z.ZodString;
|
|
1549
|
+
logoUrl: z.ZodString;
|
|
1550
|
+
primaryColor: z.ZodString;
|
|
1551
|
+
secondaryColor: z.ZodString;
|
|
1552
|
+
guidelinesUrl: z.ZodOptional<z.ZodString>;
|
|
1553
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1554
|
+
industry: z.ZodOptional<z.ZodString>;
|
|
1555
|
+
assets: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1556
|
+
assetId: z.ZodString;
|
|
1557
|
+
fileName: z.ZodString;
|
|
1558
|
+
extension: z.ZodString;
|
|
1559
|
+
fileSize: z.ZodNumber;
|
|
1560
|
+
assetUrl: z.ZodString;
|
|
1561
|
+
thumbnailUrl: z.ZodString;
|
|
1562
|
+
type: z.ZodString;
|
|
1563
|
+
duration: z.ZodOptional<z.ZodNumber>;
|
|
1564
|
+
progress: z.ZodOptional<z.ZodNumber>;
|
|
1565
|
+
error: z.ZodOptional<z.ZodString>;
|
|
1566
|
+
authorId: z.ZodString;
|
|
1567
|
+
uploadedAt: z.ZodNumber;
|
|
1568
|
+
}, "strip", z.ZodTypeAny, {
|
|
1569
|
+
type: string;
|
|
1570
|
+
assetId: string;
|
|
1571
|
+
fileName: string;
|
|
1572
|
+
extension: string;
|
|
1573
|
+
fileSize: number;
|
|
1574
|
+
assetUrl: string;
|
|
1575
|
+
thumbnailUrl: string;
|
|
1576
|
+
authorId: string;
|
|
1577
|
+
uploadedAt: number;
|
|
1578
|
+
error?: string | undefined;
|
|
1579
|
+
duration?: number | undefined;
|
|
1580
|
+
progress?: number | undefined;
|
|
1581
|
+
}, {
|
|
1582
|
+
type: string;
|
|
1583
|
+
assetId: string;
|
|
1584
|
+
fileName: string;
|
|
1585
|
+
extension: string;
|
|
1586
|
+
fileSize: number;
|
|
1587
|
+
assetUrl: string;
|
|
1588
|
+
thumbnailUrl: string;
|
|
1589
|
+
authorId: string;
|
|
1590
|
+
uploadedAt: number;
|
|
1591
|
+
error?: string | undefined;
|
|
1592
|
+
duration?: number | undefined;
|
|
1593
|
+
progress?: number | undefined;
|
|
1594
|
+
}>, "many">>;
|
|
1595
|
+
}, "strip", z.ZodTypeAny, {
|
|
1596
|
+
iconUrl: string;
|
|
1597
|
+
logoUrl: string;
|
|
1598
|
+
primaryColor: string;
|
|
1599
|
+
secondaryColor: string;
|
|
1600
|
+
description?: string | undefined;
|
|
1601
|
+
guidelinesUrl?: string | undefined;
|
|
1602
|
+
industry?: string | undefined;
|
|
1603
|
+
assets?: {
|
|
1604
|
+
type: string;
|
|
1605
|
+
assetId: string;
|
|
1606
|
+
fileName: string;
|
|
1607
|
+
extension: string;
|
|
1608
|
+
fileSize: number;
|
|
1609
|
+
assetUrl: string;
|
|
1610
|
+
thumbnailUrl: string;
|
|
1611
|
+
authorId: string;
|
|
1612
|
+
uploadedAt: number;
|
|
1613
|
+
error?: string | undefined;
|
|
1614
|
+
duration?: number | undefined;
|
|
1615
|
+
progress?: number | undefined;
|
|
1616
|
+
}[] | undefined;
|
|
1617
|
+
}, {
|
|
1618
|
+
iconUrl: string;
|
|
1619
|
+
logoUrl: string;
|
|
1620
|
+
primaryColor: string;
|
|
1621
|
+
secondaryColor: string;
|
|
1622
|
+
description?: string | undefined;
|
|
1623
|
+
guidelinesUrl?: string | undefined;
|
|
1624
|
+
industry?: string | undefined;
|
|
1625
|
+
assets?: {
|
|
1626
|
+
type: string;
|
|
1627
|
+
assetId: string;
|
|
1628
|
+
fileName: string;
|
|
1629
|
+
extension: string;
|
|
1630
|
+
fileSize: number;
|
|
1631
|
+
assetUrl: string;
|
|
1632
|
+
thumbnailUrl: string;
|
|
1633
|
+
authorId: string;
|
|
1634
|
+
uploadedAt: number;
|
|
1635
|
+
error?: string | undefined;
|
|
1636
|
+
duration?: number | undefined;
|
|
1637
|
+
progress?: number | undefined;
|
|
1638
|
+
}[] | undefined;
|
|
1639
|
+
}>>;
|
|
1640
|
+
reportUrl: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
1641
|
+
}, "strip", z.ZodTypeAny, {
|
|
1642
|
+
preferences?: {
|
|
1643
|
+
iconUrl: string;
|
|
1644
|
+
logoUrl: string;
|
|
1645
|
+
primaryColor: string;
|
|
1646
|
+
secondaryColor: string;
|
|
1647
|
+
description?: string | undefined;
|
|
1648
|
+
guidelinesUrl?: string | undefined;
|
|
1649
|
+
industry?: string | undefined;
|
|
1650
|
+
assets?: {
|
|
1651
|
+
type: string;
|
|
1652
|
+
assetId: string;
|
|
1653
|
+
fileName: string;
|
|
1654
|
+
extension: string;
|
|
1655
|
+
fileSize: number;
|
|
1656
|
+
assetUrl: string;
|
|
1657
|
+
thumbnailUrl: string;
|
|
1658
|
+
authorId: string;
|
|
1659
|
+
uploadedAt: number;
|
|
1660
|
+
error?: string | undefined;
|
|
1661
|
+
duration?: number | undefined;
|
|
1662
|
+
progress?: number | undefined;
|
|
1663
|
+
}[] | undefined;
|
|
1664
|
+
} | undefined;
|
|
1665
|
+
reportUrl?: string | undefined;
|
|
1666
|
+
}, {
|
|
1667
|
+
preferences?: {
|
|
1668
|
+
iconUrl: string;
|
|
1669
|
+
logoUrl: string;
|
|
1670
|
+
primaryColor: string;
|
|
1671
|
+
secondaryColor: string;
|
|
1672
|
+
description?: string | undefined;
|
|
1673
|
+
guidelinesUrl?: string | undefined;
|
|
1674
|
+
industry?: string | undefined;
|
|
1675
|
+
assets?: {
|
|
1676
|
+
type: string;
|
|
1677
|
+
assetId: string;
|
|
1678
|
+
fileName: string;
|
|
1679
|
+
extension: string;
|
|
1680
|
+
fileSize: number;
|
|
1681
|
+
assetUrl: string;
|
|
1682
|
+
thumbnailUrl: string;
|
|
1683
|
+
authorId: string;
|
|
1684
|
+
uploadedAt: number;
|
|
1685
|
+
error?: string | undefined;
|
|
1686
|
+
duration?: number | undefined;
|
|
1687
|
+
progress?: number | undefined;
|
|
1688
|
+
}[] | undefined;
|
|
1689
|
+
} | undefined;
|
|
1690
|
+
reportUrl?: string | undefined;
|
|
1691
|
+
}>;
|
|
1543
1692
|
type ReportViewerUpdate = z.infer<typeof ReportViewerUpdateSchema>;
|
|
1693
|
+
type TenantUpdate = z.infer<typeof TenantUpdateSchema>;
|
|
1544
1694
|
type Tenant = z.infer<typeof TenantSchema>;
|
|
1545
1695
|
type Member = z.infer<typeof MemberSchema>;
|
|
1546
1696
|
type Preferences = z.infer<typeof PreferencesSchema>;
|
|
@@ -1551,7 +1701,7 @@ interface IAPI$9 {
|
|
|
1551
1701
|
list: (context: Context) => Promise<Tenant[]>;
|
|
1552
1702
|
getTenant: (context: Context, tenantId?: string) => Promise<Tenant | null>;
|
|
1553
1703
|
getMembers: (context: Context, tenantId: string) => Promise<Member[]>;
|
|
1554
|
-
update: (tenantId: string, data:
|
|
1704
|
+
update: (tenantId: string, data: TenantUpdate, context: Context) => Promise<boolean>;
|
|
1555
1705
|
updateReportViewers: (tenantId: string, reportViewerUpdate: ReportViewerUpdate, context: Context) => Promise<boolean>;
|
|
1556
1706
|
}
|
|
1557
1707
|
declare const Endpoints$8: {
|
|
@@ -1598,8 +1748,10 @@ declare const index$a_PreferencesSchema: typeof PreferencesSchema;
|
|
|
1598
1748
|
type index$a_ReportViewerUpdate = ReportViewerUpdate;
|
|
1599
1749
|
declare const index$a_ReportViewerUpdateSchema: typeof ReportViewerUpdateSchema;
|
|
1600
1750
|
declare const index$a_TenantSchema: typeof TenantSchema;
|
|
1751
|
+
type index$a_TenantUpdate = TenantUpdate;
|
|
1752
|
+
declare const index$a_TenantUpdateSchema: typeof TenantUpdateSchema;
|
|
1601
1753
|
declare namespace index$a {
|
|
1602
|
-
export { index$a_Action as Action, Endpoints$8 as Endpoints, type Tenant as Entity, type IAPI$9 as IAPI, type index$a_Member as Member, index$a_MemberSchema as MemberSchema, type index$a_Preferences as Preferences, index$a_PreferencesSchema as PreferencesSchema, type index$a_ReportViewerUpdate as ReportViewerUpdate, index$a_ReportViewerUpdateSchema as ReportViewerUpdateSchema, index$a_TenantSchema as TenantSchema };
|
|
1754
|
+
export { index$a_Action as Action, Endpoints$8 as Endpoints, type Tenant as Entity, type IAPI$9 as IAPI, type index$a_Member as Member, index$a_MemberSchema as MemberSchema, type index$a_Preferences as Preferences, index$a_PreferencesSchema as PreferencesSchema, type index$a_ReportViewerUpdate as ReportViewerUpdate, index$a_ReportViewerUpdateSchema as ReportViewerUpdateSchema, index$a_TenantSchema as TenantSchema, type index$a_TenantUpdate as TenantUpdate, index$a_TenantUpdateSchema as TenantUpdateSchema };
|
|
1603
1755
|
}
|
|
1604
1756
|
|
|
1605
1757
|
declare const TrackParamSchema: z.ZodObject<{
|
|
@@ -1717,7 +1869,8 @@ type Style = {
|
|
|
1717
1869
|
};
|
|
1718
1870
|
declare enum InteractionType {
|
|
1719
1871
|
VIDEO_PLAYED = "video_played",
|
|
1720
|
-
DOWNLOADED = "downloaded"
|
|
1872
|
+
DOWNLOADED = "downloaded",
|
|
1873
|
+
SHARED = "shared"
|
|
1721
1874
|
}
|
|
1722
1875
|
declare const InteractionSchema: z.ZodObject<{
|
|
1723
1876
|
type: z.ZodNativeEnum<typeof InteractionType>;
|
package/dist/index.js
CHANGED
|
@@ -4775,13 +4775,12 @@ var TenantAPI = class {
|
|
|
4775
4775
|
}
|
|
4776
4776
|
async updateReportViewers(tenantId, reportViewerUpdate, context) {
|
|
4777
4777
|
const endpointInfo = tenant_exports.Endpoints.UpdateReportViewers;
|
|
4778
|
-
const
|
|
4779
|
-
const endpoint = endpointData.uri.replace(":tenantId", tenantId);
|
|
4778
|
+
const endpoint = endpointInfo.uri.replace(":tenantId", tenantId);
|
|
4780
4779
|
const data = await this.clientHTTP.makeRequest(
|
|
4781
4780
|
this.env,
|
|
4782
4781
|
`${endpoint}`,
|
|
4783
4782
|
endpointInfo.method,
|
|
4784
|
-
|
|
4783
|
+
reportViewerUpdate,
|
|
4785
4784
|
context
|
|
4786
4785
|
);
|
|
4787
4786
|
return data;
|
|
@@ -5115,6 +5114,7 @@ var Styles = [
|
|
|
5115
5114
|
var InteractionType = /* @__PURE__ */ ((InteractionType2) => {
|
|
5116
5115
|
InteractionType2["VIDEO_PLAYED"] = "video_played";
|
|
5117
5116
|
InteractionType2["DOWNLOADED"] = "downloaded";
|
|
5117
|
+
InteractionType2["SHARED"] = "shared";
|
|
5118
5118
|
return InteractionType2;
|
|
5119
5119
|
})(InteractionType || {});
|
|
5120
5120
|
var InteractionSchema = external_exports.object({
|
|
@@ -6101,7 +6101,8 @@ __export(tenant_exports, {
|
|
|
6101
6101
|
MemberSchema: () => MemberSchema,
|
|
6102
6102
|
PreferencesSchema: () => PreferencesSchema,
|
|
6103
6103
|
ReportViewerUpdateSchema: () => ReportViewerUpdateSchema,
|
|
6104
|
-
TenantSchema: () => TenantSchema
|
|
6104
|
+
TenantSchema: () => TenantSchema,
|
|
6105
|
+
TenantUpdateSchema: () => TenantUpdateSchema
|
|
6105
6106
|
});
|
|
6106
6107
|
|
|
6107
6108
|
// src/model/subscription/Subscription.schema.ts
|
|
@@ -6198,24 +6199,29 @@ var TenantSchema = external_exports.object({
|
|
|
6198
6199
|
subscription: external_exports.optional(external_exports.lazy(() => SubscriptionSchema)),
|
|
6199
6200
|
totalSubscriptions: external_exports.number().optional(),
|
|
6200
6201
|
totalUsers: external_exports.number().optional(),
|
|
6201
|
-
reportUrl: external_exports.string().optional(),
|
|
6202
|
+
reportUrl: external_exports.string().url().optional(),
|
|
6202
6203
|
reportViewers: external_exports.array(external_exports.string()).optional()
|
|
6203
6204
|
});
|
|
6204
6205
|
var MemberSchema = external_exports.object({
|
|
6206
|
+
id: external_exports.string(),
|
|
6205
6207
|
name: external_exports.string(),
|
|
6206
6208
|
email: external_exports.string(),
|
|
6207
6209
|
pictureUrl: external_exports.string(),
|
|
6208
6210
|
isActive: external_exports.boolean()
|
|
6209
6211
|
});
|
|
6210
6212
|
var Action = /* @__PURE__ */ ((Action2) => {
|
|
6211
|
-
Action2["ADD"] = "
|
|
6212
|
-
Action2["REMOVE"] = "
|
|
6213
|
+
Action2["ADD"] = "ADD";
|
|
6214
|
+
Action2["REMOVE"] = "REMOVE";
|
|
6213
6215
|
return Action2;
|
|
6214
6216
|
})(Action || {});
|
|
6215
6217
|
var ReportViewerUpdateSchema = external_exports.object({
|
|
6216
6218
|
userId: external_exports.string(),
|
|
6217
6219
|
action: external_exports.nativeEnum(Action)
|
|
6218
6220
|
});
|
|
6221
|
+
var TenantUpdateSchema = TenantSchema.pick({
|
|
6222
|
+
reportUrl: true,
|
|
6223
|
+
preferences: true
|
|
6224
|
+
}).partial();
|
|
6219
6225
|
|
|
6220
6226
|
// src/model/tenant/Tenant.api.ts
|
|
6221
6227
|
var Endpoints10 = {
|