MCPcopy Create free account
hub / github.com/B3Pay/B3Wallet / updateAgent

Function updateAgent

scripts/agent.ts:10–22  ·  view source on GitHub ↗
(mainnet: boolean)

Source from the content-addressed store, hash-verified

8})
9
10export const updateAgent = async (mainnet: boolean) => {
11 const identity = initIdentity(mainnet)
12 console.log("Identity:", identity.getPrincipal().toText())
13
14 try {
15 await agentManager.updateAgent({
16 host: mainnet ? "https://ic0.app" : "http://127.0.0.1:4943",
17 identity
18 })
19 } catch (error) {
20 console.error("System Actor initialization failed:", error)
21 }
22}

Callers 2

Calls 1

initIdentityFunction · 0.90

Tested by

no test coverage detected