Skip to content

PatternToken

Source code in docs_src/capo_cloudwatch_logs/types/pattern_token.py
class PatternToken(TypedDict, closed=True):
    dynamic_token_position: (
        "capo_cloudwatch_logs.types.dynamic_token_position.DynamicTokenPosition"
    )
    """<p>For a dynamic token, this indicates where in the pattern that this token appears, related to other dynamic tokens. The dynamic token that appears first has a value of <code>1</code>, the one that appears second is <code>2</code>, and so on.</p>"""
    is_dynamic: NotRequired["capo_cloudwatch_logs.types.boolean.Boolean"]
    """<p>Specifies whether this is a dynamic token.</p>"""
    token_string: NotRequired["capo_cloudwatch_logs.types.token_string.TokenString"]
    """<p>The string represented by this token. If this is a dynamic token, the value will be <code><*></code> </p>"""
    enumerations: NotRequired["capo_cloudwatch_logs.types.enumerations.Enumerations"]
    """<p>Contains the values found for a dynamic token, and the number of times each value was found.</p>"""
    inferred_token_name: NotRequired[
        "capo_cloudwatch_logs.types.inferred_token_name.InferredTokenName"
    ]
    """<p>A name that CloudWatch Logs assigned to this dynamic token to make the pattern more readable. The string part of the <code>inferredTokenName</code> gives you a clearer idea of the content of this token. The number part of the <code>inferredTokenName</code> shows where in the pattern this token appears, compared to other dynamic tokens. CloudWatch Logs assigns the string part of the name based on analyzing the content of the log events that contain it.</p> <p>For example, an inferred token name of <code>IPAddress-3</code> means that the token represents an IP address, and this token is the third dynamic token in the pattern.</p>"""

dynamic_token_position instance-attribute

dynamic_token_position: DynamicTokenPosition

For a dynamic token, this indicates where in the pattern that this token appears, related to other dynamic tokens. The dynamic token that appears first has a value of 1, the one that appears second is 2, and so on.

enumerations instance-attribute

enumerations: NotRequired[Enumerations]

Contains the values found for a dynamic token, and the number of times each value was found.

inferred_token_name instance-attribute

inferred_token_name: NotRequired[InferredTokenName]

A name that CloudWatch Logs assigned to this dynamic token to make the pattern more readable. The string part of the inferredTokenName gives you a clearer idea of the content of this token. The number part of the inferredTokenName shows where in the pattern this token appears, compared to other dynamic tokens. CloudWatch Logs assigns the string part of the name based on analyzing the content of the log events that contain it.

For example, an inferred token name of IPAddress-3 means that the token represents an IP address, and this token is the third dynamic token in the pattern.

is_dynamic instance-attribute

is_dynamic: NotRequired[Boolean]

Specifies whether this is a dynamic token.

token_string instance-attribute

token_string: NotRequired[TokenString]

The string represented by this token. If this is a dynamic token, the value will be <*>