marketplace_agreements
Creates, updates, deletes, gets or lists a marketplace_agreements resource.
Overview
| Name | marketplace_agreements |
| Type | Resource |
| Id | azure.marketplace_ordering.marketplace_agreements |
Fields
The following fields are returned by SELECT queries:
- get
- get_agreement
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
accepted | boolean | If any version of the terms have been accepted, otherwise false. |
licenseTextLink | string | Link to HTML with Microsoft and Publisher terms. |
marketplaceTermsLink | string | Link to HTML with Azure Marketplace terms. |
plan | string | Plan identifier string of image being deployed. |
privacyPolicyLink | string | Link to the privacy policy of the publisher. |
product | string | Offer identifier string of image being deployed. |
publisher | string | Publisher identifier string of image being deployed. |
retrieveDatetime | string | Date and time in UTC of when the terms were accepted. This is empty if Accepted is false. |
signature | string | Terms signature. |
systemData | object | The system meta data relating to this resource. |
type | string | Resource type. |
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
cancelDate | string (date-time) | Date and time in UTC of when the terms were cancelled. This is empty if state is active. |
offer | string | Offer identifier string of image being deployed. |
publisher | string | Publisher identifier string of image being deployed. |
signDate | string (date-time) | Date and time in UTC of when the terms were accepted. This is empty if state is cancelled. |
state | string | Whether the agreement is active or cancelled. Known values are: "Active" and "Canceled". |
type | string | Resource type. |
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
cancelDate | string (date-time) | Date and time in UTC of when the terms were cancelled. This is empty if state is active. |
offer | string | Offer identifier string of image being deployed. |
publisher | string | Publisher identifier string of image being deployed. |
signDate | string (date-time) | Date and time in UTC of when the terms were accepted. This is empty if state is cancelled. |
state | string | Whether the agreement is active or cancelled. Known values are: "Active" and "Canceled". |
type | string | Resource type. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | offer_type, publisher_id, offer_id, plan_id, subscription_id | Get marketplace terms. | |
get_agreement | select | publisher_id, offer_id, plan_id, subscription_id | Get marketplace agreement. | |
list | select | subscription_id | List marketplace agreements in the subscription. | |
create | insert | offer_type, publisher_id, offer_id, plan_id, subscription_id | Save marketplace terms. | |
sign | exec | publisher_id, offer_id, plan_id, subscription_id | Sign marketplace terms. | |
cancel | exec | publisher_id, offer_id, plan_id, subscription_id | Cancel marketplace terms. |
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_id | string | Offer identifier string of image being deployed. Required. |
offer_type | string | Offer Type, currently only virtualmachine type is supported. "virtualmachine" Required. |
plan_id | string | Plan identifier string of image being deployed. Required. |
publisher_id | string | Publisher identifier string of image being deployed. Required. |
subscription_id | string |
SELECT examples
- get
- get_agreement
- list
Get marketplace terms.
SELECT
id,
name,
accepted,
licenseTextLink,
marketplaceTermsLink,
plan,
privacyPolicyLink,
product,
publisher,
retrieveDatetime,
signature,
systemData,
type
FROM azure.marketplace_ordering.marketplace_agreements
WHERE offer_type = '{{ offer_type }}' -- required
AND publisher_id = '{{ publisher_id }}' -- required
AND offer_id = '{{ offer_id }}' -- required
AND plan_id = '{{ plan_id }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Get marketplace agreement.
SELECT
id,
name,
cancelDate,
offer,
publisher,
signDate,
state,
type
FROM azure.marketplace_ordering.marketplace_agreements
WHERE publisher_id = '{{ publisher_id }}' -- required
AND offer_id = '{{ offer_id }}' -- required
AND plan_id = '{{ plan_id }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
List marketplace agreements in the subscription.
SELECT
id,
name,
cancelDate,
offer,
publisher,
signDate,
state,
type
FROM azure.marketplace_ordering.marketplace_agreements
WHERE subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create
- Manifest
Save marketplace terms.
INSERT INTO azure.marketplace_ordering.marketplace_agreements (
properties,
offer_type,
publisher_id,
offer_id,
plan_id,
subscription_id
)
SELECT
'{{ properties }}',
'{{ offer_type }}',
'{{ publisher_id }}',
'{{ offer_id }}',
'{{ plan_id }}',
'{{ subscription_id }}'
RETURNING
id,
name,
properties,
systemData,
type
;
# Description fields are for documentation purposes
- name: marketplace_agreements
props:
- name: offer_type
value: "{{ offer_type }}"
description: Required parameter for the marketplace_agreements resource.
- name: publisher_id
value: "{{ publisher_id }}"
description: Required parameter for the marketplace_agreements resource.
- name: offer_id
value: "{{ offer_id }}"
description: Required parameter for the marketplace_agreements resource.
- name: plan_id
value: "{{ plan_id }}"
description: Required parameter for the marketplace_agreements resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the marketplace_agreements resource.
- name: properties
value:
publisher: "{{ publisher }}"
product: "{{ product }}"
plan: "{{ plan }}"
licenseTextLink: "{{ licenseTextLink }}"
privacyPolicyLink: "{{ privacyPolicyLink }}"
marketplaceTermsLink: "{{ marketplaceTermsLink }}"
retrieveDatetime: "{{ retrieveDatetime }}"
signature: "{{ signature }}"
accepted: {{ accepted }}
Lifecycle Methods
- sign
- cancel
Sign marketplace terms.
EXEC azure.marketplace_ordering.marketplace_agreements.sign
@publisher_id='{{ publisher_id }}' --required,
@offer_id='{{ offer_id }}' --required,
@plan_id='{{ plan_id }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Cancel marketplace terms.
EXEC azure.marketplace_ordering.marketplace_agreements.cancel
@publisher_id='{{ publisher_id }}' --required,
@offer_id='{{ offer_id }}' --required,
@plan_id='{{ plan_id }}' --required,
@subscription_id='{{ subscription_id }}' --required
;