@llmops/core 0.1.5 → 0.1.6
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/{bun-sqlite-dialect-Bp2qbl5F.cjs → bun-sqlite-dialect-CYbkeI0s.cjs} +1 -1
- package/dist/db/index.cjs +1 -1
- package/dist/db/index.d.cts +1 -1
- package/dist/db/index.d.mts +1 -1
- package/dist/db/index.mjs +1 -1
- package/dist/{db-eEfIe5dO.cjs → db-C_u1BuaR.cjs} +11 -2
- package/dist/{db-DSzwrW4p.mjs → db-D78x_Elf.mjs} +9 -0
- package/dist/{index-BO7DYWFs.d.cts → index-CCfvTBvD.d.cts} +43 -25
- package/dist/{index-mUSLoeGU.d.mts → index-CzGmPK4Q.d.mts} +43 -25
- package/dist/index.cjs +107 -18
- package/dist/index.d.cts +67 -5
- package/dist/index.d.mts +276 -214
- package/dist/index.mjs +107 -18
- package/dist/{node-sqlite-dialect-b2V910TJ.cjs → node-sqlite-dialect-BSbNUAzj.cjs} +1 -1
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { A as TableName, B as configVariantsSchema, C as EnvironmentSecretsTable, D as LLMRequestsTable, E as LLMRequest, F as VariantVersion, G as schemas, H as environmentSecretsSchema, I as VariantVersionsTable, J as variantsSchema, K as targetingRulesSchema, L as VariantsTable, M as TargetingRulesTable, N as Updateable, O as SCHEMA_METADATA, P as Variant, R as WorkspaceSettings, S as EnvironmentSecret, T as Insertable, U as environmentsSchema, V as configsSchema, W as llmRequestsSchema, Y as workspaceSettingsSchema, _ as ConfigVariant, a as createDatabaseFromConnection, b as Database, c as MigrationResult, d as runAutoMigrations, f as parsePartialTableData, g as Config, h as validateTableData, i as createDatabase, j as TargetingRule, k as Selectable, l as getMigrations, m as validatePartialTableData, n as DatabaseOptions, o as detectDatabaseType, p as parseTableData, q as variantVersionsSchema, r as DatabaseType, s as MigrationOptions, t as DatabaseConnection, u as matchType, v as ConfigVariantsTable, w as EnvironmentsTable, x as Environment, y as ConfigsTable, z as WorkspaceSettingsTable } from "./index-
|
|
1
|
+
import { A as TableName, B as configVariantsSchema, C as EnvironmentSecretsTable, D as LLMRequestsTable, E as LLMRequest, F as VariantVersion, G as schemas, H as environmentSecretsSchema, I as VariantVersionsTable, J as variantsSchema, K as targetingRulesSchema, L as VariantsTable, M as TargetingRulesTable, N as Updateable, O as SCHEMA_METADATA, P as Variant, R as WorkspaceSettings, S as EnvironmentSecret, T as Insertable, U as environmentsSchema, V as configsSchema, W as llmRequestsSchema, Y as workspaceSettingsSchema, _ as ConfigVariant, a as createDatabaseFromConnection, b as Database, c as MigrationResult, d as runAutoMigrations, f as parsePartialTableData, g as Config, h as validateTableData, i as createDatabase, j as TargetingRule, k as Selectable, l as getMigrations, m as validatePartialTableData, n as DatabaseOptions, o as detectDatabaseType, p as parseTableData, q as variantVersionsSchema, r as DatabaseType, s as MigrationOptions, t as DatabaseConnection, u as matchType, v as ConfigVariantsTable, w as EnvironmentsTable, x as Environment, y as ConfigsTable, z as WorkspaceSettingsTable } from "./index-CzGmPK4Q.mjs";
|
|
2
2
|
import gateway from "@llmops/gateway";
|
|
3
3
|
import { Kysely } from "kysely";
|
|
4
4
|
import pino from "pino";
|
|
5
|
-
import * as
|
|
5
|
+
import * as zod23 from "zod";
|
|
6
6
|
import z$1, { z } from "zod";
|
|
7
7
|
import * as zod_v4_core0 from "zod/v4/core";
|
|
8
8
|
|
|
@@ -1519,6 +1519,7 @@ declare const insertLLMRequestSchema: z$1.ZodObject<{
|
|
|
1519
1519
|
requestId: z$1.ZodString;
|
|
1520
1520
|
configId: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
|
|
1521
1521
|
variantId: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
|
|
1522
|
+
environmentId: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodString>>;
|
|
1522
1523
|
provider: z$1.ZodString;
|
|
1523
1524
|
model: z$1.ZodString;
|
|
1524
1525
|
promptTokens: z$1.ZodDefault<z$1.ZodNumber>;
|
|
@@ -1543,17 +1544,24 @@ declare const listRequestsSchema: z$1.ZodObject<{
|
|
|
1543
1544
|
limit: z$1.ZodDefault<z$1.ZodNumber>;
|
|
1544
1545
|
offset: z$1.ZodDefault<z$1.ZodNumber>;
|
|
1545
1546
|
configId: z$1.ZodOptional<z$1.ZodString>;
|
|
1547
|
+
variantId: z$1.ZodOptional<z$1.ZodString>;
|
|
1548
|
+
environmentId: z$1.ZodOptional<z$1.ZodString>;
|
|
1546
1549
|
provider: z$1.ZodOptional<z$1.ZodString>;
|
|
1547
1550
|
model: z$1.ZodOptional<z$1.ZodString>;
|
|
1548
1551
|
startDate: z$1.ZodOptional<z$1.ZodDate>;
|
|
1549
1552
|
endDate: z$1.ZodOptional<z$1.ZodDate>;
|
|
1553
|
+
tags: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodArray<z$1.ZodString>>>;
|
|
1550
1554
|
}, z$1.core.$strip>;
|
|
1551
1555
|
/**
|
|
1552
|
-
* Schema for date range queries
|
|
1556
|
+
* Schema for date range queries with optional filters
|
|
1553
1557
|
*/
|
|
1554
1558
|
declare const dateRangeSchema: z$1.ZodObject<{
|
|
1555
1559
|
startDate: z$1.ZodDate;
|
|
1556
1560
|
endDate: z$1.ZodDate;
|
|
1561
|
+
configId: z$1.ZodOptional<z$1.ZodString>;
|
|
1562
|
+
variantId: z$1.ZodOptional<z$1.ZodString>;
|
|
1563
|
+
environmentId: z$1.ZodOptional<z$1.ZodString>;
|
|
1564
|
+
tags: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodArray<z$1.ZodString>>>;
|
|
1557
1565
|
}, z$1.core.$strip>;
|
|
1558
1566
|
/**
|
|
1559
1567
|
* Schema for cost summary with grouping
|
|
@@ -1561,6 +1569,10 @@ declare const dateRangeSchema: z$1.ZodObject<{
|
|
|
1561
1569
|
declare const costSummarySchema: z$1.ZodObject<{
|
|
1562
1570
|
startDate: z$1.ZodDate;
|
|
1563
1571
|
endDate: z$1.ZodDate;
|
|
1572
|
+
configId: z$1.ZodOptional<z$1.ZodString>;
|
|
1573
|
+
variantId: z$1.ZodOptional<z$1.ZodString>;
|
|
1574
|
+
environmentId: z$1.ZodOptional<z$1.ZodString>;
|
|
1575
|
+
tags: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodArray<z$1.ZodString>>>;
|
|
1564
1576
|
groupBy: z$1.ZodOptional<z$1.ZodEnum<{
|
|
1565
1577
|
provider: "provider";
|
|
1566
1578
|
model: "model";
|
|
@@ -1585,6 +1597,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1585
1597
|
variantId: string | null;
|
|
1586
1598
|
id: string;
|
|
1587
1599
|
provider: string;
|
|
1600
|
+
environmentId: string | null;
|
|
1588
1601
|
requestId: string;
|
|
1589
1602
|
model: string;
|
|
1590
1603
|
promptTokens: number;
|
|
@@ -1613,6 +1626,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1613
1626
|
variantId: string | null;
|
|
1614
1627
|
id: string;
|
|
1615
1628
|
provider: string;
|
|
1629
|
+
environmentId: string | null;
|
|
1616
1630
|
requestId: string;
|
|
1617
1631
|
model: string;
|
|
1618
1632
|
promptTokens: number;
|
|
@@ -1643,6 +1657,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1643
1657
|
variantId: string | null;
|
|
1644
1658
|
id: string;
|
|
1645
1659
|
provider: string;
|
|
1660
|
+
environmentId: string | null;
|
|
1646
1661
|
requestId: string;
|
|
1647
1662
|
model: string;
|
|
1648
1663
|
promptTokens: number;
|
|
@@ -1662,7 +1677,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1662
1677
|
updatedAt: Date;
|
|
1663
1678
|
} | undefined>;
|
|
1664
1679
|
/**
|
|
1665
|
-
* Get total cost for a date range
|
|
1680
|
+
* Get total cost for a date range with optional filters
|
|
1666
1681
|
*/
|
|
1667
1682
|
getTotalCost: (params: z$1.infer<typeof dateRangeSchema>) => Promise<{
|
|
1668
1683
|
totalCost: number;
|
|
@@ -1723,7 +1738,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1723
1738
|
date: string;
|
|
1724
1739
|
}[]>;
|
|
1725
1740
|
/**
|
|
1726
|
-
* Get cost summary with flexible grouping
|
|
1741
|
+
* Get cost summary with flexible grouping and optional filters
|
|
1727
1742
|
*/
|
|
1728
1743
|
getCostSummary: (params: z$1.infer<typeof costSummarySchema>) => Promise<{
|
|
1729
1744
|
totalCost: number;
|
|
@@ -1731,7 +1746,7 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1731
1746
|
groupKey: string;
|
|
1732
1747
|
}[]>;
|
|
1733
1748
|
/**
|
|
1734
|
-
* Get request count and stats for a time range
|
|
1749
|
+
* Get request count and stats for a time range with optional filters
|
|
1735
1750
|
*/
|
|
1736
1751
|
getRequestStats: (params: z$1.infer<typeof dateRangeSchema>) => Promise<{
|
|
1737
1752
|
avgLatencyMs: number;
|
|
@@ -1742,6 +1757,14 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1742
1757
|
maxLatencyMs: number;
|
|
1743
1758
|
minLatencyMs: number;
|
|
1744
1759
|
} | undefined>;
|
|
1760
|
+
/**
|
|
1761
|
+
* Get all distinct tag key-value pairs from llm_requests
|
|
1762
|
+
* Used for populating tag filter dropdowns in the UI
|
|
1763
|
+
*/
|
|
1764
|
+
getDistinctTags: () => Promise<{
|
|
1765
|
+
key: string;
|
|
1766
|
+
value: string;
|
|
1767
|
+
}[]>;
|
|
1745
1768
|
};
|
|
1746
1769
|
//#endregion
|
|
1747
1770
|
//#region src/datalayer/index.d.ts
|
|
@@ -1752,19 +1775,19 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1752
1775
|
createdAt: Date;
|
|
1753
1776
|
updatedAt: Date;
|
|
1754
1777
|
} | undefined>;
|
|
1755
|
-
updateWorkspaceSettings: (params:
|
|
1756
|
-
name:
|
|
1778
|
+
updateWorkspaceSettings: (params: zod23.infer<zod23.ZodObject<{
|
|
1779
|
+
name: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodString>>;
|
|
1757
1780
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1758
1781
|
name: string | null;
|
|
1759
1782
|
id: string;
|
|
1760
1783
|
createdAt: Date;
|
|
1761
1784
|
updatedAt: Date;
|
|
1762
1785
|
} | undefined>;
|
|
1763
|
-
createVariantVersion: (params:
|
|
1764
|
-
variantId:
|
|
1765
|
-
provider:
|
|
1766
|
-
modelName:
|
|
1767
|
-
jsonData:
|
|
1786
|
+
createVariantVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1787
|
+
variantId: zod23.ZodString;
|
|
1788
|
+
provider: zod23.ZodString;
|
|
1789
|
+
modelName: zod23.ZodString;
|
|
1790
|
+
jsonData: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodUnknown>>>;
|
|
1768
1791
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1769
1792
|
version: number;
|
|
1770
1793
|
variantId: string;
|
|
@@ -1775,8 +1798,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1775
1798
|
createdAt: Date;
|
|
1776
1799
|
updatedAt: Date;
|
|
1777
1800
|
} | undefined>;
|
|
1778
|
-
getVariantVersionById: (params:
|
|
1779
|
-
id:
|
|
1801
|
+
getVariantVersionById: (params: zod23.infer<zod23.ZodObject<{
|
|
1802
|
+
id: zod23.ZodString;
|
|
1780
1803
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1781
1804
|
version: number;
|
|
1782
1805
|
variantId: string;
|
|
@@ -1787,10 +1810,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1787
1810
|
createdAt: Date;
|
|
1788
1811
|
updatedAt: Date;
|
|
1789
1812
|
} | undefined>;
|
|
1790
|
-
getVariantVersionsByVariantId: (params:
|
|
1791
|
-
variantId:
|
|
1792
|
-
limit:
|
|
1793
|
-
offset:
|
|
1813
|
+
getVariantVersionsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1814
|
+
variantId: zod23.ZodString;
|
|
1815
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1816
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1794
1817
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1795
1818
|
version: number;
|
|
1796
1819
|
variantId: string;
|
|
@@ -1801,8 +1824,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1801
1824
|
createdAt: Date;
|
|
1802
1825
|
updatedAt: Date;
|
|
1803
1826
|
}[]>;
|
|
1804
|
-
getLatestVariantVersion: (params:
|
|
1805
|
-
variantId:
|
|
1827
|
+
getLatestVariantVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1828
|
+
variantId: zod23.ZodString;
|
|
1806
1829
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1807
1830
|
version: number;
|
|
1808
1831
|
variantId: string;
|
|
@@ -1813,9 +1836,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1813
1836
|
createdAt: Date;
|
|
1814
1837
|
updatedAt: Date;
|
|
1815
1838
|
} | undefined>;
|
|
1816
|
-
getVariantVersionByNumber: (params:
|
|
1817
|
-
variantId:
|
|
1818
|
-
version:
|
|
1839
|
+
getVariantVersionByNumber: (params: zod23.infer<zod23.ZodObject<{
|
|
1840
|
+
variantId: zod23.ZodString;
|
|
1841
|
+
version: zod23.ZodNumber;
|
|
1819
1842
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1820
1843
|
version: number;
|
|
1821
1844
|
variantId: string;
|
|
@@ -1826,8 +1849,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1826
1849
|
createdAt: Date;
|
|
1827
1850
|
updatedAt: Date;
|
|
1828
1851
|
} | undefined>;
|
|
1829
|
-
deleteVariantVersion: (params:
|
|
1830
|
-
id:
|
|
1852
|
+
deleteVariantVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1853
|
+
id: zod23.ZodString;
|
|
1831
1854
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1832
1855
|
version: number;
|
|
1833
1856
|
variantId: string;
|
|
@@ -1838,8 +1861,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1838
1861
|
createdAt: Date;
|
|
1839
1862
|
updatedAt: Date;
|
|
1840
1863
|
} | undefined>;
|
|
1841
|
-
deleteVariantVersionsByVariantId: (params:
|
|
1842
|
-
variantId:
|
|
1864
|
+
deleteVariantVersionsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1865
|
+
variantId: zod23.ZodString;
|
|
1843
1866
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1844
1867
|
version: number;
|
|
1845
1868
|
variantId: string;
|
|
@@ -1850,8 +1873,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1850
1873
|
createdAt: Date;
|
|
1851
1874
|
updatedAt: Date;
|
|
1852
1875
|
}[]>;
|
|
1853
|
-
getVariantVersionWithVariant: (params:
|
|
1854
|
-
id:
|
|
1876
|
+
getVariantVersionWithVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1877
|
+
id: zod23.ZodString;
|
|
1855
1878
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1856
1879
|
version: number;
|
|
1857
1880
|
variantId: string;
|
|
@@ -1863,10 +1886,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1863
1886
|
updatedAt: Date;
|
|
1864
1887
|
variantName: string;
|
|
1865
1888
|
} | undefined>;
|
|
1866
|
-
getVariantVersionsWithVariantByVariantId: (params:
|
|
1867
|
-
variantId:
|
|
1868
|
-
limit:
|
|
1869
|
-
offset:
|
|
1889
|
+
getVariantVersionsWithVariantByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1890
|
+
variantId: zod23.ZodString;
|
|
1891
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1892
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1870
1893
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1871
1894
|
version: number;
|
|
1872
1895
|
variantId: string;
|
|
@@ -1878,33 +1901,33 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1878
1901
|
updatedAt: Date;
|
|
1879
1902
|
variantName: string;
|
|
1880
1903
|
}[]>;
|
|
1881
|
-
createVariant: (params:
|
|
1882
|
-
name:
|
|
1904
|
+
createVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1905
|
+
name: zod23.ZodString;
|
|
1883
1906
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1884
1907
|
name: string;
|
|
1885
1908
|
id: string;
|
|
1886
1909
|
createdAt: Date;
|
|
1887
1910
|
updatedAt: Date;
|
|
1888
1911
|
} | undefined>;
|
|
1889
|
-
updateVariant: (params:
|
|
1890
|
-
variantId:
|
|
1891
|
-
name:
|
|
1912
|
+
updateVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1913
|
+
variantId: zod23.ZodString;
|
|
1914
|
+
name: zod23.ZodOptional<zod23.ZodString>;
|
|
1892
1915
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1893
1916
|
name: string;
|
|
1894
1917
|
id: string;
|
|
1895
1918
|
createdAt: Date;
|
|
1896
1919
|
updatedAt: Date;
|
|
1897
1920
|
} | undefined>;
|
|
1898
|
-
getVariantById: (params:
|
|
1899
|
-
variantId:
|
|
1921
|
+
getVariantById: (params: zod23.infer<zod23.ZodObject<{
|
|
1922
|
+
variantId: zod23.ZodString;
|
|
1900
1923
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1901
1924
|
name: string;
|
|
1902
1925
|
id: string;
|
|
1903
1926
|
createdAt: Date;
|
|
1904
1927
|
updatedAt: Date;
|
|
1905
1928
|
} | undefined>;
|
|
1906
|
-
getVariantWithLatestVersion: (params:
|
|
1907
|
-
variantId:
|
|
1929
|
+
getVariantWithLatestVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1930
|
+
variantId: zod23.ZodString;
|
|
1908
1931
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1909
1932
|
latestVersion: {
|
|
1910
1933
|
version: number;
|
|
@@ -1921,26 +1944,26 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1921
1944
|
createdAt: Date;
|
|
1922
1945
|
updatedAt: Date;
|
|
1923
1946
|
} | undefined>;
|
|
1924
|
-
deleteVariant: (params:
|
|
1925
|
-
variantId:
|
|
1947
|
+
deleteVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1948
|
+
variantId: zod23.ZodString;
|
|
1926
1949
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1927
1950
|
name: string;
|
|
1928
1951
|
id: string;
|
|
1929
1952
|
createdAt: Date;
|
|
1930
1953
|
updatedAt: Date;
|
|
1931
1954
|
} | undefined>;
|
|
1932
|
-
listVariants: (params?:
|
|
1933
|
-
limit:
|
|
1934
|
-
offset:
|
|
1955
|
+
listVariants: (params?: zod23.infer<zod23.ZodObject<{
|
|
1956
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1957
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1935
1958
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1936
1959
|
name: string;
|
|
1937
1960
|
id: string;
|
|
1938
1961
|
createdAt: Date;
|
|
1939
1962
|
updatedAt: Date;
|
|
1940
1963
|
}[]>;
|
|
1941
|
-
listVariantsWithLatestVersion: (params?:
|
|
1942
|
-
limit:
|
|
1943
|
-
offset:
|
|
1964
|
+
listVariantsWithLatestVersion: (params?: zod23.infer<zod23.ZodObject<{
|
|
1965
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1966
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1944
1967
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1945
1968
|
latestVersion: {
|
|
1946
1969
|
version: number;
|
|
@@ -1957,15 +1980,15 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1957
1980
|
createdAt: Date;
|
|
1958
1981
|
updatedAt: Date;
|
|
1959
1982
|
}[]>;
|
|
1960
|
-
createTargetingRule: (params:
|
|
1961
|
-
environmentId:
|
|
1962
|
-
configId:
|
|
1963
|
-
configVariantId:
|
|
1964
|
-
variantVersionId:
|
|
1965
|
-
weight:
|
|
1966
|
-
priority:
|
|
1967
|
-
enabled:
|
|
1968
|
-
conditions:
|
|
1983
|
+
createTargetingRule: (params: zod23.infer<zod23.ZodObject<{
|
|
1984
|
+
environmentId: zod23.ZodString;
|
|
1985
|
+
configId: zod23.ZodString;
|
|
1986
|
+
configVariantId: zod23.ZodString;
|
|
1987
|
+
variantVersionId: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodString>>;
|
|
1988
|
+
weight: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodNumber>>;
|
|
1989
|
+
priority: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodNumber>>;
|
|
1990
|
+
enabled: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodBoolean>>;
|
|
1991
|
+
conditions: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodRecord<zod23.ZodString, zod23.ZodUnknown>>>;
|
|
1969
1992
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1970
1993
|
configId: string;
|
|
1971
1994
|
id: string;
|
|
@@ -1979,13 +2002,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1979
2002
|
createdAt: Date;
|
|
1980
2003
|
updatedAt: Date;
|
|
1981
2004
|
} | undefined>;
|
|
1982
|
-
updateTargetingRule: (params:
|
|
1983
|
-
id:
|
|
1984
|
-
variantVersionId:
|
|
1985
|
-
weight:
|
|
1986
|
-
priority:
|
|
1987
|
-
enabled:
|
|
1988
|
-
conditions:
|
|
2005
|
+
updateTargetingRule: (params: zod23.infer<zod23.ZodObject<{
|
|
2006
|
+
id: zod23.ZodString;
|
|
2007
|
+
variantVersionId: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodString>>;
|
|
2008
|
+
weight: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2009
|
+
priority: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2010
|
+
enabled: zod23.ZodOptional<zod23.ZodBoolean>;
|
|
2011
|
+
conditions: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodRecord<zod23.ZodString, zod23.ZodUnknown>>>;
|
|
1989
2012
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1990
2013
|
configId: string;
|
|
1991
2014
|
id: string;
|
|
@@ -1999,8 +2022,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1999
2022
|
createdAt: Date;
|
|
2000
2023
|
updatedAt: Date;
|
|
2001
2024
|
} | undefined>;
|
|
2002
|
-
getTargetingRuleById: (params:
|
|
2003
|
-
id:
|
|
2025
|
+
getTargetingRuleById: (params: zod23.infer<zod23.ZodObject<{
|
|
2026
|
+
id: zod23.ZodString;
|
|
2004
2027
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2005
2028
|
configId: string;
|
|
2006
2029
|
id: string;
|
|
@@ -2014,10 +2037,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2014
2037
|
createdAt: Date;
|
|
2015
2038
|
updatedAt: Date;
|
|
2016
2039
|
} | undefined>;
|
|
2017
|
-
getTargetingRulesByConfigId: (params:
|
|
2018
|
-
configId:
|
|
2019
|
-
limit:
|
|
2020
|
-
offset:
|
|
2040
|
+
getTargetingRulesByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2041
|
+
configId: zod23.ZodString;
|
|
2042
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2043
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2021
2044
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2022
2045
|
configId: string;
|
|
2023
2046
|
id: string;
|
|
@@ -2031,10 +2054,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2031
2054
|
createdAt: Date;
|
|
2032
2055
|
updatedAt: Date;
|
|
2033
2056
|
}[]>;
|
|
2034
|
-
getTargetingRulesByEnvironmentId: (params:
|
|
2035
|
-
environmentId:
|
|
2036
|
-
limit:
|
|
2037
|
-
offset:
|
|
2057
|
+
getTargetingRulesByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2058
|
+
environmentId: zod23.ZodString;
|
|
2059
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2060
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2038
2061
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2039
2062
|
configId: string;
|
|
2040
2063
|
id: string;
|
|
@@ -2048,9 +2071,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2048
2071
|
createdAt: Date;
|
|
2049
2072
|
updatedAt: Date;
|
|
2050
2073
|
}[]>;
|
|
2051
|
-
getTargetingRulesByConfigAndEnvironment: (params:
|
|
2052
|
-
configId:
|
|
2053
|
-
environmentId:
|
|
2074
|
+
getTargetingRulesByConfigAndEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2075
|
+
configId: zod23.ZodString;
|
|
2076
|
+
environmentId: zod23.ZodString;
|
|
2054
2077
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2055
2078
|
configId: string;
|
|
2056
2079
|
id: string;
|
|
@@ -2064,8 +2087,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2064
2087
|
createdAt: Date;
|
|
2065
2088
|
updatedAt: Date;
|
|
2066
2089
|
}[]>;
|
|
2067
|
-
deleteTargetingRule: (params:
|
|
2068
|
-
id:
|
|
2090
|
+
deleteTargetingRule: (params: zod23.infer<zod23.ZodObject<{
|
|
2091
|
+
id: zod23.ZodString;
|
|
2069
2092
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2070
2093
|
configId: string;
|
|
2071
2094
|
id: string;
|
|
@@ -2079,8 +2102,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2079
2102
|
createdAt: Date;
|
|
2080
2103
|
updatedAt: Date;
|
|
2081
2104
|
} | undefined>;
|
|
2082
|
-
deleteTargetingRulesByConfigId: (params:
|
|
2083
|
-
configId:
|
|
2105
|
+
deleteTargetingRulesByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2106
|
+
configId: zod23.ZodString;
|
|
2084
2107
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2085
2108
|
configId: string;
|
|
2086
2109
|
id: string;
|
|
@@ -2094,8 +2117,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2094
2117
|
createdAt: Date;
|
|
2095
2118
|
updatedAt: Date;
|
|
2096
2119
|
}[]>;
|
|
2097
|
-
deleteTargetingRulesByEnvironmentId: (params:
|
|
2098
|
-
environmentId:
|
|
2120
|
+
deleteTargetingRulesByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2121
|
+
environmentId: zod23.ZodString;
|
|
2099
2122
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2100
2123
|
configId: string;
|
|
2101
2124
|
id: string;
|
|
@@ -2109,9 +2132,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2109
2132
|
createdAt: Date;
|
|
2110
2133
|
updatedAt: Date;
|
|
2111
2134
|
}[]>;
|
|
2112
|
-
listTargetingRules: (params?:
|
|
2113
|
-
limit:
|
|
2114
|
-
offset:
|
|
2135
|
+
listTargetingRules: (params?: zod23.infer<zod23.ZodObject<{
|
|
2136
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2137
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2115
2138
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2116
2139
|
configId: string;
|
|
2117
2140
|
id: string;
|
|
@@ -2125,10 +2148,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2125
2148
|
createdAt: Date;
|
|
2126
2149
|
updatedAt: Date;
|
|
2127
2150
|
}[]>;
|
|
2128
|
-
getTargetingRulesWithDetailsByConfigId: (params:
|
|
2129
|
-
configId:
|
|
2130
|
-
limit:
|
|
2131
|
-
offset:
|
|
2151
|
+
getTargetingRulesWithDetailsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2152
|
+
configId: zod23.ZodString;
|
|
2153
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2154
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2132
2155
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2133
2156
|
variantProvider: string | null;
|
|
2134
2157
|
variantModelName: string | null;
|
|
@@ -2150,11 +2173,11 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2150
2173
|
environmentName: string | null;
|
|
2151
2174
|
environmentSlug: string | null;
|
|
2152
2175
|
}[]>;
|
|
2153
|
-
setTargetingForEnvironment: (params:
|
|
2154
|
-
environmentId:
|
|
2155
|
-
configId:
|
|
2156
|
-
configVariantId:
|
|
2157
|
-
variantVersionId:
|
|
2176
|
+
setTargetingForEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2177
|
+
environmentId: zod23.ZodString;
|
|
2178
|
+
configId: zod23.ZodString;
|
|
2179
|
+
configVariantId: zod23.ZodString;
|
|
2180
|
+
variantVersionId: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodString>>;
|
|
2158
2181
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2159
2182
|
configId: string;
|
|
2160
2183
|
id: string;
|
|
@@ -2176,6 +2199,7 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2176
2199
|
variantId: string | null;
|
|
2177
2200
|
id: string;
|
|
2178
2201
|
provider: string;
|
|
2202
|
+
environmentId: string | null;
|
|
2179
2203
|
requestId: string;
|
|
2180
2204
|
model: string;
|
|
2181
2205
|
promptTokens: number;
|
|
@@ -2194,20 +2218,24 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2194
2218
|
createdAt: Date;
|
|
2195
2219
|
updatedAt: Date;
|
|
2196
2220
|
} | undefined>;
|
|
2197
|
-
listRequests: (params?:
|
|
2198
|
-
limit:
|
|
2199
|
-
offset:
|
|
2200
|
-
configId:
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2221
|
+
listRequests: (params?: zod23.infer<zod23.ZodObject<{
|
|
2222
|
+
limit: zod23.ZodDefault<zod23.ZodNumber>;
|
|
2223
|
+
offset: zod23.ZodDefault<zod23.ZodNumber>;
|
|
2224
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2225
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2226
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2227
|
+
provider: zod23.ZodOptional<zod23.ZodString>;
|
|
2228
|
+
model: zod23.ZodOptional<zod23.ZodString>;
|
|
2229
|
+
startDate: zod23.ZodOptional<zod23.ZodDate>;
|
|
2230
|
+
endDate: zod23.ZodOptional<zod23.ZodDate>;
|
|
2231
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2205
2232
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2206
2233
|
data: {
|
|
2207
2234
|
configId: string | null;
|
|
2208
2235
|
variantId: string | null;
|
|
2209
2236
|
id: string;
|
|
2210
2237
|
provider: string;
|
|
2238
|
+
environmentId: string | null;
|
|
2211
2239
|
requestId: string;
|
|
2212
2240
|
model: string;
|
|
2213
2241
|
promptTokens: number;
|
|
@@ -2235,6 +2263,7 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2235
2263
|
variantId: string | null;
|
|
2236
2264
|
id: string;
|
|
2237
2265
|
provider: string;
|
|
2266
|
+
environmentId: string | null;
|
|
2238
2267
|
requestId: string;
|
|
2239
2268
|
model: string;
|
|
2240
2269
|
promptTokens: number;
|
|
@@ -2253,9 +2282,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2253
2282
|
createdAt: Date;
|
|
2254
2283
|
updatedAt: Date;
|
|
2255
2284
|
} | undefined>;
|
|
2256
|
-
getTotalCost: (params:
|
|
2257
|
-
startDate:
|
|
2258
|
-
endDate:
|
|
2285
|
+
getTotalCost: (params: zod23.infer<zod23.ZodObject<{
|
|
2286
|
+
startDate: zod23.ZodDate;
|
|
2287
|
+
endDate: zod23.ZodDate;
|
|
2288
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2289
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2290
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2291
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2259
2292
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2260
2293
|
totalCost: number;
|
|
2261
2294
|
totalInputCost: number;
|
|
@@ -2265,9 +2298,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2265
2298
|
totalTokens: number;
|
|
2266
2299
|
requestCount: number;
|
|
2267
2300
|
} | undefined>;
|
|
2268
|
-
getCostByModel: (params:
|
|
2269
|
-
startDate:
|
|
2270
|
-
endDate:
|
|
2301
|
+
getCostByModel: (params: zod23.infer<zod23.ZodObject<{
|
|
2302
|
+
startDate: zod23.ZodDate;
|
|
2303
|
+
endDate: zod23.ZodDate;
|
|
2304
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2305
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2306
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2307
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2271
2308
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2272
2309
|
provider: string;
|
|
2273
2310
|
model: string;
|
|
@@ -2278,9 +2315,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2278
2315
|
requestCount: number;
|
|
2279
2316
|
avgLatencyMs: number;
|
|
2280
2317
|
}[]>;
|
|
2281
|
-
getCostByProvider: (params:
|
|
2282
|
-
startDate:
|
|
2283
|
-
endDate:
|
|
2318
|
+
getCostByProvider: (params: zod23.infer<zod23.ZodObject<{
|
|
2319
|
+
startDate: zod23.ZodDate;
|
|
2320
|
+
endDate: zod23.ZodDate;
|
|
2321
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2322
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2323
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2324
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2284
2325
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2285
2326
|
provider: string;
|
|
2286
2327
|
totalCost: number;
|
|
@@ -2290,9 +2331,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2290
2331
|
requestCount: number;
|
|
2291
2332
|
avgLatencyMs: number;
|
|
2292
2333
|
}[]>;
|
|
2293
|
-
getCostByConfig: (params:
|
|
2294
|
-
startDate:
|
|
2295
|
-
endDate:
|
|
2334
|
+
getCostByConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2335
|
+
startDate: zod23.ZodDate;
|
|
2336
|
+
endDate: zod23.ZodDate;
|
|
2337
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2338
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2339
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2340
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2296
2341
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2297
2342
|
configId: string | null;
|
|
2298
2343
|
totalCost: number;
|
|
@@ -2303,9 +2348,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2303
2348
|
configName: string | null | undefined;
|
|
2304
2349
|
configSlug: string | null;
|
|
2305
2350
|
}[]>;
|
|
2306
|
-
getDailyCosts: (params:
|
|
2307
|
-
startDate:
|
|
2308
|
-
endDate:
|
|
2351
|
+
getDailyCosts: (params: zod23.infer<zod23.ZodObject<{
|
|
2352
|
+
startDate: zod23.ZodDate;
|
|
2353
|
+
endDate: zod23.ZodDate;
|
|
2354
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2355
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2356
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2357
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2309
2358
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2310
2359
|
totalCost: number;
|
|
2311
2360
|
totalInputCost: number;
|
|
@@ -2314,10 +2363,14 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2314
2363
|
requestCount: number;
|
|
2315
2364
|
date: string;
|
|
2316
2365
|
}[]>;
|
|
2317
|
-
getCostSummary: (params:
|
|
2318
|
-
startDate:
|
|
2319
|
-
endDate:
|
|
2320
|
-
|
|
2366
|
+
getCostSummary: (params: zod23.infer<zod23.ZodObject<{
|
|
2367
|
+
startDate: zod23.ZodDate;
|
|
2368
|
+
endDate: zod23.ZodDate;
|
|
2369
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2370
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2371
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2372
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2373
|
+
groupBy: zod23.ZodOptional<zod23.ZodEnum<{
|
|
2321
2374
|
provider: "provider";
|
|
2322
2375
|
model: "model";
|
|
2323
2376
|
day: "day";
|
|
@@ -2329,9 +2382,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2329
2382
|
requestCount: number;
|
|
2330
2383
|
groupKey: string;
|
|
2331
2384
|
}[]>;
|
|
2332
|
-
getRequestStats: (params:
|
|
2333
|
-
startDate:
|
|
2334
|
-
endDate:
|
|
2385
|
+
getRequestStats: (params: zod23.infer<zod23.ZodObject<{
|
|
2386
|
+
startDate: zod23.ZodDate;
|
|
2387
|
+
endDate: zod23.ZodDate;
|
|
2388
|
+
configId: zod23.ZodOptional<zod23.ZodString>;
|
|
2389
|
+
variantId: zod23.ZodOptional<zod23.ZodString>;
|
|
2390
|
+
environmentId: zod23.ZodOptional<zod23.ZodString>;
|
|
2391
|
+
tags: zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodArray<zod23.ZodString>>>;
|
|
2335
2392
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2336
2393
|
avgLatencyMs: number;
|
|
2337
2394
|
totalRequests: number;
|
|
@@ -2341,10 +2398,14 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2341
2398
|
maxLatencyMs: number;
|
|
2342
2399
|
minLatencyMs: number;
|
|
2343
2400
|
} | undefined>;
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2401
|
+
getDistinctTags: () => Promise<{
|
|
2402
|
+
key: string;
|
|
2403
|
+
value: string;
|
|
2404
|
+
}[]>;
|
|
2405
|
+
createEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2406
|
+
environmentId: zod23.ZodUUID;
|
|
2407
|
+
keyName: zod23.ZodString;
|
|
2408
|
+
keyValue: zod23.ZodString;
|
|
2348
2409
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2349
2410
|
id: string;
|
|
2350
2411
|
environmentId: string;
|
|
@@ -2353,10 +2414,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2353
2414
|
createdAt: Date;
|
|
2354
2415
|
updatedAt: Date;
|
|
2355
2416
|
} | undefined>;
|
|
2356
|
-
updateEnvironmentSecret: (params:
|
|
2357
|
-
secretId:
|
|
2358
|
-
keyName:
|
|
2359
|
-
keyValue:
|
|
2417
|
+
updateEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2418
|
+
secretId: zod23.ZodUUID;
|
|
2419
|
+
keyName: zod23.ZodOptional<zod23.ZodString>;
|
|
2420
|
+
keyValue: zod23.ZodOptional<zod23.ZodString>;
|
|
2360
2421
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2361
2422
|
id: string;
|
|
2362
2423
|
environmentId: string;
|
|
@@ -2365,8 +2426,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2365
2426
|
createdAt: Date;
|
|
2366
2427
|
updatedAt: Date;
|
|
2367
2428
|
} | undefined>;
|
|
2368
|
-
getEnvironmentSecretById: (params:
|
|
2369
|
-
secretId:
|
|
2429
|
+
getEnvironmentSecretById: (params: zod23.infer<zod23.ZodObject<{
|
|
2430
|
+
secretId: zod23.ZodUUID;
|
|
2370
2431
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2371
2432
|
id: string;
|
|
2372
2433
|
environmentId: string;
|
|
@@ -2375,8 +2436,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2375
2436
|
createdAt: Date;
|
|
2376
2437
|
updatedAt: Date;
|
|
2377
2438
|
} | undefined>;
|
|
2378
|
-
getSecretsByEnvironmentId: (params:
|
|
2379
|
-
environmentId:
|
|
2439
|
+
getSecretsByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2440
|
+
environmentId: zod23.ZodUUID;
|
|
2380
2441
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2381
2442
|
id: string;
|
|
2382
2443
|
environmentId: string;
|
|
@@ -2385,8 +2446,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2385
2446
|
createdAt: Date;
|
|
2386
2447
|
updatedAt: Date;
|
|
2387
2448
|
}[]>;
|
|
2388
|
-
deleteEnvironmentSecret: (params:
|
|
2389
|
-
secretId:
|
|
2449
|
+
deleteEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2450
|
+
secretId: zod23.ZodUUID;
|
|
2390
2451
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2391
2452
|
id: string;
|
|
2392
2453
|
environmentId: string;
|
|
@@ -2395,8 +2456,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2395
2456
|
createdAt: Date;
|
|
2396
2457
|
updatedAt: Date;
|
|
2397
2458
|
} | undefined>;
|
|
2398
|
-
deleteSecretsByEnvironmentId: (params:
|
|
2399
|
-
environmentId:
|
|
2459
|
+
deleteSecretsByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2460
|
+
environmentId: zod23.ZodUUID;
|
|
2400
2461
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2401
2462
|
id: string;
|
|
2402
2463
|
environmentId: string;
|
|
@@ -2405,9 +2466,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2405
2466
|
createdAt: Date;
|
|
2406
2467
|
updatedAt: Date;
|
|
2407
2468
|
}[]>;
|
|
2408
|
-
listEnvironmentSecrets: (params?:
|
|
2409
|
-
limit:
|
|
2410
|
-
offset:
|
|
2469
|
+
listEnvironmentSecrets: (params?: zod23.infer<zod23.ZodObject<{
|
|
2470
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2471
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2411
2472
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2412
2473
|
id: string;
|
|
2413
2474
|
environmentId: string;
|
|
@@ -2417,10 +2478,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2417
2478
|
updatedAt: Date;
|
|
2418
2479
|
}[]>;
|
|
2419
2480
|
countEnvironmentSecrets: () => Promise<number>;
|
|
2420
|
-
createNewEnvironment: (params:
|
|
2421
|
-
name:
|
|
2422
|
-
slug:
|
|
2423
|
-
isProd:
|
|
2481
|
+
createNewEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2482
|
+
name: zod23.ZodString;
|
|
2483
|
+
slug: zod23.ZodString;
|
|
2484
|
+
isProd: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodBoolean>>;
|
|
2424
2485
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2425
2486
|
name: string;
|
|
2426
2487
|
id: string;
|
|
@@ -2429,10 +2490,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2429
2490
|
createdAt: Date;
|
|
2430
2491
|
updatedAt: Date;
|
|
2431
2492
|
} | undefined>;
|
|
2432
|
-
updateEnvironment: (params:
|
|
2433
|
-
environmentId:
|
|
2434
|
-
name:
|
|
2435
|
-
slug:
|
|
2493
|
+
updateEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2494
|
+
environmentId: zod23.ZodUUID;
|
|
2495
|
+
name: zod23.ZodOptional<zod23.ZodString>;
|
|
2496
|
+
slug: zod23.ZodOptional<zod23.ZodString>;
|
|
2436
2497
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2437
2498
|
name: string;
|
|
2438
2499
|
id: string;
|
|
@@ -2441,8 +2502,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2441
2502
|
createdAt: Date;
|
|
2442
2503
|
updatedAt: Date;
|
|
2443
2504
|
} | undefined>;
|
|
2444
|
-
getEnvironmentById: (params:
|
|
2445
|
-
environmentId:
|
|
2505
|
+
getEnvironmentById: (params: zod23.infer<zod23.ZodObject<{
|
|
2506
|
+
environmentId: zod23.ZodUUID;
|
|
2446
2507
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2447
2508
|
name: string;
|
|
2448
2509
|
id: string;
|
|
@@ -2451,8 +2512,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2451
2512
|
createdAt: Date;
|
|
2452
2513
|
updatedAt: Date;
|
|
2453
2514
|
} | undefined>;
|
|
2454
|
-
getEnvironmentBySlug: (params:
|
|
2455
|
-
slug:
|
|
2515
|
+
getEnvironmentBySlug: (params: zod23.infer<zod23.ZodObject<{
|
|
2516
|
+
slug: zod23.ZodString;
|
|
2456
2517
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2457
2518
|
name: string;
|
|
2458
2519
|
id: string;
|
|
@@ -2461,8 +2522,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2461
2522
|
createdAt: Date;
|
|
2462
2523
|
updatedAt: Date;
|
|
2463
2524
|
} | undefined>;
|
|
2464
|
-
deleteEnvironment: (params:
|
|
2465
|
-
environmentId:
|
|
2525
|
+
deleteEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2526
|
+
environmentId: zod23.ZodUUID;
|
|
2466
2527
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2467
2528
|
name: string;
|
|
2468
2529
|
id: string;
|
|
@@ -2471,9 +2532,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2471
2532
|
createdAt: Date;
|
|
2472
2533
|
updatedAt: Date;
|
|
2473
2534
|
} | undefined>;
|
|
2474
|
-
listEnvironments: (params?:
|
|
2475
|
-
limit:
|
|
2476
|
-
offset:
|
|
2535
|
+
listEnvironments: (params?: zod23.infer<zod23.ZodObject<{
|
|
2536
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2537
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2477
2538
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2478
2539
|
name: string;
|
|
2479
2540
|
id: string;
|
|
@@ -2483,9 +2544,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2483
2544
|
updatedAt: Date;
|
|
2484
2545
|
}[]>;
|
|
2485
2546
|
countEnvironments: () => Promise<number>;
|
|
2486
|
-
createConfigVariant: (params:
|
|
2487
|
-
configId:
|
|
2488
|
-
variantId:
|
|
2547
|
+
createConfigVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
2548
|
+
configId: zod23.ZodString;
|
|
2549
|
+
variantId: zod23.ZodString;
|
|
2489
2550
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2490
2551
|
configId: string;
|
|
2491
2552
|
variantId: string;
|
|
@@ -2493,8 +2554,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2493
2554
|
createdAt: Date;
|
|
2494
2555
|
updatedAt: Date;
|
|
2495
2556
|
} | undefined>;
|
|
2496
|
-
getConfigVariantById: (params:
|
|
2497
|
-
id:
|
|
2557
|
+
getConfigVariantById: (params: zod23.infer<zod23.ZodObject<{
|
|
2558
|
+
id: zod23.ZodString;
|
|
2498
2559
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2499
2560
|
configId: string;
|
|
2500
2561
|
variantId: string;
|
|
@@ -2502,10 +2563,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2502
2563
|
createdAt: Date;
|
|
2503
2564
|
updatedAt: Date;
|
|
2504
2565
|
} | undefined>;
|
|
2505
|
-
getConfigVariantsByConfigId: (params:
|
|
2506
|
-
configId:
|
|
2507
|
-
limit:
|
|
2508
|
-
offset:
|
|
2566
|
+
getConfigVariantsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2567
|
+
configId: zod23.ZodString;
|
|
2568
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2569
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2509
2570
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2510
2571
|
configId: string;
|
|
2511
2572
|
variantId: string;
|
|
@@ -2513,10 +2574,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2513
2574
|
createdAt: Date;
|
|
2514
2575
|
updatedAt: Date;
|
|
2515
2576
|
}[]>;
|
|
2516
|
-
getConfigVariantsByVariantId: (params:
|
|
2517
|
-
variantId:
|
|
2518
|
-
limit:
|
|
2519
|
-
offset:
|
|
2577
|
+
getConfigVariantsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
2578
|
+
variantId: zod23.ZodString;
|
|
2579
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2580
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2520
2581
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2521
2582
|
configId: string;
|
|
2522
2583
|
variantId: string;
|
|
@@ -2524,8 +2585,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2524
2585
|
createdAt: Date;
|
|
2525
2586
|
updatedAt: Date;
|
|
2526
2587
|
}[]>;
|
|
2527
|
-
deleteConfigVariant: (params:
|
|
2528
|
-
id:
|
|
2588
|
+
deleteConfigVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
2589
|
+
id: zod23.ZodString;
|
|
2529
2590
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2530
2591
|
configId: string;
|
|
2531
2592
|
variantId: string;
|
|
@@ -2533,9 +2594,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2533
2594
|
createdAt: Date;
|
|
2534
2595
|
updatedAt: Date;
|
|
2535
2596
|
} | undefined>;
|
|
2536
|
-
deleteConfigVariantByIds: (params:
|
|
2537
|
-
configId:
|
|
2538
|
-
variantId:
|
|
2597
|
+
deleteConfigVariantByIds: (params: zod23.infer<zod23.ZodObject<{
|
|
2598
|
+
configId: zod23.ZodString;
|
|
2599
|
+
variantId: zod23.ZodString;
|
|
2539
2600
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2540
2601
|
configId: string;
|
|
2541
2602
|
variantId: string;
|
|
@@ -2543,9 +2604,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2543
2604
|
createdAt: Date;
|
|
2544
2605
|
updatedAt: Date;
|
|
2545
2606
|
} | undefined>;
|
|
2546
|
-
listConfigVariants: (params?:
|
|
2547
|
-
limit:
|
|
2548
|
-
offset:
|
|
2607
|
+
listConfigVariants: (params?: zod23.infer<zod23.ZodObject<{
|
|
2608
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2609
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2549
2610
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2550
2611
|
configId: string;
|
|
2551
2612
|
variantId: string;
|
|
@@ -2553,8 +2614,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2553
2614
|
createdAt: Date;
|
|
2554
2615
|
updatedAt: Date;
|
|
2555
2616
|
}[]>;
|
|
2556
|
-
getConfigVariantWithDetails: (params:
|
|
2557
|
-
id:
|
|
2617
|
+
getConfigVariantWithDetails: (params: zod23.infer<zod23.ZodObject<{
|
|
2618
|
+
id: zod23.ZodString;
|
|
2558
2619
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2559
2620
|
latestVersion: {
|
|
2560
2621
|
version: number;
|
|
@@ -2574,10 +2635,10 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2574
2635
|
updatedAt: Date;
|
|
2575
2636
|
configName: string | null | undefined;
|
|
2576
2637
|
} | undefined>;
|
|
2577
|
-
getConfigVariantsWithDetailsByConfigId: (params:
|
|
2578
|
-
configId:
|
|
2579
|
-
limit:
|
|
2580
|
-
offset:
|
|
2638
|
+
getConfigVariantsWithDetailsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2639
|
+
configId: zod23.ZodString;
|
|
2640
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2641
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2581
2642
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2582
2643
|
provider: string | null;
|
|
2583
2644
|
modelName: string | null;
|
|
@@ -2599,12 +2660,12 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2599
2660
|
createdAt: Date;
|
|
2600
2661
|
updatedAt: Date;
|
|
2601
2662
|
}[]>;
|
|
2602
|
-
createVariantAndLinkToConfig: (params:
|
|
2603
|
-
configId:
|
|
2604
|
-
name:
|
|
2605
|
-
provider:
|
|
2606
|
-
modelName:
|
|
2607
|
-
jsonData:
|
|
2663
|
+
createVariantAndLinkToConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2664
|
+
configId: zod23.ZodString;
|
|
2665
|
+
name: zod23.ZodString;
|
|
2666
|
+
provider: zod23.ZodString;
|
|
2667
|
+
modelName: zod23.ZodString;
|
|
2668
|
+
jsonData: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodRecord<zod23.ZodString, zod23.ZodUnknown>>>;
|
|
2608
2669
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2609
2670
|
variant: {
|
|
2610
2671
|
name: string;
|
|
@@ -2630,19 +2691,20 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2630
2691
|
updatedAt: Date;
|
|
2631
2692
|
};
|
|
2632
2693
|
}>;
|
|
2633
|
-
getVariantJsonDataForConfig: (params:
|
|
2634
|
-
configId:
|
|
2635
|
-
envSecret:
|
|
2694
|
+
getVariantJsonDataForConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2695
|
+
configId: zod23.ZodString;
|
|
2696
|
+
envSecret: zod23.ZodOptional<zod23.ZodString>;
|
|
2636
2697
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2637
2698
|
configId: string;
|
|
2638
2699
|
variantId: string;
|
|
2700
|
+
environmentId: string;
|
|
2639
2701
|
version: number;
|
|
2640
2702
|
provider: string;
|
|
2641
2703
|
modelName: string;
|
|
2642
2704
|
jsonData: Record<string, unknown>;
|
|
2643
2705
|
}>;
|
|
2644
|
-
createNewConfig: (params:
|
|
2645
|
-
name:
|
|
2706
|
+
createNewConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2707
|
+
name: zod23.ZodString;
|
|
2646
2708
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2647
2709
|
name: string | undefined;
|
|
2648
2710
|
id: string;
|
|
@@ -2650,9 +2712,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2650
2712
|
createdAt: Date;
|
|
2651
2713
|
updatedAt: Date;
|
|
2652
2714
|
} | undefined>;
|
|
2653
|
-
updateConfigName: (params:
|
|
2654
|
-
configId:
|
|
2655
|
-
newName:
|
|
2715
|
+
updateConfigName: (params: zod23.infer<zod23.ZodObject<{
|
|
2716
|
+
configId: zod23.ZodUUID;
|
|
2717
|
+
newName: zod23.ZodString;
|
|
2656
2718
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2657
2719
|
name: string | undefined;
|
|
2658
2720
|
id: string;
|
|
@@ -2660,8 +2722,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2660
2722
|
createdAt: Date;
|
|
2661
2723
|
updatedAt: Date;
|
|
2662
2724
|
} | undefined>;
|
|
2663
|
-
getConfigById: (params:
|
|
2664
|
-
configId:
|
|
2725
|
+
getConfigById: (params: zod23.infer<zod23.ZodObject<{
|
|
2726
|
+
configId: zod23.ZodUUID;
|
|
2665
2727
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2666
2728
|
name: string | undefined;
|
|
2667
2729
|
id: string;
|
|
@@ -2669,8 +2731,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2669
2731
|
createdAt: Date;
|
|
2670
2732
|
updatedAt: Date;
|
|
2671
2733
|
} | undefined>;
|
|
2672
|
-
deleteConfig: (params:
|
|
2673
|
-
configId:
|
|
2734
|
+
deleteConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2735
|
+
configId: zod23.ZodUUID;
|
|
2674
2736
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2675
2737
|
name: string | undefined;
|
|
2676
2738
|
id: string;
|
|
@@ -2678,9 +2740,9 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2678
2740
|
createdAt: Date;
|
|
2679
2741
|
updatedAt: Date;
|
|
2680
2742
|
} | undefined>;
|
|
2681
|
-
listConfigs: (params?:
|
|
2682
|
-
limit:
|
|
2683
|
-
offset:
|
|
2743
|
+
listConfigs: (params?: zod23.infer<zod23.ZodObject<{
|
|
2744
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2745
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2684
2746
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2685
2747
|
name: string | undefined;
|
|
2686
2748
|
id: string;
|
|
@@ -2688,8 +2750,8 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2688
2750
|
createdAt: Date;
|
|
2689
2751
|
updatedAt: Date;
|
|
2690
2752
|
}[]>;
|
|
2691
|
-
getConfigWithVariants: (params:
|
|
2692
|
-
configId:
|
|
2753
|
+
getConfigWithVariants: (params: zod23.infer<zod23.ZodObject<{
|
|
2754
|
+
configId: zod23.ZodUUID;
|
|
2693
2755
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2694
2756
|
provider: string | null;
|
|
2695
2757
|
modelName: string | null;
|