Text

data class Text(val text: String) : MessageContent(source)

Simple string content.

Constructors

Link copied to clipboard
constructor(text: String)

Properties

Link copied to clipboard

Functions

Link copied to clipboard
fun asText(): String

Extracts all text content from the message, regardless of whether it's a simple string or an array of content parts.

Link copied to clipboard
fun contains(substring: String, ignoreCase: Boolean = false): Boolean

Checks if the message content contains the specified substring.