Skip to main content

Server — HCS‑11 Client

import {
HCS11Client,
AgentBuilder,
InboundTopicType,
AIAgentCapability,
} from '@hashgraphonline/standards-sdk';

const client = new HCS11Client({
network: 'testnet',
auth: { operatorId: '0.0.123', privateKey: '302e…' },
});
const builder = new AgentBuilder()
.setName('Agent')
.setBio('Demo')
.setCapabilities([AIAgentCapability.TEXT_GENERATION])
.setInboundTopicType(InboundTopicType.PUBLIC);
const res = await client.createAndInscribeProfile(builder.build(), true);