Class RawMessageDeltaEvent
-
- All Implemented Interfaces:
public final class RawMessageDeltaEvent
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classRawMessageDeltaEvent.BuilderA builder for RawMessageDeltaEvent.
public final classRawMessageDeltaEvent.Delta
-
Method Summary
Modifier and Type Method Description final RawMessageDeltaEvent.Deltadelta()final JsonValue_type()final MessageDeltaUsageusage()Billing and rate-limit usage. final JsonField<RawMessageDeltaEvent.Delta>_delta()final JsonField<MessageDeltaUsage>_usage()Billing and rate-limit usage. final Map<String, JsonValue>_additionalProperties()final RawMessageDeltaEventvalidate()final RawMessageDeltaEvent.BuildertoBuilder()Booleanequals(Object other)IntegerhashCode()StringtoString()final static RawMessageDeltaEvent.Builderbuilder()Returns a mutable builder for constructing an instance of RawMessageDeltaEvent. -
-
Method Detail
-
delta
final RawMessageDeltaEvent.Delta delta()
-
usage
final MessageDeltaUsage usage()
Billing and rate-limit usage.
Anthropic's API bills and rate-limits by token counts, as tokens represent the underlying cost to our systems.
Under the hood, the API transforms requests into a format suitable for the model. The model's output then goes through a parsing stage before becoming an API response. As a result, the token counts in
usagewill not match one-to-one with the exact visible content of an API request or response.For example,
output_tokenswill be non-zero, even for an empty string response from Claude.Total input tokens in a request is the summation of
input_tokens,cache_creation_input_tokens, andcache_read_input_tokens.
-
_delta
final JsonField<RawMessageDeltaEvent.Delta> _delta()
-
_usage
final JsonField<MessageDeltaUsage> _usage()
Billing and rate-limit usage.
Anthropic's API bills and rate-limits by token counts, as tokens represent the underlying cost to our systems.
Under the hood, the API transforms requests into a format suitable for the model. The model's output then goes through a parsing stage before becoming an API response. As a result, the token counts in
usagewill not match one-to-one with the exact visible content of an API request or response.For example,
output_tokenswill be non-zero, even for an empty string response from Claude.Total input tokens in a request is the summation of
input_tokens,cache_creation_input_tokens, andcache_read_input_tokens.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
validate
final RawMessageDeltaEvent validate()
-
toBuilder
final RawMessageDeltaEvent.Builder toBuilder()
-
builder
final static RawMessageDeltaEvent.Builder builder()
Returns a mutable builder for constructing an instance of RawMessageDeltaEvent.
The following fields are required:
.delta() .usage()
-
-
-
-