Member Junction
    Preparing search index...

    Configuration for a messaging adapter, passed via the ServerExtensionConfig.Settings object in mj.config.cjs.

    // mj.config.cjs
    serverExtensions: [{
    DriverClass: 'SlackMessagingExtension',
    RootPath: '/webhook/slack',
    Settings: {
    DefaultAgentName: 'Sage',
    ContextUserEmail: 'bot@company.com',
    BotToken: process.env.SLACK_BOT_TOKEN,
    SigningSecret: process.env.SLACK_SIGNING_SECRET,
    }
    }]
    interface MessagingAdapterSettings {
        AppToken?: string;
        BotToken: string;
        ConnectionMode?: "http" | "socket";
        ContextUserEmail: string;
        DefaultAgentName: string;
        DisableDelegation?: boolean;
        ExplorerBaseURL?: string;
        MaxThreadMessages?: number;
        MicrosoftAppId?: string;
        MicrosoftAppPassword?: string;
        MicrosoftAppTenantId?: string;
        MicrosoftAppType?: string;
        ShowTypingIndicator?: boolean;
        SigningSecret?: string;
        SlashCommands?: Record<string, string>;
        StreamingUpdateIntervalMs?: number;
    }
    Index

    Properties

    AppToken?: string

    Optional app-level token for Slack Socket Mode connections.

    BotToken: string

    Platform-specific bot token for API access.

    ConnectionMode?: "http" | "socket"

    Connection mode for platforms that support multiple modes.

    • 'http' (default): Standard HTTP webhook endpoint
    • 'socket': WebSocket connection (Slack Socket Mode, no public URL needed)
    ContextUserEmail: string

    Fallback MJ User email for agent execution when the platform user cannot be mapped to an MJ user. Acts as a service account.

    DefaultAgentName: string

    Default MJ Agent name used when no specific agent is @mentioned. Resolved by name at initialization (e.g., 'Sage'). This is preferred over a hardcoded UUID since agent IDs differ across installations.

    DisableDelegation?: boolean

    Disable automatic agent-to-agent delegation for this extension instance.

    Delegation is detected three ways (see detectDelegation), the third of which SCANS THE REPLY TEXT for delegation phrases plus any known agent name. That makes an orchestrator agent's own self-description ("I can route you to ... Betty") trigger a real handoff, so the user gets a different agent's answer under this bot's identity — with no attribution.

    Set this on a bot that is pinned to one agent (the one-app-per-agent deployment, where each platform app has its own DefaultAgentName): the pinned agent's reply is always what posts.

    false
    
    ExplorerBaseURL?: string

    Base URL of the MJ Explorer instance (e.g., https://explorer.mycompany.com). When provided, open:resource actionable commands become deep-link buttons that open the corresponding entity/record in MJ Explorer. Without this, open:resource commands render as informational context blocks.

    MaxThreadMessages?: number

    Maximum number of thread messages to fetch for conversation context.

    50
    
    MicrosoftAppId?: string

    Microsoft App ID for Teams Bot Framework authentication. Only needed for Teams adapters.

    MicrosoftAppPassword?: string

    Microsoft App Password for Teams Bot Framework authentication. Only needed for Teams adapters.

    MicrosoftAppTenantId?: string

    Microsoft App Tenant ID for single-tenant Bot Framework authentication. Required when the Azure Bot is configured as Single Tenant.

    MicrosoftAppType?: string

    Microsoft App Type: 'SingleTenant', 'MultiTenant', or 'UserAssignedMsi'. Auto-detected from MicrosoftAppTenantId if not set (tenant ID present = SingleTenant).

    ShowTypingIndicator?: boolean

    Whether to show typing/thinking indicators while the agent processes.

    true
    
    SigningSecret?: string

    Optional signing secret for webhook signature verification (Slack).

    SlashCommands?: Record<string, string>

    Slash command to agent name mapping for Slack. Keys are command names (e.g., /research), values are MJ Agent names.

    SlashCommands: {
    '/research': 'Research Agent',
    '/marketing': 'Marketing Agent',
    '/sage': 'Sage',
    '/skip': 'Skip',
    }
    StreamingUpdateIntervalMs?: number

    Minimum interval between streaming message updates in milliseconds. Prevents rate limiting from platform APIs.

    1000