ListJobsParams

The parameter struct and builder for HistoricalClient::batch::list_jobs.

The builder can be instantiated with the associated function builder(), and the struct is created from the builder with the build() method. For every field, there is an identically named setter method on the builder.

Fields

Parameter
Type
Description
states
Option<Vec<JobState>>
The filter for job states. Can include Queued, Processing, Done, and Expired. If None, defaults to all except Expired.
since
Option<time::OffsetDateTime>
The filter for timestamp submitted (will not include jobs prior to this).
API method
pub struct ListJobsParams {
    pub states: Option<Vec<JobState>>,
    pub since: Option<OffsetDateTime>,
}
Example usage
1
2
3
4
5
6
7
8
9
10
11
12
13
use databento::historical::batch::{JobState, ListJobsParams};
use time::macros::datetime;

assert_eq!(
    ListJobsParams {
        states: Some(vec![JobState::Done]),
        since: Some(datetime!(2023-11-06 00:00 UTC))
    },
    ListJobsParams::builder()
        .states(vec![JobState::Done])
        .since(datetime!(2023-11-06 00:00 UTC))
        .build()
);