An attempt to list and view/tail the CloudWatch Logs.
Run cwlogs --help
for the complete list of options.
I wrote this to see if I could. There are quite likely faster or better ways to do this from the command line.
When you add --debug 1
the command will track some of the API calls and give a summary at the end, like this:
API queries sent: 42
This was done because I was scratching my head about the number of calls that were needed to walk the log data, which may require more calls when going in one direction than the other. This is also why there is a --reverse
option.
cwlogs --profile test-account --region us-east-1 --list
This will give you the 50 most recent lines, grouping the lines per date/time, while skipping lines with messages like INIT_START ...
, REPORT RequestId: ...
, etc.
cwlogs --profile test-account --region us-east-1 -t /aws/lambda/report -e 50 --noise --group
Check the freetier usage information of one or more accounts.
Run freetier --help
for the complete list of options.