Numeric filters
NumberComparisonFilter
Filters by comparing a field to a numeric value.
Property | Type | Description |
---|---|---|
operator | ComparisonOperators | The operator to apply to the filter value |
value | numeric | The value to use for the filter operation |
$schema: https://json-schema.org/draft/2020-12/schema$id: NumberComparisonFilter.yamltype: objectproperties: operator: $ref: ComparisonOperators.yaml description: The comparison operator to apply to the filter value value: type: number description: The value to use for the filter operationrequired: - operator - valuedescription: Filters by comparing a field to a numeric value
/** Filters by comparing a field to a numeric value */model NumberComparisonFilter { /** The comparison operator to apply to the filter value */ operator: ComparisonOperators;
/** The value to use for the filter operation */ @example(1000) value: numeric;}
{ "operator": "eq", "value": 1000}
NumberRangeFilter
Filters by comparing a field to a range of numeric values.
Property | Type | Description |
---|---|---|
operator | RangeOperators | The operator to apply to the filter value |
value | range object | The value to use for the filter operation |
Range object:
Property | Type | Description |
---|---|---|
min | numeric | The minimum numeric value for this range |
max | numeric | The maximum numeric value for this range |
$schema: https://json-schema.org/draft/2020-12/schema$id: NumberRangeFilter.yamltype: objectproperties: operator: $ref: RangeOperators.yaml description: The operator to apply to the filter value value: type: object properties: min: type: number max: type: number required: - min - max examples: - min: 1000 max: 10000 description: The value to use for the filter operationrequired: - operator - valuedescription: Filters by comparing a field to a numeric range
/** Filters by comparing a field to a numeric range */model NumberRangeFilter { /** The operator to apply to the filter value */ operator: RangeOperators;
/** The value to use for the filter operation */ @example(#{ min: 1000, max: 10000 }) value: { min: numeric; max: numeric; };}
{ "operator": "within", "value": { "min": 1000, "max": 10000 }}
NumberArrayFilter
Filters by comparing a field to an array of numeric values.
Property | Type | Description |
---|---|---|
operator | ArrayOperators | The operator to apply to the filter value |
value | Array<numeric> | The value to use for the filter operation |
$schema: https://json-schema.org/draft/2020-12/schema$id: NumberArrayFilter.yamltype: objectproperties: operator: $ref: ArrayOperators.yaml description: The operator to apply to the filter value value: type: array items: type: number description: The value to use for the filter operationrequired: - operator - valuedescription: Filters by comparing a field to an array of numeric values
/** Filters by comparing a field to an array of numeric values */model NumberArrayFilter { /** The operator to apply to the filter value */ operator: ArrayOperators;
/** The value to use for the filter operation */ @example(#[1000, 2000, 3000]) value: Array<numeric>;}
{ "operator": "in", "value": [1000, 2000, 3000]}