Skip to main content

@terascope/job-components / config-validators

config-validators

Functions

validateAPIConfig()

validateAPIConfig<T>(inputSchema, inputConfig): APIConfig & T

Merges the provided inputSchema with commonSchema and then validates the provided apiConfig against the resulting schema.

Type parameters

Type parameter
T

Parameters

ParameterType
inputSchemaSchema<any>
inputConfigRecord<string, any>

Returns

APIConfig & T

Source

packages/job-components/src/config-validators.ts:33


validateJobConfig()

validateJobConfig<T>(inputSchema, inputConfig): ValidatedJobConfig & T

Merges the provided inputSchema with commonSchema and then validates the provided jobConfig against the resulting schema.

Type parameters

Type parameter
T

Parameters

ParameterType
inputSchemaSchema<any>
inputConfigRecord<string, any>

Returns

ValidatedJobConfig & T

Source

packages/job-components/src/config-validators.ts:53


validateOpConfig()

validateOpConfig<T>(inputSchema, inputConfig): OpConfig & T

Merges the provided inputSchema with commonSchema and then validates the provided opConfig against the resulting schema.

Type parameters

Type parameter
T

Parameters

ParameterType
inputSchemaSchema<any>
inputConfigRecord<string, any>

Returns

OpConfig & T

Source

packages/job-components/src/config-validators.ts:13