Skip to content

Support for more complex json queries #1394

@pefoo

Description

@pefoo

I would like to use more complex json path expressions in our conditions but it seems they are not supported right now. Not sure if this is a bug or missing feature.

Given the response of an endpoint like this https://dummyjson.com/quotes, I would like to make sure that the response contains at least 2 quotes by Albert Einstein.

Using jq this is an easy task curl https://dummyjson.com/quotes | jq '[.quotes[] | select(.author == "Albert Einstein")] | length'
Or using RFC 9535 jsonpath to extract the quotes that match our criteria $.quotes[?(@.author == 'Albert Einstein' )].quote

Is this something the current implementation can achieve (I tried different notations with Gatus but none actually worked for me)?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions