I'd like to generate a URL for AWS Cloud Watch Logs Insights page where I can customize the following parameters:
- The query string
- The log groups I'd like to search with-in
- The time range
I couldn't find any official documentation for the structure of the URL. Also no API (at least not in boto3) would help me in this.
Here is an example:
https://eu-west-1.console.aws.amazon.com/cloudwatch/home?region=eu-west-1#logsV2:logs-insights$3FqueryDetail$3D$257E$2528end$257E$25272021-07-18T20*3a59*3a59.000Z$257Estart$257E$25272021-07-15T21*3a00*3a00.000Z$257EtimeType$257E$2527ABSOLUTE$257Etz$257E$2527Local$257EeditorString$257E$2527fields*20*40timestamp*2c*20*40message*0a*7c*20sort*20*40timestamp*20desc*0a*7c*20filter*20*40message*20*3d*7e*20*22Exception*22*0a*7c*20limit*20200$257EisLiveTail$257Efalse$257EqueryId$257E$2527####$257Esource$257E$2528$257E$2527*2faws*2flambda*2f######$2529$2529$26tab$3Dlogs
What is the encoding used to generate the URL above?
I'm thinking about simply replace the strings above with the desired params, any better way to achieve this ?
