AWS CloudWatch Logs

Integration with LogicHub

Connecting with Amazon CloudWatchLogs

To connect with Amazon CloudWatchLogs following details are required:

  • Label: Connection name.
  • Reference Values: Define variables here to templatize integration connections and actions. For example, you can use https://www.{{hostname}}.com where, hostname is a variable defined in this input. For more information on how to add data, see 'Add Data' Input Type for Integrations.
  • Region Name: Valid AWS Region Name. (To get a list of available regions, refer to this link).
  • Access Key: AWS Account Access Key.
  • Secret Key: AWS Account Secret Key.

Actions with Amazon CloudWatchLogs

Get Log Events

Lists log events from the specified log stream.

Inputs to this Action

  • Connection: Choose a connection that you have created.
  • Log Group Column name: Column name from parent table holding value for Log Group.
  • Log Stream Column name: Column name from parent table holding value for Log Stream.
  • Start Time Column name (Optional): Column name from parent table holding value for Start Time, expressed as epoch seconds (default is Batch start time). Events with a timestamp equal to this time or later than this time are included.
  • End Time Column name (Optional): Column name from parent table holding value for End Time, expressed as epoch seconds (default is Batch end time). Events with a timestamp later than this time are not returned.
  • Limit Column name(Optional): Column name from parent table holding value for Limit. The maximum number of events to return (default is 1,000 events).

Output of Action
JSON containing following items:

  • has_error: True/False
  • error: message/null
  • result: List of dictionaries in which each dict describes a log event.

Filter Log Events

Lists log events from the specified log group.

Inputs to this Action

  • Connection: Choose a connection that you have created.
  • Log Group Column name: Column name from parent table holding value for Log Group.
  • Jinja Template for Log Stream: Jinja template holding value for Log Streams (Default is all streams). Example: {{stream1}},{{stream2}}.
  • Log Stream Prefix Column name: Column name from parent table holding value for Log Stream Prefix (default is all streams).
  • Start Time Column name (Optional): Column name from parent table holding value for Start Time, expressed as epoch seconds (default is Batch start time). Events with a timestamp equal to this time or later than this time are included.
  • End Time Column name (Optional): Column name from parent table holding value for End Time, expressed as epoch seconds (default is Batch end time). Events with a timestamp later than this time are not returned.
  • Jinja Template for Filter Pattern: Jinja template holding value for Filter Pattern (Default is no filter). Example: {{msg1}} {{msg2}}. For more information, see Filter and Pattern Syntax.
  • Limit Column name (Optional): Column name from parent table holding value for Limit. The maximum number of events to return (default is 1,000 events).

Output of Action
JSON containing the following items:

  • has_error: True/False
  • error: message/null
  • result: List of dictionaries in which each dict describes a log event.

Did this page help you?