Class AssistantMessageParam
-
- All Implemented Interfaces:
public final class AssistantMessageParam
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classAssistantMessageParam.BuilderA builder for AssistantMessageParam.
-
Method Summary
Modifier and Type Method Description final MessageContentParamcontent()final JsonValue_role()Expected to always return the following:
However, this method can be useful for debugging and logging (e.g.JsonValue.from("assistant")final JsonField<MessageContentParam>_content()Returns the raw JSON value of content. final Map<String, JsonValue>_additionalProperties()final AssistantMessageParam.BuildertoBuilder()final AssistantMessageParamvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static AssistantMessageParam.Builderbuilder()Returns a mutable builder for constructing an instance of AssistantMessageParam. final static AssistantMessageParamof(MessageContentParam content)Returns an immutable instance of AssistantMessageParam with the required content set to the given value. final static AssistantMessageParamof(String string)Alias for calling of with MessageContentParam.ofString(string).final static AssistantMessageParamofContentBlockParams(List<ContentBlockParam> contentBlockParams)Alias for calling of with MessageContentParam.ofContentBlockParams(contentBlockParams).-
-
Method Detail
-
content
final MessageContentParam content()
-
_role
final JsonValue _role()
Expected to always return the following:
JsonValue.from("assistant")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_content
final JsonField<MessageContentParam> _content()
Returns the raw JSON value of content.
Unlike content, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final AssistantMessageParam.Builder toBuilder()
-
validate
final AssistantMessageParam validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
builder
final static AssistantMessageParam.Builder builder()
Returns a mutable builder for constructing an instance of AssistantMessageParam.
The following fields are required:
.content()
-
of
final static AssistantMessageParam of(MessageContentParam content)
Returns an immutable instance of AssistantMessageParam with the required content set to the given value.
-
of
final static AssistantMessageParam of(String string)
Alias for calling of with
MessageContentParam.ofString(string).
-
ofContentBlockParams
final static AssistantMessageParam ofContentBlockParams(List<ContentBlockParam> contentBlockParams)
Alias for calling of with
MessageContentParam.ofContentBlockParams(contentBlockParams).
-
-
-
-