Method
Configuration options for the list request
Response
Returns aPager[BatchJob] object that implements the iterator protocol. Each iteration yields a BatchJob object.
Each batch job in the list contains:
Usage
List All Batch Jobs
With Pagination Control
Filter by State (Vertex AI)
Monitor Active Jobs
List Recent Jobs
Filter with Complex Criteria (Vertex AI)
Generate Job Summary
Find Failed Jobs
Export Job List
Monitor Multiple Jobs
Notes
- The pager automatically fetches additional pages as you iterate
- Jobs are returned in reverse chronological order (newest first)
- Page size defaults vary between Gemini API and Vertex AI
- Filtering is only supported on Vertex AI
- The list includes jobs in all states unless filtered
Performance Tips
- Use
page_sizeto control memory usage when listing many jobs - Apply filters on the server side (Vertex AI) instead of filtering in code
- Cache job lists if you need to reference them multiple times
- Use specific filters to reduce data transfer and processing time
See Also
- batches.get - Get details of a specific job
- batches.create - Create a new batch job
- batches.cancel - Cancel a running job
- batches.delete - Delete a batch job