BetaMessageBatch Class — anthropic-sdk-python Architecture
Architecture documentation for the BetaMessageBatch class in beta_message_batch.py from the anthropic-sdk-python codebase.
Entity Profile
Dependency Diagram
graph TD f922c9c7_4662_64d5_2ca5_4c99386cbece["BetaMessageBatch"] 17ce5647_6f06_0676_a4a5_e378a3f57cb1["BaseModel"] f922c9c7_4662_64d5_2ca5_4c99386cbece -->|extends| 17ce5647_6f06_0676_a4a5_e378a3f57cb1 827e58dc_dae3_0aa6_4b86_250116317ec8["beta_message_batch.py"] f922c9c7_4662_64d5_2ca5_4c99386cbece -->|defined in| 827e58dc_dae3_0aa6_4b86_250116317ec8
Relationship Graph
Source Code
src/anthropic/types/beta/messages/beta_message_batch.py lines 13–77
class BetaMessageBatch(BaseModel):
id: str
"""Unique object identifier.
The format and length of IDs may change over time.
"""
archived_at: Optional[datetime] = None
"""
RFC 3339 datetime string representing the time at which the Message Batch was
archived and its results became unavailable.
"""
cancel_initiated_at: Optional[datetime] = None
"""
RFC 3339 datetime string representing the time at which cancellation was
initiated for the Message Batch. Specified only if cancellation was initiated.
"""
created_at: datetime
"""
RFC 3339 datetime string representing the time at which the Message Batch was
created.
"""
ended_at: Optional[datetime] = None
"""
RFC 3339 datetime string representing the time at which processing for the
Message Batch ended. Specified only once processing ends.
Processing ends when every request in a Message Batch has either succeeded,
errored, canceled, or expired.
"""
expires_at: datetime
"""
RFC 3339 datetime string representing the time at which the Message Batch will
expire and end processing, which is 24 hours after creation.
"""
processing_status: Literal["in_progress", "canceling", "ended"]
"""Processing status of the Message Batch."""
request_counts: BetaMessageBatchRequestCounts
"""Tallies requests within the Message Batch, categorized by their status.
Requests start as `processing` and move to one of the other statuses only once
processing of the entire batch ends. The sum of all values always matches the
total number of requests in the batch.
"""
results_url: Optional[str] = None
"""URL to a `.jsonl` file containing the results of the Message Batch requests.
Specified only once processing ends.
Results in the file are not guaranteed to be in the same order as requests. Use
the `custom_id` field to match results to requests.
"""
type: Literal["message_batch"]
"""Object type.
For Message Batches, this is always `"message_batch"`.
"""
Domain
Extends
Source
Frequently Asked Questions
What is the BetaMessageBatch class?
BetaMessageBatch is a class in the anthropic-sdk-python codebase, defined in src/anthropic/types/beta/messages/beta_message_batch.py.
Where is BetaMessageBatch defined?
BetaMessageBatch is defined in src/anthropic/types/beta/messages/beta_message_batch.py at line 13.
What does BetaMessageBatch extend?
BetaMessageBatch extends BaseModel.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free