deleteServiceNetwork method
Deletes a service network. You can only delete the service network if there is no service or VPC associated with it. If you delete a service network, all resources related to the service network, such as the resource policy, auth policy, and access log subscriptions, are also deleted. For more information, see Delete a service network in the Amazon VPC Lattice User Guide.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter serviceNetworkIdentifier :
The ID or ARN of the service network.
Implementation
Future<void> deleteServiceNetwork({
required String serviceNetworkIdentifier,
}) async {
final response = await _protocol.send(
payload: null,
method: 'DELETE',
requestUri:
'/servicenetworks/${Uri.encodeComponent(serviceNetworkIdentifier)}',
exceptionFnMap: _exceptionFns,
);
}