Class RealtimeConversationItemUserMessage.Content
-
- All Implemented Interfaces:
public final class RealtimeConversationItemUserMessage.Content
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
RealtimeConversationItemUserMessage.Content.Builder
A builder for Content.
public final class
RealtimeConversationItemUserMessage.Content.Detail
The detail level of the image (for
input_image
).auto
will default tohigh
.public final class
RealtimeConversationItemUserMessage.Content.Type
The content type (
input_text
,input_audio
, orinput_image
).
-
Method Summary
Modifier and Type Method Description final Optional<String>
audio()
Base64-encoded audio bytes (for input_audio
), these will be parsed as the format specified in the session input audio type configuration.final Optional<RealtimeConversationItemUserMessage.Content.Detail>
detail()
The detail level of the image (for input_image
).final Optional<String>
imageUrl()
Base64-encoded image bytes (for input_image
) as a data URI.final Optional<String>
text()
The text content (for input_text
).final Optional<String>
transcript()
Transcript of the audio (for input_audio
).final Optional<RealtimeConversationItemUserMessage.Content.Type>
type()
The content type ( input_text
,input_audio
, orinput_image
).final JsonField<String>
_audio()
Returns the raw JSON value of audio. final JsonField<RealtimeConversationItemUserMessage.Content.Detail>
_detail()
Returns the raw JSON value of detail. final JsonField<String>
_imageUrl()
Returns the raw JSON value of imageUrl. final JsonField<String>
_text()
Returns the raw JSON value of text. final JsonField<String>
_transcript()
Returns the raw JSON value of transcript. final JsonField<RealtimeConversationItemUserMessage.Content.Type>
_type()
Returns the raw JSON value of type. final Map<String, JsonValue>
_additionalProperties()
final RealtimeConversationItemUserMessage.Content.Builder
toBuilder()
final RealtimeConversationItemUserMessage.Content
validate()
final Boolean
isValid()
Boolean
equals(Object other)
Integer
hashCode()
String
toString()
final static RealtimeConversationItemUserMessage.Content.Builder
builder()
Returns a mutable builder for constructing an instance of Content. -
-
Method Detail
-
audio
final Optional<String> audio()
Base64-encoded audio bytes (for
input_audio
), these will be parsed as the format specified in the session input audio type configuration. This defaults to PCM 16-bit 24kHz mono if not specified.
-
detail
final Optional<RealtimeConversationItemUserMessage.Content.Detail> detail()
The detail level of the image (for
input_image
).auto
will default tohigh
.
-
imageUrl
final Optional<String> imageUrl()
Base64-encoded image bytes (for
input_image
) as a data URI. For exampledata:image/png;base64,iVBORw0KGgoAAAANSUhEUgAA...
. Supported formats are PNG and JPEG.
-
transcript
final Optional<String> transcript()
Transcript of the audio (for
input_audio
). This is not sent to the model, but will be attached to the message item for reference.
-
type
final Optional<RealtimeConversationItemUserMessage.Content.Type> type()
The content type (
input_text
,input_audio
, orinput_image
).
-
_audio
final JsonField<String> _audio()
Returns the raw JSON value of audio.
Unlike audio, this method doesn't throw if the JSON field has an unexpected type.
-
_detail
final JsonField<RealtimeConversationItemUserMessage.Content.Detail> _detail()
Returns the raw JSON value of detail.
Unlike detail, this method doesn't throw if the JSON field has an unexpected type.
-
_imageUrl
final JsonField<String> _imageUrl()
Returns the raw JSON value of imageUrl.
Unlike imageUrl, this method doesn't throw if the JSON field has an unexpected type.
-
_text
final JsonField<String> _text()
Returns the raw JSON value of text.
Unlike text, this method doesn't throw if the JSON field has an unexpected type.
-
_transcript
final JsonField<String> _transcript()
Returns the raw JSON value of transcript.
Unlike transcript, this method doesn't throw if the JSON field has an unexpected type.
-
_type
final JsonField<RealtimeConversationItemUserMessage.Content.Type> _type()
Returns the raw JSON value of type.
Unlike type, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final RealtimeConversationItemUserMessage.Content.Builder toBuilder()
-
validate
final RealtimeConversationItemUserMessage.Content validate()
-
builder
final static RealtimeConversationItemUserMessage.Content.Builder builder()
Returns a mutable builder for constructing an instance of Content.
-
-
-
-