shred-api-client 2.0.14 → 2.1.0
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.mts +20 -102
- package/dist/index.d.ts +20 -102
- package/dist/index.js +20 -17
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -17
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1369,7 +1369,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1369
1369
|
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
|
1370
1370
|
modified: z.ZodNumber;
|
|
1371
1371
|
captionSuggestion: z.ZodOptional<z.ZodString>;
|
|
1372
|
-
editorId: z.ZodString
|
|
1372
|
+
editorId: z.ZodOptional<z.ZodString>;
|
|
1373
1373
|
userId: z.ZodString;
|
|
1374
1374
|
assets: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1375
1375
|
assetId: z.ZodString;
|
|
@@ -1441,7 +1441,6 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1441
1441
|
title: string;
|
|
1442
1442
|
status: Status$1;
|
|
1443
1443
|
modified: number;
|
|
1444
|
-
editorId: string;
|
|
1445
1444
|
instructions: string;
|
|
1446
1445
|
submitMonth: string;
|
|
1447
1446
|
captionStyle: CaptionStyle;
|
|
@@ -1455,6 +1454,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1455
1454
|
}[];
|
|
1456
1455
|
submitTimestamp: number;
|
|
1457
1456
|
tenantId?: string | undefined;
|
|
1457
|
+
editorId?: string | undefined;
|
|
1458
1458
|
thumbnailUrl?: string | undefined;
|
|
1459
1459
|
finalVideoId?: string | undefined;
|
|
1460
1460
|
captionSuggestion?: string | undefined;
|
|
@@ -1479,7 +1479,6 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1479
1479
|
title: string;
|
|
1480
1480
|
status: Status$1;
|
|
1481
1481
|
modified: number;
|
|
1482
|
-
editorId: string;
|
|
1483
1482
|
instructions: string;
|
|
1484
1483
|
submitMonth: string;
|
|
1485
1484
|
captionStyle: CaptionStyle;
|
|
@@ -1493,6 +1492,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1493
1492
|
}[];
|
|
1494
1493
|
submitTimestamp: number;
|
|
1495
1494
|
tenantId?: string | undefined;
|
|
1495
|
+
editorId?: string | undefined;
|
|
1496
1496
|
thumbnailUrl?: string | undefined;
|
|
1497
1497
|
finalVideoId?: string | undefined;
|
|
1498
1498
|
captionSuggestion?: string | undefined;
|
|
@@ -1532,7 +1532,7 @@ interface IAPI$4 {
|
|
|
1532
1532
|
review: (context: Context, projectId: string, revision: string) => Promise<boolean>;
|
|
1533
1533
|
cancel: (context: Context, projectId: string) => Promise<boolean>;
|
|
1534
1534
|
list: (context: Context, query: QueryOptions<Project>) => Promise<Project[]>;
|
|
1535
|
-
start: (context: Context
|
|
1535
|
+
start: (context: Context) => Promise<boolean>;
|
|
1536
1536
|
sendToApproval: (context: Context, projectId: string, data: SendToApproval) => Promise<boolean>;
|
|
1537
1537
|
approve: (context: Context, projectId: string, data: Approve) => Promise<boolean>;
|
|
1538
1538
|
deny: (context: Context, projectId: string, denyFeedback: string, categories?: string[]) => Promise<boolean>;
|
|
@@ -1540,6 +1540,7 @@ interface IAPI$4 {
|
|
|
1540
1540
|
rollback: (context: Context, projectId: string) => Promise<boolean>;
|
|
1541
1541
|
getNext: (context: Context, userId: string) => Promise<Project | null>;
|
|
1542
1542
|
getUserHistory: (context: Context, userId: string) => Promise<APIResponse<Project>>;
|
|
1543
|
+
getPoolSize(context: Context): Promise<number>;
|
|
1543
1544
|
permissions: {
|
|
1544
1545
|
isEligibleForFreeProject(context: Context): Promise<boolean>;
|
|
1545
1546
|
};
|
|
@@ -1609,6 +1610,10 @@ declare const Endpoints$3: {
|
|
|
1609
1610
|
uri: string;
|
|
1610
1611
|
method: string;
|
|
1611
1612
|
};
|
|
1613
|
+
GetPoolSize: {
|
|
1614
|
+
uri: string;
|
|
1615
|
+
method: string;
|
|
1616
|
+
};
|
|
1612
1617
|
};
|
|
1613
1618
|
|
|
1614
1619
|
type index$5_Approve = Approve;
|
|
@@ -1641,11 +1646,13 @@ declare const DailyMilestoneSchema: z.ZodObject<{
|
|
|
1641
1646
|
progress: number;
|
|
1642
1647
|
target: number;
|
|
1643
1648
|
}>;
|
|
1644
|
-
declare const
|
|
1649
|
+
declare const GoalSchema: z.ZodObject<{
|
|
1645
1650
|
id: z.ZodString;
|
|
1646
|
-
|
|
1651
|
+
editorId: z.ZodString;
|
|
1652
|
+
isoWeek: z.ZodString;
|
|
1647
1653
|
target: z.ZodNumber;
|
|
1648
1654
|
progress: z.ZodNumber;
|
|
1655
|
+
createdAt: z.ZodNumber;
|
|
1649
1656
|
dailyMilestones: z.ZodArray<z.ZodObject<{
|
|
1650
1657
|
id: z.ZodString;
|
|
1651
1658
|
date: z.ZodString;
|
|
@@ -1662,98 +1669,18 @@ declare const WeeklyMilestoneSchema: z.ZodObject<{
|
|
|
1662
1669
|
progress: number;
|
|
1663
1670
|
target: number;
|
|
1664
1671
|
}>, "many">;
|
|
1665
|
-
}, "strip", z.ZodTypeAny, {
|
|
1666
|
-
id: string;
|
|
1667
|
-
progress: number;
|
|
1668
|
-
target: number;
|
|
1669
|
-
week: string;
|
|
1670
|
-
dailyMilestones: {
|
|
1671
|
-
id: string;
|
|
1672
|
-
date: string;
|
|
1673
|
-
progress: number;
|
|
1674
|
-
target: number;
|
|
1675
|
-
}[];
|
|
1676
|
-
}, {
|
|
1677
|
-
id: string;
|
|
1678
|
-
progress: number;
|
|
1679
|
-
target: number;
|
|
1680
|
-
week: string;
|
|
1681
|
-
dailyMilestones: {
|
|
1682
|
-
id: string;
|
|
1683
|
-
date: string;
|
|
1684
|
-
progress: number;
|
|
1685
|
-
target: number;
|
|
1686
|
-
}[];
|
|
1687
|
-
}>;
|
|
1688
|
-
declare const GoalSchema: z.ZodObject<{
|
|
1689
|
-
id: z.ZodString;
|
|
1690
|
-
editorId: z.ZodString;
|
|
1691
|
-
month: z.ZodString;
|
|
1692
|
-
target: z.ZodNumber;
|
|
1693
|
-
progress: z.ZodNumber;
|
|
1694
|
-
createdAt: z.ZodNumber;
|
|
1695
|
-
weeklyMilestones: z.ZodArray<z.ZodObject<{
|
|
1696
|
-
id: z.ZodString;
|
|
1697
|
-
week: z.ZodString;
|
|
1698
|
-
target: z.ZodNumber;
|
|
1699
|
-
progress: z.ZodNumber;
|
|
1700
|
-
dailyMilestones: z.ZodArray<z.ZodObject<{
|
|
1701
|
-
id: z.ZodString;
|
|
1702
|
-
date: z.ZodString;
|
|
1703
|
-
target: z.ZodNumber;
|
|
1704
|
-
progress: z.ZodNumber;
|
|
1705
|
-
}, "strip", z.ZodTypeAny, {
|
|
1706
|
-
id: string;
|
|
1707
|
-
date: string;
|
|
1708
|
-
progress: number;
|
|
1709
|
-
target: number;
|
|
1710
|
-
}, {
|
|
1711
|
-
id: string;
|
|
1712
|
-
date: string;
|
|
1713
|
-
progress: number;
|
|
1714
|
-
target: number;
|
|
1715
|
-
}>, "many">;
|
|
1716
|
-
}, "strip", z.ZodTypeAny, {
|
|
1717
|
-
id: string;
|
|
1718
|
-
progress: number;
|
|
1719
|
-
target: number;
|
|
1720
|
-
week: string;
|
|
1721
|
-
dailyMilestones: {
|
|
1722
|
-
id: string;
|
|
1723
|
-
date: string;
|
|
1724
|
-
progress: number;
|
|
1725
|
-
target: number;
|
|
1726
|
-
}[];
|
|
1727
|
-
}, {
|
|
1728
|
-
id: string;
|
|
1729
|
-
progress: number;
|
|
1730
|
-
target: number;
|
|
1731
|
-
week: string;
|
|
1732
|
-
dailyMilestones: {
|
|
1733
|
-
id: string;
|
|
1734
|
-
date: string;
|
|
1735
|
-
progress: number;
|
|
1736
|
-
target: number;
|
|
1737
|
-
}[];
|
|
1738
|
-
}>, "many">;
|
|
1739
1672
|
}, "strip", z.ZodTypeAny, {
|
|
1740
1673
|
id: string;
|
|
1741
1674
|
createdAt: number;
|
|
1742
1675
|
editorId: string;
|
|
1743
1676
|
progress: number;
|
|
1744
1677
|
target: number;
|
|
1745
|
-
|
|
1746
|
-
|
|
1678
|
+
isoWeek: string;
|
|
1679
|
+
dailyMilestones: {
|
|
1747
1680
|
id: string;
|
|
1681
|
+
date: string;
|
|
1748
1682
|
progress: number;
|
|
1749
1683
|
target: number;
|
|
1750
|
-
week: string;
|
|
1751
|
-
dailyMilestones: {
|
|
1752
|
-
id: string;
|
|
1753
|
-
date: string;
|
|
1754
|
-
progress: number;
|
|
1755
|
-
target: number;
|
|
1756
|
-
}[];
|
|
1757
1684
|
}[];
|
|
1758
1685
|
}, {
|
|
1759
1686
|
id: string;
|
|
@@ -1761,22 +1688,15 @@ declare const GoalSchema: z.ZodObject<{
|
|
|
1761
1688
|
editorId: string;
|
|
1762
1689
|
progress: number;
|
|
1763
1690
|
target: number;
|
|
1764
|
-
|
|
1765
|
-
|
|
1691
|
+
isoWeek: string;
|
|
1692
|
+
dailyMilestones: {
|
|
1766
1693
|
id: string;
|
|
1694
|
+
date: string;
|
|
1767
1695
|
progress: number;
|
|
1768
1696
|
target: number;
|
|
1769
|
-
week: string;
|
|
1770
|
-
dailyMilestones: {
|
|
1771
|
-
id: string;
|
|
1772
|
-
date: string;
|
|
1773
|
-
progress: number;
|
|
1774
|
-
target: number;
|
|
1775
|
-
}[];
|
|
1776
1697
|
}[];
|
|
1777
1698
|
}>;
|
|
1778
1699
|
type DailyMilestone = z.infer<typeof DailyMilestoneSchema>;
|
|
1779
|
-
type WeeklyMilestone = z.infer<typeof WeeklyMilestoneSchema>;
|
|
1780
1700
|
type Goal = z.infer<typeof GoalSchema>;
|
|
1781
1701
|
|
|
1782
1702
|
interface IAPI$3 {
|
|
@@ -1792,10 +1712,8 @@ declare const Endpoints$2: {
|
|
|
1792
1712
|
type index$4_DailyMilestone = DailyMilestone;
|
|
1793
1713
|
declare const index$4_DailyMilestoneSchema: typeof DailyMilestoneSchema;
|
|
1794
1714
|
declare const index$4_GoalSchema: typeof GoalSchema;
|
|
1795
|
-
type index$4_WeeklyMilestone = WeeklyMilestone;
|
|
1796
|
-
declare const index$4_WeeklyMilestoneSchema: typeof WeeklyMilestoneSchema;
|
|
1797
1715
|
declare namespace index$4 {
|
|
1798
|
-
export { type index$4_DailyMilestone as DailyMilestone, index$4_DailyMilestoneSchema as DailyMilestoneSchema, Endpoints$2 as Endpoints, type Goal as Entity, index$4_GoalSchema as GoalSchema, type IAPI$3 as IAPI
|
|
1716
|
+
export { type index$4_DailyMilestone as DailyMilestone, index$4_DailyMilestoneSchema as DailyMilestoneSchema, Endpoints$2 as Endpoints, type Goal as Entity, index$4_GoalSchema as GoalSchema, type IAPI$3 as IAPI };
|
|
1799
1717
|
}
|
|
1800
1718
|
|
|
1801
1719
|
declare enum Frequency {
|
package/dist/index.d.ts
CHANGED
|
@@ -1369,7 +1369,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1369
1369
|
thumbnailUrl: z.ZodOptional<z.ZodString>;
|
|
1370
1370
|
modified: z.ZodNumber;
|
|
1371
1371
|
captionSuggestion: z.ZodOptional<z.ZodString>;
|
|
1372
|
-
editorId: z.ZodString
|
|
1372
|
+
editorId: z.ZodOptional<z.ZodString>;
|
|
1373
1373
|
userId: z.ZodString;
|
|
1374
1374
|
assets: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1375
1375
|
assetId: z.ZodString;
|
|
@@ -1441,7 +1441,6 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1441
1441
|
title: string;
|
|
1442
1442
|
status: Status$1;
|
|
1443
1443
|
modified: number;
|
|
1444
|
-
editorId: string;
|
|
1445
1444
|
instructions: string;
|
|
1446
1445
|
submitMonth: string;
|
|
1447
1446
|
captionStyle: CaptionStyle;
|
|
@@ -1455,6 +1454,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1455
1454
|
}[];
|
|
1456
1455
|
submitTimestamp: number;
|
|
1457
1456
|
tenantId?: string | undefined;
|
|
1457
|
+
editorId?: string | undefined;
|
|
1458
1458
|
thumbnailUrl?: string | undefined;
|
|
1459
1459
|
finalVideoId?: string | undefined;
|
|
1460
1460
|
captionSuggestion?: string | undefined;
|
|
@@ -1479,7 +1479,6 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1479
1479
|
title: string;
|
|
1480
1480
|
status: Status$1;
|
|
1481
1481
|
modified: number;
|
|
1482
|
-
editorId: string;
|
|
1483
1482
|
instructions: string;
|
|
1484
1483
|
submitMonth: string;
|
|
1485
1484
|
captionStyle: CaptionStyle;
|
|
@@ -1493,6 +1492,7 @@ declare const ProjectSchema: z.ZodObject<{
|
|
|
1493
1492
|
}[];
|
|
1494
1493
|
submitTimestamp: number;
|
|
1495
1494
|
tenantId?: string | undefined;
|
|
1495
|
+
editorId?: string | undefined;
|
|
1496
1496
|
thumbnailUrl?: string | undefined;
|
|
1497
1497
|
finalVideoId?: string | undefined;
|
|
1498
1498
|
captionSuggestion?: string | undefined;
|
|
@@ -1532,7 +1532,7 @@ interface IAPI$4 {
|
|
|
1532
1532
|
review: (context: Context, projectId: string, revision: string) => Promise<boolean>;
|
|
1533
1533
|
cancel: (context: Context, projectId: string) => Promise<boolean>;
|
|
1534
1534
|
list: (context: Context, query: QueryOptions<Project>) => Promise<Project[]>;
|
|
1535
|
-
start: (context: Context
|
|
1535
|
+
start: (context: Context) => Promise<boolean>;
|
|
1536
1536
|
sendToApproval: (context: Context, projectId: string, data: SendToApproval) => Promise<boolean>;
|
|
1537
1537
|
approve: (context: Context, projectId: string, data: Approve) => Promise<boolean>;
|
|
1538
1538
|
deny: (context: Context, projectId: string, denyFeedback: string, categories?: string[]) => Promise<boolean>;
|
|
@@ -1540,6 +1540,7 @@ interface IAPI$4 {
|
|
|
1540
1540
|
rollback: (context: Context, projectId: string) => Promise<boolean>;
|
|
1541
1541
|
getNext: (context: Context, userId: string) => Promise<Project | null>;
|
|
1542
1542
|
getUserHistory: (context: Context, userId: string) => Promise<APIResponse<Project>>;
|
|
1543
|
+
getPoolSize(context: Context): Promise<number>;
|
|
1543
1544
|
permissions: {
|
|
1544
1545
|
isEligibleForFreeProject(context: Context): Promise<boolean>;
|
|
1545
1546
|
};
|
|
@@ -1609,6 +1610,10 @@ declare const Endpoints$3: {
|
|
|
1609
1610
|
uri: string;
|
|
1610
1611
|
method: string;
|
|
1611
1612
|
};
|
|
1613
|
+
GetPoolSize: {
|
|
1614
|
+
uri: string;
|
|
1615
|
+
method: string;
|
|
1616
|
+
};
|
|
1612
1617
|
};
|
|
1613
1618
|
|
|
1614
1619
|
type index$5_Approve = Approve;
|
|
@@ -1641,11 +1646,13 @@ declare const DailyMilestoneSchema: z.ZodObject<{
|
|
|
1641
1646
|
progress: number;
|
|
1642
1647
|
target: number;
|
|
1643
1648
|
}>;
|
|
1644
|
-
declare const
|
|
1649
|
+
declare const GoalSchema: z.ZodObject<{
|
|
1645
1650
|
id: z.ZodString;
|
|
1646
|
-
|
|
1651
|
+
editorId: z.ZodString;
|
|
1652
|
+
isoWeek: z.ZodString;
|
|
1647
1653
|
target: z.ZodNumber;
|
|
1648
1654
|
progress: z.ZodNumber;
|
|
1655
|
+
createdAt: z.ZodNumber;
|
|
1649
1656
|
dailyMilestones: z.ZodArray<z.ZodObject<{
|
|
1650
1657
|
id: z.ZodString;
|
|
1651
1658
|
date: z.ZodString;
|
|
@@ -1662,98 +1669,18 @@ declare const WeeklyMilestoneSchema: z.ZodObject<{
|
|
|
1662
1669
|
progress: number;
|
|
1663
1670
|
target: number;
|
|
1664
1671
|
}>, "many">;
|
|
1665
|
-
}, "strip", z.ZodTypeAny, {
|
|
1666
|
-
id: string;
|
|
1667
|
-
progress: number;
|
|
1668
|
-
target: number;
|
|
1669
|
-
week: string;
|
|
1670
|
-
dailyMilestones: {
|
|
1671
|
-
id: string;
|
|
1672
|
-
date: string;
|
|
1673
|
-
progress: number;
|
|
1674
|
-
target: number;
|
|
1675
|
-
}[];
|
|
1676
|
-
}, {
|
|
1677
|
-
id: string;
|
|
1678
|
-
progress: number;
|
|
1679
|
-
target: number;
|
|
1680
|
-
week: string;
|
|
1681
|
-
dailyMilestones: {
|
|
1682
|
-
id: string;
|
|
1683
|
-
date: string;
|
|
1684
|
-
progress: number;
|
|
1685
|
-
target: number;
|
|
1686
|
-
}[];
|
|
1687
|
-
}>;
|
|
1688
|
-
declare const GoalSchema: z.ZodObject<{
|
|
1689
|
-
id: z.ZodString;
|
|
1690
|
-
editorId: z.ZodString;
|
|
1691
|
-
month: z.ZodString;
|
|
1692
|
-
target: z.ZodNumber;
|
|
1693
|
-
progress: z.ZodNumber;
|
|
1694
|
-
createdAt: z.ZodNumber;
|
|
1695
|
-
weeklyMilestones: z.ZodArray<z.ZodObject<{
|
|
1696
|
-
id: z.ZodString;
|
|
1697
|
-
week: z.ZodString;
|
|
1698
|
-
target: z.ZodNumber;
|
|
1699
|
-
progress: z.ZodNumber;
|
|
1700
|
-
dailyMilestones: z.ZodArray<z.ZodObject<{
|
|
1701
|
-
id: z.ZodString;
|
|
1702
|
-
date: z.ZodString;
|
|
1703
|
-
target: z.ZodNumber;
|
|
1704
|
-
progress: z.ZodNumber;
|
|
1705
|
-
}, "strip", z.ZodTypeAny, {
|
|
1706
|
-
id: string;
|
|
1707
|
-
date: string;
|
|
1708
|
-
progress: number;
|
|
1709
|
-
target: number;
|
|
1710
|
-
}, {
|
|
1711
|
-
id: string;
|
|
1712
|
-
date: string;
|
|
1713
|
-
progress: number;
|
|
1714
|
-
target: number;
|
|
1715
|
-
}>, "many">;
|
|
1716
|
-
}, "strip", z.ZodTypeAny, {
|
|
1717
|
-
id: string;
|
|
1718
|
-
progress: number;
|
|
1719
|
-
target: number;
|
|
1720
|
-
week: string;
|
|
1721
|
-
dailyMilestones: {
|
|
1722
|
-
id: string;
|
|
1723
|
-
date: string;
|
|
1724
|
-
progress: number;
|
|
1725
|
-
target: number;
|
|
1726
|
-
}[];
|
|
1727
|
-
}, {
|
|
1728
|
-
id: string;
|
|
1729
|
-
progress: number;
|
|
1730
|
-
target: number;
|
|
1731
|
-
week: string;
|
|
1732
|
-
dailyMilestones: {
|
|
1733
|
-
id: string;
|
|
1734
|
-
date: string;
|
|
1735
|
-
progress: number;
|
|
1736
|
-
target: number;
|
|
1737
|
-
}[];
|
|
1738
|
-
}>, "many">;
|
|
1739
1672
|
}, "strip", z.ZodTypeAny, {
|
|
1740
1673
|
id: string;
|
|
1741
1674
|
createdAt: number;
|
|
1742
1675
|
editorId: string;
|
|
1743
1676
|
progress: number;
|
|
1744
1677
|
target: number;
|
|
1745
|
-
|
|
1746
|
-
|
|
1678
|
+
isoWeek: string;
|
|
1679
|
+
dailyMilestones: {
|
|
1747
1680
|
id: string;
|
|
1681
|
+
date: string;
|
|
1748
1682
|
progress: number;
|
|
1749
1683
|
target: number;
|
|
1750
|
-
week: string;
|
|
1751
|
-
dailyMilestones: {
|
|
1752
|
-
id: string;
|
|
1753
|
-
date: string;
|
|
1754
|
-
progress: number;
|
|
1755
|
-
target: number;
|
|
1756
|
-
}[];
|
|
1757
1684
|
}[];
|
|
1758
1685
|
}, {
|
|
1759
1686
|
id: string;
|
|
@@ -1761,22 +1688,15 @@ declare const GoalSchema: z.ZodObject<{
|
|
|
1761
1688
|
editorId: string;
|
|
1762
1689
|
progress: number;
|
|
1763
1690
|
target: number;
|
|
1764
|
-
|
|
1765
|
-
|
|
1691
|
+
isoWeek: string;
|
|
1692
|
+
dailyMilestones: {
|
|
1766
1693
|
id: string;
|
|
1694
|
+
date: string;
|
|
1767
1695
|
progress: number;
|
|
1768
1696
|
target: number;
|
|
1769
|
-
week: string;
|
|
1770
|
-
dailyMilestones: {
|
|
1771
|
-
id: string;
|
|
1772
|
-
date: string;
|
|
1773
|
-
progress: number;
|
|
1774
|
-
target: number;
|
|
1775
|
-
}[];
|
|
1776
1697
|
}[];
|
|
1777
1698
|
}>;
|
|
1778
1699
|
type DailyMilestone = z.infer<typeof DailyMilestoneSchema>;
|
|
1779
|
-
type WeeklyMilestone = z.infer<typeof WeeklyMilestoneSchema>;
|
|
1780
1700
|
type Goal = z.infer<typeof GoalSchema>;
|
|
1781
1701
|
|
|
1782
1702
|
interface IAPI$3 {
|
|
@@ -1792,10 +1712,8 @@ declare const Endpoints$2: {
|
|
|
1792
1712
|
type index$4_DailyMilestone = DailyMilestone;
|
|
1793
1713
|
declare const index$4_DailyMilestoneSchema: typeof DailyMilestoneSchema;
|
|
1794
1714
|
declare const index$4_GoalSchema: typeof GoalSchema;
|
|
1795
|
-
type index$4_WeeklyMilestone = WeeklyMilestone;
|
|
1796
|
-
declare const index$4_WeeklyMilestoneSchema: typeof WeeklyMilestoneSchema;
|
|
1797
1715
|
declare namespace index$4 {
|
|
1798
|
-
export { type index$4_DailyMilestone as DailyMilestone, index$4_DailyMilestoneSchema as DailyMilestoneSchema, Endpoints$2 as Endpoints, type Goal as Entity, index$4_GoalSchema as GoalSchema, type IAPI$3 as IAPI
|
|
1716
|
+
export { type index$4_DailyMilestone as DailyMilestone, index$4_DailyMilestoneSchema as DailyMilestoneSchema, Endpoints$2 as Endpoints, type Goal as Entity, index$4_GoalSchema as GoalSchema, type IAPI$3 as IAPI };
|
|
1799
1717
|
}
|
|
1800
1718
|
|
|
1801
1719
|
declare enum Frequency {
|
package/dist/index.js
CHANGED
|
@@ -947,7 +947,7 @@ var ProjectSchema = import_zod4.z.object({
|
|
|
947
947
|
thumbnailUrl: import_zod4.z.string().optional(),
|
|
948
948
|
modified: import_zod4.z.number(),
|
|
949
949
|
captionSuggestion: import_zod4.z.string().optional(),
|
|
950
|
-
editorId: import_zod4.z.string(),
|
|
950
|
+
editorId: import_zod4.z.string().optional(),
|
|
951
951
|
userId: import_zod4.z.string(),
|
|
952
952
|
assets: import_zod4.z.array(AssetSchema).optional(),
|
|
953
953
|
expirationTimestamp: import_zod4.z.number(),
|
|
@@ -981,7 +981,8 @@ var Endpoints3 = {
|
|
|
981
981
|
Unschedule: { uri: "/projects/:projectId/unschedule/", method: "POST" },
|
|
982
982
|
Rollback: { uri: "/projects/:projectId/rollback/", method: "POST" },
|
|
983
983
|
Deny: { uri: "/projects/:projectId/deny/", method: "POST" },
|
|
984
|
-
GetUserHistory: { uri: "/projects/user/:userId/history/", method: "GET" }
|
|
984
|
+
GetUserHistory: { uri: "/projects/user/:userId/history/", method: "GET" },
|
|
985
|
+
GetPoolSize: { uri: "/projects/pool/size/", method: "GET" }
|
|
985
986
|
};
|
|
986
987
|
|
|
987
988
|
// src/api/Project.api.ts
|
|
@@ -1003,6 +1004,17 @@ var ProjectAPI = class {
|
|
|
1003
1004
|
this.env = env;
|
|
1004
1005
|
this.clientHTTP = new HTTPClient();
|
|
1005
1006
|
}
|
|
1007
|
+
async getPoolSize(context) {
|
|
1008
|
+
const endpointData = Endpoints3.GetPoolSize;
|
|
1009
|
+
const data = await this.clientHTTP.makeRequest(
|
|
1010
|
+
this.env,
|
|
1011
|
+
endpointData.uri,
|
|
1012
|
+
endpointData.method,
|
|
1013
|
+
null,
|
|
1014
|
+
context
|
|
1015
|
+
);
|
|
1016
|
+
return data.size;
|
|
1017
|
+
}
|
|
1006
1018
|
async reorder(ctx, projectId, position) {
|
|
1007
1019
|
const endpointData = Endpoints3.Reorder;
|
|
1008
1020
|
const data = await this.clientHTTP.makeRequest(
|
|
@@ -1133,12 +1145,11 @@ var ProjectAPI = class {
|
|
|
1133
1145
|
);
|
|
1134
1146
|
return data.success;
|
|
1135
1147
|
}
|
|
1136
|
-
async start(context
|
|
1148
|
+
async start(context) {
|
|
1137
1149
|
const endpointData = Endpoints3.StartEdition;
|
|
1138
|
-
const endpoint = endpointData.uri.replace(":projectId", projectId);
|
|
1139
1150
|
const data = await this.clientHTTP.makeRequest(
|
|
1140
1151
|
this.env,
|
|
1141
|
-
|
|
1152
|
+
endpointData.uri,
|
|
1142
1153
|
endpointData.method,
|
|
1143
1154
|
null,
|
|
1144
1155
|
context
|
|
@@ -1177,8 +1188,7 @@ var goal_exports = {};
|
|
|
1177
1188
|
__export(goal_exports, {
|
|
1178
1189
|
DailyMilestoneSchema: () => DailyMilestoneSchema,
|
|
1179
1190
|
Endpoints: () => Endpoints4,
|
|
1180
|
-
GoalSchema: () => GoalSchema
|
|
1181
|
-
WeeklyMilestoneSchema: () => WeeklyMilestoneSchema
|
|
1191
|
+
GoalSchema: () => GoalSchema
|
|
1182
1192
|
});
|
|
1183
1193
|
|
|
1184
1194
|
// src/model/goal/Goal.schema.ts
|
|
@@ -1189,22 +1199,15 @@ var DailyMilestoneSchema = import_zod5.z.object({
|
|
|
1189
1199
|
target: import_zod5.z.number(),
|
|
1190
1200
|
progress: import_zod5.z.number()
|
|
1191
1201
|
});
|
|
1192
|
-
var WeeklyMilestoneSchema = import_zod5.z.object({
|
|
1193
|
-
id: import_zod5.z.string(),
|
|
1194
|
-
week: import_zod5.z.string(),
|
|
1195
|
-
target: import_zod5.z.number(),
|
|
1196
|
-
progress: import_zod5.z.number(),
|
|
1197
|
-
dailyMilestones: import_zod5.z.array(DailyMilestoneSchema)
|
|
1198
|
-
});
|
|
1199
1202
|
var GoalSchema = import_zod5.z.object({
|
|
1200
1203
|
id: import_zod5.z.string(),
|
|
1201
1204
|
editorId: import_zod5.z.string(),
|
|
1202
|
-
|
|
1203
|
-
// ex: "
|
|
1205
|
+
isoWeek: import_zod5.z.string(),
|
|
1206
|
+
// ex: "2026-W27"
|
|
1204
1207
|
target: import_zod5.z.number(),
|
|
1205
1208
|
progress: import_zod5.z.number(),
|
|
1206
1209
|
createdAt: import_zod5.z.number(),
|
|
1207
|
-
|
|
1210
|
+
dailyMilestones: import_zod5.z.array(DailyMilestoneSchema)
|
|
1208
1211
|
});
|
|
1209
1212
|
|
|
1210
1213
|
// src/model/goal/Goal.api.ts
|