[**@rxap/open-api v19.1.0-dev.1**](../README.md)

***

[@rxap/open-api](../globals.md) / SchemaValidationMixin

# Class: SchemaValidationMixin\<Response, Parameters, RequestBody\>

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:31](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L31)

## Type Parameters

• **Response** = `any`

• **Parameters** *extends* `Record`\<`string`, `any`\> \| `void` = `any`

• **RequestBody** = `any`

## Constructors

### new SchemaValidationMixin()

> **new SchemaValidationMixin**\<`Response`, `Parameters`, `RequestBody`\>(): [`SchemaValidationMixin`](SchemaValidationMixin.md)\<`Response`, `Parameters`, `RequestBody`\>

#### Returns

[`SchemaValidationMixin`](SchemaValidationMixin.md)\<`Response`, `Parameters`, `RequestBody`\>

## Properties

### disableSchemaValidation?

> `protected` `optional` **disableSchemaValidation**: `boolean`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:35](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L35)

***

### STRICT

> `static` **STRICT**: `boolean` = `false`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:33](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L33)

## Methods

### buildHttpHeaders()

> **buildHttpHeaders**(`operationParameters`, `parameters`?): `HttpHeaders`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:293](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L293)

#### Parameters

##### operationParameters

`ParameterObject`[]

##### parameters?

`Parameters`

#### Returns

`HttpHeaders`

***

### buildHttpOptions()

> **buildHttpOptions**(`operation`, `parameters`?, `requestBody`?, `ignoreUndefined`?): `HttpRemoteMethodParameter`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:367](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L367)

Converts open api parameters into the corresponding http options to
create a http request. The transformation is guided by the openapi definition

#### Parameters

##### operation

[`OperationObjectWithMetadata`](../interfaces/OperationObjectWithMetadata.md)

##### parameters?

`Parameters`

##### requestBody?

`RequestBody`

##### ignoreUndefined?

`boolean` = `true`

#### Returns

`HttpRemoteMethodParameter`

***

### buildHttpParams()

> **buildHttpParams**(`operationParameters`, `parameters`?, `ignoreUndefined`?): `HttpParams`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:244](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L244)

#### Parameters

##### operationParameters

`ParameterObject`[]

##### parameters?

`Parameters`

##### ignoreUndefined?

`boolean` = `true`

#### Returns

`HttpParams`

***

### buildHttpPathParams()

> **buildHttpPathParams**(`operationParameters`, `parameters`?): `Record`\<`string`, `string`\>

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:333](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L333)

#### Parameters

##### operationParameters

`ParameterObject`[]

##### parameters?

`Parameters`

#### Returns

`Record`\<`string`, `string`\>

***

### validateParameters()

> `protected` **validateParameters**(`operation`, `parameters`?, `strict`?): `void`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:45](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L45)

Validates the parameters against the schema specified in the operation object

#### Parameters

##### operation

[`OperationObjectWithMetadata`](../interfaces/OperationObjectWithMetadata.md)

##### parameters?

`Parameters`

##### strict?

`boolean` = `false`

#### Returns

`void`

***

### validateRequestBody()

> **validateRequestBody**(`operation`, `body`?, `strict`?): `void`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:189](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L189)

#### Parameters

##### operation

[`OperationObjectWithMetadata`](../interfaces/OperationObjectWithMetadata.md)

##### body?

`RequestBody`

##### strict?

`boolean` = `false`

#### Returns

`void`

***

### validateResponse()

> `protected` **validateResponse**(`operation`, `response`, `strict`): `void`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:122](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L122)

Validates the http response against the schema specified in the operation object

#### Parameters

##### operation

[`OperationObjectWithMetadata`](../interfaces/OperationObjectWithMetadata.md)

##### response

[`SchemaValidationResponse`](../interfaces/SchemaValidationResponse.md)\<`Response`\>

##### strict

`boolean` = `false`

#### Returns

`void`

***

### validationError()

> **validationError**(`message`, `strict`, `schema`?, `value`?): `void`

Defined in: [packages/angular/open-api/src/lib/schema-validation.mixin.ts:222](https://gitlab.com/rxap/packages/-/blob/8b57a83e5e2b112c82a6d37b4e6b77fd365cbf05/packages/angular/open-api/src/lib/schema-validation.mixin.ts#L222)

#### Parameters

##### message

`string`

##### strict

`boolean`

##### schema?

`ReferenceObject` | `SchemaObject`

##### value?

`any`

#### Returns

`void`
