Class BetaMessageBatchIndividualResponse.Builder
-
- All Implemented Interfaces:
public final class BetaMessageBatchIndividualResponse.BuilderA builder for BetaMessageBatchIndividualResponse.
-
-
Method Summary
-
-
Method Detail
-
customId
final BetaMessageBatchIndividualResponse.Builder customId(String customId)
Developer-provided ID created for each request in a Message Batch. Useful for matching results to requests, as results may be given out of request order.
Must be unique for each request within the Message Batch.
-
customId
final BetaMessageBatchIndividualResponse.Builder customId(JsonField<String> customId)
Sets Builder.customId to an arbitrary JSON value.
You should usually call Builder.customId with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
result
final BetaMessageBatchIndividualResponse.Builder result(BetaMessageBatchResult result)
Processing result for this request.
Contains a Message output if processing was successful, an error response if processing failed, or the reason why processing was not attempted, such as cancellation or expiration.
-
result
final BetaMessageBatchIndividualResponse.Builder result(JsonField<BetaMessageBatchResult> result)
Sets Builder.result to an arbitrary JSON value.
You should usually call Builder.result with a well-typed BetaMessageBatchResult value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
result
final BetaMessageBatchIndividualResponse.Builder result(BetaMessageBatchSucceededResult succeeded)
Alias for calling result with
BetaMessageBatchResult.ofSucceeded(succeeded).
-
result
final BetaMessageBatchIndividualResponse.Builder result(BetaMessageBatchErroredResult errored)
Alias for calling result with
BetaMessageBatchResult.ofErrored(errored).
-
result
final BetaMessageBatchIndividualResponse.Builder result(BetaMessageBatchCanceledResult canceled)
Alias for calling result with
BetaMessageBatchResult.ofCanceled(canceled).
-
result
final BetaMessageBatchIndividualResponse.Builder result(BetaMessageBatchExpiredResult expired)
Alias for calling result with
BetaMessageBatchResult.ofExpired(expired).
-
succeededResult
final BetaMessageBatchIndividualResponse.Builder succeededResult(BetaMessage message)
Alias for calling result with the following:
BetaMessageBatchSucceededResult.builder() .message(message) .build()
-
erroredResult
final BetaMessageBatchIndividualResponse.Builder erroredResult(BetaErrorResponse error)
Alias for calling result with the following:
BetaMessageBatchErroredResult.builder() .error(error) .build()
-
additionalProperties
final BetaMessageBatchIndividualResponse.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final BetaMessageBatchIndividualResponse.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final BetaMessageBatchIndividualResponse.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final BetaMessageBatchIndividualResponse.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final BetaMessageBatchIndividualResponse.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final BetaMessageBatchIndividualResponse build()
Returns an immutable instance of BetaMessageBatchIndividualResponse.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.customId() .result()
-
-
-
-