@elevasis/sdk 1.15.0 → 1.15.1
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/cli.cjs +1 -1
- package/dist/index.d.ts +510 -359
- package/dist/index.js +74 -2
- package/dist/test-utils/index.d.ts +497 -358
- package/dist/test-utils/index.js +2 -0
- package/dist/types/worker/adapters/lead.d.ts +1 -1
- package/dist/worker/index.js +1 -0
- package/package.json +2 -2
- package/reference/claude-config/rules/ui.md +2 -6
- package/reference/claude-config/sync-notes/2026-05-02-crm-ownership-next-action.md +58 -0
- package/reference/claude-config/sync-notes/2026-05-02-template-hardcode-workos-config.md +56 -0
- package/reference/scaffold/recipes/customize-crm-actions.md +433 -433
- package/reference/scaffold/recipes/extend-crm.md +12 -8
- package/reference/scaffold/recipes/extend-lead-gen.md +78 -4
- package/reference/scaffold/reference/contracts.md +826 -703
package/dist/index.d.ts
CHANGED
|
@@ -1114,7 +1114,7 @@ type Json = string | number | boolean | null | {
|
|
|
1114
1114
|
} | Json[];
|
|
1115
1115
|
type Database = {
|
|
1116
1116
|
__InternalSupabase: {
|
|
1117
|
-
PostgrestVersion:
|
|
1117
|
+
PostgrestVersion: "12.2.3 (519615d)";
|
|
1118
1118
|
};
|
|
1119
1119
|
public: {
|
|
1120
1120
|
Tables: {
|
|
@@ -1157,11 +1157,11 @@ type Database = {
|
|
|
1157
1157
|
};
|
|
1158
1158
|
Relationships: [
|
|
1159
1159
|
{
|
|
1160
|
-
foreignKeyName:
|
|
1161
|
-
columns: [
|
|
1160
|
+
foreignKeyName: "acq_artifacts_organization_id_fkey";
|
|
1161
|
+
columns: ["organization_id"];
|
|
1162
1162
|
isOneToOne: false;
|
|
1163
|
-
referencedRelation:
|
|
1164
|
-
referencedColumns: [
|
|
1163
|
+
referencedRelation: "organizations";
|
|
1164
|
+
referencedColumns: ["id"];
|
|
1165
1165
|
}
|
|
1166
1166
|
];
|
|
1167
1167
|
};
|
|
@@ -1246,11 +1246,11 @@ type Database = {
|
|
|
1246
1246
|
};
|
|
1247
1247
|
Relationships: [
|
|
1248
1248
|
{
|
|
1249
|
-
foreignKeyName:
|
|
1250
|
-
columns: [
|
|
1249
|
+
foreignKeyName: "acq_companies_organization_id_fkey";
|
|
1250
|
+
columns: ["organization_id"];
|
|
1251
1251
|
isOneToOne: false;
|
|
1252
|
-
referencedRelation:
|
|
1253
|
-
referencedColumns: [
|
|
1252
|
+
referencedRelation: "organizations";
|
|
1253
|
+
referencedColumns: ["id"];
|
|
1254
1254
|
}
|
|
1255
1255
|
];
|
|
1256
1256
|
};
|
|
@@ -1341,18 +1341,18 @@ type Database = {
|
|
|
1341
1341
|
};
|
|
1342
1342
|
Relationships: [
|
|
1343
1343
|
{
|
|
1344
|
-
foreignKeyName:
|
|
1345
|
-
columns: [
|
|
1344
|
+
foreignKeyName: "acq_contacts_company_id_fkey";
|
|
1345
|
+
columns: ["company_id"];
|
|
1346
1346
|
isOneToOne: false;
|
|
1347
|
-
referencedRelation:
|
|
1348
|
-
referencedColumns: [
|
|
1347
|
+
referencedRelation: "acq_companies";
|
|
1348
|
+
referencedColumns: ["id"];
|
|
1349
1349
|
},
|
|
1350
1350
|
{
|
|
1351
|
-
foreignKeyName:
|
|
1352
|
-
columns: [
|
|
1351
|
+
foreignKeyName: "acq_contacts_organization_id_fkey";
|
|
1352
|
+
columns: ["organization_id"];
|
|
1353
1353
|
isOneToOne: false;
|
|
1354
|
-
referencedRelation:
|
|
1355
|
-
referencedColumns: [
|
|
1354
|
+
referencedRelation: "organizations";
|
|
1355
|
+
referencedColumns: ["id"];
|
|
1356
1356
|
}
|
|
1357
1357
|
];
|
|
1358
1358
|
};
|
|
@@ -1389,11 +1389,11 @@ type Database = {
|
|
|
1389
1389
|
};
|
|
1390
1390
|
Relationships: [
|
|
1391
1391
|
{
|
|
1392
|
-
foreignKeyName:
|
|
1393
|
-
columns: [
|
|
1392
|
+
foreignKeyName: "acq_content_organization_id_fkey";
|
|
1393
|
+
columns: ["organization_id"];
|
|
1394
1394
|
isOneToOne: false;
|
|
1395
|
-
referencedRelation:
|
|
1396
|
-
referencedColumns: [
|
|
1395
|
+
referencedRelation: "organizations";
|
|
1396
|
+
referencedColumns: ["id"];
|
|
1397
1397
|
}
|
|
1398
1398
|
];
|
|
1399
1399
|
};
|
|
@@ -1457,18 +1457,18 @@ type Database = {
|
|
|
1457
1457
|
};
|
|
1458
1458
|
Relationships: [
|
|
1459
1459
|
{
|
|
1460
|
-
foreignKeyName:
|
|
1461
|
-
columns: [
|
|
1460
|
+
foreignKeyName: "acq_content_distributions_content_id_fkey";
|
|
1461
|
+
columns: ["content_id"];
|
|
1462
1462
|
isOneToOne: false;
|
|
1463
|
-
referencedRelation:
|
|
1464
|
-
referencedColumns: [
|
|
1463
|
+
referencedRelation: "acq_content";
|
|
1464
|
+
referencedColumns: ["id"];
|
|
1465
1465
|
},
|
|
1466
1466
|
{
|
|
1467
|
-
foreignKeyName:
|
|
1468
|
-
columns: [
|
|
1467
|
+
foreignKeyName: "acq_content_distributions_organization_id_fkey";
|
|
1468
|
+
columns: ["organization_id"];
|
|
1469
1469
|
isOneToOne: false;
|
|
1470
|
-
referencedRelation:
|
|
1471
|
-
referencedColumns: [
|
|
1470
|
+
referencedRelation: "organizations";
|
|
1471
|
+
referencedColumns: ["id"];
|
|
1472
1472
|
}
|
|
1473
1473
|
];
|
|
1474
1474
|
};
|
|
@@ -1502,18 +1502,18 @@ type Database = {
|
|
|
1502
1502
|
};
|
|
1503
1503
|
Relationships: [
|
|
1504
1504
|
{
|
|
1505
|
-
foreignKeyName:
|
|
1506
|
-
columns: [
|
|
1505
|
+
foreignKeyName: "acq_deal_notes_deal_id_fkey";
|
|
1506
|
+
columns: ["deal_id"];
|
|
1507
1507
|
isOneToOne: false;
|
|
1508
|
-
referencedRelation:
|
|
1509
|
-
referencedColumns: [
|
|
1508
|
+
referencedRelation: "acq_deals";
|
|
1509
|
+
referencedColumns: ["id"];
|
|
1510
1510
|
},
|
|
1511
1511
|
{
|
|
1512
|
-
foreignKeyName:
|
|
1513
|
-
columns: [
|
|
1512
|
+
foreignKeyName: "acq_deal_notes_organization_id_fkey";
|
|
1513
|
+
columns: ["organization_id"];
|
|
1514
1514
|
isOneToOne: false;
|
|
1515
|
-
referencedRelation:
|
|
1516
|
-
referencedColumns: [
|
|
1515
|
+
referencedRelation: "organizations";
|
|
1516
|
+
referencedColumns: ["id"];
|
|
1517
1517
|
}
|
|
1518
1518
|
];
|
|
1519
1519
|
};
|
|
@@ -1565,18 +1565,18 @@ type Database = {
|
|
|
1565
1565
|
};
|
|
1566
1566
|
Relationships: [
|
|
1567
1567
|
{
|
|
1568
|
-
foreignKeyName:
|
|
1569
|
-
columns: [
|
|
1568
|
+
foreignKeyName: "acq_deal_tasks_deal_id_fkey";
|
|
1569
|
+
columns: ["deal_id"];
|
|
1570
1570
|
isOneToOne: false;
|
|
1571
|
-
referencedRelation:
|
|
1572
|
-
referencedColumns: [
|
|
1571
|
+
referencedRelation: "acq_deals";
|
|
1572
|
+
referencedColumns: ["id"];
|
|
1573
1573
|
},
|
|
1574
1574
|
{
|
|
1575
|
-
foreignKeyName:
|
|
1576
|
-
columns: [
|
|
1575
|
+
foreignKeyName: "acq_deal_tasks_organization_id_fkey";
|
|
1576
|
+
columns: ["organization_id"];
|
|
1577
1577
|
isOneToOne: false;
|
|
1578
|
-
referencedRelation:
|
|
1579
|
-
referencedColumns: [
|
|
1578
|
+
referencedRelation: "organizations";
|
|
1579
|
+
referencedColumns: ["id"];
|
|
1580
1580
|
}
|
|
1581
1581
|
];
|
|
1582
1582
|
};
|
|
@@ -1593,6 +1593,8 @@ type Database = {
|
|
|
1593
1593
|
discovery_submitted_by: string | null;
|
|
1594
1594
|
id: string;
|
|
1595
1595
|
initial_fee: number | null;
|
|
1596
|
+
instantly_email_account: string | null;
|
|
1597
|
+
instantly_thread_uuid: string | null;
|
|
1596
1598
|
monthly_fee: number | null;
|
|
1597
1599
|
organization_id: string;
|
|
1598
1600
|
payment_link_sent_at: string | null;
|
|
@@ -1628,6 +1630,8 @@ type Database = {
|
|
|
1628
1630
|
discovery_submitted_by?: string | null;
|
|
1629
1631
|
id?: string;
|
|
1630
1632
|
initial_fee?: number | null;
|
|
1633
|
+
instantly_email_account?: string | null;
|
|
1634
|
+
instantly_thread_uuid?: string | null;
|
|
1631
1635
|
monthly_fee?: number | null;
|
|
1632
1636
|
organization_id: string;
|
|
1633
1637
|
payment_link_sent_at?: string | null;
|
|
@@ -1663,6 +1667,8 @@ type Database = {
|
|
|
1663
1667
|
discovery_submitted_by?: string | null;
|
|
1664
1668
|
id?: string;
|
|
1665
1669
|
initial_fee?: number | null;
|
|
1670
|
+
instantly_email_account?: string | null;
|
|
1671
|
+
instantly_thread_uuid?: string | null;
|
|
1666
1672
|
monthly_fee?: number | null;
|
|
1667
1673
|
organization_id?: string;
|
|
1668
1674
|
payment_link_sent_at?: string | null;
|
|
@@ -1688,25 +1694,25 @@ type Database = {
|
|
|
1688
1694
|
};
|
|
1689
1695
|
Relationships: [
|
|
1690
1696
|
{
|
|
1691
|
-
foreignKeyName:
|
|
1692
|
-
columns: [
|
|
1697
|
+
foreignKeyName: "acq_deals_contact_id_fkey";
|
|
1698
|
+
columns: ["contact_id"];
|
|
1693
1699
|
isOneToOne: false;
|
|
1694
|
-
referencedRelation:
|
|
1695
|
-
referencedColumns: [
|
|
1700
|
+
referencedRelation: "acq_contacts";
|
|
1701
|
+
referencedColumns: ["id"];
|
|
1696
1702
|
},
|
|
1697
1703
|
{
|
|
1698
|
-
foreignKeyName:
|
|
1699
|
-
columns: [
|
|
1704
|
+
foreignKeyName: "acq_deals_organization_id_fkey";
|
|
1705
|
+
columns: ["organization_id"];
|
|
1700
1706
|
isOneToOne: false;
|
|
1701
|
-
referencedRelation:
|
|
1702
|
-
referencedColumns: [
|
|
1707
|
+
referencedRelation: "organizations";
|
|
1708
|
+
referencedColumns: ["id"];
|
|
1703
1709
|
},
|
|
1704
1710
|
{
|
|
1705
|
-
foreignKeyName:
|
|
1706
|
-
columns: [
|
|
1711
|
+
foreignKeyName: "acq_deals_source_list_id_fkey";
|
|
1712
|
+
columns: ["source_list_id"];
|
|
1707
1713
|
isOneToOne: false;
|
|
1708
|
-
referencedRelation:
|
|
1709
|
-
referencedColumns: [
|
|
1714
|
+
referencedRelation: "acq_lists";
|
|
1715
|
+
referencedColumns: ["id"];
|
|
1710
1716
|
}
|
|
1711
1717
|
];
|
|
1712
1718
|
};
|
|
@@ -1758,25 +1764,25 @@ type Database = {
|
|
|
1758
1764
|
};
|
|
1759
1765
|
Relationships: [
|
|
1760
1766
|
{
|
|
1761
|
-
foreignKeyName:
|
|
1762
|
-
columns: [
|
|
1767
|
+
foreignKeyName: "acq_list_companies_company_id_fkey";
|
|
1768
|
+
columns: ["company_id"];
|
|
1763
1769
|
isOneToOne: false;
|
|
1764
|
-
referencedRelation:
|
|
1765
|
-
referencedColumns: [
|
|
1770
|
+
referencedRelation: "acq_companies";
|
|
1771
|
+
referencedColumns: ["id"];
|
|
1766
1772
|
},
|
|
1767
1773
|
{
|
|
1768
|
-
foreignKeyName:
|
|
1769
|
-
columns: [
|
|
1774
|
+
foreignKeyName: "acq_list_companies_list_id_fkey";
|
|
1775
|
+
columns: ["list_id"];
|
|
1770
1776
|
isOneToOne: false;
|
|
1771
|
-
referencedRelation:
|
|
1772
|
-
referencedColumns: [
|
|
1777
|
+
referencedRelation: "acq_lists";
|
|
1778
|
+
referencedColumns: ["id"];
|
|
1773
1779
|
},
|
|
1774
1780
|
{
|
|
1775
|
-
foreignKeyName:
|
|
1776
|
-
columns: [
|
|
1781
|
+
foreignKeyName: "acq_list_companies_source_execution_id_fkey";
|
|
1782
|
+
columns: ["source_execution_id"];
|
|
1777
1783
|
isOneToOne: false;
|
|
1778
|
-
referencedRelation:
|
|
1779
|
-
referencedColumns: [
|
|
1784
|
+
referencedRelation: "execution_logs";
|
|
1785
|
+
referencedColumns: ["execution_id"];
|
|
1780
1786
|
}
|
|
1781
1787
|
];
|
|
1782
1788
|
};
|
|
@@ -1804,18 +1810,18 @@ type Database = {
|
|
|
1804
1810
|
};
|
|
1805
1811
|
Relationships: [
|
|
1806
1812
|
{
|
|
1807
|
-
foreignKeyName:
|
|
1808
|
-
columns: [
|
|
1813
|
+
foreignKeyName: "acq_list_executions_execution_id_fkey";
|
|
1814
|
+
columns: ["execution_id"];
|
|
1809
1815
|
isOneToOne: false;
|
|
1810
|
-
referencedRelation:
|
|
1811
|
-
referencedColumns: [
|
|
1816
|
+
referencedRelation: "execution_logs";
|
|
1817
|
+
referencedColumns: ["execution_id"];
|
|
1812
1818
|
},
|
|
1813
1819
|
{
|
|
1814
|
-
foreignKeyName:
|
|
1815
|
-
columns: [
|
|
1820
|
+
foreignKeyName: "acq_list_executions_list_id_fkey";
|
|
1821
|
+
columns: ["list_id"];
|
|
1816
1822
|
isOneToOne: false;
|
|
1817
|
-
referencedRelation:
|
|
1818
|
-
referencedColumns: [
|
|
1823
|
+
referencedRelation: "acq_lists";
|
|
1824
|
+
referencedColumns: ["id"];
|
|
1819
1825
|
}
|
|
1820
1826
|
];
|
|
1821
1827
|
};
|
|
@@ -1867,25 +1873,25 @@ type Database = {
|
|
|
1867
1873
|
};
|
|
1868
1874
|
Relationships: [
|
|
1869
1875
|
{
|
|
1870
|
-
foreignKeyName:
|
|
1871
|
-
columns: [
|
|
1876
|
+
foreignKeyName: "acq_list_members_contact_id_fkey";
|
|
1877
|
+
columns: ["contact_id"];
|
|
1872
1878
|
isOneToOne: false;
|
|
1873
|
-
referencedRelation:
|
|
1874
|
-
referencedColumns: [
|
|
1879
|
+
referencedRelation: "acq_contacts";
|
|
1880
|
+
referencedColumns: ["id"];
|
|
1875
1881
|
},
|
|
1876
1882
|
{
|
|
1877
|
-
foreignKeyName:
|
|
1878
|
-
columns: [
|
|
1883
|
+
foreignKeyName: "acq_list_members_list_id_fkey";
|
|
1884
|
+
columns: ["list_id"];
|
|
1879
1885
|
isOneToOne: false;
|
|
1880
|
-
referencedRelation:
|
|
1881
|
-
referencedColumns: [
|
|
1886
|
+
referencedRelation: "acq_lists";
|
|
1887
|
+
referencedColumns: ["id"];
|
|
1882
1888
|
},
|
|
1883
1889
|
{
|
|
1884
|
-
foreignKeyName:
|
|
1885
|
-
columns: [
|
|
1890
|
+
foreignKeyName: "acq_list_members_source_execution_id_fkey";
|
|
1891
|
+
columns: ["source_execution_id"];
|
|
1886
1892
|
isOneToOne: false;
|
|
1887
|
-
referencedRelation:
|
|
1888
|
-
referencedColumns: [
|
|
1893
|
+
referencedRelation: "execution_logs";
|
|
1894
|
+
referencedColumns: ["execution_id"];
|
|
1889
1895
|
}
|
|
1890
1896
|
];
|
|
1891
1897
|
};
|
|
@@ -1940,11 +1946,11 @@ type Database = {
|
|
|
1940
1946
|
};
|
|
1941
1947
|
Relationships: [
|
|
1942
1948
|
{
|
|
1943
|
-
foreignKeyName:
|
|
1944
|
-
columns: [
|
|
1949
|
+
foreignKeyName: "acq_lists_organization_id_fkey";
|
|
1950
|
+
columns: ["organization_id"];
|
|
1945
1951
|
isOneToOne: false;
|
|
1946
|
-
referencedRelation:
|
|
1947
|
-
referencedColumns: [
|
|
1952
|
+
referencedRelation: "organizations";
|
|
1953
|
+
referencedColumns: ["id"];
|
|
1948
1954
|
}
|
|
1949
1955
|
];
|
|
1950
1956
|
};
|
|
@@ -2020,18 +2026,18 @@ type Database = {
|
|
|
2020
2026
|
};
|
|
2021
2027
|
Relationships: [
|
|
2022
2028
|
{
|
|
2023
|
-
foreignKeyName:
|
|
2024
|
-
columns: [
|
|
2029
|
+
foreignKeyName: "acq_seo_metrics_organization_id_fkey";
|
|
2030
|
+
columns: ["organization_id"];
|
|
2025
2031
|
isOneToOne: false;
|
|
2026
|
-
referencedRelation:
|
|
2027
|
-
referencedColumns: [
|
|
2032
|
+
referencedRelation: "organizations";
|
|
2033
|
+
referencedColumns: ["id"];
|
|
2028
2034
|
},
|
|
2029
2035
|
{
|
|
2030
|
-
foreignKeyName:
|
|
2031
|
-
columns: [
|
|
2036
|
+
foreignKeyName: "acq_seo_metrics_seo_page_id_fkey";
|
|
2037
|
+
columns: ["seo_page_id"];
|
|
2032
2038
|
isOneToOne: false;
|
|
2033
|
-
referencedRelation:
|
|
2034
|
-
referencedColumns: [
|
|
2039
|
+
referencedRelation: "acq_seo_pages";
|
|
2040
|
+
referencedColumns: ["id"];
|
|
2035
2041
|
}
|
|
2036
2042
|
];
|
|
2037
2043
|
};
|
|
@@ -2107,11 +2113,11 @@ type Database = {
|
|
|
2107
2113
|
};
|
|
2108
2114
|
Relationships: [
|
|
2109
2115
|
{
|
|
2110
|
-
foreignKeyName:
|
|
2111
|
-
columns: [
|
|
2116
|
+
foreignKeyName: "acq_seo_pages_organization_id_fkey";
|
|
2117
|
+
columns: ["organization_id"];
|
|
2112
2118
|
isOneToOne: false;
|
|
2113
|
-
referencedRelation:
|
|
2114
|
-
referencedColumns: [
|
|
2119
|
+
referencedRelation: "organizations";
|
|
2120
|
+
referencedColumns: ["id"];
|
|
2115
2121
|
}
|
|
2116
2122
|
];
|
|
2117
2123
|
};
|
|
@@ -2208,11 +2214,11 @@ type Database = {
|
|
|
2208
2214
|
};
|
|
2209
2215
|
Relationships: [
|
|
2210
2216
|
{
|
|
2211
|
-
foreignKeyName:
|
|
2212
|
-
columns: [
|
|
2217
|
+
foreignKeyName: "acq_social_posts_organization_id_fkey";
|
|
2218
|
+
columns: ["organization_id"];
|
|
2213
2219
|
isOneToOne: false;
|
|
2214
|
-
referencedRelation:
|
|
2215
|
-
referencedColumns: [
|
|
2220
|
+
referencedRelation: "organizations";
|
|
2221
|
+
referencedColumns: ["id"];
|
|
2216
2222
|
}
|
|
2217
2223
|
];
|
|
2218
2224
|
};
|
|
@@ -2267,11 +2273,11 @@ type Database = {
|
|
|
2267
2273
|
};
|
|
2268
2274
|
Relationships: [
|
|
2269
2275
|
{
|
|
2270
|
-
foreignKeyName:
|
|
2271
|
-
columns: [
|
|
2276
|
+
foreignKeyName: "activities_organization_id_fkey";
|
|
2277
|
+
columns: ["organization_id"];
|
|
2272
2278
|
isOneToOne: false;
|
|
2273
|
-
referencedRelation:
|
|
2274
|
-
referencedColumns: [
|
|
2279
|
+
referencedRelation: "organizations";
|
|
2280
|
+
referencedColumns: ["id"];
|
|
2275
2281
|
}
|
|
2276
2282
|
];
|
|
2277
2283
|
};
|
|
@@ -2302,11 +2308,11 @@ type Database = {
|
|
|
2302
2308
|
};
|
|
2303
2309
|
Relationships: [
|
|
2304
2310
|
{
|
|
2305
|
-
foreignKeyName:
|
|
2306
|
-
columns: [
|
|
2311
|
+
foreignKeyName: "api_keys_organization_id_fkey";
|
|
2312
|
+
columns: ["organization_id"];
|
|
2307
2313
|
isOneToOne: false;
|
|
2308
|
-
referencedRelation:
|
|
2309
|
-
referencedColumns: [
|
|
2314
|
+
referencedRelation: "organizations";
|
|
2315
|
+
referencedColumns: ["id"];
|
|
2310
2316
|
}
|
|
2311
2317
|
];
|
|
2312
2318
|
};
|
|
@@ -2385,25 +2391,25 @@ type Database = {
|
|
|
2385
2391
|
};
|
|
2386
2392
|
Relationships: [
|
|
2387
2393
|
{
|
|
2388
|
-
foreignKeyName:
|
|
2389
|
-
columns: [
|
|
2394
|
+
foreignKeyName: "command_queue_completed_by_fkey";
|
|
2395
|
+
columns: ["completed_by"];
|
|
2390
2396
|
isOneToOne: false;
|
|
2391
|
-
referencedRelation:
|
|
2392
|
-
referencedColumns: [
|
|
2397
|
+
referencedRelation: "users";
|
|
2398
|
+
referencedColumns: ["id"];
|
|
2393
2399
|
},
|
|
2394
2400
|
{
|
|
2395
|
-
foreignKeyName:
|
|
2396
|
-
columns: [
|
|
2401
|
+
foreignKeyName: "command_queue_organization_id_fkey";
|
|
2402
|
+
columns: ["organization_id"];
|
|
2397
2403
|
isOneToOne: false;
|
|
2398
|
-
referencedRelation:
|
|
2399
|
-
referencedColumns: [
|
|
2404
|
+
referencedRelation: "organizations";
|
|
2405
|
+
referencedColumns: ["id"];
|
|
2400
2406
|
},
|
|
2401
2407
|
{
|
|
2402
|
-
foreignKeyName:
|
|
2403
|
-
columns: [
|
|
2408
|
+
foreignKeyName: "command_queue_target_execution_id_fkey";
|
|
2409
|
+
columns: ["target_execution_id"];
|
|
2404
2410
|
isOneToOne: false;
|
|
2405
|
-
referencedRelation:
|
|
2406
|
-
referencedColumns: [
|
|
2411
|
+
referencedRelation: "execution_logs";
|
|
2412
|
+
referencedColumns: ["execution_id"];
|
|
2407
2413
|
}
|
|
2408
2414
|
];
|
|
2409
2415
|
};
|
|
@@ -2443,18 +2449,18 @@ type Database = {
|
|
|
2443
2449
|
};
|
|
2444
2450
|
Relationships: [
|
|
2445
2451
|
{
|
|
2446
|
-
foreignKeyName:
|
|
2447
|
-
columns: [
|
|
2452
|
+
foreignKeyName: "credentials_created_by_fkey";
|
|
2453
|
+
columns: ["created_by"];
|
|
2448
2454
|
isOneToOne: false;
|
|
2449
|
-
referencedRelation:
|
|
2450
|
-
referencedColumns: [
|
|
2455
|
+
referencedRelation: "users";
|
|
2456
|
+
referencedColumns: ["id"];
|
|
2451
2457
|
},
|
|
2452
2458
|
{
|
|
2453
|
-
foreignKeyName:
|
|
2454
|
-
columns: [
|
|
2459
|
+
foreignKeyName: "credentials_organization_id_fkey";
|
|
2460
|
+
columns: ["organization_id"];
|
|
2455
2461
|
isOneToOne: false;
|
|
2456
|
-
referencedRelation:
|
|
2457
|
-
referencedColumns: [
|
|
2462
|
+
referencedRelation: "organizations";
|
|
2463
|
+
referencedColumns: ["id"];
|
|
2458
2464
|
}
|
|
2459
2465
|
];
|
|
2460
2466
|
};
|
|
@@ -2500,11 +2506,11 @@ type Database = {
|
|
|
2500
2506
|
};
|
|
2501
2507
|
Relationships: [
|
|
2502
2508
|
{
|
|
2503
|
-
foreignKeyName:
|
|
2504
|
-
columns: [
|
|
2509
|
+
foreignKeyName: "deployments_organization_id_fkey";
|
|
2510
|
+
columns: ["organization_id"];
|
|
2505
2511
|
isOneToOne: false;
|
|
2506
|
-
referencedRelation:
|
|
2507
|
-
referencedColumns: [
|
|
2512
|
+
referencedRelation: "organizations";
|
|
2513
|
+
referencedColumns: ["id"];
|
|
2508
2514
|
}
|
|
2509
2515
|
];
|
|
2510
2516
|
};
|
|
@@ -2559,25 +2565,25 @@ type Database = {
|
|
|
2559
2565
|
};
|
|
2560
2566
|
Relationships: [
|
|
2561
2567
|
{
|
|
2562
|
-
foreignKeyName:
|
|
2563
|
-
columns: [
|
|
2568
|
+
foreignKeyName: "execution_errors_execution_id_fkey";
|
|
2569
|
+
columns: ["execution_id"];
|
|
2564
2570
|
isOneToOne: false;
|
|
2565
|
-
referencedRelation:
|
|
2566
|
-
referencedColumns: [
|
|
2571
|
+
referencedRelation: "execution_logs";
|
|
2572
|
+
referencedColumns: ["execution_id"];
|
|
2567
2573
|
},
|
|
2568
2574
|
{
|
|
2569
|
-
foreignKeyName:
|
|
2570
|
-
columns: [
|
|
2575
|
+
foreignKeyName: "execution_errors_organization_id_fkey";
|
|
2576
|
+
columns: ["organization_id"];
|
|
2571
2577
|
isOneToOne: false;
|
|
2572
|
-
referencedRelation:
|
|
2573
|
-
referencedColumns: [
|
|
2578
|
+
referencedRelation: "organizations";
|
|
2579
|
+
referencedColumns: ["id"];
|
|
2574
2580
|
},
|
|
2575
2581
|
{
|
|
2576
|
-
foreignKeyName:
|
|
2577
|
-
columns: [
|
|
2582
|
+
foreignKeyName: "execution_errors_resolved_by_fkey";
|
|
2583
|
+
columns: ["resolved_by"];
|
|
2578
2584
|
isOneToOne: false;
|
|
2579
|
-
referencedRelation:
|
|
2580
|
-
referencedColumns: [
|
|
2585
|
+
referencedRelation: "users";
|
|
2586
|
+
referencedColumns: ["id"];
|
|
2581
2587
|
}
|
|
2582
2588
|
];
|
|
2583
2589
|
};
|
|
@@ -2659,32 +2665,32 @@ type Database = {
|
|
|
2659
2665
|
};
|
|
2660
2666
|
Relationships: [
|
|
2661
2667
|
{
|
|
2662
|
-
foreignKeyName:
|
|
2663
|
-
columns: [
|
|
2668
|
+
foreignKeyName: "execution_history_organization_id_fkey";
|
|
2669
|
+
columns: ["organization_id"];
|
|
2664
2670
|
isOneToOne: false;
|
|
2665
|
-
referencedRelation:
|
|
2666
|
-
referencedColumns: [
|
|
2671
|
+
referencedRelation: "organizations";
|
|
2672
|
+
referencedColumns: ["id"];
|
|
2667
2673
|
},
|
|
2668
2674
|
{
|
|
2669
|
-
foreignKeyName:
|
|
2670
|
-
columns: [
|
|
2675
|
+
foreignKeyName: "execution_logs_origin_execution_id_fkey";
|
|
2676
|
+
columns: ["origin_execution_id"];
|
|
2671
2677
|
isOneToOne: false;
|
|
2672
|
-
referencedRelation:
|
|
2673
|
-
referencedColumns: [
|
|
2678
|
+
referencedRelation: "execution_logs";
|
|
2679
|
+
referencedColumns: ["execution_id"];
|
|
2674
2680
|
},
|
|
2675
2681
|
{
|
|
2676
|
-
foreignKeyName:
|
|
2677
|
-
columns: [
|
|
2682
|
+
foreignKeyName: "execution_logs_session_id_fkey";
|
|
2683
|
+
columns: ["session_id"];
|
|
2678
2684
|
isOneToOne: false;
|
|
2679
|
-
referencedRelation:
|
|
2680
|
-
referencedColumns: [
|
|
2685
|
+
referencedRelation: "sessions";
|
|
2686
|
+
referencedColumns: ["session_id"];
|
|
2681
2687
|
},
|
|
2682
2688
|
{
|
|
2683
|
-
foreignKeyName:
|
|
2684
|
-
columns: [
|
|
2689
|
+
foreignKeyName: "execution_logs_user_id_fkey";
|
|
2690
|
+
columns: ["user_id"];
|
|
2685
2691
|
isOneToOne: false;
|
|
2686
|
-
referencedRelation:
|
|
2687
|
-
referencedColumns: [
|
|
2692
|
+
referencedRelation: "users";
|
|
2693
|
+
referencedColumns: ["id"];
|
|
2688
2694
|
}
|
|
2689
2695
|
];
|
|
2690
2696
|
};
|
|
@@ -2730,18 +2736,18 @@ type Database = {
|
|
|
2730
2736
|
};
|
|
2731
2737
|
Relationships: [
|
|
2732
2738
|
{
|
|
2733
|
-
foreignKeyName:
|
|
2734
|
-
columns: [
|
|
2739
|
+
foreignKeyName: "execution_metrics_execution_id_fkey";
|
|
2740
|
+
columns: ["execution_id"];
|
|
2735
2741
|
isOneToOne: true;
|
|
2736
|
-
referencedRelation:
|
|
2737
|
-
referencedColumns: [
|
|
2742
|
+
referencedRelation: "execution_logs";
|
|
2743
|
+
referencedColumns: ["execution_id"];
|
|
2738
2744
|
},
|
|
2739
2745
|
{
|
|
2740
|
-
foreignKeyName:
|
|
2741
|
-
columns: [
|
|
2746
|
+
foreignKeyName: "execution_metrics_organization_id_fkey";
|
|
2747
|
+
columns: ["organization_id"];
|
|
2742
2748
|
isOneToOne: false;
|
|
2743
|
-
referencedRelation:
|
|
2744
|
-
referencedColumns: [
|
|
2749
|
+
referencedRelation: "organizations";
|
|
2750
|
+
referencedColumns: ["id"];
|
|
2745
2751
|
}
|
|
2746
2752
|
];
|
|
2747
2753
|
};
|
|
@@ -2784,18 +2790,18 @@ type Database = {
|
|
|
2784
2790
|
};
|
|
2785
2791
|
Relationships: [
|
|
2786
2792
|
{
|
|
2787
|
-
foreignKeyName:
|
|
2788
|
-
columns: [
|
|
2793
|
+
foreignKeyName: "notifications_organization_id_fkey";
|
|
2794
|
+
columns: ["organization_id"];
|
|
2789
2795
|
isOneToOne: false;
|
|
2790
|
-
referencedRelation:
|
|
2791
|
-
referencedColumns: [
|
|
2796
|
+
referencedRelation: "organizations";
|
|
2797
|
+
referencedColumns: ["id"];
|
|
2792
2798
|
},
|
|
2793
2799
|
{
|
|
2794
|
-
foreignKeyName:
|
|
2795
|
-
columns: [
|
|
2800
|
+
foreignKeyName: "notifications_user_id_fkey";
|
|
2801
|
+
columns: ["user_id"];
|
|
2796
2802
|
isOneToOne: false;
|
|
2797
|
-
referencedRelation:
|
|
2798
|
-
referencedColumns: [
|
|
2803
|
+
referencedRelation: "users";
|
|
2804
|
+
referencedColumns: ["id"];
|
|
2799
2805
|
}
|
|
2800
2806
|
];
|
|
2801
2807
|
};
|
|
@@ -2850,18 +2856,18 @@ type Database = {
|
|
|
2850
2856
|
};
|
|
2851
2857
|
Relationships: [
|
|
2852
2858
|
{
|
|
2853
|
-
foreignKeyName:
|
|
2854
|
-
columns: [
|
|
2859
|
+
foreignKeyName: "org_invitations_inviter_user_id_fkey";
|
|
2860
|
+
columns: ["inviter_user_id"];
|
|
2855
2861
|
isOneToOne: false;
|
|
2856
|
-
referencedRelation:
|
|
2857
|
-
referencedColumns: [
|
|
2862
|
+
referencedRelation: "users";
|
|
2863
|
+
referencedColumns: ["id"];
|
|
2858
2864
|
},
|
|
2859
2865
|
{
|
|
2860
|
-
foreignKeyName:
|
|
2861
|
-
columns: [
|
|
2866
|
+
foreignKeyName: "org_invitations_organization_id_fkey";
|
|
2867
|
+
columns: ["organization_id"];
|
|
2862
2868
|
isOneToOne: false;
|
|
2863
|
-
referencedRelation:
|
|
2864
|
-
referencedColumns: [
|
|
2869
|
+
referencedRelation: "organizations";
|
|
2870
|
+
referencedColumns: ["id"];
|
|
2865
2871
|
}
|
|
2866
2872
|
];
|
|
2867
2873
|
};
|
|
@@ -2904,18 +2910,18 @@ type Database = {
|
|
|
2904
2910
|
};
|
|
2905
2911
|
Relationships: [
|
|
2906
2912
|
{
|
|
2907
|
-
foreignKeyName:
|
|
2908
|
-
columns: [
|
|
2913
|
+
foreignKeyName: "org_memberships_organization_id_fkey";
|
|
2914
|
+
columns: ["organization_id"];
|
|
2909
2915
|
isOneToOne: false;
|
|
2910
|
-
referencedRelation:
|
|
2911
|
-
referencedColumns: [
|
|
2916
|
+
referencedRelation: "organizations";
|
|
2917
|
+
referencedColumns: ["id"];
|
|
2912
2918
|
},
|
|
2913
2919
|
{
|
|
2914
|
-
foreignKeyName:
|
|
2915
|
-
columns: [
|
|
2920
|
+
foreignKeyName: "org_memberships_user_id_fkey";
|
|
2921
|
+
columns: ["user_id"];
|
|
2916
2922
|
isOneToOne: false;
|
|
2917
|
-
referencedRelation:
|
|
2918
|
-
referencedColumns: [
|
|
2923
|
+
referencedRelation: "users";
|
|
2924
|
+
referencedColumns: ["id"];
|
|
2919
2925
|
}
|
|
2920
2926
|
];
|
|
2921
2927
|
};
|
|
@@ -2940,25 +2946,25 @@ type Database = {
|
|
|
2940
2946
|
};
|
|
2941
2947
|
Relationships: [
|
|
2942
2948
|
{
|
|
2943
|
-
foreignKeyName:
|
|
2944
|
-
columns: [
|
|
2949
|
+
foreignKeyName: "org_rol_assignments_granted_by_fkey";
|
|
2950
|
+
columns: ["granted_by"];
|
|
2945
2951
|
isOneToOne: false;
|
|
2946
|
-
referencedRelation:
|
|
2947
|
-
referencedColumns: [
|
|
2952
|
+
referencedRelation: "users";
|
|
2953
|
+
referencedColumns: ["id"];
|
|
2948
2954
|
},
|
|
2949
2955
|
{
|
|
2950
|
-
foreignKeyName:
|
|
2951
|
-
columns: [
|
|
2956
|
+
foreignKeyName: "org_rol_assignments_membership_id_fkey";
|
|
2957
|
+
columns: ["membership_id"];
|
|
2952
2958
|
isOneToOne: false;
|
|
2953
|
-
referencedRelation:
|
|
2954
|
-
referencedColumns: [
|
|
2959
|
+
referencedRelation: "org_memberships";
|
|
2960
|
+
referencedColumns: ["id"];
|
|
2955
2961
|
},
|
|
2956
2962
|
{
|
|
2957
|
-
foreignKeyName:
|
|
2958
|
-
columns: [
|
|
2963
|
+
foreignKeyName: "org_rol_assignments_role_id_fkey";
|
|
2964
|
+
columns: ["role_id"];
|
|
2959
2965
|
isOneToOne: false;
|
|
2960
|
-
referencedRelation:
|
|
2961
|
-
referencedColumns: [
|
|
2966
|
+
referencedRelation: "org_rol_definitions";
|
|
2967
|
+
referencedColumns: ["id"];
|
|
2962
2968
|
}
|
|
2963
2969
|
];
|
|
2964
2970
|
};
|
|
@@ -2995,11 +3001,11 @@ type Database = {
|
|
|
2995
3001
|
};
|
|
2996
3002
|
Relationships: [
|
|
2997
3003
|
{
|
|
2998
|
-
foreignKeyName:
|
|
2999
|
-
columns: [
|
|
3004
|
+
foreignKeyName: "org_rol_definitions_organization_id_fkey";
|
|
3005
|
+
columns: ["organization_id"];
|
|
3000
3006
|
isOneToOne: false;
|
|
3001
|
-
referencedRelation:
|
|
3002
|
-
referencedColumns: [
|
|
3007
|
+
referencedRelation: "organizations";
|
|
3008
|
+
referencedColumns: ["id"];
|
|
3003
3009
|
}
|
|
3004
3010
|
];
|
|
3005
3011
|
};
|
|
@@ -3021,18 +3027,18 @@ type Database = {
|
|
|
3021
3027
|
};
|
|
3022
3028
|
Relationships: [
|
|
3023
3029
|
{
|
|
3024
|
-
foreignKeyName:
|
|
3025
|
-
columns: [
|
|
3030
|
+
foreignKeyName: "org_rol_grants_permission_key_fkey";
|
|
3031
|
+
columns: ["permission_key"];
|
|
3026
3032
|
isOneToOne: false;
|
|
3027
|
-
referencedRelation:
|
|
3028
|
-
referencedColumns: [
|
|
3033
|
+
referencedRelation: "org_rol_permissions";
|
|
3034
|
+
referencedColumns: ["key"];
|
|
3029
3035
|
},
|
|
3030
3036
|
{
|
|
3031
|
-
foreignKeyName:
|
|
3032
|
-
columns: [
|
|
3037
|
+
foreignKeyName: "org_rol_grants_role_id_fkey";
|
|
3038
|
+
columns: ["role_id"];
|
|
3033
3039
|
isOneToOne: false;
|
|
3034
|
-
referencedRelation:
|
|
3035
|
-
referencedColumns: [
|
|
3040
|
+
referencedRelation: "org_rol_definitions";
|
|
3041
|
+
referencedColumns: ["id"];
|
|
3036
3042
|
}
|
|
3037
3043
|
];
|
|
3038
3044
|
};
|
|
@@ -3144,25 +3150,25 @@ type Database = {
|
|
|
3144
3150
|
};
|
|
3145
3151
|
Relationships: [
|
|
3146
3152
|
{
|
|
3147
|
-
foreignKeyName:
|
|
3148
|
-
columns: [
|
|
3153
|
+
foreignKeyName: "fk_milestones_project";
|
|
3154
|
+
columns: ["project_id"];
|
|
3149
3155
|
isOneToOne: false;
|
|
3150
|
-
referencedRelation:
|
|
3151
|
-
referencedColumns: [
|
|
3156
|
+
referencedRelation: "prj_projects";
|
|
3157
|
+
referencedColumns: ["id"];
|
|
3152
3158
|
},
|
|
3153
3159
|
{
|
|
3154
|
-
foreignKeyName:
|
|
3155
|
-
columns: [
|
|
3160
|
+
foreignKeyName: "prj_milestones_organization_id_fkey";
|
|
3161
|
+
columns: ["organization_id"];
|
|
3156
3162
|
isOneToOne: false;
|
|
3157
|
-
referencedRelation:
|
|
3158
|
-
referencedColumns: [
|
|
3163
|
+
referencedRelation: "organizations";
|
|
3164
|
+
referencedColumns: ["id"];
|
|
3159
3165
|
},
|
|
3160
3166
|
{
|
|
3161
|
-
foreignKeyName:
|
|
3162
|
-
columns: [
|
|
3167
|
+
foreignKeyName: "prj_milestones_project_id_fkey";
|
|
3168
|
+
columns: ["project_id"];
|
|
3163
3169
|
isOneToOne: false;
|
|
3164
|
-
referencedRelation:
|
|
3165
|
-
referencedColumns: [
|
|
3170
|
+
referencedRelation: "prj_projects";
|
|
3171
|
+
referencedColumns: ["id"];
|
|
3166
3172
|
}
|
|
3167
3173
|
];
|
|
3168
3174
|
};
|
|
@@ -3211,67 +3217,67 @@ type Database = {
|
|
|
3211
3217
|
};
|
|
3212
3218
|
Relationships: [
|
|
3213
3219
|
{
|
|
3214
|
-
foreignKeyName:
|
|
3215
|
-
columns: [
|
|
3220
|
+
foreignKeyName: "fk_notes_created_by";
|
|
3221
|
+
columns: ["created_by"];
|
|
3216
3222
|
isOneToOne: false;
|
|
3217
|
-
referencedRelation:
|
|
3218
|
-
referencedColumns: [
|
|
3223
|
+
referencedRelation: "users";
|
|
3224
|
+
referencedColumns: ["id"];
|
|
3219
3225
|
},
|
|
3220
3226
|
{
|
|
3221
|
-
foreignKeyName:
|
|
3222
|
-
columns: [
|
|
3227
|
+
foreignKeyName: "fk_notes_milestone";
|
|
3228
|
+
columns: ["milestone_id"];
|
|
3223
3229
|
isOneToOne: false;
|
|
3224
|
-
referencedRelation:
|
|
3225
|
-
referencedColumns: [
|
|
3230
|
+
referencedRelation: "prj_milestones";
|
|
3231
|
+
referencedColumns: ["id"];
|
|
3226
3232
|
},
|
|
3227
3233
|
{
|
|
3228
|
-
foreignKeyName:
|
|
3229
|
-
columns: [
|
|
3234
|
+
foreignKeyName: "fk_notes_project";
|
|
3235
|
+
columns: ["project_id"];
|
|
3230
3236
|
isOneToOne: false;
|
|
3231
|
-
referencedRelation:
|
|
3232
|
-
referencedColumns: [
|
|
3237
|
+
referencedRelation: "prj_projects";
|
|
3238
|
+
referencedColumns: ["id"];
|
|
3233
3239
|
},
|
|
3234
3240
|
{
|
|
3235
|
-
foreignKeyName:
|
|
3236
|
-
columns: [
|
|
3241
|
+
foreignKeyName: "fk_notes_task";
|
|
3242
|
+
columns: ["task_id"];
|
|
3237
3243
|
isOneToOne: false;
|
|
3238
|
-
referencedRelation:
|
|
3239
|
-
referencedColumns: [
|
|
3244
|
+
referencedRelation: "prj_tasks";
|
|
3245
|
+
referencedColumns: ["id"];
|
|
3240
3246
|
},
|
|
3241
3247
|
{
|
|
3242
|
-
foreignKeyName:
|
|
3243
|
-
columns: [
|
|
3248
|
+
foreignKeyName: "prj_notes_created_by_fkey";
|
|
3249
|
+
columns: ["created_by"];
|
|
3244
3250
|
isOneToOne: false;
|
|
3245
|
-
referencedRelation:
|
|
3246
|
-
referencedColumns: [
|
|
3251
|
+
referencedRelation: "users";
|
|
3252
|
+
referencedColumns: ["id"];
|
|
3247
3253
|
},
|
|
3248
3254
|
{
|
|
3249
|
-
foreignKeyName:
|
|
3250
|
-
columns: [
|
|
3255
|
+
foreignKeyName: "prj_notes_milestone_id_fkey";
|
|
3256
|
+
columns: ["milestone_id"];
|
|
3251
3257
|
isOneToOne: false;
|
|
3252
|
-
referencedRelation:
|
|
3253
|
-
referencedColumns: [
|
|
3258
|
+
referencedRelation: "prj_milestones";
|
|
3259
|
+
referencedColumns: ["id"];
|
|
3254
3260
|
},
|
|
3255
3261
|
{
|
|
3256
|
-
foreignKeyName:
|
|
3257
|
-
columns: [
|
|
3262
|
+
foreignKeyName: "prj_notes_organization_id_fkey";
|
|
3263
|
+
columns: ["organization_id"];
|
|
3258
3264
|
isOneToOne: false;
|
|
3259
|
-
referencedRelation:
|
|
3260
|
-
referencedColumns: [
|
|
3265
|
+
referencedRelation: "organizations";
|
|
3266
|
+
referencedColumns: ["id"];
|
|
3261
3267
|
},
|
|
3262
3268
|
{
|
|
3263
|
-
foreignKeyName:
|
|
3264
|
-
columns: [
|
|
3269
|
+
foreignKeyName: "prj_notes_project_id_fkey";
|
|
3270
|
+
columns: ["project_id"];
|
|
3265
3271
|
isOneToOne: false;
|
|
3266
|
-
referencedRelation:
|
|
3267
|
-
referencedColumns: [
|
|
3272
|
+
referencedRelation: "prj_projects";
|
|
3273
|
+
referencedColumns: ["id"];
|
|
3268
3274
|
},
|
|
3269
3275
|
{
|
|
3270
|
-
foreignKeyName:
|
|
3271
|
-
columns: [
|
|
3276
|
+
foreignKeyName: "prj_notes_task_id_fkey";
|
|
3277
|
+
columns: ["task_id"];
|
|
3272
3278
|
isOneToOne: false;
|
|
3273
|
-
referencedRelation:
|
|
3274
|
-
referencedColumns: [
|
|
3279
|
+
referencedRelation: "prj_tasks";
|
|
3280
|
+
referencedColumns: ["id"];
|
|
3275
3281
|
}
|
|
3276
3282
|
];
|
|
3277
3283
|
};
|
|
@@ -3329,39 +3335,39 @@ type Database = {
|
|
|
3329
3335
|
};
|
|
3330
3336
|
Relationships: [
|
|
3331
3337
|
{
|
|
3332
|
-
foreignKeyName:
|
|
3333
|
-
columns: [
|
|
3338
|
+
foreignKeyName: "fk_projects_company";
|
|
3339
|
+
columns: ["client_company_id"];
|
|
3334
3340
|
isOneToOne: false;
|
|
3335
|
-
referencedRelation:
|
|
3336
|
-
referencedColumns: [
|
|
3341
|
+
referencedRelation: "acq_companies";
|
|
3342
|
+
referencedColumns: ["id"];
|
|
3337
3343
|
},
|
|
3338
3344
|
{
|
|
3339
|
-
foreignKeyName:
|
|
3340
|
-
columns: [
|
|
3345
|
+
foreignKeyName: "fk_projects_deal";
|
|
3346
|
+
columns: ["deal_id"];
|
|
3341
3347
|
isOneToOne: false;
|
|
3342
|
-
referencedRelation:
|
|
3343
|
-
referencedColumns: [
|
|
3348
|
+
referencedRelation: "acq_deals";
|
|
3349
|
+
referencedColumns: ["id"];
|
|
3344
3350
|
},
|
|
3345
3351
|
{
|
|
3346
|
-
foreignKeyName:
|
|
3347
|
-
columns: [
|
|
3352
|
+
foreignKeyName: "prj_projects_client_company_id_fkey";
|
|
3353
|
+
columns: ["client_company_id"];
|
|
3348
3354
|
isOneToOne: false;
|
|
3349
|
-
referencedRelation:
|
|
3350
|
-
referencedColumns: [
|
|
3355
|
+
referencedRelation: "acq_companies";
|
|
3356
|
+
referencedColumns: ["id"];
|
|
3351
3357
|
},
|
|
3352
3358
|
{
|
|
3353
|
-
foreignKeyName:
|
|
3354
|
-
columns: [
|
|
3359
|
+
foreignKeyName: "prj_projects_deal_id_fkey";
|
|
3360
|
+
columns: ["deal_id"];
|
|
3355
3361
|
isOneToOne: false;
|
|
3356
|
-
referencedRelation:
|
|
3357
|
-
referencedColumns: [
|
|
3362
|
+
referencedRelation: "acq_deals";
|
|
3363
|
+
referencedColumns: ["id"];
|
|
3358
3364
|
},
|
|
3359
3365
|
{
|
|
3360
|
-
foreignKeyName:
|
|
3361
|
-
columns: [
|
|
3366
|
+
foreignKeyName: "prj_projects_organization_id_fkey";
|
|
3367
|
+
columns: ["organization_id"];
|
|
3362
3368
|
isOneToOne: false;
|
|
3363
|
-
referencedRelation:
|
|
3364
|
-
referencedColumns: [
|
|
3369
|
+
referencedRelation: "organizations";
|
|
3370
|
+
referencedColumns: ["id"];
|
|
3365
3371
|
}
|
|
3366
3372
|
];
|
|
3367
3373
|
};
|
|
@@ -3425,53 +3431,53 @@ type Database = {
|
|
|
3425
3431
|
};
|
|
3426
3432
|
Relationships: [
|
|
3427
3433
|
{
|
|
3428
|
-
foreignKeyName:
|
|
3429
|
-
columns: [
|
|
3434
|
+
foreignKeyName: "fk_tasks_milestone";
|
|
3435
|
+
columns: ["milestone_id"];
|
|
3430
3436
|
isOneToOne: false;
|
|
3431
|
-
referencedRelation:
|
|
3432
|
-
referencedColumns: [
|
|
3437
|
+
referencedRelation: "prj_milestones";
|
|
3438
|
+
referencedColumns: ["id"];
|
|
3433
3439
|
},
|
|
3434
3440
|
{
|
|
3435
|
-
foreignKeyName:
|
|
3436
|
-
columns: [
|
|
3441
|
+
foreignKeyName: "fk_tasks_parent";
|
|
3442
|
+
columns: ["parent_task_id"];
|
|
3437
3443
|
isOneToOne: false;
|
|
3438
|
-
referencedRelation:
|
|
3439
|
-
referencedColumns: [
|
|
3444
|
+
referencedRelation: "prj_tasks";
|
|
3445
|
+
referencedColumns: ["id"];
|
|
3440
3446
|
},
|
|
3441
3447
|
{
|
|
3442
|
-
foreignKeyName:
|
|
3443
|
-
columns: [
|
|
3448
|
+
foreignKeyName: "fk_tasks_project";
|
|
3449
|
+
columns: ["project_id"];
|
|
3444
3450
|
isOneToOne: false;
|
|
3445
|
-
referencedRelation:
|
|
3446
|
-
referencedColumns: [
|
|
3451
|
+
referencedRelation: "prj_projects";
|
|
3452
|
+
referencedColumns: ["id"];
|
|
3447
3453
|
},
|
|
3448
3454
|
{
|
|
3449
|
-
foreignKeyName:
|
|
3450
|
-
columns: [
|
|
3455
|
+
foreignKeyName: "prj_tasks_milestone_id_fkey";
|
|
3456
|
+
columns: ["milestone_id"];
|
|
3451
3457
|
isOneToOne: false;
|
|
3452
|
-
referencedRelation:
|
|
3453
|
-
referencedColumns: [
|
|
3458
|
+
referencedRelation: "prj_milestones";
|
|
3459
|
+
referencedColumns: ["id"];
|
|
3454
3460
|
},
|
|
3455
3461
|
{
|
|
3456
|
-
foreignKeyName:
|
|
3457
|
-
columns: [
|
|
3462
|
+
foreignKeyName: "prj_tasks_organization_id_fkey";
|
|
3463
|
+
columns: ["organization_id"];
|
|
3458
3464
|
isOneToOne: false;
|
|
3459
|
-
referencedRelation:
|
|
3460
|
-
referencedColumns: [
|
|
3465
|
+
referencedRelation: "organizations";
|
|
3466
|
+
referencedColumns: ["id"];
|
|
3461
3467
|
},
|
|
3462
3468
|
{
|
|
3463
|
-
foreignKeyName:
|
|
3464
|
-
columns: [
|
|
3469
|
+
foreignKeyName: "prj_tasks_parent_task_id_fkey";
|
|
3470
|
+
columns: ["parent_task_id"];
|
|
3465
3471
|
isOneToOne: false;
|
|
3466
|
-
referencedRelation:
|
|
3467
|
-
referencedColumns: [
|
|
3472
|
+
referencedRelation: "prj_tasks";
|
|
3473
|
+
referencedColumns: ["id"];
|
|
3468
3474
|
},
|
|
3469
3475
|
{
|
|
3470
|
-
foreignKeyName:
|
|
3471
|
-
columns: [
|
|
3476
|
+
foreignKeyName: "prj_tasks_project_id_fkey";
|
|
3477
|
+
columns: ["project_id"];
|
|
3472
3478
|
isOneToOne: false;
|
|
3473
|
-
referencedRelation:
|
|
3474
|
-
referencedColumns: [
|
|
3479
|
+
referencedRelation: "prj_projects";
|
|
3480
|
+
referencedColumns: ["id"];
|
|
3475
3481
|
}
|
|
3476
3482
|
];
|
|
3477
3483
|
};
|
|
@@ -3541,25 +3547,25 @@ type Database = {
|
|
|
3541
3547
|
};
|
|
3542
3548
|
Relationships: [
|
|
3543
3549
|
{
|
|
3544
|
-
foreignKeyName:
|
|
3545
|
-
columns: [
|
|
3550
|
+
foreignKeyName: "reported_requests_organization_id_fkey";
|
|
3551
|
+
columns: ["organization_id"];
|
|
3546
3552
|
isOneToOne: false;
|
|
3547
|
-
referencedRelation:
|
|
3548
|
-
referencedColumns: [
|
|
3553
|
+
referencedRelation: "organizations";
|
|
3554
|
+
referencedColumns: ["id"];
|
|
3549
3555
|
},
|
|
3550
3556
|
{
|
|
3551
|
-
foreignKeyName:
|
|
3552
|
-
columns: [
|
|
3557
|
+
foreignKeyName: "reported_requests_project_id_fkey";
|
|
3558
|
+
columns: ["project_id"];
|
|
3553
3559
|
isOneToOne: false;
|
|
3554
|
-
referencedRelation:
|
|
3555
|
-
referencedColumns: [
|
|
3560
|
+
referencedRelation: "prj_projects";
|
|
3561
|
+
referencedColumns: ["id"];
|
|
3556
3562
|
},
|
|
3557
3563
|
{
|
|
3558
|
-
foreignKeyName:
|
|
3559
|
-
columns: [
|
|
3564
|
+
foreignKeyName: "reported_requests_task_id_fkey";
|
|
3565
|
+
columns: ["task_id"];
|
|
3560
3566
|
isOneToOne: false;
|
|
3561
|
-
referencedRelation:
|
|
3562
|
-
referencedColumns: [
|
|
3567
|
+
referencedRelation: "prj_tasks";
|
|
3568
|
+
referencedColumns: ["id"];
|
|
3563
3569
|
}
|
|
3564
3570
|
];
|
|
3565
3571
|
};
|
|
@@ -3599,11 +3605,11 @@ type Database = {
|
|
|
3599
3605
|
};
|
|
3600
3606
|
Relationships: [
|
|
3601
3607
|
{
|
|
3602
|
-
foreignKeyName:
|
|
3603
|
-
columns: [
|
|
3608
|
+
foreignKeyName: "session_messages_session_id_fkey";
|
|
3609
|
+
columns: ["session_id"];
|
|
3604
3610
|
isOneToOne: false;
|
|
3605
|
-
referencedRelation:
|
|
3606
|
-
referencedColumns: [
|
|
3611
|
+
referencedRelation: "sessions";
|
|
3612
|
+
referencedColumns: ["session_id"];
|
|
3607
3613
|
}
|
|
3608
3614
|
];
|
|
3609
3615
|
};
|
|
@@ -3658,18 +3664,18 @@ type Database = {
|
|
|
3658
3664
|
};
|
|
3659
3665
|
Relationships: [
|
|
3660
3666
|
{
|
|
3661
|
-
foreignKeyName:
|
|
3662
|
-
columns: [
|
|
3667
|
+
foreignKeyName: "fk_organization";
|
|
3668
|
+
columns: ["organization_id"];
|
|
3663
3669
|
isOneToOne: false;
|
|
3664
|
-
referencedRelation:
|
|
3665
|
-
referencedColumns: [
|
|
3670
|
+
referencedRelation: "organizations";
|
|
3671
|
+
referencedColumns: ["id"];
|
|
3666
3672
|
},
|
|
3667
3673
|
{
|
|
3668
|
-
foreignKeyName:
|
|
3669
|
-
columns: [
|
|
3674
|
+
foreignKeyName: "fk_user";
|
|
3675
|
+
columns: ["user_id"];
|
|
3670
3676
|
isOneToOne: false;
|
|
3671
|
-
referencedRelation:
|
|
3672
|
-
referencedColumns: [
|
|
3677
|
+
referencedRelation: "users";
|
|
3678
|
+
referencedColumns: ["id"];
|
|
3673
3679
|
}
|
|
3674
3680
|
];
|
|
3675
3681
|
};
|
|
@@ -3745,11 +3751,11 @@ type Database = {
|
|
|
3745
3751
|
};
|
|
3746
3752
|
Relationships: [
|
|
3747
3753
|
{
|
|
3748
|
-
foreignKeyName:
|
|
3749
|
-
columns: [
|
|
3754
|
+
foreignKeyName: "task_schedules_organization_id_fkey";
|
|
3755
|
+
columns: ["organization_id"];
|
|
3750
3756
|
isOneToOne: false;
|
|
3751
|
-
referencedRelation:
|
|
3752
|
-
referencedColumns: [
|
|
3757
|
+
referencedRelation: "organizations";
|
|
3758
|
+
referencedColumns: ["id"];
|
|
3753
3759
|
}
|
|
3754
3760
|
];
|
|
3755
3761
|
};
|
|
@@ -3804,11 +3810,11 @@ type Database = {
|
|
|
3804
3810
|
};
|
|
3805
3811
|
Relationships: [
|
|
3806
3812
|
{
|
|
3807
|
-
foreignKeyName:
|
|
3808
|
-
columns: [
|
|
3813
|
+
foreignKeyName: "user_profiles_last_visited_org_fkey";
|
|
3814
|
+
columns: ["last_visited_org"];
|
|
3809
3815
|
isOneToOne: false;
|
|
3810
|
-
referencedRelation:
|
|
3811
|
-
referencedColumns: [
|
|
3816
|
+
referencedRelation: "organizations";
|
|
3817
|
+
referencedColumns: ["id"];
|
|
3812
3818
|
}
|
|
3813
3819
|
];
|
|
3814
3820
|
};
|
|
@@ -3857,11 +3863,11 @@ type Database = {
|
|
|
3857
3863
|
};
|
|
3858
3864
|
Relationships: [
|
|
3859
3865
|
{
|
|
3860
|
-
foreignKeyName:
|
|
3861
|
-
columns: [
|
|
3866
|
+
foreignKeyName: "webhook_endpoints_organization_id_fkey";
|
|
3867
|
+
columns: ["organization_id"];
|
|
3862
3868
|
isOneToOne: false;
|
|
3863
|
-
referencedRelation:
|
|
3864
|
-
referencedColumns: [
|
|
3869
|
+
referencedRelation: "organizations";
|
|
3870
|
+
referencedColumns: ["id"];
|
|
3865
3871
|
}
|
|
3866
3872
|
];
|
|
3867
3873
|
};
|
|
@@ -4149,6 +4155,30 @@ interface PipelineStage {
|
|
|
4149
4155
|
interface PipelineConfig {
|
|
4150
4156
|
stages: PipelineStage[];
|
|
4151
4157
|
}
|
|
4158
|
+
type BuildPlanSnapshotPrimaryEntity = 'company' | 'contact';
|
|
4159
|
+
type BuildPlanSnapshotOutput = 'company' | 'contact' | 'export';
|
|
4160
|
+
type BuildPlanSnapshotDependencyMode = 'per-record-eligibility';
|
|
4161
|
+
interface BuildPlanSnapshotStep {
|
|
4162
|
+
id: string;
|
|
4163
|
+
label: string;
|
|
4164
|
+
description?: string;
|
|
4165
|
+
primaryEntity: BuildPlanSnapshotPrimaryEntity;
|
|
4166
|
+
outputs: BuildPlanSnapshotOutput[];
|
|
4167
|
+
stageKey: string;
|
|
4168
|
+
dependsOn?: string[];
|
|
4169
|
+
dependencyMode: BuildPlanSnapshotDependencyMode;
|
|
4170
|
+
capabilityKey: string;
|
|
4171
|
+
defaultBatchSize: number;
|
|
4172
|
+
maxBatchSize: number;
|
|
4173
|
+
}
|
|
4174
|
+
interface BuildPlanSnapshot {
|
|
4175
|
+
templateId: string;
|
|
4176
|
+
templateLabel: string;
|
|
4177
|
+
steps: BuildPlanSnapshotStep[];
|
|
4178
|
+
}
|
|
4179
|
+
interface AcqListMetadata extends Record<string, unknown> {
|
|
4180
|
+
buildPlanSnapshot?: BuildPlanSnapshot;
|
|
4181
|
+
}
|
|
4152
4182
|
interface AcqList {
|
|
4153
4183
|
id: string;
|
|
4154
4184
|
organizationId: string;
|
|
@@ -4160,7 +4190,7 @@ interface AcqList {
|
|
|
4160
4190
|
scrapingConfig: ScrapingConfig;
|
|
4161
4191
|
icp: IcpRubric;
|
|
4162
4192
|
pipelineConfig: PipelineConfig;
|
|
4163
|
-
metadata:
|
|
4193
|
+
metadata: AcqListMetadata;
|
|
4164
4194
|
launchedAt: Date | null;
|
|
4165
4195
|
completedAt: Date | null;
|
|
4166
4196
|
createdAt: Date;
|
|
@@ -4228,6 +4258,16 @@ interface AcqContact {
|
|
|
4228
4258
|
createdAt: Date;
|
|
4229
4259
|
updatedAt: Date;
|
|
4230
4260
|
}
|
|
4261
|
+
type DealPriorityBucketKey = 'needs_response' | 'follow_up_due' | 'waiting' | 'stale' | 'closed_low';
|
|
4262
|
+
interface DealPriority {
|
|
4263
|
+
bucketKey: DealPriorityBucketKey;
|
|
4264
|
+
rank: number;
|
|
4265
|
+
label: string;
|
|
4266
|
+
color: string;
|
|
4267
|
+
reason: string;
|
|
4268
|
+
latestActivityAt: string | null;
|
|
4269
|
+
nextActionAt: string | null;
|
|
4270
|
+
}
|
|
4231
4271
|
interface DealContact {
|
|
4232
4272
|
id: string;
|
|
4233
4273
|
first_name: string | null;
|
|
@@ -4251,6 +4291,9 @@ interface DealContact {
|
|
|
4251
4291
|
}
|
|
4252
4292
|
/** Deal list item with joined contact and company data */
|
|
4253
4293
|
interface DealListItem extends AcqDealRow {
|
|
4294
|
+
priority: DealPriority;
|
|
4295
|
+
ownership: 'us' | 'them' | null;
|
|
4296
|
+
nextAction: string | null;
|
|
4254
4297
|
contact: DealContact | null;
|
|
4255
4298
|
}
|
|
4256
4299
|
type DealDetail = DealListItem;
|
|
@@ -4344,6 +4387,21 @@ declare const DealSchemas: {
|
|
|
4344
4387
|
ExecuteActionRequest: z.ZodObject<{
|
|
4345
4388
|
payload: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
4346
4389
|
}, z.core.$strict>;
|
|
4390
|
+
DealPriority: z.ZodObject<{
|
|
4391
|
+
bucketKey: z.ZodEnum<{
|
|
4392
|
+
needs_response: "needs_response";
|
|
4393
|
+
follow_up_due: "follow_up_due";
|
|
4394
|
+
waiting: "waiting";
|
|
4395
|
+
stale: "stale";
|
|
4396
|
+
closed_low: "closed_low";
|
|
4397
|
+
}>;
|
|
4398
|
+
rank: z.ZodNumber;
|
|
4399
|
+
label: z.ZodString;
|
|
4400
|
+
color: z.ZodString;
|
|
4401
|
+
reason: z.ZodString;
|
|
4402
|
+
latestActivityAt: z.ZodNullable<z.ZodString>;
|
|
4403
|
+
nextActionAt: z.ZodNullable<z.ZodString>;
|
|
4404
|
+
}, z.core.$strip>;
|
|
4347
4405
|
DealListResponse: z.ZodObject<{
|
|
4348
4406
|
data: z.ZodArray<z.ZodObject<{
|
|
4349
4407
|
id: z.ZodString;
|
|
@@ -4369,6 +4427,26 @@ declare const DealSchemas: {
|
|
|
4369
4427
|
closed_lost_reason: z.ZodNullable<z.ZodString>;
|
|
4370
4428
|
created_at: z.ZodString;
|
|
4371
4429
|
updated_at: z.ZodString;
|
|
4430
|
+
priority: z.ZodObject<{
|
|
4431
|
+
bucketKey: z.ZodEnum<{
|
|
4432
|
+
needs_response: "needs_response";
|
|
4433
|
+
follow_up_due: "follow_up_due";
|
|
4434
|
+
waiting: "waiting";
|
|
4435
|
+
stale: "stale";
|
|
4436
|
+
closed_low: "closed_low";
|
|
4437
|
+
}>;
|
|
4438
|
+
rank: z.ZodNumber;
|
|
4439
|
+
label: z.ZodString;
|
|
4440
|
+
color: z.ZodString;
|
|
4441
|
+
reason: z.ZodString;
|
|
4442
|
+
latestActivityAt: z.ZodNullable<z.ZodString>;
|
|
4443
|
+
nextActionAt: z.ZodNullable<z.ZodString>;
|
|
4444
|
+
}, z.core.$strip>;
|
|
4445
|
+
ownership: z.ZodNullable<z.ZodEnum<{
|
|
4446
|
+
us: "us";
|
|
4447
|
+
them: "them";
|
|
4448
|
+
}>>;
|
|
4449
|
+
nextAction: z.ZodNullable<z.ZodString>;
|
|
4372
4450
|
contact: z.ZodNullable<z.ZodObject<{
|
|
4373
4451
|
id: z.ZodString;
|
|
4374
4452
|
first_name: z.ZodNullable<z.ZodString>;
|
|
@@ -4427,6 +4505,18 @@ declare const DealSchemas: {
|
|
|
4427
4505
|
companyName: z.ZodNullable<z.ZodString>;
|
|
4428
4506
|
displayLabel: z.ZodString;
|
|
4429
4507
|
}, z.core.$strip>>;
|
|
4508
|
+
ConversationMessage: z.ZodObject<{
|
|
4509
|
+
id: z.ZodString;
|
|
4510
|
+
direction: z.ZodEnum<{
|
|
4511
|
+
inbound: "inbound";
|
|
4512
|
+
outbound: "outbound";
|
|
4513
|
+
}>;
|
|
4514
|
+
fromEmail: z.ZodString;
|
|
4515
|
+
toEmail: z.ZodString;
|
|
4516
|
+
subject: z.ZodNullable<z.ZodString>;
|
|
4517
|
+
body: z.ZodString;
|
|
4518
|
+
sentAt: z.ZodNullable<z.ZodString>;
|
|
4519
|
+
}, z.core.$strip>;
|
|
4430
4520
|
DealDetailResponse: z.ZodObject<{
|
|
4431
4521
|
id: z.ZodString;
|
|
4432
4522
|
organization_id: z.ZodString;
|
|
@@ -4451,6 +4541,26 @@ declare const DealSchemas: {
|
|
|
4451
4541
|
closed_lost_reason: z.ZodNullable<z.ZodString>;
|
|
4452
4542
|
created_at: z.ZodString;
|
|
4453
4543
|
updated_at: z.ZodString;
|
|
4544
|
+
priority: z.ZodObject<{
|
|
4545
|
+
bucketKey: z.ZodEnum<{
|
|
4546
|
+
needs_response: "needs_response";
|
|
4547
|
+
follow_up_due: "follow_up_due";
|
|
4548
|
+
waiting: "waiting";
|
|
4549
|
+
stale: "stale";
|
|
4550
|
+
closed_low: "closed_low";
|
|
4551
|
+
}>;
|
|
4552
|
+
rank: z.ZodNumber;
|
|
4553
|
+
label: z.ZodString;
|
|
4554
|
+
color: z.ZodString;
|
|
4555
|
+
reason: z.ZodString;
|
|
4556
|
+
latestActivityAt: z.ZodNullable<z.ZodString>;
|
|
4557
|
+
nextActionAt: z.ZodNullable<z.ZodString>;
|
|
4558
|
+
}, z.core.$strip>;
|
|
4559
|
+
ownership: z.ZodNullable<z.ZodEnum<{
|
|
4560
|
+
us: "us";
|
|
4561
|
+
them: "them";
|
|
4562
|
+
}>>;
|
|
4563
|
+
nextAction: z.ZodNullable<z.ZodString>;
|
|
4454
4564
|
contact: z.ZodNullable<z.ZodObject<{
|
|
4455
4565
|
id: z.ZodString;
|
|
4456
4566
|
first_name: z.ZodNullable<z.ZodString>;
|
|
@@ -4472,6 +4582,20 @@ declare const DealSchemas: {
|
|
|
4472
4582
|
num_employees: z.ZodNullable<z.ZodNumber>;
|
|
4473
4583
|
}, z.core.$strip>>;
|
|
4474
4584
|
}, z.core.$strip>>;
|
|
4585
|
+
conversation: z.ZodObject<{
|
|
4586
|
+
messages: z.ZodArray<z.ZodObject<{
|
|
4587
|
+
id: z.ZodString;
|
|
4588
|
+
direction: z.ZodEnum<{
|
|
4589
|
+
inbound: "inbound";
|
|
4590
|
+
outbound: "outbound";
|
|
4591
|
+
}>;
|
|
4592
|
+
fromEmail: z.ZodString;
|
|
4593
|
+
toEmail: z.ZodString;
|
|
4594
|
+
subject: z.ZodNullable<z.ZodString>;
|
|
4595
|
+
body: z.ZodString;
|
|
4596
|
+
sentAt: z.ZodNullable<z.ZodString>;
|
|
4597
|
+
}, z.core.$strip>>;
|
|
4598
|
+
}, z.core.$strip>;
|
|
4475
4599
|
}, z.core.$strip>;
|
|
4476
4600
|
DealNoteResponse: z.ZodObject<{
|
|
4477
4601
|
id: z.ZodString;
|
|
@@ -4566,6 +4690,7 @@ interface CreateListParams {
|
|
|
4566
4690
|
batchIds?: string[];
|
|
4567
4691
|
instantlyCampaignId?: string;
|
|
4568
4692
|
status?: ListStatus;
|
|
4693
|
+
buildTemplateId?: string;
|
|
4569
4694
|
metadata?: Record<string, unknown>;
|
|
4570
4695
|
scrapingConfig?: ScrapingConfig;
|
|
4571
4696
|
icp?: IcpRubric;
|
|
@@ -4680,6 +4805,10 @@ interface UpsertDealParams {
|
|
|
4680
4805
|
discoveryData?: unknown;
|
|
4681
4806
|
/** Optional proposal data JSONB to set on upsert */
|
|
4682
4807
|
proposalData?: unknown;
|
|
4808
|
+
/** Instantly email UUID used to hydrate the reply thread */
|
|
4809
|
+
instantlyThreadUuid?: string;
|
|
4810
|
+
/** Instantly sender account for direction detection */
|
|
4811
|
+
instantlyEmailAccount?: string;
|
|
4683
4812
|
}
|
|
4684
4813
|
interface UpdateDiscoveryDataParams {
|
|
4685
4814
|
organizationId: string;
|
|
@@ -4715,6 +4844,12 @@ interface UpdateFeesParams {
|
|
|
4715
4844
|
initialFee?: number;
|
|
4716
4845
|
monthlyFee?: number;
|
|
4717
4846
|
}
|
|
4847
|
+
interface CacheInstantlyThreadIdsParams {
|
|
4848
|
+
organizationId: string;
|
|
4849
|
+
dealId: string;
|
|
4850
|
+
instantlyThreadUuid: string;
|
|
4851
|
+
instantlyEmailAccount: string;
|
|
4852
|
+
}
|
|
4718
4853
|
interface TransitionItemParams {
|
|
4719
4854
|
organizationId: string;
|
|
4720
4855
|
dealId: string;
|
|
@@ -5123,9 +5258,17 @@ declare const ActivityEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
5123
5258
|
}, z.core.$strip>, z.ZodObject<{
|
|
5124
5259
|
type: z.ZodLiteral<"deal_created">;
|
|
5125
5260
|
timestamp: z.ZodString;
|
|
5261
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
5262
|
+
type: z.ZodLiteral<"action_failed">;
|
|
5263
|
+
timestamp: z.ZodString;
|
|
5264
|
+
actionKey: z.ZodString;
|
|
5265
|
+
errorMessage: z.ZodString;
|
|
5266
|
+
payload: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5126
5267
|
}, z.core.$strip>], "type">;
|
|
5127
5268
|
type ActivityEvent = z.infer<typeof ActivityEventSchema>;
|
|
5128
5269
|
|
|
5270
|
+
type DealOwnership = 'us' | 'them' | null;
|
|
5271
|
+
|
|
5129
5272
|
interface Action {
|
|
5130
5273
|
key: string;
|
|
5131
5274
|
label: string;
|
|
@@ -5138,8 +5281,12 @@ interface ActionDef {
|
|
|
5138
5281
|
workflowId: string;
|
|
5139
5282
|
payloadSchema?: z.ZodTypeAny;
|
|
5140
5283
|
}
|
|
5284
|
+
type DealActionInput = AcqDealRow & {
|
|
5285
|
+
ownership?: DealOwnership;
|
|
5286
|
+
nextAction?: string | null;
|
|
5287
|
+
};
|
|
5141
5288
|
declare const DEFAULT_CRM_ACTIONS: ActionDef[];
|
|
5142
|
-
declare function deriveActions(deal:
|
|
5289
|
+
declare function deriveActions(deal: DealActionInput, actions?: ActionDef[]): Action[];
|
|
5143
5290
|
|
|
5144
5291
|
/**
|
|
5145
5292
|
* A single CRM activity entry (note, stage change, or deal creation).
|
|
@@ -7848,6 +7995,10 @@ type LeadToolMap = {
|
|
|
7848
7995
|
params: Omit<UpdateFeesParams, 'organizationId'>;
|
|
7849
7996
|
result: void;
|
|
7850
7997
|
};
|
|
7998
|
+
cacheInstantlyThreadIds: {
|
|
7999
|
+
params: Omit<CacheInstantlyThreadIdsParams, 'organizationId'>;
|
|
8000
|
+
result: void;
|
|
8001
|
+
};
|
|
7851
8002
|
transitionItem: {
|
|
7852
8003
|
params: Omit<TransitionItemParams, 'organizationId'>;
|
|
7853
8004
|
result: void;
|