Duplicate Hosted Agent

Duplicate a hosted agent’s code and optionally secrets and storage.

The source agent is read from its actual owner. The duplicate is created under the personal account or the team from the X-Team request header. Profile data must be registered separately via the hub API.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

addressstringRequired

Query parameters

no_cachebooleanOptionalDefaults to false

Request

This endpoint expects an object.
include_secretsbooleanOptionalDefaults to false
Whether to copy secrets from the source agent to the duplicate.
include_storagebooleanOptionalDefaults to false
Whether to copy storage from the source agent to the duplicate.

Response

Successful Response
addressstring
Bech32 address of the agent.
runningboolean
Whether the agent is currently running.
compiledboolean
Whether the agent code has been compiled.
code_digeststring
Digest of the agent's code.
wallet_addressstring
Wallet address of the agent.
code_update_timestampstringformat: "date-time"
Last time the code was updated.
creation_timestampstringformat: "date-time"
Time when the agent was created.
revisionintegerDefaults to 0
Revision number of the agent.
metadataobject
Metadata associated with the agent.

Errors

422
Unprocessable Entity Error