Hi All,
I have a curl command which works fine but I have trouble using that curl command in the json format. Please guide on how to correct this script to output the data.
==========================================================
</>
input {
exec {
command => "curl -X 'POST'
'https://my.imperva.com/api/stats/v1?account_id=#####&time_range=last_90_days&start=1610356734&end=1610356734&site_id=######&stats=bandwidth_timeseries&granularity=7200000'
-H 'accept: application/json'
-H 'x-API-Key: #####'
-H 'x-API-Id: #####'
-d '' -vvv"
codec => "json"
schedule => {every =>"10s"}
}
}
output {
stdout {codec => rubydebug}
}
</>