AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for the parameters to the DeregisterTargets operation. Deregisters the specified targets from the specified target group. After the targets are deregistered, they no longer receive traffic from the load balancer.

Inheritance Hierarchy


Namespace: Amazon.ElasticLoadBalancingV2.Model
Assembly: AWSSDK.ElasticLoadBalancingV2.dll
Version: 3.x.y.z


public class DeregisterTargetsRequest : AmazonElasticLoadBalancingV2Request

The DeregisterTargetsRequest type exposes the following members


Public Method DeregisterTargetsRequest()


Public Property TargetGroupArn System.String

Gets and sets the property TargetGroupArn.

The Amazon Resource Name (ARN) of the target group.

Public Property Targets System.Collections.Generic.List<Amazon.ElasticLoadBalancingV2.Model.TargetDescription>

Gets and sets the property Targets.

The targets. If you specified a port override when you registered a target, you must specify both the target ID and the port when you deregister it.


This example deregisters the specified instance from the specified target group.

To deregister a target from a target group

var response = client.DeregisterTargets(new DeregisterTargetsRequest 
    TargetGroupArn = "arn:aws:elasticloadbalancing:us-west-2:123456789012:targetgroup/my-targets/73e2d6bc24d8a067",
    Targets = new List {
        new TargetDescription { Id = "i-0f76fade" }


Version Information

.NET Standard:
Supported in: 1.3

.NET Framework:
Supported in: 4.5, 4.0, 3.5

Portable Class Library:
Supported in: Windows Store Apps
Supported in: Windows Phone 8.1
Supported in: Xamarin Android
Supported in: Xamarin iOS (Unified)
Supported in: Xamarin.Forms