Previous Topic: Ensure Result ContainsNext Topic: Virtual Service Environment Assertion


Ensure JSON Schema

The Ensure JSON Schema assertion lets you ensure that a JSON schema is valid and that the payload of a JSON response is valid for that schema.

Complete the following fields:

Name

Defines the name of the assertion.

If

Specifies the behavior of the assertion from the drop-down list.

then

Specifies the step to which to redirect if the assertion fires.

Log

Identifies event text to print if the assertion fires.

Validate Payload Against Schema

Indicates whether to validate both the JSON schema and the payload (the response). When cleared, only the schema is validated.

Default: selected

Select Contents Tab

The Select Contents tab lets you select the origin of the JSON schema and the payload, and inspect their contents.

Complete the following fields:

Schema

Indicates the source of the JSON schema for this assertion. From the drop-down list, select from:

Payload

Indicates the source of the payload, or JSON text. From the drop-down list, select from:

Settings Tab

The Settings tab lets you set advanced options for the Ensure JSON Schema assertion.

Complete the following fields:

Use Subschema

Instructs the application to look for a specific subschema. Enter the subschema in the Subschema Filter field.

Referencing Mode

Indicates the dereferencing mode to use.

To dereference all resolved URIs, select Canonical. To dereference URIs within the schema, select Inline.

Default: Canonical

Run Assertion

To run and execute the filter, click Run Assertion.