List Subscription Operations
Updated: June 7, 2012
The List Subscription Operations operation returns a list of create, update, and delete operations that were performed on a subscription during the specified timeframe.
Request
The List Subscription Operations request may be specified as follows. Replace the following parameters with your own:
-
<subscription-id>with your subscription ID -
<start-of-timeframe>with the start of the timeframe -
<end-of-timeframe>with the end of the timeframe -
<object-id>(optional) with the desired object from your subscription -
<Succeeded|Failed|InProgress>(optional) with the status of the subscription operation you want -
<opaque-continuation-token>(optional) with your continuation token from a previous request that returned too many results for one response
Note |
|---|
| Having trouble viewing this topic in the Windows Azure library? Try viewing it in the MSDN library. |
| Method | Request URI | HTTP Version |
|---|---|---|
|
GET |
|
HTTP/1.1 |
URI Parameters
| URI Parameter | Description | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
StartTime=<start-of-timeframe> |
Required. The start of the timeframe to begin listing subscription operations in UTC format. This parameter and the <end-of-timeframe> parameter indicate the timeframe to retrieve subscription operations. This parameter cannot indicate a start date of more than 90 days in the past. If you specify a time for this parameter, you must include the literal string “T” before the time, which indicates the start of the time element. Also, you must include the literal string “Z” after the time element, which indicates that the time is in UTC format. For example, a start time of March 1st, 2011 at 4:30PM would be expressed as follows: You can use the following time formats:
|
||||||||||||||||
|
EndTime=<end-of-timeframe> |
Required. The end of the timeframe to begin listing subscription operations in UTC format. This parameter and the <start-of-timeframe> parameter indicate the timeframe to retrieve subscription operations. If you specify a time for this parameter, you must include the literal string “T” before the time, which indicates the start of the time element. Also, you must include the literal string “Z” after the time element, which indicates that the time is in UTC format. For example, an end time of March 7st, 2011 at 4:30PM would be expressed as follows: You can use the following time formats:
|
||||||||||||||||
|
ObjectIdFilter=<object-url> |
Optional. Returns subscription operations only for the specified object type and object ID. This parameter must be set equal to the URL value for performing an HTTP GET on the object. If no object is specified, a filter is not applied. Applicable object types and examples are included below. Replace sample values such as
|
||||||||||||||||
|
OperationResultFilter=<Succeeded|Failed|InProgress> |
Optional. Returns subscription operations only for the specified result status, either
|
||||||||||||||||
|
ContinuationToken=<opaque-continuation-token> |
Optional. When there are too many operations to list, such as when the requested timeframe is very large, the response includes an incomplete list and a token that can be used to return the rest of the list. Subsequent requests must include this parameter to continue listing operations from where the last response left off. If no token is specified, a filter is not applied and the response will begin at the specified StartTime. |
Request Headers
The following table describes required and optional request headers.
| Request Header | Description |
|---|---|
|
x-ms-version |
Required. Specifies the version of the operation to use for this request. This header should be set to 2011-02-25 or later. The current version of this API is 2012-03-01. For more information about versioning headers, see Service Management Versioning. |
Request Body
None.
Response
The response includes an HTTP status code, a set of response headers, and a response body.
Status Code
A successful operation returns status code 200 (OK).
For information about status codes, see Service Management Status and Error Codes.
Response Headers
The response for this operation includes the following headers. The response may also include additional standard HTTP headers. All standard headers conform to the HTTP/1.1 protocol specification.
| Response Header | Description |
|---|---|
|
x-ms-request-id |
A value that uniquely identifies a request made against the management service. |
Response Body
The format for the 2011-06-01 version of the response body is as follows. The following sample response applies to an operation that was initiated by the Windows Azure Management Portal and has a string parameter value.
<?xml version="1.0" encoding="utf-8"?>
<SubscriptionOperationCollection xmlns="http://schemas.microsoft.com/windowsazure" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<SubscriptionOperations>
<SubscriptionOperation>
<OperationId>subscription-operation-id</OperationId>
<OperationObjectId>subscription-operation-object-id</OperationObjectId>
<OperationName>subscription-operation-name</OperationName>
<OperationParameters xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Samples.WindowsAzure.ServiceManagement">
<OperationParameter>
<a:Name>operation-parameter-name</a:Name>
<a:Value>operation-parameter-value</a:Value>
</OperationParameter>
</OperationParameters>
<OperationCaller>
<UsedServiceManagementApi>false</UsedServiceManagementApi>
<UserEmailAddress>user-email-address</UserEmailAddress>
</OperationCaller>
<OperationStatus>operation-status</OperationStatus>
<OperationStartedTime>operation-start-time</OperationStartedTime>
<OperationCompletedTime>operation-completed-time</OperationCompletedTime>
</SubscriptionOperation>
…
</SubscriptionOperations>
<ContinuationToken>continuation-token-value</ContinuationToken>
</SubscriptionOperationCollection>
The format for the 2011-06-01 version of the response body is as follows. The following sample response applies to an operation that was initiated by the Service Management API and has XML as the parameter value.
<?xml version="1.0" encoding="utf-8"?>
<SubscriptionOperationCollection xmlns="http://schemas.microsoft.com/windowsazure" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<SubscriptionOperations>
<SubscriptionOperation>
<OperationId>subscription-operation-id</OperationId>
<OperationObjectId>subscription-object-id</OperationObjectId>
<OperationName>subscription-operation-name</OperationName>
<OperationParameters xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Samples.WindowsAzure.ServiceManagement">
<OperationParameter>
<a:Name>operation-parameter-name</a:Name>
<a:Value><?xml version="1.0" encoding="utf-16"?>
<z:anyType xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:d1p1="http://schemas.microsoft.com/windowsazure" i:type="d1p1:<type-body>" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/">
…xml body…
</z:anyType>
</a:Value>
</OperationParameter>
</OperationParameters>
<OperationCaller>
<UsedServiceManagementApi>true</UsedServiceManagementApi>
<SubscriptionCertificateThumbprint>subscription-certificate-thumbprint</SubscriptionCertificateThumbprint>
<ClientIP>client-ip-address</ClientIP>
</OperationCaller>
<OperationStatus>operation-status</OperationStatus>
<OperationStartedTime>operation-start-time</OperationStartedTime>
<OperationCompletedTime>operation-completed-time</OperationCompletedTime>
</SubscriptionOperation>
…
</SubscriptionOperations>
<ContinuationToken>continuation-token-value</ContinuationToken>
</SubscriptionOperationCollection>
Note |
|---|
| The sample response bodies show the format of the latest version. If you are using an older version of the Service Management API, verify whether a specific element is available in the response by consulting the element description table. |
The following table describes the key elements in the response body:
| Element name | Description | ||
|---|---|---|---|
|
Subscription Operations |
The list of operations that have been performed on the subscription during the specified timeframe. |
||
|
Continuation Token |
The string that can be used to return the rest of the list. Subsequent requests must include this parameter to continue listing operations from where the last response left off. This element exists only if the complete list of subscription operations was not returned. |
||
|
Subscription Operation |
A single operation that has been performed on the subscription during the specified timeframe. |
||
|
Operation ID |
The globally unique identifier (GUID) of the operation. |
||
|
Operation Object ID |
The target object for the operation. This value is equal to the URL for performing an HTTP GET on the object, and corresponds to the same values for the ObjectIdFilter in the request. |
||
|
Operation Name |
The name of the performed operation. Possible values are:
|
||
|
Operation Parameters |
The collection of parameters for the performed operation. |
||
|
Operation Parameter |
A single parameter for the performed operation. |
||
|
Name |
The name of the parameter. |
||
|
Value |
The value of the parameter. The value can be represented as a string or an XML document, depending on the subscription operation that was performed. |
||
|
OperationCaller |
A collection of attributes that identifies the source of the operation. |
||
|
UsedServiceManagementApi |
Indicates whether the operation was initiated by using the Service Management API. False if it was initiated by another source, such as the Management Portal. |
||
|
UserEmailAddress |
The email associated with the Windows Live ID of the user who initiated the operation from the Management Portal. This element is returned only if UsedServiceManagementApi is |
||
|
ClientIP |
The IP address of the client computer that initiated the operation. This element is returned only if UsedServiceManagementApi is |
||
|
SubscriptionCertificateThumbprint |
The thumbprint of the subscription certificate used to initiate the operation. |
||
|
Operation Status |
An object that contains information on the current status of the operation. The object returned has the following XML format:
Possible values of the Status element, which holds the operation status, are:
|
||
|
OperationStartedTime |
The time that the operation started to execute. The format of the time is:
Example:
|
||
|
OperationCompletedTime |
The time that the operation finished executing. This element is not present if the operation is still in progress. The format of the time is:
Example:
|
Authorization
Any management certificate associated with the subscription specified by <subscription-id> can be used to authenticate this operation. For additional details, see Authenticating Service Management Requests.
Remarks
None.
Note