Amazon EC2 Auto Scaling Ec2 Auto Scaling Load Balancer Target Group API

The Ec2 Auto Scaling Load Balancer Target Group API from Amazon EC2 Auto Scaling — 3 operation(s) for ec2 auto scaling load balancer target group.

GitHub OpenAPI

Operations 3

POST /?Action=AttachLoadBalancerTargetGroups Attach Load Balancer Target Groups #
POST /?Action=DescribeLoadBalancerTargetGroups Describe Load Balancer Target Groups #
POST /?Action=DetachLoadBalancerTargetGroups Detach Load Balancer Target Groups #

Documentation

Specifications

Schemas & Data

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/amazon-ec2-auto-scaling:amazon-ec2-auto-scaling-load-balancer-target-group-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

amazon-ec2-auto-scaling-load-balancer-target-group-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Auto Scaling Load Balancer Target Group API
  version: '2011-01-01'
  description: Generated from AWS's published Smithy model for Auto Scaling. 3 operation(s).
  contact:
    name: Amazon Web Services
    url: https://aws.amazon.com/contact-us/
  license:
    name: Apache 2.0
    identifier: Apache-2.0
    url: https://github.com/aws/api-models-aws/blob/main/LICENSE
servers:
- url: https://autoscaling.{region}.amazonaws.com
  variables:
    region:
      default: us-east-1
security:
- sigv4: []
paths:
  /?Action=AttachLoadBalancerTargetGroups:
    post:
      operationId: AttachLoadBalancerTargetGroups
      summary: Attach Load Balancer Target Groups
      description: 'This API operation is superseded by AttachTrafficSources, which can attach multiple traffic sources types.
        We recommend using AttachTrafficSources to simplify how you manage traffic sources. However, we continue to support
        AttachLoadBalancerTargetGroups. You can use both the original AttachLoadBalancerTargetGroups API operation and AttachTrafficSources
        on the same Auto Scaling group. Attaches one or more target groups to the specified Auto Scaling group. This operation
        is used with the following load balancer types: Application Load Balancer - Operates at the application layer (layer
        7) and supports HTTP and HTTPS. Network Load Balancer - Operates at the transport layer (layer 4) and supports TCP,
        TLS, and UDP. Gateway Load Balancer - Operates at the network layer (layer 3). To describe the target groups for an
        Auto Scaling group, call the DescribeLoadBalancerTargetGroups API. To detach the target group from the Auto Scaling
        group, call the DetachLoadBalancerTargetGroups API. This operation is additive and does not detach existing target
        groups or Classic Load Balancers from the Auto Scaling group. For more information, see Use Elastic Load Balancing
        to distribute traffic across th'
      responses:
        '200':
          description: Success
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/AttachLoadBalancerTargetGroupsResultType'
        '400':
          description: InstanceRefreshInProgressFault
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/InstanceRefreshInProgressFault'
        '500':
          description: ResourceContentionFault; ServiceLinkedRoleFailure
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/ResourceContentionFault'
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              allOf:
              - type: object
                required:
                - Action
                - Version
                properties:
                  Action:
                    type: string
                    const: AttachLoadBalancerTargetGroups
                  Version:
                    type: string
                    const: '2011-01-01'
              - $ref: '#/components/schemas/AttachLoadBalancerTargetGroupsType'
            example:
              AutoScalingGroupName: my-auto-scaling-group
              TargetGroupARNs:
              - arn:aws:elasticloadbalancing:us-west-2:123456789012:targetgroup/my-targets/73e2d6bc24d8a067
      tags:
      - Load Balancer Target Group
  /?Action=DescribeLoadBalancerTargetGroups:
    post:
      operationId: DescribeLoadBalancerTargetGroups
      summary: Describe Load Balancer Target Groups
      description: 'This API operation is superseded by DescribeTrafficSources, which can describe multiple traffic sources
        types. We recommend using DetachTrafficSources to simplify how you manage traffic sources. However, we continue to
        support DescribeLoadBalancerTargetGroups. You can use both the original DescribeLoadBalancerTargetGroups API operation
        and DescribeTrafficSources on the same Auto Scaling group. Gets information about the Elastic Load Balancing target
        groups for the specified Auto Scaling group. To determine the attachment status of the target group, use the State
        element in the response. When you attach a target group to an Auto Scaling group, the initial State value is Adding.
        The state transitions to Added after all Auto Scaling instances are registered with the target group. If Elastic Load
        Balancing health checks are enabled for the Auto Scaling group, the state transitions to InService after at least
        one Auto Scaling instance passes the health check. When the target group is in the InService state, Amazon EC2 Auto
        Scaling can terminate and replace any instances that are reported as unhealthy. If no registered instances pass the
        health checks, the target group doesn''t enter the '
      responses:
        '200':
          description: Success
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/DescribeLoadBalancerTargetGroupsResponse'
              example:
                LoadBalancerTargetGroups:
                - LoadBalancerTargetGroupARN: arn:aws:elasticloadbalancing:us-west-2:123456789012:targetgroup/my-targets/73e2d6bc24d8a067
                  State: Added
        '400':
          description: InvalidNextToken
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/InvalidNextToken'
        '500':
          description: ResourceContentionFault
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/ResourceContentionFault'
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              allOf:
              - type: object
                required:
                - Action
                - Version
                properties:
                  Action:
                    type: string
                    const: DescribeLoadBalancerTargetGroups
                  Version:
                    type: string
                    const: '2011-01-01'
              - $ref: '#/components/schemas/DescribeLoadBalancerTargetGroupsRequest'
            example:
              AutoScalingGroupName: my-auto-scaling-group
      tags:
      - Load Balancer Target Group
  /?Action=DetachLoadBalancerTargetGroups:
    post:
      operationId: DetachLoadBalancerTargetGroups
      summary: Detach Load Balancer Target Groups
      description: This API operation is superseded by DetachTrafficSources, which can detach multiple traffic sources types.
        We recommend using DetachTrafficSources to simplify how you manage traffic sources. However, we continue to support
        DetachLoadBalancerTargetGroups. You can use both the original DetachLoadBalancerTargetGroups API operation and DetachTrafficSources
        on the same Auto Scaling group. Detaches one or more target groups from the specified Auto Scaling group. When you
        detach a target group, it enters the Removing state while deregistering the instances in the group. When all instances
        are deregistered, then you can no longer describe the target group using the DescribeLoadBalancerTargetGroups API
        call. The instances remain running. You can use this operation to detach target groups that were attached by using
        AttachLoadBalancerTargetGroups, but not for target groups that were attached by using AttachTrafficSources.
      responses:
        '200':
          description: Success
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/DetachLoadBalancerTargetGroupsResultType'
        '500':
          description: ResourceContentionFault
          content:
            text/xml:
              schema:
                $ref: '#/components/schemas/ResourceContentionFault'
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              allOf:
              - type: object
                required:
                - Action
                - Version
                properties:
                  Action:
                    type: string
                    const: DetachLoadBalancerTargetGroups
                  Version:
                    type: string
                    const: '2011-01-01'
              - $ref: '#/components/schemas/DetachLoadBalancerTargetGroupsType'
            example:
              AutoScalingGroupName: my-auto-scaling-group
              TargetGroupARNs:
              - arn:aws:elasticloadbalancing:us-west-2:123456789012:targetgroup/my-targets/73e2d6bc24d8a067
      tags:
      - Load Balancer Target Group
