v0.7.9
Another small release that's primarily focused around custom-api widget improvements.
Changed
You no longer need to convert numbers to float before doing math operations with them. When adding two integers together, the result will be an integer. Adding two floats together or an integer and a float will result in a float.
Before:
{{ (add (.JSON.Int "foo" | toFloat) (.JSON.Int "bar" | toFloat)) | toInt }}
Now:
{{ add (.JSON.Int "foo") (.JSON.Int "bar") }}
(this is consistent for all math operations, not just addition)
New
skip-json-validation and .JSONLines
- type: custom-api
url: https://api.example.com
skip-json-validation: true
Some API's return newline separated JSON objects instead of a single JSON array. This is not valid JSON, so the custom-api widget will fail to parse it. You can now set skip-json-validation to true to skip the validation step and parse the response as a list of JSON objects within your template.