API Reference
The Amazon EC2 API allows developers to launch and control instances from their own programs. This
API follows the SOAP and WSDL standards, making it accessible from any language for which suitable
libraries exist.
This section discusses the messages available in the Amazon EC2 SOAP API, the semantics of those
calls and the parameters that must be supplied. Examples of SOAP requests and responses are also
provided.
We recommend you familiarize yourself with the conventions we've used in describing the API.
Amazon EC2
Developer Guide
52
API Conventions
Overview
This topic discusses the conventions used in the Amazon EC2 SOAP API reference. This includes
terminology, notation and any abbreviations used to illuminate the API.
The API reference is broken down into a collection of Operations and Data Types.
Operations
Operations encapsulate the possible interactions with Amazon EC2. These can be viewed as remote
procedure calls and consist of a request and response message pair. Requests must be signed, allowing
Amazon EC2 to authenticate the caller. For clarity, the sample requests and responses illustrating each
of the operations described in this reference are not signed.
Data Types and the Amazon EC2 WSDL
The current version of the Amazon EC2 WSDL is available at the following location:
http://ec2.amazonaws.com/doc/2006-06-26/AmazonEC2.wsdl. Some libraries can generate code directly
from the WSDL. Other libraries require a little more work on your part.
Values provided as parameters to the various operations must be of the indicated type. Standard XSD
types (like string, boolean, int) are prefixed with xsd:. Complex types defined by the
Amazon EC2 WSDL are prefixed with ec2:.
Parameters that consist of lists of information are defined within our WSDL to require <info> tags
around each member. Throughout the API, type references for parameters that accept such a list of
values are specified using the notation type[] The type referred to in these instances is the type nested
within the <info> tag (for Amazon EC2 types this is defined in the WSDL).
For example, the <imagesSet> element in the following XML snippet is of type xsd:string[]:
<imagesSet>
<item>
<imageId>ami-61a54008</imageId>
</item>
<item>
<imageId>ami-61b54608</imageId>
</item>
</imagesSet>
And the <instancesSet> element in the following XML snippet is of type
ec2:RunInstanceItemType[]:
<instancesSet>
<item>
<imageId>ami-60a54009</imageId>
<minCount>10</minCount>
<maxCount>30</maxCount>
</item>
<item>
<imageId>ami-60b54209</imageId>
<minCount>5</minCount>
<maxCount>20</maxCount>
</item>
</instancesSet>
Amazon EC2
Developer Guide
53
Previous Page Next Page