Class ConversationItemWithReference
-
- All Implemented Interfaces:
public final class ConversationItemWithReferenceThe item to add to the conversation.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classConversationItemWithReference.BuilderA builder for ConversationItemWithReference.
public final classConversationItemWithReference.Contentpublic final classConversationItemWithReference.ObjectIdentifier for the API object being returned - always
realtime.item.public final classConversationItemWithReference.RoleThe role of the message sender (
user,assistant,system), only applicable formessageitems.public final classConversationItemWithReference.StatusThe status of the item (
completed,incomplete,in_progress). These have no effect on the conversation, but are accepted for consistency with theconversation.item.createdevent.public final classConversationItemWithReference.TypeThe type of the item (
message,function_call,function_call_output,item_reference).
-
Method Summary
Modifier and Type Method Description final Optional<String>id()For an item of type ( message|function_call|function_call_output) this field allows the client to assign the unique ID of the item.final Optional<String>arguments()The arguments of the function call (for function_callitems).final Optional<String>callId()The ID of the function call (for function_callandfunction_call_outputitems).final Optional<List<ConversationItemWithReference.Content>>content()The content of the message, applicable for messageitems.final Optional<String>name()The name of the function being called (for function_callitems).final Optional<ConversationItemWithReference.Object>object_()Identifier for the API object being returned - always realtime.item.final Optional<String>output()The output of the function call (for function_call_outputitems).final Optional<ConversationItemWithReference.Role>role()The role of the message sender ( user,assistant,system), only applicable formessageitems.final Optional<ConversationItemWithReference.Status>status()The status of the item ( completed,incomplete,in_progress).final Optional<ConversationItemWithReference.Type>type()The type of the item ( message,function_call,function_call_output,item_reference).final JsonField<String>_id()Returns the raw JSON value of id. final JsonField<String>_arguments()Returns the raw JSON value of arguments. final JsonField<String>_callId()Returns the raw JSON value of callId. final JsonField<List<ConversationItemWithReference.Content>>_content()Returns the raw JSON value of content. final JsonField<String>_name()Returns the raw JSON value of name. final JsonField<ConversationItemWithReference.Object>_object_()Returns the raw JSON value of object_. final JsonField<String>_output()Returns the raw JSON value of output. final JsonField<ConversationItemWithReference.Role>_role()Returns the raw JSON value of role. final JsonField<ConversationItemWithReference.Status>_status()Returns the raw JSON value of status. final JsonField<ConversationItemWithReference.Type>_type()Returns the raw JSON value of type. final Map<String, JsonValue>_additionalProperties()final ConversationItemWithReference.BuildertoBuilder()final ConversationItemWithReferencevalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static ConversationItemWithReference.Builderbuilder()Returns a mutable builder for constructing an instance of ConversationItemWithReference. -
-
Method Detail
-
id
final Optional<String> id()
For an item of type (
message|function_call|function_call_output) this field allows the client to assign the unique ID of the item. It is not required because the server will generate one if not provided.For an item of type
item_reference, this field is required and is a reference to any item that has previously existed in the conversation.
-
arguments
final Optional<String> arguments()
The arguments of the function call (for
function_callitems).
-
callId
final Optional<String> callId()
The ID of the function call (for
function_callandfunction_call_outputitems). If passed on afunction_call_outputitem, the server will check that afunction_callitem with the same ID exists in the conversation history.
-
content
final Optional<List<ConversationItemWithReference.Content>> content()
The content of the message, applicable for
messageitems.Message items of role
systemsupport onlyinput_textcontentMessage items of role
usersupportinput_textandinput_audiocontentMessage items of role
assistantsupporttextcontent.
-
object_
final Optional<ConversationItemWithReference.Object> object_()
Identifier for the API object being returned - always
realtime.item.
-
output
final Optional<String> output()
The output of the function call (for
function_call_outputitems).
-
role
final Optional<ConversationItemWithReference.Role> role()
The role of the message sender (
user,assistant,system), only applicable formessageitems.
-
status
final Optional<ConversationItemWithReference.Status> status()
The status of the item (
completed,incomplete,in_progress). These have no effect on the conversation, but are accepted for consistency with theconversation.item.createdevent.
-
type
final Optional<ConversationItemWithReference.Type> type()
The type of the item (
message,function_call,function_call_output,item_reference).
-
_id
final JsonField<String> _id()
Returns the raw JSON value of id.
Unlike id, this method doesn't throw if the JSON field has an unexpected type.
-
_arguments
final JsonField<String> _arguments()
Returns the raw JSON value of arguments.
Unlike arguments, this method doesn't throw if the JSON field has an unexpected type.
-
_callId
final JsonField<String> _callId()
Returns the raw JSON value of callId.
Unlike callId, this method doesn't throw if the JSON field has an unexpected type.
-
_content
final JsonField<List<ConversationItemWithReference.Content>> _content()
Returns the raw JSON value of content.
Unlike content, this method doesn't throw if the JSON field has an unexpected type.
-
_name
final JsonField<String> _name()
Returns the raw JSON value of name.
Unlike name, this method doesn't throw if the JSON field has an unexpected type.
-
_object_
final JsonField<ConversationItemWithReference.Object> _object_()
Returns the raw JSON value of object_.
Unlike object_, this method doesn't throw if the JSON field has an unexpected type.
-
_output
final JsonField<String> _output()
Returns the raw JSON value of output.
Unlike output, this method doesn't throw if the JSON field has an unexpected type.
-
_role
final JsonField<ConversationItemWithReference.Role> _role()
Returns the raw JSON value of role.
Unlike role, this method doesn't throw if the JSON field has an unexpected type.
-
_status
final JsonField<ConversationItemWithReference.Status> _status()
Returns the raw JSON value of status.
Unlike status, this method doesn't throw if the JSON field has an unexpected type.
-
_type
final JsonField<ConversationItemWithReference.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 ConversationItemWithReference.Builder toBuilder()
-
validate
final ConversationItemWithReference validate()
-
builder
final static ConversationItemWithReference.Builder builder()
Returns a mutable builder for constructing an instance of ConversationItemWithReference.
-
-
-
-