Interface AgentResponsesMultipartRequest
multipart/form-data body for a /responses request when files are attached. The JSON fields go in the payload part; files go in files parts.
Example to create an instance using the builder pattern
AgentResponsesMultipartRequest agentResponsesMultipartRequest = AgentResponsesMultipartRequest.builder()
.payload(payloadBuilder -> payloadBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for AgentResponsesMultipartRequestbuilder(AgentResponsesMultipartRequest template) create builder for AgentResponsesMultipartRequest instancecopyDeep()deepCopy(AgentResponsesMultipartRequest template) factory method to create a deep copy of AgentResponsesMultipartRequestgetFiles()Supporting files.@NotNull @Valid AgentResponsesPayloadJSON document matching AgentResponsesPayload.of()factory methodof(AgentResponsesMultipartRequest template) factory method to create a shallow copy AgentResponsesMultipartRequestvoidSupporting files.voidSupporting files.voidsetPayload(AgentResponsesPayload payload) JSON document matching AgentResponsesPayload.static tools.jackson.core.type.TypeReference<AgentResponsesMultipartRequest>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map function
-
Method Details
-
getPayload
JSON document matching AgentResponsesPayload. Must include
outputTypeandlocale. At least one ofpromptorfilesmust be provided.- Returns:
- payload
-
getFiles
Supporting files. Repeat this part for each file. Maximum of 3 files, 20 MB each. Allowed content types:
application/pdf,text/plain,text/csv,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,message/rfc822,text/markdown,text/html.- Returns:
- files
-
setPayload
JSON document matching AgentResponsesPayload. Must include
outputTypeandlocale. At least one ofpromptorfilesmust be provided.- Parameters:
payload- value to be set
-
setFiles
Supporting files. Repeat this part for each file. Maximum of 3 files, 20 MB each. Allowed content types:
application/pdf,text/plain,text/csv,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,message/rfc822,text/markdown,text/html.- Parameters:
files- values to be set
-
setFiles
Supporting files. Repeat this part for each file. Maximum of 3 files, 20 MB each. Allowed content types:
application/pdf,text/plain,text/csv,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,message/rfc822,text/markdown,text/html.- Parameters:
files- values to be set
-
of
factory method- Returns:
- instance of AgentResponsesMultipartRequest
-
of
factory method to create a shallow copy AgentResponsesMultipartRequest- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
AgentResponsesMultipartRequest copyDeep() -
deepCopy
@Nullable static AgentResponsesMultipartRequest deepCopy(@Nullable AgentResponsesMultipartRequest template) factory method to create a deep copy of AgentResponsesMultipartRequest- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for AgentResponsesMultipartRequest- Returns:
- builder
-
builder
create builder for AgentResponsesMultipartRequest instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withAgentResponsesMultipartRequest
accessor map function- Type Parameters:
T- mapped type- Parameters:
helper- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-