Hello, i’ve been playing around with the Cloudflare API recently to monitor the status of my website and i was wondering if any of you also do that. If yes, feel free to share more about it .
Seems like people are curious so i am going to add my telegraf configuration here.
[[inputs.http]]
urls = [
"https://api.cloudflare.com/client/v4/zones/zxzxzxzxzxzxzxzxz/analytics/dashboard?continuous=true&since=-4320"
]
method = "GET"
headers = {"X-Auth-Email" = "zxzxzxzxzxzxzxzxz","X-Auth-Key" = "zxzxzxzxzxzxzxzxz","Content-Type" = "application/json"}
data_format = "json"
name_override = "Cloudflare_content_types"
json_query = "result.timeseries.1.requests.content_type"
interval = "1h"
and
[[inputs.http]]
urls = [
"https://api.cloudflare.com/client/v4/zones/zxzxzxzxzxzxzxzxz/analytics/dashboard?continuous=true&since=-4320"
]
method = "GET"
headers = {"X-Auth-Email" = "zxzxzxzxzxzxzxzxz","X-Auth-Key" = "zxzxzxzxzxzxzxzxz","Content-Type" = "application/json"}
data_format = "json"
name_override = "Cloudflare_http_statuses"
json_query = "result.timeseries.1.requests.http_status"
interval = "1h"
Now you use graphql? Can you show how its works on tekegraf?