I think I am missing something simple here, but here goes.
Thsi works from the command line with no problem, it give me the required output.
curl -X GET \
-H "X-Auth-Email: REDACTED" \
-H "X-Auth-Key: REDACTED" \
"https://api.cloudflare.com/client/v4/zones/aa5ac150d414359642d85f1aa434e5db/filters" | jq -r '.result[0] .id'
However when I try to use it in a bash script, I get no output at all
FWRID="$(curl -X GET \
-H "X-Auth-Email: REDACTED" \
-H "X-Auth-Key: REDACTED" \
"https://api.cloudflare.com/client/v4/zones/aa5ac150d414359642d85f1aa434e5db/filters")" | jq -r '.result[0] .id'
echo "$FWRID"
Any help would be most appreciated.