@openfloor/protocol - v0.0.4
    Preparing search index...

    Class BotAgent

    Bot agent implementation providing default behaviors per specification Section 2.1 Handles conversation state and implements minimal required behaviors

    const bot = new BotAgent({
    identification: {
    speakerUri: 'tag:example.com,2025:bot1',
    serviceUrl: 'https://example.com/bot',
    organization: 'Example Corp',
    conversationalName: 'Assistant'
    },
    capabilities: []
    });

    const response = await bot.processEnvelope(incomingEnvelope);

    Hierarchy (View Summary)

    Index

    Constructors

    Accessors

    • get hasFloor(): boolean

      Check if agent currently has the floor

      Returns boolean

    • get serviceUrl(): string

      Get the agent's service URL from the manifest

      Returns string

    • get speakerUri(): string

      Get the agent's speaker URI from the manifest

      Returns string

    Methods

    • Add an event handler for a specific event type

      Parameters

      • eventType: keyof AgentEventHandlers

        Type of event to handle

      • handler: (...args: any[]) => Promise<void>

        Handler function

      Returns void