aws logs put-metric-filter
Creates or updates a metric filter and associates it with the specified log group. AWS CLI reference
7 options Its page in the AWS CLI reference
Options
--apply-on-transformed-logsThis parameter is valid only for log groups that have an active log transformer.--emit-system-field-dimensionsA list of system fields to emit as additional dimensions in the generated metrics.--field-selection-criteriaA filter expression that specifies which log events should be processed by this metric filter based on system fields such as source account and source region.--filter-nameA name for the metric filter.--filter-patternA filter pattern for extracting metric data out of ingested log events.--log-group-nameThe name of the log group.--metric-transformationsA collection of information that defines how metric data gets emitted.