list_rules
¶
list_rules(
*,
config_overrides: Optional[CloudWatchEventsClientConfig] = None,
name_prefix: Optional[RuleName] = None,
event_bus_name: Optional[EventBusNameOrArn] = None,
next_token: Optional[NextToken] = None,
limit: Optional[LimitMax100] = None,
) -> ListRulesResponse
Lists your Amazon EventBridge rules. You can either list all the rules or you can provide a prefix to match to the rule names.
ListRules does not list the targets of a rule. To see the targets associated with a rule, use ListTargetsByRule.
Parameters:
-
name_prefix(Optional[RuleName], default:None) –The prefix matching the rule name.
-
event_bus_name(Optional[EventBusNameOrArn], default:None) –The name or ARN of the event bus to list the rules for. If you omit this, the default event bus is used.
-
next_token(Optional[NextToken], default:None) –The token returned by a previous call to retrieve the next set of results.
-
limit(Optional[LimitMax100], default:None) –The maximum number of results to return.
Raises:
-
InternalException–This exception occurs due to unexpected causes.
-
ResourceNotFoundException–An entity that you specified does not exist.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_cloudwatch_events/_services/cloud_watch_events.py
2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 | |