@theokit/sdk 4.7.1 → 4.8.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/agent.d.ts +8 -0
- package/dist/cron.cjs +15 -0
- package/dist/cron.cjs.map +1 -1
- package/dist/cron.js +15 -0
- package/dist/cron.js.map +1 -1
- package/dist/eval.cjs +15 -0
- package/dist/eval.cjs.map +1 -1
- package/dist/eval.js +15 -0
- package/dist/eval.js.map +1 -1
- package/dist/index.cjs +15 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +8 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +15 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/eval.cjs
CHANGED
|
@@ -17805,6 +17805,11 @@ async function setArchivedFlag(agentId, archived) {
|
|
|
17805
17805
|
updateRegisteredAgent(agentId, { archived });
|
|
17806
17806
|
await flushRegistrySaves();
|
|
17807
17807
|
}
|
|
17808
|
+
async function setAgentName(agentId, name) {
|
|
17809
|
+
await getRegisteredAgentOrThrow(agentId);
|
|
17810
|
+
updateRegisteredAgent(agentId, { name });
|
|
17811
|
+
await flushRegistrySaves();
|
|
17812
|
+
}
|
|
17808
17813
|
async function getRegisteredAgentOrThrow(agentId) {
|
|
17809
17814
|
let agent = getRegisteredAgent(agentId);
|
|
17810
17815
|
if (agent === void 0) {
|
|
@@ -18084,6 +18089,16 @@ var Agent = class _Agent {
|
|
|
18084
18089
|
static unarchive(agentId, _options = {}) {
|
|
18085
18090
|
return setArchivedFlag(agentId, false);
|
|
18086
18091
|
}
|
|
18092
|
+
/**
|
|
18093
|
+
* Set the human-facing `name` of a registered agent (the label `Agent.list()` returns). The registry
|
|
18094
|
+
* already carries a `name` field; this is the missing public mutator for it. Runtime-agnostic (mutates
|
|
18095
|
+
* the local per-cwd registry for local agents; the cloud registry for cloud agents).
|
|
18096
|
+
*
|
|
18097
|
+
* @public
|
|
18098
|
+
*/
|
|
18099
|
+
static async rename(agentId, name, _options = {}) {
|
|
18100
|
+
await setAgentName(agentId, name);
|
|
18101
|
+
}
|
|
18087
18102
|
/**
|
|
18088
18103
|
* Permanently delete a cloud agent.
|
|
18089
18104
|
*
|