reservation_order
Creates, updates, deletes, gets or lists a reservation_order resource.
Overview
| Name | reservation_order |
| Type | Resource |
| Id | azure.reservations.reservation_order |
Fields
The following fields are returned by SELECT queries:
- get
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
benefitStartTime | string (date-time) | This is the DateTime when the reservation benefit started. |
billingPlan | string | Represent the billing plans. Known values are: "Upfront" and "Monthly". (Upfront, Monthly) |
createdDateTime | string (date-time) | This is the DateTime when the reservation was created. |
displayName | string | Friendly name for user to easily identified the reservation. |
etag | integer | :vartype etag: int |
expiryDate | string (date) | This is the date when the reservation will expire. |
expiryDateTime | string (date-time) | This is the date-time when the reservation will expire. |
originalQuantity | integer | Total Quantity of the skus purchased in the reservation. |
planInformation | object | Information describing the type of billing plan for this reservation. |
provisioningState | string | Current state of the reservation. Known values are: "Creating", "PendingResourceHold", "ConfirmedResourceHold", "PendingBilling", "ConfirmedBilling", "Created", "Succeeded", "Cancelled", "Expired", "BillingFailed", "Failed", "Split", and "Merged". (Creating, PendingResourceHold, ConfirmedResourceHold, PendingBilling, ConfirmedBilling, Created, Succeeded, Cancelled, Expired, BillingFailed, Failed, Split, Merged) |
requestDateTime | string (date-time) | This is the DateTime when the reservation was initially requested for purchase. |
reservations | array | :vartype reservations: list[~azure.mgmt.reservations.models.ReservationResponse] |
reviewDateTime | string (date-time) | This is the date-time when the Azure Hybrid Benefit needs to be reviewed. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
term | string | Represent the term of reservation. Known values are: "P1Y", "P3Y", and "P5Y". (P1Y, P3Y, P5Y) |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
benefitStartTime | string (date-time) | This is the DateTime when the reservation benefit started. |
billingPlan | string | Represent the billing plans. Known values are: "Upfront" and "Monthly". (Upfront, Monthly) |
createdDateTime | string (date-time) | This is the DateTime when the reservation was created. |
displayName | string | Friendly name for user to easily identified the reservation. |
etag | integer | :vartype etag: int |
expiryDate | string (date) | This is the date when the reservation will expire. |
expiryDateTime | string (date-time) | This is the date-time when the reservation will expire. |
originalQuantity | integer | Total Quantity of the skus purchased in the reservation. |
planInformation | object | Information describing the type of billing plan for this reservation. |
provisioningState | string | Current state of the reservation. Known values are: "Creating", "PendingResourceHold", "ConfirmedResourceHold", "PendingBilling", "ConfirmedBilling", "Created", "Succeeded", "Cancelled", "Expired", "BillingFailed", "Failed", "Split", and "Merged". (Creating, PendingResourceHold, ConfirmedResourceHold, PendingBilling, ConfirmedBilling, Created, Succeeded, Cancelled, Expired, BillingFailed, Failed, Split, Merged) |
requestDateTime | string (date-time) | This is the DateTime when the reservation was initially requested for purchase. |
reservations | array | :vartype reservations: list[~azure.mgmt.reservations.models.ReservationResponse] |
reviewDateTime | string (date-time) | This is the date-time when the Azure Hybrid Benefit needs to be reviewed. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
term | string | Represent the term of reservation. Known values are: "P1Y", "P3Y", and "P5Y". (P1Y, P3Y, P5Y) |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | reservation_order_id | $expand | Get a specific ReservationOrder. Get the details of the ReservationOrder. |
list | select | Get all ReservationOrders. List of all the ReservationOrders that the user has access to in the current tenant. | ||
purchase | exec | reservation_order_id | Purchase ReservationOrder. Purchase ReservationOrder and create resource under the specified URI. | |
change_directory | exec | reservation_order_id | Change directory of ReservationOrder. Change directory (tenant) of ReservationOrder and all Reservation under it to specified tenant id. | |
calculate | exec | Calculate price for a ReservationOrder. Calculate price for placing a ReservationOrder. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
reservation_order_id | string | Order Id of the reservation. Required. |
$expand | string | May be used to expand the planInformation. Default value is None. |
SELECT examples
- get
- list
Get a specific ReservationOrder. Get the details of the ReservationOrder.
SELECT
id,
name,
benefitStartTime,
billingPlan,
createdDateTime,
displayName,
etag,
expiryDate,
expiryDateTime,
originalQuantity,
planInformation,
provisioningState,
requestDateTime,
reservations,
reviewDateTime,
systemData,
term,
type
FROM azure.reservations.reservation_order
WHERE reservation_order_id = '{{ reservation_order_id }}' -- required
AND $expand = '{{ $expand }}'
;
Get all ReservationOrders. List of all the ReservationOrders that the user has access to in the current tenant.
SELECT
id,
name,
benefitStartTime,
billingPlan,
createdDateTime,
displayName,
etag,
expiryDate,
expiryDateTime,
originalQuantity,
planInformation,
provisioningState,
requestDateTime,
reservations,
reviewDateTime,
systemData,
term,
type
FROM azure.reservations.reservation_order
;
Lifecycle Methods
- purchase
- change_directory
- calculate
Purchase ReservationOrder. Purchase ReservationOrder and create resource under the specified URI.
EXEC azure.reservations.reservation_order.purchase
@reservation_order_id='{{ reservation_order_id }}' --required
@@json=
'{
"sku": "{{ sku }}",
"location": "{{ location }}",
"properties": "{{ properties }}"
}'
;
Change directory of ReservationOrder. Change directory (tenant) of ReservationOrder and all Reservation under it to specified tenant id.
EXEC azure.reservations.reservation_order.change_directory
@reservation_order_id='{{ reservation_order_id }}' --required
@@json=
'{
"destinationTenantId": "{{ destinationTenantId }}"
}'
;
Calculate price for a ReservationOrder. Calculate price for placing a ReservationOrder.
EXEC azure.reservations.reservation_order.calculate
@@json=
'{
"sku": "{{ sku }}",
"location": "{{ location }}",
"properties": "{{ properties }}"
}'
;