Skip to main content
All docs
V26.1
  • ResponseReceivedEventArgs.Messages Property

    Returns all messages received from the AI provider.

    Namespace: DevExpress.AIIntegration.Blazor.Chat

    Assembly: DevExpress.AIIntegration.Blazor.Chat.v26.1.dll

    Declaration

    public IReadOnlyList<BlazorChatMessage> Messages { get; }

    Property Value

    Type Description
    IReadOnlyList<BlazorChatMessage>

    A list of messages.

    Remarks

    Use this property to access all messages included in the AI provider’s response. A response can contain multiple messages when the AI produces a multi-part reply — for example, when function calls are performed.

    The following code sample logs content from each message in the AI response:

    <DxAIChat ResponseReceived="OnResponseReceived" />
    
    @code {
        private void OnResponseReceived(ResponseReceivedEventArgs args) {
            foreach(var message in args.Messages) {
                File.AppendAllLines("chatlog.txt", new[] { message.Text });
            }
        }
    }
    
    See Also