components:
  securitySchemes:
    sigv4:
      type: apiKey
      in: header
      name: Authorization
      description: AWS Signature Version 4. The Authorization header carries an AWS4-HMAC-SHA256 signature over the canonical
        request, with X-Amz-Date (and X-Amz-Security-Token for temporary credentials). Not a bearer token.
      x-aws-sigv4:
        signingName: autoscaling
  schemas:
    AttachLoadBalancerTargetGroupsResultType:
      type: object
      properties: {}
    AttachLoadBalancerTargetGroupsType:
      type: object
      properties:
        AutoScalingGroupName:
          type: string
          description: The name of the Auto Scaling group.
        TargetGroupARNs:
          type: array
          items:
            type: string
          description: The Amazon Resource Names (ARNs) of the target groups. You can specify up to 10 target groups. To get
            the ARN of a target group, use the Elastic Load Balancing DescribeTargetGroups API operation.
      required:
      - AutoScalingGroupName
      - TargetGroupARNs
    DescribeLoadBalancerTargetGroupsRequest:
      type: object
      properties:
        AutoScalingGroupName:
          type: string
          description: The name of the Auto Scaling group.
        NextToken:
          type: string
          description: The token for the next set of items to return. (You received this token from a previous call.)
        MaxRecords:
          type: integer
          description: The maximum number of items to return with this call. The default value is 100 and the maximum value
            is 100.
      required:
      - AutoScalingGroupName
    DescribeLoadBalancerTargetGroupsResponse:
      type: object
      properties:
        LoadBalancerTargetGroups:
          type: array
          items:
            $ref: '#/components/schemas/LoadBalancerTargetGroupState'
          description: Information about the target groups.
        NextToken:
          type: string
          description: A string that indicates that the response contains more items than can be returned in a single response.
            To receive additional items, specify this string for the NextToken value when requesting the next set of items.
            This value is null when there are no more items to return.
    DetachLoadBalancerTargetGroupsResultType:
      type: object
      properties: {}
    DetachLoadBalancerTargetGroupsType:
      type: object
      properties:
        AutoScalingGroupName:
          type: string
          description: The name of the Auto Scaling group.
        TargetGroupARNs:
          type: array
          items:
            type: string
          description: The Amazon Resource Names (ARN) of the target groups. You can specify up to 10 target groups.
      required:
      - AutoScalingGroupName
      - TargetGroupARNs
    InstanceRefreshInProgressFault:
      type: object
      properties:
        message:
          type: string
    InvalidNextToken:
      type: object
      properties:
        message:
          type: string
    LoadBalancerTargetGroupState:
      type: object
      properties:
        LoadBalancerTargetGroupARN:
          type: string
          description: The Amazon Resource Name (ARN) of the target group.
        State:
          type: string
          description: 'The state of the target group. Adding - The Auto Scaling instances are being registered with the target
            group. Added - All Auto Scaling instances are registered with the target group. InService - At least one Auto
            Scaling instance passed an ELB health check. Note that the target group enters this state immediately if you attach
            it in the CreateAutoScalingGroup API call. Removing - The Auto Scaling instances are being deregistered from the
            target group. If connection draining is enabled, Elastic Load Balancing waits for in-flight requests to complete
            before deregistering the instances. Removed '
    ResourceContentionFault:
      type: object
      properties:
        message:
          type: string
x-provenance:
  method: harvested
  publisher: Amazon Web Services
  source: https://raw.githubusercontent.com/aws/api-models-aws/3cd98287b471c106254abd89279cc87308d38bfd/models/auto-scaling/service/2011-01-01/auto-scaling-2011-01-01.json
  note: converted by smithy-to-openapi.py from AWS's Smithy model (roadmap#1001)