offers
Creates, updates, deletes, gets or lists an offers
resource.
Overview
Name | offers |
Type | Resource |
Id | azure_stack.subscriptions_admin.offers |
Fields
The following fields are returned by SELECT
queries:
- get
- list
- list_all
Name | Datatype | Description |
---|---|---|
id | string | URI of the resource. |
name | string | Name of the resource. |
location | string | Location of the resource |
properties | object | Represents an offering of services against which a subscription can be created. |
tags | object | List of key-value pairs. |
type | string | Type of resource. |
Name | Datatype | Description |
---|---|---|
id | string | URI of the resource. |
name | string | Name of the resource. |
location | string | Location of the resource |
properties | object | Represents an offering of services against which a subscription can be created. |
tags | object | List of key-value pairs. |
type | string | Type of resource. |
Name | Datatype | Description |
---|---|---|
id | string | URI of the resource. |
name | string | Name of the resource. |
location | string | Location of the resource |
properties | object | Represents an offering of services against which a subscription can be created. |
tags | object | List of key-value pairs. |
type | string | Type of resource. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | subscriptionId , resourceGroupName , offer | Get the specified offer. | |
list | select | subscriptionId , resourceGroupName | Get the list of offers under a resource group. | |
list_all | select | subscriptionId | Get the list of offers. | |
create_or_update | insert | subscriptionId , resourceGroupName , offer | Create or update the offer. | |
delete | delete | subscriptionId , resourceGroupName , offer | Delete the specified offer. | |
link | exec | subscriptionId , resourceGroupName , offer | Links a plan to an offer. | |
unlink | exec | subscriptionId , resourceGroupName , offer | Unlink a plan from an offer. |
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 |
---|---|---|
offer | string | Name of an offer. |
resourceGroupName | string | The resource group the resource is located under. |
subscriptionId | string | Subscription credentials which uniquely identify Microsoft Azure subscription.The subscription ID forms part of the URI for every service call. |
SELECT
examples
- get
- list
- list_all
Get the specified offer.
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure_stack.subscriptions_admin.offers
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND offer = '{{ offer }}' -- required
;
Get the list of offers under a resource group.
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure_stack.subscriptions_admin.offers
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
;
Get the list of offers.
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure_stack.subscriptions_admin.offers
WHERE subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create_or_update
- Manifest
Create or update the offer.
INSERT INTO azure_stack.subscriptions_admin.offers (
data__properties,
data__location,
subscriptionId,
resourceGroupName,
offer
)
SELECT
'{{ properties }}',
'{{ location }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ offer }}'
RETURNING
id,
name,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: offers
props:
- name: subscriptionId
value: string
description: Required parameter for the offers resource.
- name: resourceGroupName
value: string
description: Required parameter for the offers resource.
- name: offer
value: string
description: Required parameter for the offers resource.
- name: properties
value: object
description: |
Represents an offering of services against which a subscription can be created.
- name: location
value: string
description: |
Location of the resource
DELETE
examples
- delete
Delete the specified offer.
DELETE FROM azure_stack.subscriptions_admin.offers
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND offer = '{{ offer }}' --required
;
Lifecycle Methods
- link
- unlink
Links a plan to an offer.
EXEC azure_stack.subscriptions_admin.offers.link
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@offer='{{ offer }}' --required
@@json=
'{
"planName": "{{ planName }}",
"planLinkType": "{{ planLinkType }}",
"maxAcquisitionCount": {{ maxAcquisitionCount }}
}'
;
Unlink a plan from an offer.
EXEC azure_stack.subscriptions_admin.offers.unlink
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@offer='{{ offer }}' --required
@@json=
'{
"planName": "{{ planName }}",
"planLinkType": "{{ planLinkType }}",
"maxAcquisitionCount": {{ maxAcquisitionCount }}
}'
;