@soat/sdk 0.4.17 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/index.js +198 -45
- package/dist/index.d.cts +891 -166
- package/dist/index.d.ts +891 -166
- package/dist/index.js +205 -46
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -33,7 +33,6 @@ var index_exports = {};
|
|
|
33
33
|
__export(index_exports, {
|
|
34
34
|
Actors: () => Actors,
|
|
35
35
|
AgentTools: () => AgentTools,
|
|
36
|
-
AgentTraces: () => AgentTraces,
|
|
37
36
|
Agents: () => Agents,
|
|
38
37
|
AiProviders: () => AiProviders,
|
|
39
38
|
ApiKeys: () => ApiKeys,
|
|
@@ -41,11 +40,15 @@ __export(index_exports, {
|
|
|
41
40
|
Conversations: () => Conversations,
|
|
42
41
|
Documents: () => Documents,
|
|
43
42
|
Files: () => Files,
|
|
43
|
+
Knowledge: () => Knowledge,
|
|
44
|
+
Memories: () => Memories,
|
|
45
|
+
MemoryEntries: () => MemoryEntries,
|
|
44
46
|
Policies: () => Policies,
|
|
45
47
|
Projects: () => Projects,
|
|
46
48
|
Secrets: () => Secrets,
|
|
47
49
|
Sessions: () => Sessions,
|
|
48
50
|
SoatClient: () => SoatClient,
|
|
51
|
+
Traces: () => Traces,
|
|
49
52
|
Users: () => Users,
|
|
50
53
|
Webhooks: () => Webhooks,
|
|
51
54
|
createClient: () => createClient,
|
|
@@ -1087,33 +1090,6 @@ var AgentTools = class {
|
|
|
1087
1090
|
});
|
|
1088
1091
|
}
|
|
1089
1092
|
};
|
|
1090
|
-
var AgentTraces = class {
|
|
1091
|
-
static {
|
|
1092
|
-
__name(this, "AgentTraces");
|
|
1093
|
-
}
|
|
1094
|
-
/**
|
|
1095
|
-
* List agent traces
|
|
1096
|
-
*
|
|
1097
|
-
* Returns all traces for the project.
|
|
1098
|
-
*/
|
|
1099
|
-
static listAgentTraces(options) {
|
|
1100
|
-
return (options?.client ?? client).get({
|
|
1101
|
-
url: "/api/v1/agents/traces",
|
|
1102
|
-
...options
|
|
1103
|
-
});
|
|
1104
|
-
}
|
|
1105
|
-
/**
|
|
1106
|
-
* Get a trace
|
|
1107
|
-
*
|
|
1108
|
-
* Returns a single trace by ID.
|
|
1109
|
-
*/
|
|
1110
|
-
static getAgentTrace(options) {
|
|
1111
|
-
return (options.client ?? client).get({
|
|
1112
|
-
url: "/api/v1/agents/traces/{trace_id}",
|
|
1113
|
-
...options
|
|
1114
|
-
});
|
|
1115
|
-
}
|
|
1116
|
-
};
|
|
1117
1093
|
var Agents = class {
|
|
1118
1094
|
static {
|
|
1119
1095
|
__name(this, "Agents");
|
|
@@ -1755,21 +1731,6 @@ var Documents = class {
|
|
|
1755
1731
|
}
|
|
1756
1732
|
});
|
|
1757
1733
|
}
|
|
1758
|
-
/**
|
|
1759
|
-
* Semantic search over documents
|
|
1760
|
-
*
|
|
1761
|
-
* Searches documents using semantic search, file paths, or document IDs. At least one of search, paths, or document_ids must be provided. Returns results ordered by similarity score.
|
|
1762
|
-
*/
|
|
1763
|
-
static searchDocuments(options) {
|
|
1764
|
-
return (options.client ?? client).post({
|
|
1765
|
-
url: "/api/v1/documents/search",
|
|
1766
|
-
...options,
|
|
1767
|
-
headers: {
|
|
1768
|
-
"Content-Type": "application/json",
|
|
1769
|
-
...options.headers
|
|
1770
|
-
}
|
|
1771
|
-
});
|
|
1772
|
-
}
|
|
1773
1734
|
};
|
|
1774
1735
|
var Files = class {
|
|
1775
1736
|
static {
|
|
@@ -1933,6 +1894,162 @@ var Files = class {
|
|
|
1933
1894
|
});
|
|
1934
1895
|
}
|
|
1935
1896
|
};
|
|
1897
|
+
var Knowledge = class {
|
|
1898
|
+
static {
|
|
1899
|
+
__name(this, "Knowledge");
|
|
1900
|
+
}
|
|
1901
|
+
/**
|
|
1902
|
+
* Search knowledge
|
|
1903
|
+
*
|
|
1904
|
+
* Searches across documents and memory entries using semantic search, file paths, document IDs, or memory IDs/tags. At least one of `query`, `document_paths`, `document_ids`, `memory_ids`, or `memory_tags` must be provided.
|
|
1905
|
+
*/
|
|
1906
|
+
static searchKnowledge(options) {
|
|
1907
|
+
return (options.client ?? client).post({
|
|
1908
|
+
url: "/api/v1/knowledge/search",
|
|
1909
|
+
...options,
|
|
1910
|
+
headers: {
|
|
1911
|
+
"Content-Type": "application/json",
|
|
1912
|
+
...options.headers
|
|
1913
|
+
}
|
|
1914
|
+
});
|
|
1915
|
+
}
|
|
1916
|
+
};
|
|
1917
|
+
var Memories = class {
|
|
1918
|
+
static {
|
|
1919
|
+
__name(this, "Memories");
|
|
1920
|
+
}
|
|
1921
|
+
/**
|
|
1922
|
+
* List memories
|
|
1923
|
+
*
|
|
1924
|
+
* Returns a list of memory configurations for a project
|
|
1925
|
+
*/
|
|
1926
|
+
static listMemories(options) {
|
|
1927
|
+
return (options?.client ?? client).get({
|
|
1928
|
+
url: "/api/v1/memories",
|
|
1929
|
+
...options
|
|
1930
|
+
});
|
|
1931
|
+
}
|
|
1932
|
+
/**
|
|
1933
|
+
* Create a memory
|
|
1934
|
+
*
|
|
1935
|
+
* Creates a new memory configuration in a project
|
|
1936
|
+
*/
|
|
1937
|
+
static createMemory(options) {
|
|
1938
|
+
return (options.client ?? client).post({
|
|
1939
|
+
url: "/api/v1/memories",
|
|
1940
|
+
...options,
|
|
1941
|
+
headers: {
|
|
1942
|
+
"Content-Type": "application/json",
|
|
1943
|
+
...options.headers
|
|
1944
|
+
}
|
|
1945
|
+
});
|
|
1946
|
+
}
|
|
1947
|
+
/**
|
|
1948
|
+
* Delete a memory
|
|
1949
|
+
*
|
|
1950
|
+
* Deletes a memory configuration
|
|
1951
|
+
*/
|
|
1952
|
+
static deleteMemory(options) {
|
|
1953
|
+
return (options.client ?? client).delete({
|
|
1954
|
+
url: "/api/v1/memories/{memory_id}",
|
|
1955
|
+
...options
|
|
1956
|
+
});
|
|
1957
|
+
}
|
|
1958
|
+
/**
|
|
1959
|
+
* Get a memory
|
|
1960
|
+
*
|
|
1961
|
+
* Returns a single memory configuration by ID
|
|
1962
|
+
*/
|
|
1963
|
+
static getMemory(options) {
|
|
1964
|
+
return (options.client ?? client).get({
|
|
1965
|
+
url: "/api/v1/memories/{memory_id}",
|
|
1966
|
+
...options
|
|
1967
|
+
});
|
|
1968
|
+
}
|
|
1969
|
+
/**
|
|
1970
|
+
* Update a memory
|
|
1971
|
+
*
|
|
1972
|
+
* Updates an existing memory configuration
|
|
1973
|
+
*/
|
|
1974
|
+
static updateMemory(options) {
|
|
1975
|
+
return (options.client ?? client).put({
|
|
1976
|
+
url: "/api/v1/memories/{memory_id}",
|
|
1977
|
+
...options,
|
|
1978
|
+
headers: {
|
|
1979
|
+
"Content-Type": "application/json",
|
|
1980
|
+
...options.headers
|
|
1981
|
+
}
|
|
1982
|
+
});
|
|
1983
|
+
}
|
|
1984
|
+
};
|
|
1985
|
+
var MemoryEntries = class {
|
|
1986
|
+
static {
|
|
1987
|
+
__name(this, "MemoryEntries");
|
|
1988
|
+
}
|
|
1989
|
+
/**
|
|
1990
|
+
* List memory entries
|
|
1991
|
+
*
|
|
1992
|
+
* Returns all entries in a memory container
|
|
1993
|
+
*/
|
|
1994
|
+
static listMemoryEntries(options) {
|
|
1995
|
+
return (options.client ?? client).get({
|
|
1996
|
+
url: "/api/v1/memories/{memory_id}/entries",
|
|
1997
|
+
...options
|
|
1998
|
+
});
|
|
1999
|
+
}
|
|
2000
|
+
/**
|
|
2001
|
+
* Create a memory entry
|
|
2002
|
+
*
|
|
2003
|
+
* Creates a new entry in the specified memory container. Automatically generates an embedding for semantic search.
|
|
2004
|
+
*/
|
|
2005
|
+
static createMemoryEntry(options) {
|
|
2006
|
+
return (options.client ?? client).post({
|
|
2007
|
+
url: "/api/v1/memories/{memory_id}/entries",
|
|
2008
|
+
...options,
|
|
2009
|
+
headers: {
|
|
2010
|
+
"Content-Type": "application/json",
|
|
2011
|
+
...options.headers
|
|
2012
|
+
}
|
|
2013
|
+
});
|
|
2014
|
+
}
|
|
2015
|
+
/**
|
|
2016
|
+
* Delete a memory entry
|
|
2017
|
+
*
|
|
2018
|
+
* Deletes a memory entry
|
|
2019
|
+
*/
|
|
2020
|
+
static deleteMemoryEntry(options) {
|
|
2021
|
+
return (options.client ?? client).delete({
|
|
2022
|
+
url: "/api/v1/memories/{memory_id}/entries/{entry_id}",
|
|
2023
|
+
...options
|
|
2024
|
+
});
|
|
2025
|
+
}
|
|
2026
|
+
/**
|
|
2027
|
+
* Get a memory entry
|
|
2028
|
+
*
|
|
2029
|
+
* Returns a single memory entry by ID
|
|
2030
|
+
*/
|
|
2031
|
+
static getMemoryEntry(options) {
|
|
2032
|
+
return (options.client ?? client).get({
|
|
2033
|
+
url: "/api/v1/memories/{memory_id}/entries/{entry_id}",
|
|
2034
|
+
...options
|
|
2035
|
+
});
|
|
2036
|
+
}
|
|
2037
|
+
/**
|
|
2038
|
+
* Update a memory entry
|
|
2039
|
+
*
|
|
2040
|
+
* Updates an existing memory entry. Regenerates the embedding if content changes.
|
|
2041
|
+
*/
|
|
2042
|
+
static updateMemoryEntry(options) {
|
|
2043
|
+
return (options.client ?? client).put({
|
|
2044
|
+
url: "/api/v1/memories/{memory_id}/entries/{entry_id}",
|
|
2045
|
+
...options,
|
|
2046
|
+
headers: {
|
|
2047
|
+
"Content-Type": "application/json",
|
|
2048
|
+
...options.headers
|
|
2049
|
+
}
|
|
2050
|
+
});
|
|
2051
|
+
}
|
|
2052
|
+
};
|
|
1936
2053
|
var Policies = class {
|
|
1937
2054
|
static {
|
|
1938
2055
|
__name(this, "Policies");
|
|
@@ -2281,6 +2398,45 @@ var Sessions = class {
|
|
|
2281
2398
|
});
|
|
2282
2399
|
}
|
|
2283
2400
|
};
|
|
2401
|
+
var Traces = class {
|
|
2402
|
+
static {
|
|
2403
|
+
__name(this, "Traces");
|
|
2404
|
+
}
|
|
2405
|
+
/**
|
|
2406
|
+
* List traces
|
|
2407
|
+
*
|
|
2408
|
+
* Returns a paginated list of execution traces for the project.
|
|
2409
|
+
*/
|
|
2410
|
+
static listTraces(options) {
|
|
2411
|
+
return (options?.client ?? client).get({
|
|
2412
|
+
url: "/api/v1/traces",
|
|
2413
|
+
...options
|
|
2414
|
+
});
|
|
2415
|
+
}
|
|
2416
|
+
/**
|
|
2417
|
+
* Get a trace
|
|
2418
|
+
*
|
|
2419
|
+
* Returns a single trace by ID.
|
|
2420
|
+
*/
|
|
2421
|
+
static getTrace(options) {
|
|
2422
|
+
return (options.client ?? client).get({
|
|
2423
|
+
url: "/api/v1/traces/{trace_id}",
|
|
2424
|
+
...options
|
|
2425
|
+
});
|
|
2426
|
+
}
|
|
2427
|
+
/**
|
|
2428
|
+
* Get trace tree
|
|
2429
|
+
*
|
|
2430
|
+
* Returns the full execution tree rooted at the given trace (or its root if the given trace is a child). Each node represents one agent's execution session. The `children` array contains traces triggered by sub-agent tool calls from that trace.
|
|
2431
|
+
*
|
|
2432
|
+
*/
|
|
2433
|
+
static getTraceTree(options) {
|
|
2434
|
+
return (options.client ?? client).get({
|
|
2435
|
+
url: "/api/v1/traces/{trace_id}/tree",
|
|
2436
|
+
...options
|
|
2437
|
+
});
|
|
2438
|
+
}
|
|
2439
|
+
};
|
|
2284
2440
|
var Users = class {
|
|
2285
2441
|
static {
|
|
2286
2442
|
__name(this, "Users");
|
|
@@ -2515,7 +2671,6 @@ var SoatClient = class {
|
|
|
2515
2671
|
}
|
|
2516
2672
|
actors;
|
|
2517
2673
|
agentTools;
|
|
2518
|
-
agentTraces;
|
|
2519
2674
|
agents;
|
|
2520
2675
|
aiProviders;
|
|
2521
2676
|
apiKeys;
|
|
@@ -2527,6 +2682,7 @@ var SoatClient = class {
|
|
|
2527
2682
|
projects;
|
|
2528
2683
|
secrets;
|
|
2529
2684
|
sessions;
|
|
2685
|
+
traces;
|
|
2530
2686
|
users;
|
|
2531
2687
|
webhooks;
|
|
2532
2688
|
constructor({
|
|
@@ -2546,7 +2702,6 @@ var SoatClient = class {
|
|
|
2546
2702
|
}));
|
|
2547
2703
|
this.actors = bindResource(Actors, httpClient);
|
|
2548
2704
|
this.agentTools = bindResource(AgentTools, httpClient);
|
|
2549
|
-
this.agentTraces = bindResource(AgentTraces, httpClient);
|
|
2550
2705
|
this.agents = bindResource(Agents, httpClient);
|
|
2551
2706
|
this.aiProviders = bindResource(AiProviders, httpClient);
|
|
2552
2707
|
this.apiKeys = bindResource(ApiKeys, httpClient);
|
|
@@ -2558,6 +2713,7 @@ var SoatClient = class {
|
|
|
2558
2713
|
this.projects = bindResource(Projects, httpClient);
|
|
2559
2714
|
this.secrets = bindResource(Secrets, httpClient);
|
|
2560
2715
|
this.sessions = bindResource(Sessions, httpClient);
|
|
2716
|
+
this.traces = bindResource(Traces, httpClient);
|
|
2561
2717
|
this.users = bindResource(Users, httpClient);
|
|
2562
2718
|
this.webhooks = bindResource(Webhooks, httpClient);
|
|
2563
2719
|
}
|
|
@@ -2566,7 +2722,6 @@ var SoatClient = class {
|
|
|
2566
2722
|
0 && (module.exports = {
|
|
2567
2723
|
Actors,
|
|
2568
2724
|
AgentTools,
|
|
2569
|
-
AgentTraces,
|
|
2570
2725
|
Agents,
|
|
2571
2726
|
AiProviders,
|
|
2572
2727
|
ApiKeys,
|
|
@@ -2574,11 +2729,15 @@ var SoatClient = class {
|
|
|
2574
2729
|
Conversations,
|
|
2575
2730
|
Documents,
|
|
2576
2731
|
Files,
|
|
2732
|
+
Knowledge,
|
|
2733
|
+
Memories,
|
|
2734
|
+
MemoryEntries,
|
|
2577
2735
|
Policies,
|
|
2578
2736
|
Projects,
|
|
2579
2737
|
Secrets,
|
|
2580
2738
|
Sessions,
|
|
2581
2739
|
SoatClient,
|
|
2740
|
+
Traces,
|
|
2582
2741
|
Users,
|
|
2583
2742
|
Webhooks,
|
|
2584
2743
|
createClient,
|