Structured JSON assertions
36-json-paths.yaml
HTTP(S)
What this example does
This example demonstrates structured json assertions.
Checks and behavior
- Sends an GET request to https://api.example.invalid/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 assertions
url: https://api.example.invalid/health
tests:
json:
paths:
- path: status
equals: healthy
- path: database.connected
equals: true
- path: services
min_items: 2
- path: error
exists: false
- path: services.0.name
exists: true