How can we assert an API response which contains [] or "transaction"?
Jmeter Assertion should pass if it contains any of the below response Response 1: [] (only empty square brackets) or Response 2: contains string "transaction" as part of response
The easiest is going for Response Assertion configured like:
It will pass in 2 cases:
[]
transaction
if response body won't contain any of these - the assertion will fail.
More information: What Are JMeter Response Assertions?