Class CreateMessageRequest
- java.lang.Object
-
- org.opensearch.client.opensearch._types.RequestBase
-
- org.opensearch.client.opensearch.ml.CreateMessageRequest
-
- All Implemented Interfaces:
JsonpSerializable,PlainJsonSerializable,ToCopyableBuilder<CreateMessageRequest.Builder,CreateMessageRequest>
@JsonpDeserializable @Generated("org.opensearch.client.codegen.CodeGenerator") public final class CreateMessageRequest extends RequestBase implements PlainJsonSerializable, ToCopyableBuilder<CreateMessageRequest.Builder,CreateMessageRequest>
Create a message.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCreateMessageRequest.BuilderBuilder forCreateMessageRequest.-
Nested classes/interfaces inherited from class org.opensearch.client.opensearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>>
-
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<CreateMessageRequest>_DESERIALIZERJson deserializer forCreateMessageRequeststatic Endpoint<CreateMessageRequest,CreateMessageResponse,ErrorResponse>_ENDPOINTEndpoint "ml.create_message".
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<java.lang.String,JsonData>additionalInfo()API name:additional_infostatic CreateMessageRequest.Builderbuilder()booleanequals(java.lang.Object o)inthashCode()java.lang.Stringinput()The question in the message.java.lang.StringmemoryId()Required - API name:memory_idstatic CreateMessageRequestof(java.util.function.Function<CreateMessageRequest.Builder,ObjectBuilder<CreateMessageRequest>> fn)java.lang.Stringorigin()The system name that generated the response.java.lang.StringpromptTemplate()The prompt template.java.lang.Stringresponse()The answer to the question.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)Serialize this object to JSON.protected voidserializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)protected static voidsetupCreateMessageRequestDeserializer(ObjectDeserializer<CreateMessageRequest.Builder> op)CreateMessageRequest.BuildertoBuilder()Create a new builderToCopyableBuilderthat is initialised with the current state of this object.-
Methods inherited from class org.opensearch.client.opensearch._types.RequestBase
applyQueryParameters, errorTrace, human
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.opensearch.client.json.PlainJsonSerializable
toJsonString
-
Methods inherited from interface org.opensearch.client.util.ToCopyableBuilder
copy
-
-
-
-
Field Detail
-
_DESERIALIZER
public static final JsonpDeserializer<CreateMessageRequest> _DESERIALIZER
Json deserializer forCreateMessageRequest
-
_ENDPOINT
public static final Endpoint<CreateMessageRequest,CreateMessageResponse,ErrorResponse> _ENDPOINT
Endpoint "ml.create_message".
-
-
Method Detail
-
of
public static CreateMessageRequest of(java.util.function.Function<CreateMessageRequest.Builder,ObjectBuilder<CreateMessageRequest>> fn)
-
additionalInfo
@Nonnull public final java.util.Map<java.lang.String,JsonData> additionalInfo()
API name:additional_info
-
input
@Nullable public final java.lang.String input()
The question in the message.API name:
input
-
memoryId
@Nonnull public final java.lang.String memoryId()
Required - API name:memory_id
-
origin
@Nullable public final java.lang.String origin()
The system name that generated the response.API name:
origin
-
promptTemplate
@Nullable public final java.lang.String promptTemplate()
The prompt template.API name:
prompt_template
-
response
@Nullable public final java.lang.String response()
The answer to the question.API name:
response
-
serialize
public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)Serialize this object to JSON.- Specified by:
serializein interfaceJsonpSerializable
-
serializeInternal
protected void serializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
-
toBuilder
@Nonnull public CreateMessageRequest.Builder toBuilder()
Description copied from interface:ToCopyableBuilderCreate a new builderToCopyableBuilderthat is initialised with the current state of this object.- Specified by:
toBuilderin interfaceToCopyableBuilder<CreateMessageRequest.Builder,CreateMessageRequest>- Returns:
- a new builder instance.
-
builder
@Nonnull public static CreateMessageRequest.Builder builder()
-
setupCreateMessageRequestDeserializer
protected static void setupCreateMessageRequestDeserializer(ObjectDeserializer<CreateMessageRequest.Builder> op)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
-