describe_auto_scaling_instances ( $opt )

Returns a description of each Auto Scaling instance in the InstanceIds list. If a list is not provided, the service returns the full details of all instances up to a maximum of 50. By default, the service returns a list of 20 items.

This action supports pagination by returning a token if there are more pages to retrieve. To get the next page, call this action again with the returned token as the NextToken parameter.

Access

public

Parameters

Parameter

Type

Required

Description

$opt

array

Optional

An associative array of parameters that can have the following keys:

  • InstanceIds - string|array - Optional - The list of Auto Scaling instances to describe. If this list is omitted, all auto scaling instances are described. The list of requested instances cannot contain more than 50 items. If unknown instances are requested, they are ignored with no error. Pass a string for a single value, or an indexed array for multiple values.
  • MaxRecords - integer - Optional - The maximum number of Auto Scaling instances to be described with each call.
  • NextToken - string - Optional - The token returned by a previous call to indicate that there is more data available. [Constraints: The value must match the following regular expression pattern: [\u0020-\uD7FF\uE000-\uFFFD\uD800\uDC00-\uDBFF\uDFFF\r\n\t]*]
  • curlopts - array - Optional - A set of values to pass directly into curl_setopt(), where the key is a pre-defined CURLOPT_* constant.
  • returnCurlHandle - boolean - Optional - A private toggle specifying that the cURL handle be returned rather than actually completing the request. This toggle is useful for manually managed batch requests.

Returns

Type

Description

CFResponse

A CFResponse object containing a parsed HTTP response.

Examples

Describe all auto scaling instances.

// Instantiate the class
$as = new AmazonAS();

$response = $as->describe_auto_scaling_instances();

// Success?
var_dump($response->isOK());
Result:
bool(true)

Related Methods

Source

Method defined in services/as.class.php | Toggle source view (15 lines) | View on GitHub

public function describe_auto_scaling_instances($opt = null)
{
    if (!$opt) $opt = array();
            
    // Optional list (non-map)
    if (isset($opt['InstanceIds']))
    {
        $opt = array_merge($opt, CFComplexType::map(array(
            'InstanceIds' => (is_array($opt['InstanceIds']) ? $opt['InstanceIds'] : array($opt['InstanceIds']))
        ), 'member'));
        unset($opt['InstanceIds']);
    }

    return $this->authenticate('DescribeAutoScalingInstances', $opt);
}

Copyright © 2010–2013 Amazon Web Services, LLC


Feedback