Created
August 2, 2019 12:04
-
-
Save dooferlad/3ce7e7d3276d5ede5fea039febd37dbb to your computer and use it in GitHub Desktop.
Search Loggly on the command line
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -H 'Authorization: bearer $LOGGLY_APIKEY' "http://octoenergy.loggly.com/apiv2/events?rsid=$(curl -H 'Authorization: bearer $LOGGLY_APIKEY' "http://octoenergy.loggly.com/apiv2/search?q=$1" | jq .rsid.id | xargs)" | jq $2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Obviously need to set
$LOGGLY_APIKEY
as well as install curl and jq.Usage:
logglyq
<search>
<query>