Structured JSON validation
33-json-assertions.yaml
HTTP(S)
What this example does
This example demonstrates structured json validation.
Checks and behavior
- Sends an GET request to https://api.example.com/health.
- Inspects structured JSON response values.
Adapt example domains, addresses, credentials and thresholds to your environment before use.
YAML configuration
# Copyright (c) 2026 mati peterson. Maintainer: mati peterson <ipsonic@mailbox.org>. Project: https://ipsonic.com/probe/. Disclaimer: Provided AS IS, without warranty of any kind. Use at your own risk; validate checks and configurations before production use.
name: Structured JSON validation
url: https://api.example.com/health
tests:
json:
paths:
- path: status
equals: healthy
- path: database.connected
equals: true
- path: services
min_items: 2
- path: version
exists: true
- path: error
exists: false