I would like to check the "grade" my site has been assigned by SSL Labs to be sure it's not failing. (Norton uses this to decide if they should block a website, and mine was recently blocked)
The REST API URL and JSON response are at the bottom of this post.
What I need to identify is whether I have an "A" or "B" grade versus a "C", "D" or "F" grade.
Using the TEXT parser, I can't include quotes, so searching for "A" really isn't allowed. And if I just search for the letter A, that occurs everywhere.
For JSON I tried both ['endpoints'][1]['grade'] and I tried endpoints[1].grade. Neither worked.
I've never really got RegEx down, so if that's the only option, I'd really appreciate a specific search string to use.
Suggestions?
Thanks,
Pete
https://api.ssllabs.com/api/v2/analyze?host=www.governmenttools.com&fromCache=true
The JSON response is this:
{
"host": "www.governmenttools.com",
"port": 443,
"protocol": "HTTP",
"isPublic": false,
"status": "READY",
"startTime": 1468620780267,
"testTime": 1468620827254,
"engineVersion": "1.23.46",
"criteriaVersion": "2009l",
"endpoints": [
{
"ipAddress": "199.45.236.51",
"serverName": "sta-199-45-236-51.rockynet.com",
"statusMessage": "Ready",
"grade": "B",
"gradeTrustIgnored": "B",
"hasWarnings": false,
"isExceptional": false,
"progress": 100,
"duration": 46670,
"eta": 1,
"delegation": 2
}
]
}
We now support JsonPath and XPath expressions in the REST API Monitor. You can enter a path expression that contains your required conditions for a successful response. If the expression returns one or more results, the content check succeeds.