@llmops/core 0.1.6-beta.1 → 0.1.7
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/db/index.d.cts +1 -1
- package/dist/db/index.d.mts +1 -1
- package/dist/{index-CCfvTBvD.d.cts → index-CzGmPK4Q.d.mts} +25 -25
- package/dist/{index-fgiyw393.d.mts → index-dC_m_WTU.d.cts} +25 -25
- package/dist/index.d.cts +395 -395
- package/dist/index.d.mts +395 -395
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
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-dC_m_WTU.cjs";
|
|
2
2
|
import { Kysely } from "kysely";
|
|
3
|
-
import * as
|
|
3
|
+
import * as zod23 from "zod";
|
|
4
4
|
import z$1, { z } from "zod";
|
|
5
5
|
import gateway from "@llmops/gateway";
|
|
6
6
|
import pino from "pino";
|
|
@@ -1593,11 +1593,13 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1593
1593
|
* Insert a single LLM request log
|
|
1594
1594
|
*/
|
|
1595
1595
|
insertRequest: (request: LLMRequestInsert) => Promise<{
|
|
1596
|
-
configId: string | null;
|
|
1597
|
-
variantId: string | null;
|
|
1598
1596
|
id: string;
|
|
1597
|
+
createdAt: Date;
|
|
1598
|
+
updatedAt: Date;
|
|
1599
|
+
variantId: string | null;
|
|
1599
1600
|
provider: string;
|
|
1600
1601
|
environmentId: string | null;
|
|
1602
|
+
configId: string | null;
|
|
1601
1603
|
requestId: string;
|
|
1602
1604
|
model: string;
|
|
1603
1605
|
promptTokens: number;
|
|
@@ -1613,8 +1615,6 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1613
1615
|
isStreaming: boolean;
|
|
1614
1616
|
userId: string | null;
|
|
1615
1617
|
tags: Record<string, string>;
|
|
1616
|
-
createdAt: Date;
|
|
1617
|
-
updatedAt: Date;
|
|
1618
1618
|
} | undefined>;
|
|
1619
1619
|
/**
|
|
1620
1620
|
* List LLM requests with filtering and pagination
|
|
@@ -1622,11 +1622,13 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1622
1622
|
*/
|
|
1623
1623
|
listRequests: (params?: z$1.infer<typeof listRequestsSchema>) => Promise<{
|
|
1624
1624
|
data: {
|
|
1625
|
-
configId: string | null;
|
|
1626
|
-
variantId: string | null;
|
|
1627
1625
|
id: string;
|
|
1626
|
+
createdAt: Date;
|
|
1627
|
+
updatedAt: Date;
|
|
1628
|
+
variantId: string | null;
|
|
1628
1629
|
provider: string;
|
|
1629
1630
|
environmentId: string | null;
|
|
1631
|
+
configId: string | null;
|
|
1630
1632
|
requestId: string;
|
|
1631
1633
|
model: string;
|
|
1632
1634
|
promptTokens: number;
|
|
@@ -1642,8 +1644,6 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1642
1644
|
isStreaming: boolean;
|
|
1643
1645
|
userId: string | null;
|
|
1644
1646
|
tags: Record<string, string>;
|
|
1645
|
-
createdAt: Date;
|
|
1646
|
-
updatedAt: Date;
|
|
1647
1647
|
}[];
|
|
1648
1648
|
total: number;
|
|
1649
1649
|
limit: number;
|
|
@@ -1653,11 +1653,13 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1653
1653
|
* Get a single request by requestId
|
|
1654
1654
|
*/
|
|
1655
1655
|
getRequestByRequestId: (requestId: string) => Promise<{
|
|
1656
|
-
configId: string | null;
|
|
1657
|
-
variantId: string | null;
|
|
1658
1656
|
id: string;
|
|
1657
|
+
createdAt: Date;
|
|
1658
|
+
updatedAt: Date;
|
|
1659
|
+
variantId: string | null;
|
|
1659
1660
|
provider: string;
|
|
1660
1661
|
environmentId: string | null;
|
|
1662
|
+
configId: string | null;
|
|
1661
1663
|
requestId: string;
|
|
1662
1664
|
model: string;
|
|
1663
1665
|
promptTokens: number;
|
|
@@ -1673,8 +1675,6 @@ declare const createLLMRequestsDataLayer: (db: Kysely<Database>) => {
|
|
|
1673
1675
|
isStreaming: boolean;
|
|
1674
1676
|
userId: string | null;
|
|
1675
1677
|
tags: Record<string, string>;
|
|
1676
|
-
createdAt: Date;
|
|
1677
|
-
updatedAt: Date;
|
|
1678
1678
|
} | undefined>;
|
|
1679
1679
|
/**
|
|
1680
1680
|
* Get total cost for a date range with optional filters
|
|
@@ -1775,431 +1775,433 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
1775
1775
|
createdAt: Date;
|
|
1776
1776
|
updatedAt: Date;
|
|
1777
1777
|
} | undefined>;
|
|
1778
|
-
updateWorkspaceSettings: (params:
|
|
1779
|
-
name:
|
|
1778
|
+
updateWorkspaceSettings: (params: zod23.infer<zod23.ZodObject<{
|
|
1779
|
+
name: zod23.ZodOptional<zod23.ZodNullable<zod23.ZodString>>;
|
|
1780
1780
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1781
1781
|
name: string | null;
|
|
1782
1782
|
id: string;
|
|
1783
1783
|
createdAt: Date;
|
|
1784
1784
|
updatedAt: Date;
|
|
1785
1785
|
} | undefined>;
|
|
1786
|
-
createVariantVersion: (params:
|
|
1787
|
-
variantId:
|
|
1788
|
-
provider:
|
|
1789
|
-
modelName:
|
|
1790
|
-
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>>>;
|
|
1791
1791
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1792
1792
|
version: number;
|
|
1793
|
-
variantId: string;
|
|
1794
1793
|
id: string;
|
|
1794
|
+
createdAt: Date;
|
|
1795
|
+
updatedAt: Date;
|
|
1796
|
+
variantId: string;
|
|
1795
1797
|
provider: string;
|
|
1796
1798
|
modelName: string;
|
|
1797
1799
|
jsonData: Record<string, unknown>;
|
|
1798
|
-
createdAt: Date;
|
|
1799
|
-
updatedAt: Date;
|
|
1800
1800
|
} | undefined>;
|
|
1801
|
-
getVariantVersionById: (params:
|
|
1802
|
-
id:
|
|
1801
|
+
getVariantVersionById: (params: zod23.infer<zod23.ZodObject<{
|
|
1802
|
+
id: zod23.ZodString;
|
|
1803
1803
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1804
1804
|
version: number;
|
|
1805
|
-
variantId: string;
|
|
1806
1805
|
id: string;
|
|
1806
|
+
createdAt: Date;
|
|
1807
|
+
updatedAt: Date;
|
|
1808
|
+
variantId: string;
|
|
1807
1809
|
provider: string;
|
|
1808
1810
|
modelName: string;
|
|
1809
1811
|
jsonData: Record<string, unknown>;
|
|
1810
|
-
createdAt: Date;
|
|
1811
|
-
updatedAt: Date;
|
|
1812
1812
|
} | undefined>;
|
|
1813
|
-
getVariantVersionsByVariantId: (params:
|
|
1814
|
-
variantId:
|
|
1815
|
-
limit:
|
|
1816
|
-
offset:
|
|
1813
|
+
getVariantVersionsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1814
|
+
variantId: zod23.ZodString;
|
|
1815
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1816
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1817
1817
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1818
1818
|
version: number;
|
|
1819
|
-
variantId: string;
|
|
1820
1819
|
id: string;
|
|
1820
|
+
createdAt: Date;
|
|
1821
|
+
updatedAt: Date;
|
|
1822
|
+
variantId: string;
|
|
1821
1823
|
provider: string;
|
|
1822
1824
|
modelName: string;
|
|
1823
1825
|
jsonData: Record<string, unknown>;
|
|
1824
|
-
createdAt: Date;
|
|
1825
|
-
updatedAt: Date;
|
|
1826
1826
|
}[]>;
|
|
1827
|
-
getLatestVariantVersion: (params:
|
|
1828
|
-
variantId:
|
|
1827
|
+
getLatestVariantVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1828
|
+
variantId: zod23.ZodString;
|
|
1829
1829
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1830
1830
|
version: number;
|
|
1831
|
-
variantId: string;
|
|
1832
1831
|
id: string;
|
|
1832
|
+
createdAt: Date;
|
|
1833
|
+
updatedAt: Date;
|
|
1834
|
+
variantId: string;
|
|
1833
1835
|
provider: string;
|
|
1834
1836
|
modelName: string;
|
|
1835
1837
|
jsonData: Record<string, unknown>;
|
|
1836
|
-
createdAt: Date;
|
|
1837
|
-
updatedAt: Date;
|
|
1838
1838
|
} | undefined>;
|
|
1839
|
-
getVariantVersionByNumber: (params:
|
|
1840
|
-
variantId:
|
|
1841
|
-
version:
|
|
1839
|
+
getVariantVersionByNumber: (params: zod23.infer<zod23.ZodObject<{
|
|
1840
|
+
variantId: zod23.ZodString;
|
|
1841
|
+
version: zod23.ZodNumber;
|
|
1842
1842
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1843
1843
|
version: number;
|
|
1844
|
-
variantId: string;
|
|
1845
1844
|
id: string;
|
|
1845
|
+
createdAt: Date;
|
|
1846
|
+
updatedAt: Date;
|
|
1847
|
+
variantId: string;
|
|
1846
1848
|
provider: string;
|
|
1847
1849
|
modelName: string;
|
|
1848
1850
|
jsonData: Record<string, unknown>;
|
|
1849
|
-
createdAt: Date;
|
|
1850
|
-
updatedAt: Date;
|
|
1851
1851
|
} | undefined>;
|
|
1852
|
-
deleteVariantVersion: (params:
|
|
1853
|
-
id:
|
|
1852
|
+
deleteVariantVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1853
|
+
id: zod23.ZodString;
|
|
1854
1854
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1855
1855
|
version: number;
|
|
1856
|
-
variantId: string;
|
|
1857
1856
|
id: string;
|
|
1857
|
+
createdAt: Date;
|
|
1858
|
+
updatedAt: Date;
|
|
1859
|
+
variantId: string;
|
|
1858
1860
|
provider: string;
|
|
1859
1861
|
modelName: string;
|
|
1860
1862
|
jsonData: Record<string, unknown>;
|
|
1861
|
-
createdAt: Date;
|
|
1862
|
-
updatedAt: Date;
|
|
1863
1863
|
} | undefined>;
|
|
1864
|
-
deleteVariantVersionsByVariantId: (params:
|
|
1865
|
-
variantId:
|
|
1864
|
+
deleteVariantVersionsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1865
|
+
variantId: zod23.ZodString;
|
|
1866
1866
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1867
1867
|
version: number;
|
|
1868
|
-
variantId: string;
|
|
1869
1868
|
id: string;
|
|
1869
|
+
createdAt: Date;
|
|
1870
|
+
updatedAt: Date;
|
|
1871
|
+
variantId: string;
|
|
1870
1872
|
provider: string;
|
|
1871
1873
|
modelName: string;
|
|
1872
1874
|
jsonData: Record<string, unknown>;
|
|
1873
|
-
createdAt: Date;
|
|
1874
|
-
updatedAt: Date;
|
|
1875
1875
|
}[]>;
|
|
1876
|
-
getVariantVersionWithVariant: (params:
|
|
1877
|
-
id:
|
|
1876
|
+
getVariantVersionWithVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1877
|
+
id: zod23.ZodString;
|
|
1878
1878
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1879
1879
|
version: number;
|
|
1880
|
-
variantId: string;
|
|
1881
1880
|
id: string;
|
|
1881
|
+
createdAt: Date;
|
|
1882
|
+
updatedAt: Date;
|
|
1883
|
+
variantId: string;
|
|
1882
1884
|
provider: string;
|
|
1883
1885
|
modelName: string;
|
|
1884
1886
|
jsonData: Record<string, unknown>;
|
|
1885
|
-
createdAt: Date;
|
|
1886
|
-
updatedAt: Date;
|
|
1887
1887
|
variantName: string;
|
|
1888
1888
|
} | undefined>;
|
|
1889
|
-
getVariantVersionsWithVariantByVariantId: (params:
|
|
1890
|
-
variantId:
|
|
1891
|
-
limit:
|
|
1892
|
-
offset:
|
|
1889
|
+
getVariantVersionsWithVariantByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
1890
|
+
variantId: zod23.ZodString;
|
|
1891
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1892
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1893
1893
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1894
1894
|
version: number;
|
|
1895
|
-
variantId: string;
|
|
1896
1895
|
id: string;
|
|
1896
|
+
createdAt: Date;
|
|
1897
|
+
updatedAt: Date;
|
|
1898
|
+
variantId: string;
|
|
1897
1899
|
provider: string;
|
|
1898
1900
|
modelName: string;
|
|
1899
1901
|
jsonData: Record<string, unknown>;
|
|
1900
|
-
createdAt: Date;
|
|
1901
|
-
updatedAt: Date;
|
|
1902
1902
|
variantName: string;
|
|
1903
1903
|
}[]>;
|
|
1904
|
-
createVariant: (params:
|
|
1905
|
-
name:
|
|
1904
|
+
createVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1905
|
+
name: zod23.ZodString;
|
|
1906
1906
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1907
1907
|
name: string;
|
|
1908
1908
|
id: string;
|
|
1909
1909
|
createdAt: Date;
|
|
1910
1910
|
updatedAt: Date;
|
|
1911
1911
|
} | undefined>;
|
|
1912
|
-
updateVariant: (params:
|
|
1913
|
-
variantId:
|
|
1914
|
-
name:
|
|
1912
|
+
updateVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1913
|
+
variantId: zod23.ZodString;
|
|
1914
|
+
name: zod23.ZodOptional<zod23.ZodString>;
|
|
1915
1915
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1916
1916
|
name: string;
|
|
1917
1917
|
id: string;
|
|
1918
1918
|
createdAt: Date;
|
|
1919
1919
|
updatedAt: Date;
|
|
1920
1920
|
} | undefined>;
|
|
1921
|
-
getVariantById: (params:
|
|
1922
|
-
variantId:
|
|
1921
|
+
getVariantById: (params: zod23.infer<zod23.ZodObject<{
|
|
1922
|
+
variantId: zod23.ZodString;
|
|
1923
1923
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1924
1924
|
name: string;
|
|
1925
1925
|
id: string;
|
|
1926
1926
|
createdAt: Date;
|
|
1927
1927
|
updatedAt: Date;
|
|
1928
1928
|
} | undefined>;
|
|
1929
|
-
getVariantWithLatestVersion: (params:
|
|
1930
|
-
variantId:
|
|
1929
|
+
getVariantWithLatestVersion: (params: zod23.infer<zod23.ZodObject<{
|
|
1930
|
+
variantId: zod23.ZodString;
|
|
1931
1931
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1932
1932
|
latestVersion: {
|
|
1933
1933
|
version: number;
|
|
1934
|
-
variantId: string;
|
|
1935
1934
|
id: string;
|
|
1935
|
+
createdAt: Date;
|
|
1936
|
+
updatedAt: Date;
|
|
1937
|
+
variantId: string;
|
|
1936
1938
|
provider: string;
|
|
1937
1939
|
modelName: string;
|
|
1938
1940
|
jsonData: Record<string, unknown>;
|
|
1939
|
-
createdAt: Date;
|
|
1940
|
-
updatedAt: Date;
|
|
1941
1941
|
} | null;
|
|
1942
1942
|
name: string;
|
|
1943
1943
|
id: string;
|
|
1944
1944
|
createdAt: Date;
|
|
1945
1945
|
updatedAt: Date;
|
|
1946
1946
|
} | undefined>;
|
|
1947
|
-
deleteVariant: (params:
|
|
1948
|
-
variantId:
|
|
1947
|
+
deleteVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
1948
|
+
variantId: zod23.ZodString;
|
|
1949
1949
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1950
1950
|
name: string;
|
|
1951
1951
|
id: string;
|
|
1952
1952
|
createdAt: Date;
|
|
1953
1953
|
updatedAt: Date;
|
|
1954
1954
|
} | undefined>;
|
|
1955
|
-
listVariants: (params?:
|
|
1956
|
-
limit:
|
|
1957
|
-
offset:
|
|
1955
|
+
listVariants: (params?: zod23.infer<zod23.ZodObject<{
|
|
1956
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1957
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1958
1958
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1959
1959
|
name: string;
|
|
1960
1960
|
id: string;
|
|
1961
1961
|
createdAt: Date;
|
|
1962
1962
|
updatedAt: Date;
|
|
1963
1963
|
}[]>;
|
|
1964
|
-
listVariantsWithLatestVersion: (params?:
|
|
1965
|
-
limit:
|
|
1966
|
-
offset:
|
|
1964
|
+
listVariantsWithLatestVersion: (params?: zod23.infer<zod23.ZodObject<{
|
|
1965
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1966
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
1967
1967
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1968
1968
|
latestVersion: {
|
|
1969
1969
|
version: number;
|
|
1970
|
-
variantId: string;
|
|
1971
1970
|
id: string;
|
|
1971
|
+
createdAt: Date;
|
|
1972
|
+
updatedAt: Date;
|
|
1973
|
+
variantId: string;
|
|
1972
1974
|
provider: string;
|
|
1973
1975
|
modelName: string;
|
|
1974
1976
|
jsonData: Record<string, unknown>;
|
|
1975
|
-
createdAt: Date;
|
|
1976
|
-
updatedAt: Date;
|
|
1977
1977
|
} | null;
|
|
1978
1978
|
name: string;
|
|
1979
1979
|
id: string;
|
|
1980
1980
|
createdAt: Date;
|
|
1981
1981
|
updatedAt: Date;
|
|
1982
1982
|
}[]>;
|
|
1983
|
-
createTargetingRule: (params:
|
|
1984
|
-
environmentId:
|
|
1985
|
-
configId:
|
|
1986
|
-
configVariantId:
|
|
1987
|
-
variantVersionId:
|
|
1988
|
-
weight:
|
|
1989
|
-
priority:
|
|
1990
|
-
enabled:
|
|
1991
|
-
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>>>;
|
|
1992
1992
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
1993
|
-
configId: string;
|
|
1994
1993
|
id: string;
|
|
1994
|
+
createdAt: Date;
|
|
1995
|
+
updatedAt: Date;
|
|
1995
1996
|
environmentId: string;
|
|
1997
|
+
configId: string;
|
|
1996
1998
|
configVariantId: string;
|
|
1997
1999
|
variantVersionId: string | null;
|
|
1998
2000
|
weight: number;
|
|
1999
2001
|
priority: number;
|
|
2000
2002
|
enabled: boolean;
|
|
2001
2003
|
conditions: Record<string, unknown>;
|
|
2002
|
-
createdAt: Date;
|
|
2003
|
-
updatedAt: Date;
|
|
2004
2004
|
} | undefined>;
|
|
2005
|
-
updateTargetingRule: (params:
|
|
2006
|
-
id:
|
|
2007
|
-
variantVersionId:
|
|
2008
|
-
weight:
|
|
2009
|
-
priority:
|
|
2010
|
-
enabled:
|
|
2011
|
-
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>>>;
|
|
2012
2012
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2013
|
-
configId: string;
|
|
2014
2013
|
id: string;
|
|
2014
|
+
createdAt: Date;
|
|
2015
|
+
updatedAt: Date;
|
|
2015
2016
|
environmentId: string;
|
|
2017
|
+
configId: string;
|
|
2016
2018
|
configVariantId: string;
|
|
2017
2019
|
variantVersionId: string | null;
|
|
2018
2020
|
weight: number;
|
|
2019
2021
|
priority: number;
|
|
2020
2022
|
enabled: boolean;
|
|
2021
2023
|
conditions: Record<string, unknown>;
|
|
2022
|
-
createdAt: Date;
|
|
2023
|
-
updatedAt: Date;
|
|
2024
2024
|
} | undefined>;
|
|
2025
|
-
getTargetingRuleById: (params:
|
|
2026
|
-
id:
|
|
2025
|
+
getTargetingRuleById: (params: zod23.infer<zod23.ZodObject<{
|
|
2026
|
+
id: zod23.ZodString;
|
|
2027
2027
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2028
|
-
configId: string;
|
|
2029
2028
|
id: string;
|
|
2029
|
+
createdAt: Date;
|
|
2030
|
+
updatedAt: Date;
|
|
2030
2031
|
environmentId: string;
|
|
2032
|
+
configId: string;
|
|
2031
2033
|
configVariantId: string;
|
|
2032
2034
|
variantVersionId: string | null;
|
|
2033
2035
|
weight: number;
|
|
2034
2036
|
priority: number;
|
|
2035
2037
|
enabled: boolean;
|
|
2036
2038
|
conditions: Record<string, unknown>;
|
|
2037
|
-
createdAt: Date;
|
|
2038
|
-
updatedAt: Date;
|
|
2039
2039
|
} | undefined>;
|
|
2040
|
-
getTargetingRulesByConfigId: (params:
|
|
2041
|
-
configId:
|
|
2042
|
-
limit:
|
|
2043
|
-
offset:
|
|
2040
|
+
getTargetingRulesByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2041
|
+
configId: zod23.ZodString;
|
|
2042
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2043
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2044
2044
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2045
|
-
configId: string;
|
|
2046
2045
|
id: string;
|
|
2046
|
+
createdAt: Date;
|
|
2047
|
+
updatedAt: Date;
|
|
2047
2048
|
environmentId: string;
|
|
2049
|
+
configId: string;
|
|
2048
2050
|
configVariantId: string;
|
|
2049
2051
|
variantVersionId: string | null;
|
|
2050
2052
|
weight: number;
|
|
2051
2053
|
priority: number;
|
|
2052
2054
|
enabled: boolean;
|
|
2053
2055
|
conditions: Record<string, unknown>;
|
|
2054
|
-
createdAt: Date;
|
|
2055
|
-
updatedAt: Date;
|
|
2056
2056
|
}[]>;
|
|
2057
|
-
getTargetingRulesByEnvironmentId: (params:
|
|
2058
|
-
environmentId:
|
|
2059
|
-
limit:
|
|
2060
|
-
offset:
|
|
2057
|
+
getTargetingRulesByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2058
|
+
environmentId: zod23.ZodString;
|
|
2059
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2060
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2061
2061
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2062
|
-
configId: string;
|
|
2063
2062
|
id: string;
|
|
2063
|
+
createdAt: Date;
|
|
2064
|
+
updatedAt: Date;
|
|
2064
2065
|
environmentId: string;
|
|
2066
|
+
configId: string;
|
|
2065
2067
|
configVariantId: string;
|
|
2066
2068
|
variantVersionId: string | null;
|
|
2067
2069
|
weight: number;
|
|
2068
2070
|
priority: number;
|
|
2069
2071
|
enabled: boolean;
|
|
2070
2072
|
conditions: Record<string, unknown>;
|
|
2071
|
-
createdAt: Date;
|
|
2072
|
-
updatedAt: Date;
|
|
2073
2073
|
}[]>;
|
|
2074
|
-
getTargetingRulesByConfigAndEnvironment: (params:
|
|
2075
|
-
configId:
|
|
2076
|
-
environmentId:
|
|
2074
|
+
getTargetingRulesByConfigAndEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2075
|
+
configId: zod23.ZodString;
|
|
2076
|
+
environmentId: zod23.ZodString;
|
|
2077
2077
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2078
|
-
configId: string;
|
|
2079
2078
|
id: string;
|
|
2079
|
+
createdAt: Date;
|
|
2080
|
+
updatedAt: Date;
|
|
2080
2081
|
environmentId: string;
|
|
2082
|
+
configId: string;
|
|
2081
2083
|
configVariantId: string;
|
|
2082
2084
|
variantVersionId: string | null;
|
|
2083
2085
|
weight: number;
|
|
2084
2086
|
priority: number;
|
|
2085
2087
|
enabled: boolean;
|
|
2086
2088
|
conditions: Record<string, unknown>;
|
|
2087
|
-
createdAt: Date;
|
|
2088
|
-
updatedAt: Date;
|
|
2089
2089
|
}[]>;
|
|
2090
|
-
deleteTargetingRule: (params:
|
|
2091
|
-
id:
|
|
2090
|
+
deleteTargetingRule: (params: zod23.infer<zod23.ZodObject<{
|
|
2091
|
+
id: zod23.ZodString;
|
|
2092
2092
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2093
|
-
configId: string;
|
|
2094
2093
|
id: string;
|
|
2094
|
+
createdAt: Date;
|
|
2095
|
+
updatedAt: Date;
|
|
2095
2096
|
environmentId: string;
|
|
2097
|
+
configId: string;
|
|
2096
2098
|
configVariantId: string;
|
|
2097
2099
|
variantVersionId: string | null;
|
|
2098
2100
|
weight: number;
|
|
2099
2101
|
priority: number;
|
|
2100
2102
|
enabled: boolean;
|
|
2101
2103
|
conditions: Record<string, unknown>;
|
|
2102
|
-
createdAt: Date;
|
|
2103
|
-
updatedAt: Date;
|
|
2104
2104
|
} | undefined>;
|
|
2105
|
-
deleteTargetingRulesByConfigId: (params:
|
|
2106
|
-
configId:
|
|
2105
|
+
deleteTargetingRulesByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2106
|
+
configId: zod23.ZodString;
|
|
2107
2107
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2108
|
-
configId: string;
|
|
2109
2108
|
id: string;
|
|
2109
|
+
createdAt: Date;
|
|
2110
|
+
updatedAt: Date;
|
|
2110
2111
|
environmentId: string;
|
|
2112
|
+
configId: string;
|
|
2111
2113
|
configVariantId: string;
|
|
2112
2114
|
variantVersionId: string | null;
|
|
2113
2115
|
weight: number;
|
|
2114
2116
|
priority: number;
|
|
2115
2117
|
enabled: boolean;
|
|
2116
2118
|
conditions: Record<string, unknown>;
|
|
2117
|
-
createdAt: Date;
|
|
2118
|
-
updatedAt: Date;
|
|
2119
2119
|
}[]>;
|
|
2120
|
-
deleteTargetingRulesByEnvironmentId: (params:
|
|
2121
|
-
environmentId:
|
|
2120
|
+
deleteTargetingRulesByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2121
|
+
environmentId: zod23.ZodString;
|
|
2122
2122
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2123
|
-
configId: string;
|
|
2124
2123
|
id: string;
|
|
2124
|
+
createdAt: Date;
|
|
2125
|
+
updatedAt: Date;
|
|
2125
2126
|
environmentId: string;
|
|
2127
|
+
configId: string;
|
|
2126
2128
|
configVariantId: string;
|
|
2127
2129
|
variantVersionId: string | null;
|
|
2128
2130
|
weight: number;
|
|
2129
2131
|
priority: number;
|
|
2130
2132
|
enabled: boolean;
|
|
2131
2133
|
conditions: Record<string, unknown>;
|
|
2132
|
-
createdAt: Date;
|
|
2133
|
-
updatedAt: Date;
|
|
2134
2134
|
}[]>;
|
|
2135
|
-
listTargetingRules: (params?:
|
|
2136
|
-
limit:
|
|
2137
|
-
offset:
|
|
2135
|
+
listTargetingRules: (params?: zod23.infer<zod23.ZodObject<{
|
|
2136
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2137
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2138
2138
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2139
|
-
configId: string;
|
|
2140
2139
|
id: string;
|
|
2140
|
+
createdAt: Date;
|
|
2141
|
+
updatedAt: Date;
|
|
2141
2142
|
environmentId: string;
|
|
2143
|
+
configId: string;
|
|
2142
2144
|
configVariantId: string;
|
|
2143
2145
|
variantVersionId: string | null;
|
|
2144
2146
|
weight: number;
|
|
2145
2147
|
priority: number;
|
|
2146
2148
|
enabled: boolean;
|
|
2147
2149
|
conditions: Record<string, unknown>;
|
|
2148
|
-
createdAt: Date;
|
|
2149
|
-
updatedAt: Date;
|
|
2150
2150
|
}[]>;
|
|
2151
|
-
getTargetingRulesWithDetailsByConfigId: (params:
|
|
2152
|
-
configId:
|
|
2153
|
-
limit:
|
|
2154
|
-
offset:
|
|
2151
|
+
getTargetingRulesWithDetailsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2152
|
+
configId: zod23.ZodString;
|
|
2153
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2154
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2155
2155
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2156
2156
|
variantProvider: string | null;
|
|
2157
2157
|
variantModelName: string | null;
|
|
2158
2158
|
pinnedVersion: number | null | undefined;
|
|
2159
2159
|
latestVersion: number | null | undefined;
|
|
2160
2160
|
variantName: string | null;
|
|
2161
|
-
configId: string;
|
|
2162
2161
|
id: string;
|
|
2162
|
+
createdAt: Date;
|
|
2163
|
+
updatedAt: Date;
|
|
2163
2164
|
environmentId: string;
|
|
2165
|
+
configId: string;
|
|
2164
2166
|
configVariantId: string;
|
|
2165
2167
|
variantVersionId: string | null;
|
|
2166
2168
|
weight: number;
|
|
2167
2169
|
priority: number;
|
|
2168
2170
|
enabled: boolean;
|
|
2169
2171
|
conditions: Record<string, unknown>;
|
|
2170
|
-
createdAt: Date;
|
|
2171
|
-
updatedAt: Date;
|
|
2172
2172
|
variantId: string | null;
|
|
2173
2173
|
environmentName: string | null;
|
|
2174
2174
|
environmentSlug: string | null;
|
|
2175
2175
|
}[]>;
|
|
2176
|
-
setTargetingForEnvironment: (params:
|
|
2177
|
-
environmentId:
|
|
2178
|
-
configId:
|
|
2179
|
-
configVariantId:
|
|
2180
|
-
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>>;
|
|
2181
2181
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2182
|
-
configId: string;
|
|
2183
2182
|
id: string;
|
|
2183
|
+
createdAt: Date;
|
|
2184
|
+
updatedAt: Date;
|
|
2184
2185
|
environmentId: string;
|
|
2186
|
+
configId: string;
|
|
2185
2187
|
configVariantId: string;
|
|
2186
2188
|
variantVersionId: string | null;
|
|
2187
2189
|
weight: number;
|
|
2188
2190
|
priority: number;
|
|
2189
2191
|
enabled: boolean;
|
|
2190
2192
|
conditions: Record<string, unknown>;
|
|
2191
|
-
createdAt: Date;
|
|
2192
|
-
updatedAt: Date;
|
|
2193
2193
|
} | undefined>;
|
|
2194
2194
|
batchInsertRequests: (requests: LLMRequestInsert[]) => Promise<{
|
|
2195
2195
|
count: number;
|
|
2196
2196
|
}>;
|
|
2197
2197
|
insertRequest: (request: LLMRequestInsert) => Promise<{
|
|
2198
|
-
configId: string | null;
|
|
2199
|
-
variantId: string | null;
|
|
2200
2198
|
id: string;
|
|
2199
|
+
createdAt: Date;
|
|
2200
|
+
updatedAt: Date;
|
|
2201
|
+
variantId: string | null;
|
|
2201
2202
|
provider: string;
|
|
2202
2203
|
environmentId: string | null;
|
|
2204
|
+
configId: string | null;
|
|
2203
2205
|
requestId: string;
|
|
2204
2206
|
model: string;
|
|
2205
2207
|
promptTokens: number;
|
|
@@ -2215,27 +2217,27 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2215
2217
|
isStreaming: boolean;
|
|
2216
2218
|
userId: string | null;
|
|
2217
2219
|
tags: Record<string, string>;
|
|
2218
|
-
createdAt: Date;
|
|
2219
|
-
updatedAt: Date;
|
|
2220
2220
|
} | undefined>;
|
|
2221
|
-
listRequests: (params?:
|
|
2222
|
-
limit:
|
|
2223
|
-
offset:
|
|
2224
|
-
configId:
|
|
2225
|
-
variantId:
|
|
2226
|
-
environmentId:
|
|
2227
|
-
provider:
|
|
2228
|
-
model:
|
|
2229
|
-
startDate:
|
|
2230
|
-
endDate:
|
|
2231
|
-
tags:
|
|
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>>>;
|
|
2232
2232
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2233
2233
|
data: {
|
|
2234
|
-
configId: string | null;
|
|
2235
|
-
variantId: string | null;
|
|
2236
2234
|
id: string;
|
|
2235
|
+
createdAt: Date;
|
|
2236
|
+
updatedAt: Date;
|
|
2237
|
+
variantId: string | null;
|
|
2237
2238
|
provider: string;
|
|
2238
2239
|
environmentId: string | null;
|
|
2240
|
+
configId: string | null;
|
|
2239
2241
|
requestId: string;
|
|
2240
2242
|
model: string;
|
|
2241
2243
|
promptTokens: number;
|
|
@@ -2251,19 +2253,19 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2251
2253
|
isStreaming: boolean;
|
|
2252
2254
|
userId: string | null;
|
|
2253
2255
|
tags: Record<string, string>;
|
|
2254
|
-
createdAt: Date;
|
|
2255
|
-
updatedAt: Date;
|
|
2256
2256
|
}[];
|
|
2257
2257
|
total: number;
|
|
2258
2258
|
limit: number;
|
|
2259
2259
|
offset: number;
|
|
2260
2260
|
}>;
|
|
2261
2261
|
getRequestByRequestId: (requestId: string) => Promise<{
|
|
2262
|
-
configId: string | null;
|
|
2263
|
-
variantId: string | null;
|
|
2264
2262
|
id: string;
|
|
2263
|
+
createdAt: Date;
|
|
2264
|
+
updatedAt: Date;
|
|
2265
|
+
variantId: string | null;
|
|
2265
2266
|
provider: string;
|
|
2266
2267
|
environmentId: string | null;
|
|
2268
|
+
configId: string | null;
|
|
2267
2269
|
requestId: string;
|
|
2268
2270
|
model: string;
|
|
2269
2271
|
promptTokens: number;
|
|
@@ -2279,16 +2281,14 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2279
2281
|
isStreaming: boolean;
|
|
2280
2282
|
userId: string | null;
|
|
2281
2283
|
tags: Record<string, string>;
|
|
2282
|
-
createdAt: Date;
|
|
2283
|
-
updatedAt: Date;
|
|
2284
2284
|
} | undefined>;
|
|
2285
|
-
getTotalCost: (params:
|
|
2286
|
-
startDate:
|
|
2287
|
-
endDate:
|
|
2288
|
-
configId:
|
|
2289
|
-
variantId:
|
|
2290
|
-
environmentId:
|
|
2291
|
-
tags:
|
|
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>>>;
|
|
2292
2292
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2293
2293
|
totalCost: number;
|
|
2294
2294
|
totalInputCost: number;
|
|
@@ -2298,13 +2298,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2298
2298
|
totalTokens: number;
|
|
2299
2299
|
requestCount: number;
|
|
2300
2300
|
} | undefined>;
|
|
2301
|
-
getCostByModel: (params:
|
|
2302
|
-
startDate:
|
|
2303
|
-
endDate:
|
|
2304
|
-
configId:
|
|
2305
|
-
variantId:
|
|
2306
|
-
environmentId:
|
|
2307
|
-
tags:
|
|
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>>>;
|
|
2308
2308
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2309
2309
|
provider: string;
|
|
2310
2310
|
model: string;
|
|
@@ -2315,13 +2315,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2315
2315
|
requestCount: number;
|
|
2316
2316
|
avgLatencyMs: number;
|
|
2317
2317
|
}[]>;
|
|
2318
|
-
getCostByProvider: (params:
|
|
2319
|
-
startDate:
|
|
2320
|
-
endDate:
|
|
2321
|
-
configId:
|
|
2322
|
-
variantId:
|
|
2323
|
-
environmentId:
|
|
2324
|
-
tags:
|
|
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>>>;
|
|
2325
2325
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2326
2326
|
provider: string;
|
|
2327
2327
|
totalCost: number;
|
|
@@ -2331,13 +2331,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2331
2331
|
requestCount: number;
|
|
2332
2332
|
avgLatencyMs: number;
|
|
2333
2333
|
}[]>;
|
|
2334
|
-
getCostByConfig: (params:
|
|
2335
|
-
startDate:
|
|
2336
|
-
endDate:
|
|
2337
|
-
configId:
|
|
2338
|
-
variantId:
|
|
2339
|
-
environmentId:
|
|
2340
|
-
tags:
|
|
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>>>;
|
|
2341
2341
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2342
2342
|
configId: string | null;
|
|
2343
2343
|
totalCost: number;
|
|
@@ -2348,13 +2348,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2348
2348
|
configName: string | null | undefined;
|
|
2349
2349
|
configSlug: string | null;
|
|
2350
2350
|
}[]>;
|
|
2351
|
-
getDailyCosts: (params:
|
|
2352
|
-
startDate:
|
|
2353
|
-
endDate:
|
|
2354
|
-
configId:
|
|
2355
|
-
variantId:
|
|
2356
|
-
environmentId:
|
|
2357
|
-
tags:
|
|
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>>>;
|
|
2358
2358
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2359
2359
|
totalCost: number;
|
|
2360
2360
|
totalInputCost: number;
|
|
@@ -2363,14 +2363,14 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2363
2363
|
requestCount: number;
|
|
2364
2364
|
date: string;
|
|
2365
2365
|
}[]>;
|
|
2366
|
-
getCostSummary: (params:
|
|
2367
|
-
startDate:
|
|
2368
|
-
endDate:
|
|
2369
|
-
configId:
|
|
2370
|
-
variantId:
|
|
2371
|
-
environmentId:
|
|
2372
|
-
tags:
|
|
2373
|
-
groupBy:
|
|
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<{
|
|
2374
2374
|
provider: "provider";
|
|
2375
2375
|
model: "model";
|
|
2376
2376
|
day: "day";
|
|
@@ -2382,13 +2382,13 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2382
2382
|
requestCount: number;
|
|
2383
2383
|
groupKey: string;
|
|
2384
2384
|
}[]>;
|
|
2385
|
-
getRequestStats: (params:
|
|
2386
|
-
startDate:
|
|
2387
|
-
endDate:
|
|
2388
|
-
configId:
|
|
2389
|
-
variantId:
|
|
2390
|
-
environmentId:
|
|
2391
|
-
tags:
|
|
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>>>;
|
|
2392
2392
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2393
2393
|
avgLatencyMs: number;
|
|
2394
2394
|
totalRequests: number;
|
|
@@ -2402,270 +2402,270 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2402
2402
|
key: string;
|
|
2403
2403
|
value: string;
|
|
2404
2404
|
}[]>;
|
|
2405
|
-
createEnvironmentSecret: (params:
|
|
2406
|
-
environmentId:
|
|
2407
|
-
keyName:
|
|
2408
|
-
keyValue:
|
|
2405
|
+
createEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2406
|
+
environmentId: zod23.ZodUUID;
|
|
2407
|
+
keyName: zod23.ZodString;
|
|
2408
|
+
keyValue: zod23.ZodString;
|
|
2409
2409
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2410
2410
|
id: string;
|
|
2411
|
+
createdAt: Date;
|
|
2412
|
+
updatedAt: Date;
|
|
2411
2413
|
environmentId: string;
|
|
2412
2414
|
keyName: string;
|
|
2413
2415
|
keyValue: string;
|
|
2414
|
-
createdAt: Date;
|
|
2415
|
-
updatedAt: Date;
|
|
2416
2416
|
} | undefined>;
|
|
2417
|
-
updateEnvironmentSecret: (params:
|
|
2418
|
-
secretId:
|
|
2419
|
-
keyName:
|
|
2420
|
-
keyValue:
|
|
2417
|
+
updateEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2418
|
+
secretId: zod23.ZodUUID;
|
|
2419
|
+
keyName: zod23.ZodOptional<zod23.ZodString>;
|
|
2420
|
+
keyValue: zod23.ZodOptional<zod23.ZodString>;
|
|
2421
2421
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2422
2422
|
id: string;
|
|
2423
|
+
createdAt: Date;
|
|
2424
|
+
updatedAt: Date;
|
|
2423
2425
|
environmentId: string;
|
|
2424
2426
|
keyName: string;
|
|
2425
2427
|
keyValue: string;
|
|
2426
|
-
createdAt: Date;
|
|
2427
|
-
updatedAt: Date;
|
|
2428
2428
|
} | undefined>;
|
|
2429
|
-
getEnvironmentSecretById: (params:
|
|
2430
|
-
secretId:
|
|
2429
|
+
getEnvironmentSecretById: (params: zod23.infer<zod23.ZodObject<{
|
|
2430
|
+
secretId: zod23.ZodUUID;
|
|
2431
2431
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2432
2432
|
id: string;
|
|
2433
|
+
createdAt: Date;
|
|
2434
|
+
updatedAt: Date;
|
|
2433
2435
|
environmentId: string;
|
|
2434
2436
|
keyName: string;
|
|
2435
2437
|
keyValue: string;
|
|
2436
|
-
createdAt: Date;
|
|
2437
|
-
updatedAt: Date;
|
|
2438
2438
|
} | undefined>;
|
|
2439
|
-
getSecretsByEnvironmentId: (params:
|
|
2440
|
-
environmentId:
|
|
2439
|
+
getSecretsByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2440
|
+
environmentId: zod23.ZodUUID;
|
|
2441
2441
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2442
2442
|
id: string;
|
|
2443
|
+
createdAt: Date;
|
|
2444
|
+
updatedAt: Date;
|
|
2443
2445
|
environmentId: string;
|
|
2444
2446
|
keyName: string;
|
|
2445
2447
|
keyValue: string;
|
|
2446
|
-
createdAt: Date;
|
|
2447
|
-
updatedAt: Date;
|
|
2448
2448
|
}[]>;
|
|
2449
|
-
deleteEnvironmentSecret: (params:
|
|
2450
|
-
secretId:
|
|
2449
|
+
deleteEnvironmentSecret: (params: zod23.infer<zod23.ZodObject<{
|
|
2450
|
+
secretId: zod23.ZodUUID;
|
|
2451
2451
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2452
2452
|
id: string;
|
|
2453
|
+
createdAt: Date;
|
|
2454
|
+
updatedAt: Date;
|
|
2453
2455
|
environmentId: string;
|
|
2454
2456
|
keyName: string;
|
|
2455
2457
|
keyValue: string;
|
|
2456
|
-
createdAt: Date;
|
|
2457
|
-
updatedAt: Date;
|
|
2458
2458
|
} | undefined>;
|
|
2459
|
-
deleteSecretsByEnvironmentId: (params:
|
|
2460
|
-
environmentId:
|
|
2459
|
+
deleteSecretsByEnvironmentId: (params: zod23.infer<zod23.ZodObject<{
|
|
2460
|
+
environmentId: zod23.ZodUUID;
|
|
2461
2461
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2462
2462
|
id: string;
|
|
2463
|
+
createdAt: Date;
|
|
2464
|
+
updatedAt: Date;
|
|
2463
2465
|
environmentId: string;
|
|
2464
2466
|
keyName: string;
|
|
2465
2467
|
keyValue: string;
|
|
2466
|
-
createdAt: Date;
|
|
2467
|
-
updatedAt: Date;
|
|
2468
2468
|
}[]>;
|
|
2469
|
-
listEnvironmentSecrets: (params?:
|
|
2470
|
-
limit:
|
|
2471
|
-
offset:
|
|
2469
|
+
listEnvironmentSecrets: (params?: zod23.infer<zod23.ZodObject<{
|
|
2470
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2471
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2472
2472
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2473
2473
|
id: string;
|
|
2474
|
+
createdAt: Date;
|
|
2475
|
+
updatedAt: Date;
|
|
2474
2476
|
environmentId: string;
|
|
2475
2477
|
keyName: string;
|
|
2476
2478
|
keyValue: string;
|
|
2477
|
-
createdAt: Date;
|
|
2478
|
-
updatedAt: Date;
|
|
2479
2479
|
}[]>;
|
|
2480
2480
|
countEnvironmentSecrets: () => Promise<number>;
|
|
2481
|
-
createNewEnvironment: (params:
|
|
2482
|
-
name:
|
|
2483
|
-
slug:
|
|
2484
|
-
isProd:
|
|
2481
|
+
createNewEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2482
|
+
name: zod23.ZodString;
|
|
2483
|
+
slug: zod23.ZodString;
|
|
2484
|
+
isProd: zod23.ZodDefault<zod23.ZodOptional<zod23.ZodBoolean>>;
|
|
2485
2485
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2486
|
+
slug: string;
|
|
2486
2487
|
name: string;
|
|
2487
2488
|
id: string;
|
|
2488
|
-
slug: string;
|
|
2489
|
-
isProd: boolean;
|
|
2490
2489
|
createdAt: Date;
|
|
2491
2490
|
updatedAt: Date;
|
|
2491
|
+
isProd: boolean;
|
|
2492
2492
|
} | undefined>;
|
|
2493
|
-
updateEnvironment: (params:
|
|
2494
|
-
environmentId:
|
|
2495
|
-
name:
|
|
2496
|
-
slug:
|
|
2493
|
+
updateEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2494
|
+
environmentId: zod23.ZodUUID;
|
|
2495
|
+
name: zod23.ZodOptional<zod23.ZodString>;
|
|
2496
|
+
slug: zod23.ZodOptional<zod23.ZodString>;
|
|
2497
2497
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2498
|
+
slug: string;
|
|
2498
2499
|
name: string;
|
|
2499
2500
|
id: string;
|
|
2500
|
-
slug: string;
|
|
2501
|
-
isProd: boolean;
|
|
2502
2501
|
createdAt: Date;
|
|
2503
2502
|
updatedAt: Date;
|
|
2503
|
+
isProd: boolean;
|
|
2504
2504
|
} | undefined>;
|
|
2505
|
-
getEnvironmentById: (params:
|
|
2506
|
-
environmentId:
|
|
2505
|
+
getEnvironmentById: (params: zod23.infer<zod23.ZodObject<{
|
|
2506
|
+
environmentId: zod23.ZodUUID;
|
|
2507
2507
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2508
|
+
slug: string;
|
|
2508
2509
|
name: string;
|
|
2509
2510
|
id: string;
|
|
2510
|
-
slug: string;
|
|
2511
|
-
isProd: boolean;
|
|
2512
2511
|
createdAt: Date;
|
|
2513
2512
|
updatedAt: Date;
|
|
2513
|
+
isProd: boolean;
|
|
2514
2514
|
} | undefined>;
|
|
2515
|
-
getEnvironmentBySlug: (params:
|
|
2516
|
-
slug:
|
|
2515
|
+
getEnvironmentBySlug: (params: zod23.infer<zod23.ZodObject<{
|
|
2516
|
+
slug: zod23.ZodString;
|
|
2517
2517
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2518
|
+
slug: string;
|
|
2518
2519
|
name: string;
|
|
2519
2520
|
id: string;
|
|
2520
|
-
slug: string;
|
|
2521
|
-
isProd: boolean;
|
|
2522
2521
|
createdAt: Date;
|
|
2523
2522
|
updatedAt: Date;
|
|
2523
|
+
isProd: boolean;
|
|
2524
2524
|
} | undefined>;
|
|
2525
|
-
deleteEnvironment: (params:
|
|
2526
|
-
environmentId:
|
|
2525
|
+
deleteEnvironment: (params: zod23.infer<zod23.ZodObject<{
|
|
2526
|
+
environmentId: zod23.ZodUUID;
|
|
2527
2527
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2528
|
+
slug: string;
|
|
2528
2529
|
name: string;
|
|
2529
2530
|
id: string;
|
|
2530
|
-
slug: string;
|
|
2531
|
-
isProd: boolean;
|
|
2532
2531
|
createdAt: Date;
|
|
2533
2532
|
updatedAt: Date;
|
|
2533
|
+
isProd: boolean;
|
|
2534
2534
|
} | undefined>;
|
|
2535
|
-
listEnvironments: (params?:
|
|
2536
|
-
limit:
|
|
2537
|
-
offset:
|
|
2535
|
+
listEnvironments: (params?: zod23.infer<zod23.ZodObject<{
|
|
2536
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2537
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2538
2538
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2539
|
+
slug: string;
|
|
2539
2540
|
name: string;
|
|
2540
2541
|
id: string;
|
|
2541
|
-
slug: string;
|
|
2542
|
-
isProd: boolean;
|
|
2543
2542
|
createdAt: Date;
|
|
2544
2543
|
updatedAt: Date;
|
|
2544
|
+
isProd: boolean;
|
|
2545
2545
|
}[]>;
|
|
2546
2546
|
countEnvironments: () => Promise<number>;
|
|
2547
|
-
createConfigVariant: (params:
|
|
2548
|
-
configId:
|
|
2549
|
-
variantId:
|
|
2547
|
+
createConfigVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
2548
|
+
configId: zod23.ZodString;
|
|
2549
|
+
variantId: zod23.ZodString;
|
|
2550
2550
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2551
|
-
configId: string;
|
|
2552
|
-
variantId: string;
|
|
2553
2551
|
id: string;
|
|
2554
2552
|
createdAt: Date;
|
|
2555
2553
|
updatedAt: Date;
|
|
2554
|
+
variantId: string;
|
|
2555
|
+
configId: string;
|
|
2556
2556
|
} | undefined>;
|
|
2557
|
-
getConfigVariantById: (params:
|
|
2558
|
-
id:
|
|
2557
|
+
getConfigVariantById: (params: zod23.infer<zod23.ZodObject<{
|
|
2558
|
+
id: zod23.ZodString;
|
|
2559
2559
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2560
|
-
configId: string;
|
|
2561
|
-
variantId: string;
|
|
2562
2560
|
id: string;
|
|
2563
2561
|
createdAt: Date;
|
|
2564
2562
|
updatedAt: Date;
|
|
2563
|
+
variantId: string;
|
|
2564
|
+
configId: string;
|
|
2565
2565
|
} | undefined>;
|
|
2566
|
-
getConfigVariantsByConfigId: (params:
|
|
2567
|
-
configId:
|
|
2568
|
-
limit:
|
|
2569
|
-
offset:
|
|
2566
|
+
getConfigVariantsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2567
|
+
configId: zod23.ZodString;
|
|
2568
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2569
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2570
2570
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2571
|
-
configId: string;
|
|
2572
|
-
variantId: string;
|
|
2573
2571
|
id: string;
|
|
2574
2572
|
createdAt: Date;
|
|
2575
2573
|
updatedAt: Date;
|
|
2574
|
+
variantId: string;
|
|
2575
|
+
configId: string;
|
|
2576
2576
|
}[]>;
|
|
2577
|
-
getConfigVariantsByVariantId: (params:
|
|
2578
|
-
variantId:
|
|
2579
|
-
limit:
|
|
2580
|
-
offset:
|
|
2577
|
+
getConfigVariantsByVariantId: (params: zod23.infer<zod23.ZodObject<{
|
|
2578
|
+
variantId: zod23.ZodString;
|
|
2579
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2580
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2581
2581
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2582
|
-
configId: string;
|
|
2583
|
-
variantId: string;
|
|
2584
2582
|
id: string;
|
|
2585
2583
|
createdAt: Date;
|
|
2586
2584
|
updatedAt: Date;
|
|
2585
|
+
variantId: string;
|
|
2586
|
+
configId: string;
|
|
2587
2587
|
}[]>;
|
|
2588
|
-
deleteConfigVariant: (params:
|
|
2589
|
-
id:
|
|
2588
|
+
deleteConfigVariant: (params: zod23.infer<zod23.ZodObject<{
|
|
2589
|
+
id: zod23.ZodString;
|
|
2590
2590
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2591
|
-
configId: string;
|
|
2592
|
-
variantId: string;
|
|
2593
2591
|
id: string;
|
|
2594
2592
|
createdAt: Date;
|
|
2595
2593
|
updatedAt: Date;
|
|
2594
|
+
variantId: string;
|
|
2595
|
+
configId: string;
|
|
2596
2596
|
} | undefined>;
|
|
2597
|
-
deleteConfigVariantByIds: (params:
|
|
2598
|
-
configId:
|
|
2599
|
-
variantId:
|
|
2597
|
+
deleteConfigVariantByIds: (params: zod23.infer<zod23.ZodObject<{
|
|
2598
|
+
configId: zod23.ZodString;
|
|
2599
|
+
variantId: zod23.ZodString;
|
|
2600
2600
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2601
|
-
configId: string;
|
|
2602
|
-
variantId: string;
|
|
2603
2601
|
id: string;
|
|
2604
2602
|
createdAt: Date;
|
|
2605
2603
|
updatedAt: Date;
|
|
2604
|
+
variantId: string;
|
|
2605
|
+
configId: string;
|
|
2606
2606
|
} | undefined>;
|
|
2607
|
-
listConfigVariants: (params?:
|
|
2608
|
-
limit:
|
|
2609
|
-
offset:
|
|
2607
|
+
listConfigVariants: (params?: zod23.infer<zod23.ZodObject<{
|
|
2608
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2609
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2610
2610
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2611
|
-
configId: string;
|
|
2612
|
-
variantId: string;
|
|
2613
2611
|
id: string;
|
|
2614
2612
|
createdAt: Date;
|
|
2615
2613
|
updatedAt: Date;
|
|
2614
|
+
variantId: string;
|
|
2615
|
+
configId: string;
|
|
2616
2616
|
}[]>;
|
|
2617
|
-
getConfigVariantWithDetails: (params:
|
|
2618
|
-
id:
|
|
2617
|
+
getConfigVariantWithDetails: (params: zod23.infer<zod23.ZodObject<{
|
|
2618
|
+
id: zod23.ZodString;
|
|
2619
2619
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2620
2620
|
latestVersion: {
|
|
2621
2621
|
version: number;
|
|
2622
|
-
variantId: string;
|
|
2623
2622
|
id: string;
|
|
2623
|
+
createdAt: Date;
|
|
2624
|
+
updatedAt: Date;
|
|
2625
|
+
variantId: string;
|
|
2624
2626
|
provider: string;
|
|
2625
2627
|
modelName: string;
|
|
2626
2628
|
jsonData: Record<string, unknown>;
|
|
2627
|
-
createdAt: Date;
|
|
2628
|
-
updatedAt: Date;
|
|
2629
2629
|
} | null;
|
|
2630
2630
|
variantName: string | null;
|
|
2631
2631
|
id: string;
|
|
2632
|
-
configId: string;
|
|
2633
|
-
variantId: string;
|
|
2634
2632
|
createdAt: Date;
|
|
2635
2633
|
updatedAt: Date;
|
|
2634
|
+
variantId: string;
|
|
2635
|
+
configId: string;
|
|
2636
2636
|
configName: string | null | undefined;
|
|
2637
2637
|
} | undefined>;
|
|
2638
|
-
getConfigVariantsWithDetailsByConfigId: (params:
|
|
2639
|
-
configId:
|
|
2640
|
-
limit:
|
|
2641
|
-
offset:
|
|
2638
|
+
getConfigVariantsWithDetailsByConfigId: (params: zod23.infer<zod23.ZodObject<{
|
|
2639
|
+
configId: zod23.ZodString;
|
|
2640
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2641
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2642
2642
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2643
2643
|
provider: string | null;
|
|
2644
2644
|
modelName: string | null;
|
|
2645
2645
|
jsonData: Record<string, unknown> | null;
|
|
2646
2646
|
latestVersion: {
|
|
2647
2647
|
version: number;
|
|
2648
|
-
variantId: string;
|
|
2649
2648
|
id: string;
|
|
2649
|
+
createdAt: Date;
|
|
2650
|
+
updatedAt: Date;
|
|
2651
|
+
variantId: string;
|
|
2650
2652
|
provider: string;
|
|
2651
2653
|
modelName: string;
|
|
2652
2654
|
jsonData: Record<string, unknown>;
|
|
2653
|
-
createdAt: Date;
|
|
2654
|
-
updatedAt: Date;
|
|
2655
2655
|
} | null;
|
|
2656
2656
|
name: string | null;
|
|
2657
2657
|
id: string;
|
|
2658
|
-
configId: string;
|
|
2659
|
-
variantId: string;
|
|
2660
2658
|
createdAt: Date;
|
|
2661
2659
|
updatedAt: Date;
|
|
2660
|
+
variantId: string;
|
|
2661
|
+
configId: string;
|
|
2662
2662
|
}[]>;
|
|
2663
|
-
createVariantAndLinkToConfig: (params:
|
|
2664
|
-
configId:
|
|
2665
|
-
name:
|
|
2666
|
-
provider:
|
|
2667
|
-
modelName:
|
|
2668
|
-
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>>>;
|
|
2669
2669
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2670
2670
|
variant: {
|
|
2671
2671
|
name: string;
|
|
@@ -2675,25 +2675,25 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2675
2675
|
};
|
|
2676
2676
|
version: {
|
|
2677
2677
|
version: number;
|
|
2678
|
-
variantId: string;
|
|
2679
2678
|
id: string;
|
|
2679
|
+
createdAt: Date;
|
|
2680
|
+
updatedAt: Date;
|
|
2681
|
+
variantId: string;
|
|
2680
2682
|
provider: string;
|
|
2681
2683
|
modelName: string;
|
|
2682
2684
|
jsonData: Record<string, unknown>;
|
|
2683
|
-
createdAt: Date;
|
|
2684
|
-
updatedAt: Date;
|
|
2685
2685
|
};
|
|
2686
2686
|
configVariant: {
|
|
2687
|
-
configId: string;
|
|
2688
|
-
variantId: string;
|
|
2689
2687
|
id: string;
|
|
2690
2688
|
createdAt: Date;
|
|
2691
2689
|
updatedAt: Date;
|
|
2690
|
+
variantId: string;
|
|
2691
|
+
configId: string;
|
|
2692
2692
|
};
|
|
2693
2693
|
}>;
|
|
2694
|
-
getVariantJsonDataForConfig: (params:
|
|
2695
|
-
configId:
|
|
2696
|
-
envSecret:
|
|
2694
|
+
getVariantJsonDataForConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2695
|
+
configId: zod23.ZodString;
|
|
2696
|
+
envSecret: zod23.ZodOptional<zod23.ZodString>;
|
|
2697
2697
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2698
2698
|
configId: string;
|
|
2699
2699
|
variantId: string;
|
|
@@ -2703,63 +2703,63 @@ declare const createDataLayer: (db: Kysely<Database>) => Promise<{
|
|
|
2703
2703
|
modelName: string;
|
|
2704
2704
|
jsonData: Record<string, unknown>;
|
|
2705
2705
|
}>;
|
|
2706
|
-
createNewConfig: (params:
|
|
2707
|
-
name:
|
|
2706
|
+
createNewConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2707
|
+
name: zod23.ZodString;
|
|
2708
2708
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2709
|
+
slug: string;
|
|
2709
2710
|
name: string | undefined;
|
|
2710
2711
|
id: string;
|
|
2711
|
-
slug: string;
|
|
2712
2712
|
createdAt: Date;
|
|
2713
2713
|
updatedAt: Date;
|
|
2714
2714
|
} | undefined>;
|
|
2715
|
-
updateConfigName: (params:
|
|
2716
|
-
configId:
|
|
2717
|
-
newName:
|
|
2715
|
+
updateConfigName: (params: zod23.infer<zod23.ZodObject<{
|
|
2716
|
+
configId: zod23.ZodUUID;
|
|
2717
|
+
newName: zod23.ZodString;
|
|
2718
2718
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2719
|
+
slug: string;
|
|
2719
2720
|
name: string | undefined;
|
|
2720
2721
|
id: string;
|
|
2721
|
-
slug: string;
|
|
2722
2722
|
createdAt: Date;
|
|
2723
2723
|
updatedAt: Date;
|
|
2724
2724
|
} | undefined>;
|
|
2725
|
-
getConfigById: (params:
|
|
2726
|
-
configId:
|
|
2725
|
+
getConfigById: (params: zod23.infer<zod23.ZodObject<{
|
|
2726
|
+
configId: zod23.ZodUUID;
|
|
2727
2727
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2728
|
+
slug: string;
|
|
2728
2729
|
name: string | undefined;
|
|
2729
2730
|
id: string;
|
|
2730
|
-
slug: string;
|
|
2731
2731
|
createdAt: Date;
|
|
2732
2732
|
updatedAt: Date;
|
|
2733
2733
|
} | undefined>;
|
|
2734
|
-
deleteConfig: (params:
|
|
2735
|
-
configId:
|
|
2734
|
+
deleteConfig: (params: zod23.infer<zod23.ZodObject<{
|
|
2735
|
+
configId: zod23.ZodUUID;
|
|
2736
2736
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2737
|
+
slug: string;
|
|
2737
2738
|
name: string | undefined;
|
|
2738
2739
|
id: string;
|
|
2739
|
-
slug: string;
|
|
2740
2740
|
createdAt: Date;
|
|
2741
2741
|
updatedAt: Date;
|
|
2742
2742
|
} | undefined>;
|
|
2743
|
-
listConfigs: (params?:
|
|
2744
|
-
limit:
|
|
2745
|
-
offset:
|
|
2743
|
+
listConfigs: (params?: zod23.infer<zod23.ZodObject<{
|
|
2744
|
+
limit: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2745
|
+
offset: zod23.ZodOptional<zod23.ZodNumber>;
|
|
2746
2746
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2747
|
+
slug: string;
|
|
2747
2748
|
name: string | undefined;
|
|
2748
2749
|
id: string;
|
|
2749
|
-
slug: string;
|
|
2750
2750
|
createdAt: Date;
|
|
2751
2751
|
updatedAt: Date;
|
|
2752
2752
|
}[]>;
|
|
2753
|
-
getConfigWithVariants: (params:
|
|
2754
|
-
configId:
|
|
2753
|
+
getConfigWithVariants: (params: zod23.infer<zod23.ZodObject<{
|
|
2754
|
+
configId: zod23.ZodUUID;
|
|
2755
2755
|
}, zod_v4_core0.$strip>>) => Promise<{
|
|
2756
2756
|
provider: string | null;
|
|
2757
2757
|
modelName: string | null;
|
|
2758
2758
|
jsonData: Record<string, unknown> | null;
|
|
2759
2759
|
variantName: string | null;
|
|
2760
2760
|
id: string;
|
|
2761
|
-
name: string | undefined;
|
|
2762
2761
|
slug: string;
|
|
2762
|
+
name: string | undefined;
|
|
2763
2763
|
createdAt: Date;
|
|
2764
2764
|
updatedAt: Date;
|
|
2765
2765
|
variantId: string | null;
|