Returns the accounts that are sending traffic to, or receiving traffic from, resources in a monitor, but that aren't included in the monitoring scope for the monitor. By adding the suggested accounts to your scope, you enable Network Flow Monitor to resolve the network paths for that traffic.
Parameters:
-
monitor_arn
(MonitorArn)
–
The Amazon Resource Name (ARN) of the monitor that you want to return scope suggestions for.
-
max_results
(Optional[MaxResults], default:
None
)
–
The number of query results that you want to return with this call.
-
next_token
(Optional[str], default:
None
)
–
The token for the next set of results. You receive this token from a previous call.
Raises:
Source code in docs_src/capo_networkflowmonitor/_services/async_network_flow_monitor.py
| async def get_monitor_scope_suggestions(
self,
monitor_arn: "capo_networkflowmonitor.types.monitor_arn.MonitorArn",
*,
config_overrides: Optional[AsyncNetworkFlowMonitorClientConfig] = None,
max_results: Optional[
"capo_networkflowmonitor.types.max_results.MaxResults"
] = None,
next_token: Optional[str] = None,
) -> "capo_networkflowmonitor.types.get_monitor_scope_suggestions_output.GetMonitorScopeSuggestionsOutput":
"""<p>Returns the accounts that are sending traffic to, or receiving traffic from, resources in a monitor, but that aren't included in the monitoring scope for the monitor. By adding the suggested accounts to your scope, you enable Network Flow Monitor to resolve the network paths for that traffic.</p>
Args:
monitor_arn: <p>The Amazon Resource Name (ARN) of the monitor that you want to return scope suggestions for.</p>
max_results: <p>The number of query results that you want to return with this call.</p>
next_token: <p>The token for the next set of results. You receive this token from a previous call.</p>
Raises:
capo_networkflowmonitor.errors.access_denied_exception.AccessDeniedException: <p>You don't have sufficient permission to perform this action.</p>
capo_networkflowmonitor.errors.internal_server_exception.InternalServerException: <p>An internal error occurred.</p>
capo_networkflowmonitor.errors.resource_not_found_exception.ResourceNotFoundException: <p>The request specifies a resource that doesn't exist.</p>
capo_networkflowmonitor.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling.</p>
capo_networkflowmonitor.errors.validation_exception.ValidationException: <p>Invalid request.</p>
capo_networkflowmonitor.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_networkflowmonitor.types.get_monitor_scope_suggestions_input.GetMonitorScopeSuggestionsInput]",
) -> AsyncOperationResponse[
"capo_networkflowmonitor.types.get_monitor_scope_suggestions_output.GetMonitorScopeSuggestionsOutput"
]:
import capo_networkflowmonitor._operations.network_flow_monitor.get_monitor_scope_suggestions
(
output,
http_response,
) = await capo_networkflowmonitor._operations.network_flow_monitor.get_monitor_scope_suggestions.async_get_monitor_scope_suggestions(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("GetMonitorScopeSuggestions")
)
input_: capo_networkflowmonitor.types.get_monitor_scope_suggestions_input.GetMonitorScopeSuggestionsInput = {
"monitor_arn": monitor_arn
}
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|