output
    Preparing search index...

    Type Alias PromptMessage

    Represents a single message in a prompt conversation.

    const msg: PromptMessage = {
    role: 'user',
    content: 'Hello, Claude!'
    };
    type PromptMessage = {
        content: string;
        providerOptions?: Record<string, Record<string, unknown>>;
        role: "system" | "user" | "assistant";
    }
    Index

    Properties

    content: string

    The content of the message

    providerOptions?: Record<string, Record<string, unknown>>

    Per-message provider options resolved at load from the role tag's options attribute and matching config.messageOptions sets. Authored as <system options="set_a set_b">. options is the only supported role-tag attribute and must have a value. Omitted when the tag has no effective options.

    role: "system" | "user" | "assistant"

    The message role. Authored prompt blocks support 'system', 'user', and 'assistant'.