<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>CloudWatch Reference &mdash; boto v2.33.0</title>
    
    <link rel="stylesheet" href="../_static/boto.css" type="text/css" />
    <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '../',
        VERSION:     'HEAD',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="../_static/jquery.js"></script>
    <script type="text/javascript" src="../_static/underscore.js"></script>
    <script type="text/javascript" src="../_static/doctools.js"></script>
    <link rel="top" title="boto v2.33.0" href="../index.html" />
    <link rel="next" title="Cognito Identity" href="cognito-identity.html" />
    <link rel="prev" title="CloudTrail" href="cloudtrail.html" /> 
  </head>
  <body>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="../genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="../py-modindex.html" title="Python Module Index"
             >modules</a> |</li>
        <li class="right" >
          <a href="cognito-identity.html" title="Cognito Identity"
             accesskey="N">next</a> |</li>
        <li class="right" >
          <a href="cloudtrail.html" title="CloudTrail"
             accesskey="P">previous</a> |</li>
        <li><a href="../index.html">boto v2.33.0</a> &raquo;</li> 
      </ul>
    </div>  

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="cloudwatch-reference">
<h1>CloudWatch Reference<a class="headerlink" href="#cloudwatch-reference" title="Permalink to this headline">¶</a></h1>
<div class="section" id="module-boto.ec2.cloudwatch">
<span id="boto-ec2-cloudwatch"></span><h2>boto.ec2.cloudwatch<a class="headerlink" href="#module-boto.ec2.cloudwatch" title="Permalink to this headline">¶</a></h2>
<p>This module provides an interface to the Elastic Compute Cloud (EC2)
CloudWatch service from AWS.</p>
<dl class="class">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.</tt><tt class="descname">CloudWatchConnection</tt><big>(</big><em>aws_access_key_id=None</em>, <em>aws_secret_access_key=None</em>, <em>is_secure=True</em>, <em>port=None</em>, <em>proxy=None</em>, <em>proxy_port=None</em>, <em>proxy_user=None</em>, <em>proxy_pass=None</em>, <em>debug=0</em>, <em>https_connection_factory=None</em>, <em>region=None</em>, <em>path='/'</em>, <em>security_token=None</em>, <em>validate_certs=True</em>, <em>profile_name=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection" title="Permalink to this definition">¶</a></dt>
<dd><p>Init method to create a new connection to EC2 Monitoring Service.</p>
<p>B{Note:} The host argument is overridden by the host specified in the
boto configuration file.</p>
<dl class="attribute">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.APIVersion">
<tt class="descname">APIVersion</tt><em class="property"> = '2010-08-01'</em><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.APIVersion" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="attribute">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.DefaultRegionEndpoint">
<tt class="descname">DefaultRegionEndpoint</tt><em class="property"> = 'monitoring.us-east-1.amazonaws.com'</em><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.DefaultRegionEndpoint" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="attribute">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.DefaultRegionName">
<tt class="descname">DefaultRegionName</tt><em class="property"> = 'us-east-1'</em><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.DefaultRegionName" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.build_dimension_param">
<tt class="descname">build_dimension_param</tt><big>(</big><em>dimension</em>, <em>params</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.build_dimension_param" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.build_list_params">
<tt class="descname">build_list_params</tt><big>(</big><em>params</em>, <em>items</em>, <em>label</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.build_list_params" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.build_put_params">
<tt class="descname">build_put_params</tt><big>(</big><em>params</em>, <em>name</em>, <em>value=None</em>, <em>timestamp=None</em>, <em>unit=None</em>, <em>dimensions=None</em>, <em>statistics=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.build_put_params" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.create_alarm">
<tt class="descname">create_alarm</tt><big>(</big><em>alarm</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.create_alarm" title="Permalink to this definition">¶</a></dt>
<dd><p>Creates or updates an alarm and associates it with the specified Amazon
CloudWatch metric. Optionally, this operation can associate one or more
Amazon Simple Notification Service resources with the alarm.</p>
<p>When this operation creates an alarm, the alarm state is immediately
set to INSUFFICIENT_DATA. The alarm is evaluated and its StateValue is
set appropriately. Any actions associated with the StateValue is then
executed.</p>
<p>When updating an existing alarm, its StateValue is left unchanged.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarm</strong> (<a class="reference internal" href="#boto.ec2.cloudwatch.alarm.MetricAlarm" title="boto.ec2.cloudwatch.alarm.MetricAlarm"><em>boto.ec2.cloudwatch.alarm.MetricAlarm</em></a>) &#8211; MetricAlarm object.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.delete_alarms">
<tt class="descname">delete_alarms</tt><big>(</big><em>alarms</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.delete_alarms" title="Permalink to this definition">¶</a></dt>
<dd><p>Deletes all specified alarms. In the event of an error, no
alarms are deleted.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarms</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; List of alarm names.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.describe_alarm_history">
<tt class="descname">describe_alarm_history</tt><big>(</big><em>alarm_name=None</em>, <em>start_date=None</em>, <em>end_date=None</em>, <em>max_records=None</em>, <em>history_item_type=None</em>, <em>next_token=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.describe_alarm_history" title="Permalink to this definition">¶</a></dt>
<dd><p>Retrieves history for the specified alarm. Filter alarms by date range
or item type. If an alarm name is not specified, Amazon CloudWatch
returns histories for all of the owner&#8217;s alarms.</p>
<p>Amazon CloudWatch retains the history of deleted alarms for a period of
six weeks. If an alarm has been deleted, its history can still be
queried.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>alarm_name</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The name of the alarm.</li>
<li><strong>start_date</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The starting date to retrieve alarm history.</li>
<li><strong>end_date</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The starting date to retrieve alarm history.</li>
<li><strong>history_item_type</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The type of alarm histories to retreive
(ConfigurationUpdate | StateUpdate | Action)</li>
<li><strong>max_records</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The maximum number of alarm descriptions
to retrieve.</li>
<li><strong>next_token</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The token returned by a previous call to indicate
that there is more data.</li>
</ul>
</td>
</tr>
</tbody>
</table>
<p>:rtype list</p>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.describe_alarms">
<tt class="descname">describe_alarms</tt><big>(</big><em>action_prefix=None</em>, <em>alarm_name_prefix=None</em>, <em>alarm_names=None</em>, <em>max_records=None</em>, <em>state_value=None</em>, <em>next_token=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.describe_alarms" title="Permalink to this definition">¶</a></dt>
<dd><p>Retrieves alarms with the specified names. If no name is specified, all
alarms for the user are returned. Alarms can be retrieved by using only
a prefix for the alarm name, the alarm state, or a prefix for any
action.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>action_name</strong> &#8211; The action name prefix.</li>
<li><strong>alarm_name_prefix</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The alarm name prefix. AlarmNames cannot
be specified if this parameter is specified.</li>
<li><strong>alarm_names</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; A list of alarm names to retrieve information for.</li>
<li><strong>max_records</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The maximum number of alarm descriptions
to retrieve.</li>
<li><strong>state_value</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The state value to be used in matching alarms.</li>
<li><strong>next_token</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The token returned by a previous call to
indicate that there is more data.</li>
</ul>
</td>
</tr>
</tbody>
</table>
<p>:rtype list</p>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.describe_alarms_for_metric">
<tt class="descname">describe_alarms_for_metric</tt><big>(</big><em>metric_name</em>, <em>namespace</em>, <em>period=None</em>, <em>statistic=None</em>, <em>dimensions=None</em>, <em>unit=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.describe_alarms_for_metric" title="Permalink to this definition">¶</a></dt>
<dd><p>Retrieves all alarms for a single metric. Specify a statistic, period,
or unit to filter the set of alarms further.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>metric_name</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The name of the metric</li>
<li><strong>namespace</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The namespace of the metric.</li>
<li><strong>period</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The period in seconds over which the statistic
is applied.</li>
<li><strong>statistic</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The statistic for the metric.</li>
<li><strong>dimension_filters</strong> &#8211; A dictionary containing name/value
pairs that will be used to filter the results.  The key in
the dictionary is the name of a Dimension.  The value in
the dictionary is either a scalar value of that Dimension
name that you want to filter on, a list of values to
filter on or None if you want all metrics with that
Dimension name.</li>
</ul>
</td>
</tr>
</tbody>
</table>
<p>:rtype list</p>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.disable_alarm_actions">
<tt class="descname">disable_alarm_actions</tt><big>(</big><em>alarm_names</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.disable_alarm_actions" title="Permalink to this definition">¶</a></dt>
<dd><p>Disables actions for the specified alarms.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarms</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; List of alarm names.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.enable_alarm_actions">
<tt class="descname">enable_alarm_actions</tt><big>(</big><em>alarm_names</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.enable_alarm_actions" title="Permalink to this definition">¶</a></dt>
<dd><p>Enables actions for the specified alarms.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarms</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; List of alarm names.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.get_metric_statistics">
<tt class="descname">get_metric_statistics</tt><big>(</big><em>period</em>, <em>start_time</em>, <em>end_time</em>, <em>metric_name</em>, <em>namespace</em>, <em>statistics</em>, <em>dimensions=None</em>, <em>unit=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.get_metric_statistics" title="Permalink to this definition">¶</a></dt>
<dd><p>Get time-series data for one or more statistics of a given metric.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>period</strong> (<em>integer</em>) &#8211; The granularity, in seconds, of the returned datapoints.
Period must be at least 60 seconds and must be a multiple
of 60. The default value is 60.</li>
<li><strong>start_time</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The time stamp to use for determining the
first datapoint to return. The value specified is
inclusive; results include datapoints with the time stamp
specified.</li>
<li><strong>end_time</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The time stamp to use for determining the
last datapoint to return. The value specified is
exclusive; results will include datapoints up to the time
stamp specified.</li>
<li><strong>metric_name</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The metric name.</li>
<li><strong>namespace</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The metric&#8217;s namespace.</li>
<li><strong>statistics</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; A list of statistics names Valid values:
Average | Sum | SampleCount | Maximum | Minimum</li>
<li><strong>dimensions</strong> (<a class="reference external" href="http://docs.python.org/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) &#8211; A dictionary of dimension key/values where
the key is the dimension name and the value
is either a scalar value or an iterator
of values to be associated with that
dimension.</li>
<li><strong>unit</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The unit for the metric.  Value values are:
Seconds | Microseconds | Milliseconds | Bytes | Kilobytes |
Megabytes | Gigabytes | Terabytes | Bits | Kilobits |
Megabits | Gigabits | Terabits | Percent | Count |
Bytes/Second | Kilobytes/Second | Megabytes/Second |
Gigabytes/Second | Terabytes/Second | Bits/Second |
Kilobits/Second | Megabits/Second | Gigabits/Second |
Terabits/Second | Count/Second | None</li>
</ul>
</td>
</tr>
<tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">list</p>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.list_metrics">
<tt class="descname">list_metrics</tt><big>(</big><em>next_token=None</em>, <em>dimensions=None</em>, <em>metric_name=None</em>, <em>namespace=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.list_metrics" title="Permalink to this definition">¶</a></dt>
<dd><p>Returns a list of the valid metrics for which there is recorded
data available.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>next_token</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; A maximum of 500 metrics will be returned
at one time.  If more results are available, the ResultSet
returned will contain a non-Null next_token attribute.
Passing that token as a parameter to list_metrics will
retrieve the next page of metrics.</li>
<li><strong>dimensions</strong> (<a class="reference external" href="http://docs.python.org/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) &#8211; A dictionary containing name/value
pairs that will be used to filter the results.  The key in
the dictionary is the name of a Dimension.  The value in
the dictionary is either a scalar value of that Dimension
name that you want to filter on or None if you want all
metrics with that Dimension name.  To be included in the
result a metric must contain all specified dimensions,
although the metric may contain additional dimensions beyond
the requested metrics.  The Dimension names, and values must
be strings between 1 and 250 characters long. A maximum of
10 dimensions are allowed.</li>
<li><strong>metric_name</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; The name of the Metric to filter against.  If None,
all Metric names will be returned.</li>
<li><strong>namespace</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; A Metric namespace to filter against (e.g. AWS/EC2).
If None, Metrics from all namespaces will be returned.</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.put_metric_alarm">
<tt class="descname">put_metric_alarm</tt><big>(</big><em>alarm</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.put_metric_alarm" title="Permalink to this definition">¶</a></dt>
<dd><p>Creates or updates an alarm and associates it with the specified Amazon
CloudWatch metric. Optionally, this operation can associate one or more
Amazon Simple Notification Service resources with the alarm.</p>
<p>When this operation creates an alarm, the alarm state is immediately
set to INSUFFICIENT_DATA. The alarm is evaluated and its StateValue is
set appropriately. Any actions associated with the StateValue is then
executed.</p>
<p>When updating an existing alarm, its StateValue is left unchanged.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarm</strong> (<a class="reference internal" href="#boto.ec2.cloudwatch.alarm.MetricAlarm" title="boto.ec2.cloudwatch.alarm.MetricAlarm"><em>boto.ec2.cloudwatch.alarm.MetricAlarm</em></a>) &#8211; MetricAlarm object.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.put_metric_data">
<tt class="descname">put_metric_data</tt><big>(</big><em>namespace</em>, <em>name</em>, <em>value=None</em>, <em>timestamp=None</em>, <em>unit=None</em>, <em>dimensions=None</em>, <em>statistics=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.put_metric_data" title="Permalink to this definition">¶</a></dt>
<dd><p>Publishes metric data points to Amazon CloudWatch. Amazon Cloudwatch
associates the data points with the specified metric. If the specified
metric does not exist, Amazon CloudWatch creates the metric. If a list
is specified for some, but not all, of the arguments, the remaining
arguments are repeated a corresponding number of times.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>namespace</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; The namespace of the metric.</li>
<li><strong>name</strong> (<em>str or list</em>) &#8211; The name of the metric.</li>
<li><strong>value</strong> (<em>float or list</em>) &#8211; The value for the metric.</li>
<li><strong>timestamp</strong> (<em>datetime or list</em>) &#8211; The time stamp used for the metric. If not specified,
the default value is set to the time the metric data was received.</li>
<li><strong>unit</strong> (<em>string or list</em>) &#8211; The unit of the metric.  Valid Values: Seconds |
Microseconds | Milliseconds | Bytes | Kilobytes |
Megabytes | Gigabytes | Terabytes | Bits | Kilobits |
Megabits | Gigabits | Terabits | Percent | Count |
Bytes/Second | Kilobytes/Second | Megabytes/Second |
Gigabytes/Second | Terabytes/Second | Bits/Second |
Kilobits/Second | Megabits/Second | Gigabits/Second |
Terabits/Second | Count/Second | None</li>
<li><strong>dimensions</strong> (<a class="reference external" href="http://docs.python.org/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) &#8211; Add extra name value pairs to associate
with the metric, i.e.:
{&#8216;name1&#8217;: value1, &#8216;name2&#8217;: (value2, value3)}</li>
<li><strong>statistics</strong> (<em>dict or list</em>) &#8211; <p>Use a statistic set instead of a value, for example:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="p">{</span><span class="s">&#39;maximum&#39;</span><span class="p">:</span> <span class="mi">30</span><span class="p">,</span> <span class="s">&#39;minimum&#39;</span><span class="p">:</span> <span class="mi">1</span><span class="p">,</span> <span class="s">&#39;samplecount&#39;</span><span class="p">:</span> <span class="mi">100</span><span class="p">,</span> <span class="s">&#39;sum&#39;</span><span class="p">:</span> <span class="mi">10000</span><span class="p">}</span>
</pre></div>
</div>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.set_alarm_state">
<tt class="descname">set_alarm_state</tt><big>(</big><em>alarm_name</em>, <em>state_reason</em>, <em>state_value</em>, <em>state_reason_data=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.set_alarm_state" title="Permalink to this definition">¶</a></dt>
<dd><p>Temporarily sets the state of an alarm. When the updated StateValue
differs from the previous value, the action configured for the
appropriate state is invoked. This is not a permanent change. The next
periodic alarm check (in about a minute) will set the alarm to its
actual state.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>alarm_name</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; Descriptive name for alarm.</li>
<li><strong>state_reason</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; Human readable reason.</li>
<li><strong>state_value</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; OK | ALARM | INSUFFICIENT_DATA</li>
<li><strong>state_reason_data</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; Reason string (will be jsonified).</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.CloudWatchConnection.update_alarm">
<tt class="descname">update_alarm</tt><big>(</big><em>alarm</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.CloudWatchConnection.update_alarm" title="Permalink to this definition">¶</a></dt>
<dd><p>Creates or updates an alarm and associates it with the specified Amazon
CloudWatch metric. Optionally, this operation can associate one or more
Amazon Simple Notification Service resources with the alarm.</p>
<p>When this operation creates an alarm, the alarm state is immediately
set to INSUFFICIENT_DATA. The alarm is evaluated and its StateValue is
set appropriately. Any actions associated with the StateValue is then
executed.</p>
<p>When updating an existing alarm, its StateValue is left unchanged.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarm</strong> (<a class="reference internal" href="#boto.ec2.cloudwatch.alarm.MetricAlarm" title="boto.ec2.cloudwatch.alarm.MetricAlarm"><em>boto.ec2.cloudwatch.alarm.MetricAlarm</em></a>) &#8211; MetricAlarm object.</td>
</tr>
</tbody>
</table>
</dd></dl>

</dd></dl>

<dl class="function">
<dt id="boto.ec2.cloudwatch.connect_to_region">
<tt class="descclassname">boto.ec2.cloudwatch.</tt><tt class="descname">connect_to_region</tt><big>(</big><em>region_name</em>, <em>**kw_params</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.connect_to_region" title="Permalink to this definition">¶</a></dt>
<dd><p>Given a valid region name, return a
<a class="reference internal" href="#boto.ec2.cloudwatch.CloudWatchConnection" title="boto.ec2.cloudwatch.CloudWatchConnection"><tt class="xref py py-class docutils literal"><span class="pre">boto.ec2.cloudwatch.CloudWatchConnection</span></tt></a>.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>region_name</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; The name of the region to connect to.</td>
</tr>
<tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body"><tt class="xref py py-class docutils literal"><span class="pre">boto.ec2.CloudWatchConnection</span></tt> or <tt class="docutils literal"><span class="pre">None</span></tt></td>
</tr>
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">A connection to the given region, or None if an invalid region
name is given</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="function">
<dt id="boto.ec2.cloudwatch.regions">
<tt class="descclassname">boto.ec2.cloudwatch.</tt><tt class="descname">regions</tt><big>(</big><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.regions" title="Permalink to this definition">¶</a></dt>
<dd><p>Get all available regions for the CloudWatch service.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">list</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">A list of <tt class="xref py py-class docutils literal"><span class="pre">boto.RegionInfo</span></tt> instances</td>
</tr>
</tbody>
</table>
</dd></dl>

</div>
<div class="section" id="module-boto.ec2.cloudwatch.datapoint">
<span id="boto-ec2-cloudwatch-datapoint"></span><h2>boto.ec2.cloudwatch.datapoint<a class="headerlink" href="#module-boto.ec2.cloudwatch.datapoint" title="Permalink to this headline">¶</a></h2>
<dl class="class">
<dt id="boto.ec2.cloudwatch.datapoint.Datapoint">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.datapoint.</tt><tt class="descname">Datapoint</tt><big>(</big><em>connection=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.datapoint.Datapoint" title="Permalink to this definition">¶</a></dt>
<dd><dl class="method">
<dt id="boto.ec2.cloudwatch.datapoint.Datapoint.endElement">
<tt class="descname">endElement</tt><big>(</big><em>name</em>, <em>value</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.datapoint.Datapoint.endElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.datapoint.Datapoint.startElement">
<tt class="descname">startElement</tt><big>(</big><em>name</em>, <em>attrs</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.datapoint.Datapoint.startElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

</dd></dl>

</div>
<div class="section" id="module-boto.ec2.cloudwatch.metric">
<span id="boto-ec2-cloudwatch-metric"></span><h2>boto.ec2.cloudwatch.metric<a class="headerlink" href="#module-boto.ec2.cloudwatch.metric" title="Permalink to this headline">¶</a></h2>
<dl class="class">
<dt id="boto.ec2.cloudwatch.metric.Metric">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.metric.</tt><tt class="descname">Metric</tt><big>(</big><em>connection=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric" title="Permalink to this definition">¶</a></dt>
<dd><dl class="attribute">
<dt id="boto.ec2.cloudwatch.metric.Metric.Statistics">
<tt class="descname">Statistics</tt><em class="property"> = ['Minimum', 'Maximum', 'Sum', 'Average', 'SampleCount']</em><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.Statistics" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="attribute">
<dt id="boto.ec2.cloudwatch.metric.Metric.Units">
<tt class="descname">Units</tt><em class="property"> = ['Seconds', 'Microseconds', 'Milliseconds', 'Bytes', 'Kilobytes', 'Megabytes', 'Gigabytes', 'Terabytes', 'Bits', 'Kilobits', 'Megabits', 'Gigabits', 'Terabits', 'Percent', 'Count', 'Bytes/Second', 'Kilobytes/Second', 'Megabytes/Second', 'Gigabytes/Second', 'Terabytes/Second', 'Bits/Second', 'Kilobits/Second', 'Megabits/Second', 'Gigabits/Second', 'Terabits/Second', 'Count/Second', None]</em><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.Units" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.metric.Metric.create_alarm">
<tt class="descname">create_alarm</tt><big>(</big><em>name</em>, <em>comparison</em>, <em>threshold</em>, <em>period</em>, <em>evaluation_periods</em>, <em>statistic</em>, <em>enabled=True</em>, <em>description=None</em>, <em>dimensions=None</em>, <em>alarm_actions=None</em>, <em>ok_actions=None</em>, <em>insufficient_data_actions=None</em>, <em>unit=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.create_alarm" title="Permalink to this definition">¶</a></dt>
<dd><p>Creates or updates an alarm and associates it with this metric.
Optionally, this operation can associate one or more
Amazon Simple Notification Service resources with the alarm.</p>
<p>When this operation creates an alarm, the alarm state is immediately
set to INSUFFICIENT_DATA. The alarm is evaluated and its StateValue is
set appropriately. Any actions associated with the StateValue is then
executed.</p>
<p>When updating an existing alarm, its StateValue is left unchanged.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>alarm</strong> (<a class="reference internal" href="#boto.ec2.cloudwatch.alarm.MetricAlarm" title="boto.ec2.cloudwatch.alarm.MetricAlarm"><em>boto.ec2.cloudwatch.alarm.MetricAlarm</em></a>) &#8211; MetricAlarm object.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.metric.Metric.describe_alarms">
<tt class="descname">describe_alarms</tt><big>(</big><em>period=None</em>, <em>statistic=None</em>, <em>dimensions=None</em>, <em>unit=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.describe_alarms" title="Permalink to this definition">¶</a></dt>
<dd><p>Retrieves all alarms for this metric. Specify a statistic, period,
or unit to filter the set of alarms further.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>period</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The period in seconds over which the statistic
is applied.</li>
<li><strong>statistic</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The statistic for the metric.</li>
<li><strong>dimension_filters</strong> &#8211; A dictionary containing name/value
pairs that will be used to filter the results.  The key in
the dictionary is the name of a Dimension.  The value in
the dictionary is either a scalar value of that Dimension
name that you want to filter on, a list of values to
filter on or None if you want all metrics with that
Dimension name.</li>
</ul>
</td>
</tr>
</tbody>
</table>
<p>:rtype list</p>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.metric.Metric.endElement">
<tt class="descname">endElement</tt><big>(</big><em>name</em>, <em>value</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.endElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.metric.Metric.query">
<tt class="descname">query</tt><big>(</big><em>start_time</em>, <em>end_time</em>, <em>statistics</em>, <em>unit=None</em>, <em>period=60</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.query" title="Permalink to this definition">¶</a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>start_time</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The time stamp to use for determining the
first datapoint to return. The value specified is
inclusive; results include datapoints with the time stamp
specified.</li>
<li><strong>end_time</strong> (<a class="reference external" href="http://docs.python.org/library/datetime.html#module-datetime" title="(in Python v2.7)"><em>datetime</em></a>) &#8211; The time stamp to use for determining the
last datapoint to return. The value specified is
exclusive; results will include datapoints up to the time
stamp specified.</li>
<li><strong>statistics</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#list" title="(in Python v2.7)"><em>list</em></a>) &#8211; A list of statistics names Valid values:
Average | Sum | SampleCount | Maximum | Minimum</li>
<li><strong>unit</strong> (<a class="reference external" href="http://docs.python.org/library/string.html#module-string" title="(in Python v2.7)"><em>string</em></a>) &#8211; The unit for the metric.  Value values are:
Seconds | Microseconds | Milliseconds | Bytes | Kilobytes |
Megabytes | Gigabytes | Terabytes | Bits | Kilobits |
Megabits | Gigabits | Terabits | Percent | Count |
Bytes/Second | Kilobytes/Second | Megabytes/Second |
Gigabytes/Second | Terabytes/Second | Bits/Second |
Kilobits/Second | Megabits/Second | Gigabits/Second |
Terabits/Second | Count/Second | None</li>
<li><strong>period</strong> (<em>integer</em>) &#8211; The granularity, in seconds, of the returned datapoints.
Period must be at least 60 seconds and must be a multiple
of 60. The default value is 60.</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.metric.Metric.startElement">
<tt class="descname">startElement</tt><big>(</big><em>name</em>, <em>attrs</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.metric.Metric.startElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

</dd></dl>

</div>
<div class="section" id="module-boto.ec2.cloudwatch.alarm">
<span id="boto-ec2-cloudwatch-alarm"></span><h2>boto.ec2.cloudwatch.alarm<a class="headerlink" href="#module-boto.ec2.cloudwatch.alarm" title="Permalink to this headline">¶</a></h2>
<dl class="class">
<dt id="boto.ec2.cloudwatch.alarm.AlarmHistoryItem">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.alarm.</tt><tt class="descname">AlarmHistoryItem</tt><big>(</big><em>connection=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.AlarmHistoryItem" title="Permalink to this definition">¶</a></dt>
<dd><dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.AlarmHistoryItem.endElement">
<tt class="descname">endElement</tt><big>(</big><em>name</em>, <em>value</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.AlarmHistoryItem.endElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.AlarmHistoryItem.startElement">
<tt class="descname">startElement</tt><big>(</big><em>name</em>, <em>attrs</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.AlarmHistoryItem.startElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="class">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.alarm.</tt><tt class="descname">MetricAlarm</tt><big>(</big><em>connection=None</em>, <em>name=None</em>, <em>metric=None</em>, <em>namespace=None</em>, <em>statistic=None</em>, <em>comparison=None</em>, <em>threshold=None</em>, <em>period=None</em>, <em>evaluation_periods=None</em>, <em>unit=None</em>, <em>description=''</em>, <em>dimensions=None</em>, <em>alarm_actions=None</em>, <em>insufficient_data_actions=None</em>, <em>ok_actions=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm" title="Permalink to this definition">¶</a></dt>
<dd><p>Creates a new Alarm.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>name</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Name of alarm.</li>
<li><strong>metric</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Name of alarm&#8217;s associated metric.</li>
<li><strong>namespace</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; The namespace for the alarm&#8217;s metric.</li>
<li><strong>statistic</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; The statistic to apply to the alarm&#8217;s associated
metric.
Valid values: SampleCount|Average|Sum|Minimum|Maximum</li>
<li><strong>comparison</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Comparison used to compare statistic with threshold.
Valid values: &gt;= | &gt; | &lt; | &lt;=</li>
<li><strong>threshold</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#float" title="(in Python v2.7)"><em>float</em></a>) &#8211; The value against which the specified statistic
is compared.</li>
<li><strong>period</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The period in seconds over which teh specified
statistic is applied.</li>
<li><strong>evaluation_periods</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) &#8211; The number of periods over which data is
compared to the specified threshold.</li>
<li><strong>unit</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Allowed Values are:
Seconds|Microseconds|Milliseconds,
Bytes|Kilobytes|Megabytes|Gigabytes|Terabytes,
Bits|Kilobits|Megabits|Gigabits|Terabits,
Percent|Count|
Bytes/Second|Kilobytes/Second|Megabytes/Second|
Gigabytes/Second|Terabytes/Second,
Bits/Second|Kilobits/Second|Megabits/Second,
Gigabits/Second|Terabits/Second|Count/Second|None</li>
<li><strong>description</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Description of MetricAlarm</li>
<li><strong>dimensions</strong> (<a class="reference external" href="http://docs.python.org/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) &#8211; <p>A dictionary of dimension key/values where
the key is the dimension name and the value
is either a scalar value or an iterator
of values to be associated with that
dimension.
Example: {</p>
<blockquote>
<div>&#8216;InstanceId&#8217;: [&#8216;i-0123456&#8217;, &#8216;i-0123457&#8217;],
&#8216;LoadBalancerName&#8217;: &#8216;test-lb&#8217;</div></blockquote>
<p>}</p>
</li>
<li><strong>alarm_actions</strong> (<em>list of strs</em>) &#8211; A list of the ARNs of the actions to take in
ALARM state</li>
<li><strong>insufficient_data_actions</strong> (<em>list of strs</em>) &#8211; A list of the ARNs of the actions to
take in INSUFFICIENT_DATA state</li>
<li><strong>ok_actions</strong> (<em>list of strs</em>) &#8211; A list of the ARNs of the actions to take in OK state</li>
</ul>
</td>
</tr>
</tbody>
</table>
<dl class="attribute">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.ALARM">
<tt class="descname">ALARM</tt><em class="property"> = 'ALARM'</em><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.ALARM" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="attribute">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.INSUFFICIENT_DATA">
<tt class="descname">INSUFFICIENT_DATA</tt><em class="property"> = 'INSUFFICIENT_DATA'</em><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.INSUFFICIENT_DATA" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="attribute">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.OK">
<tt class="descname">OK</tt><em class="property"> = 'OK'</em><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.OK" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.add_alarm_action">
<tt class="descname">add_alarm_action</tt><big>(</big><em>action_arn=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.add_alarm_action" title="Permalink to this definition">¶</a></dt>
<dd><p>Adds an alarm action, represented as an SNS topic, to this alarm.
What do do when alarm is triggered.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>action_arn</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; SNS topics to which notification should be
sent if the alarm goes to state ALARM.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.add_insufficient_data_action">
<tt class="descname">add_insufficient_data_action</tt><big>(</big><em>action_arn=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.add_insufficient_data_action" title="Permalink to this definition">¶</a></dt>
<dd><p>Adds an insufficient_data action, represented as an SNS topic, to
this alarm. What to do when the insufficient_data state is reached.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>action_arn</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; SNS topics to which notification should be
sent if the alarm goes to state INSUFFICIENT_DATA.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.add_ok_action">
<tt class="descname">add_ok_action</tt><big>(</big><em>action_arn=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.add_ok_action" title="Permalink to this definition">¶</a></dt>
<dd><p>Adds an ok action, represented as an SNS topic, to this alarm. What
to do when the ok state is reached.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>action_arn</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; SNS topics to which notification should be
sent if the alarm goes to state INSUFFICIENT_DATA.</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.delete">
<tt class="descname">delete</tt><big>(</big><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.delete" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.describe_history">
<tt class="descname">describe_history</tt><big>(</big><em>start_date=None</em>, <em>end_date=None</em>, <em>max_records=None</em>, <em>history_item_type=None</em>, <em>next_token=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.describe_history" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.disable_actions">
<tt class="descname">disable_actions</tt><big>(</big><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.disable_actions" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.enable_actions">
<tt class="descname">enable_actions</tt><big>(</big><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.enable_actions" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.endElement">
<tt class="descname">endElement</tt><big>(</big><em>name</em>, <em>value</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.endElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.set_state">
<tt class="descname">set_state</tt><big>(</big><em>value</em>, <em>reason</em>, <em>data=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.set_state" title="Permalink to this definition">¶</a></dt>
<dd><p>Temporarily sets the state of an alarm.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>value</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; OK | ALARM | INSUFFICIENT_DATA</li>
<li><strong>reason</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Reason alarm set (human readable).</li>
<li><strong>data</strong> (<a class="reference external" href="http://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) &#8211; Reason data (will be jsonified).</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.startElement">
<tt class="descname">startElement</tt><big>(</big><em>name</em>, <em>attrs</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.startElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarm.update">
<tt class="descname">update</tt><big>(</big><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarm.update" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="class">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarms">
<em class="property">class </em><tt class="descclassname">boto.ec2.cloudwatch.alarm.</tt><tt class="descname">MetricAlarms</tt><big>(</big><em>connection=None</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarms" title="Permalink to this definition">¶</a></dt>
<dd><p>Parses a list of MetricAlarms.</p>
<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarms.endElement">
<tt class="descname">endElement</tt><big>(</big><em>name</em>, <em>value</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarms.endElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

<dl class="method">
<dt id="boto.ec2.cloudwatch.alarm.MetricAlarms.startElement">
<tt class="descname">startElement</tt><big>(</big><em>name</em>, <em>attrs</em>, <em>connection</em><big>)</big><a class="headerlink" href="#boto.ec2.cloudwatch.alarm.MetricAlarms.startElement" title="Permalink to this definition">¶</a></dt>
<dd></dd></dl>

</dd></dl>

</div>
</div>


          </div>
        </div>
      </div>
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h3><a href="../index.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">CloudWatch Reference</a><ul>
<li><a class="reference internal" href="#module-boto.ec2.cloudwatch">boto.ec2.cloudwatch</a></li>
<li><a class="reference internal" href="#module-boto.ec2.cloudwatch.datapoint">boto.ec2.cloudwatch.datapoint</a></li>
<li><a class="reference internal" href="#module-boto.ec2.cloudwatch.metric">boto.ec2.cloudwatch.metric</a></li>
<li><a class="reference internal" href="#module-boto.ec2.cloudwatch.alarm">boto.ec2.cloudwatch.alarm</a></li>
</ul>
</li>
</ul>

  <h4>Previous topic</h4>
  <p class="topless"><a href="cloudtrail.html"
                        title="previous chapter">CloudTrail</a></p>
  <h4>Next topic</h4>
  <p class="topless"><a href="cognito-identity.html"
                        title="next chapter">Cognito Identity</a></p>
  <h3>This Page</h3>
  <ul class="this-page-menu">
    <li><a href="../_sources/ref/cloudwatch.txt"
           rel="nofollow">Show Source</a></li>
  </ul>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="../search.html" method="get">
      <input type="text" name="q" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script><div><a href="boto.pdf">PDF Version</a></div>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="../genindex.html" title="General Index"
             >index</a></li>
        <li class="right" >
          <a href="../py-modindex.html" title="Python Module Index"
             >modules</a> |</li>
        <li class="right" >
          <a href="cognito-identity.html" title="Cognito Identity"
             >next</a> |</li>
        <li class="right" >
          <a href="cloudtrail.html" title="CloudTrail"
             >previous</a> |</li>
        <li><a href="../index.html">boto v2.33.0</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
        &copy; Copyright 2009,2010, Mitch Garnaat.
      Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.2.3.
    </div>
  </body>
</html>