Agent Versions hooks
Hand-written shim. Generated CRUD hooks via ./agent-versions.gen. useForkAgentVersion + useSetDefaultAgentVersion stay hand-written.
Hooks
useCreateAgentVersion mutation
Create an ADDITIONAL version of an existing agent. The initial v1 is created automatically by createAgent — do NOT call this right after createAgent. Use this only when you actually need a v2+, or use forkAgentVersion to branch from a specific version.
useCreateAgentVersion(options?: MutationOpts<AgentVersion, CreateAgentVersionParams>)Types: AgentVersion · CreateAgentVersionParams
useDeleteAgentVersion mutation
Soft-delete an agent version.
useDeleteAgentVersion(options?: MutationOpts<SuccessResponse, string>)Types: SuccessResponse
useForkAgentVersion composite
useForkAgentVersion(options?: MutationOpts<AgentVersion, ForkAgentVersionParams>)Types: AgentVersion · ForkAgentVersionParams
useListAgentVersions query
List agent versions.
useListAgentVersions(params?: Omit<ListAgentVersionsParams, | > & { filter?: AgentVersionFilter; orderBy?: AgentVersionOrderBy[]; } & AgentVersionShorthands, options?: QueryOpts<Page<AgentVersion>>)Types: ListAgentVersionsParams · AgentVersionFilter · AgentVersionOrderBy · AgentVersionShorthands · Page · AgentVersion
usePurgeAgentVersion composite
Permanently delete a soft-deleted agent version.
usePurgeAgentVersion(options?: MutationOpts<SuccessResponse, PurgeAgentVersionParams>)Types: SuccessResponse · PurgeAgentVersionParams
useRestoreAgentVersion composite
Restore a soft-deleted agent version.
useRestoreAgentVersion(options?: MutationOpts<AgentVersion, string>)Types: AgentVersion
useRetrieveAgentVersion query
Get an agent version by ID.
useRetrieveAgentVersion(id: string, options?: QueryOpts<AgentVersion>)Types: AgentVersion
useSetDefaultAgentVersion composite
useSetDefaultAgentVersion(options?: MutationOpts<Agent, SetDefaultAgentVersionParams>)Types: Agent · SetDefaultAgentVersionParams
useUpdateAgentVersion mutation
Update an agent version.
useUpdateAgentVersion(options?: MutationOpts<AgentVersion, UpdateAgentVersionParams>)Types: AgentVersion · UpdateAgentVersionParams