workspace_products
Creates, updates, deletes, gets or lists a workspace_products
resource.
Overview
Name | workspace_products |
Type | Resource |
Id | azure.api_management.workspace_products |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_service
The response body contains the specified Product entity.
Name | Datatype | Description |
---|---|---|
properties | object | Product entity contract properties. |
A Collection of the Product entities for the specified workspace in an API Management service instance.
Name | Datatype | Description |
---|---|---|
properties | object | Product entity contract properties. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | resourceGroupName , serviceName , workspaceId , productId , subscriptionId | Gets the details of the product specified by its identifier. | |
list_by_service | select | resourceGroupName , serviceName , workspaceId , subscriptionId | $filter , $top , $skip , expandGroups , tags | Lists a collection of products in the specified workspace in a service instance. |
create_or_update | insert | resourceGroupName , serviceName , workspaceId , productId , subscriptionId | If-Match | Creates or Updates a product. |
update | update | resourceGroupName , serviceName , workspaceId , productId , If-Match , subscriptionId | Update existing product details. | |
delete | delete | resourceGroupName , serviceName , workspaceId , productId , If-Match , subscriptionId | deleteSubscriptions | Delete product. |
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 |
---|---|---|
If-Match | string | ETag of the Entity. ETag should match the current entity state from the header response of the GET request or it should be * for unconditional update. |
productId | string | Product identifier. Must be unique in the current API Management service instance. |
resourceGroupName | string | The name of the resource group. The name is case insensitive. |
serviceName | string | The name of the API Management service. |
subscriptionId | string | The ID of the target subscription. |
workspaceId | string | Workspace identifier. Must be unique in the current API Management service instance. |
$filter | string | | Field | Usage | Supported operators | Supported functions |</br>|-------------|-------------|-------------|-------------|</br>| name | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |</br>| displayName | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |</br>| description | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |</br>| terms | filter | ge, le, eq, ne, gt, lt | substringof, contains, startswith, endswith |</br>| state | filter | eq | |</br>| groups | expand | | |</br> |
$skip | integer (int32) | Number of records to skip. |
$top | integer (int32) | Number of records to return. |
If-Match | string | ETag of the Entity. Not required when creating an entity, but required when updating an entity. |
deleteSubscriptions | boolean | Delete existing subscriptions associated with the product or not. |
expandGroups | boolean | When set to true, the response contains an array of groups that have visibility to the product. The default is false. |
tags | string | Products which are part of a specific tag. |
SELECT
examples
- get
- list_by_service
Gets the details of the product specified by its identifier.
SELECT
properties
FROM azure.api_management.workspace_products
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND serviceName = '{{ serviceName }}' -- required
AND workspaceId = '{{ workspaceId }}' -- required
AND productId = '{{ productId }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Lists a collection of products in the specified workspace in a service instance.
SELECT
properties
FROM azure.api_management.workspace_products
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND serviceName = '{{ serviceName }}' -- required
AND workspaceId = '{{ workspaceId }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
AND $filter = '{{ $filter }}'
AND $top = '{{ $top }}'
AND $skip = '{{ $skip }}'
AND expandGroups = '{{ expandGroups }}'
AND tags = '{{ tags }}'
;
INSERT
examples
- create_or_update
- Manifest
Creates or Updates a product.
INSERT INTO azure.api_management.workspace_products (
data__properties,
resourceGroupName,
serviceName,
workspaceId,
productId,
subscriptionId,
If-Match
)
SELECT
'{{ properties }}',
'{{ resourceGroupName }}',
'{{ serviceName }}',
'{{ workspaceId }}',
'{{ productId }}',
'{{ subscriptionId }}',
'{{ If-Match }}'
RETURNING
properties
;
# Description fields are for documentation purposes
- name: workspace_products
props:
- name: resourceGroupName
value: string
description: Required parameter for the workspace_products resource.
- name: serviceName
value: string
description: Required parameter for the workspace_products resource.
- name: workspaceId
value: string
description: Required parameter for the workspace_products resource.
- name: productId
value: string
description: Required parameter for the workspace_products resource.
- name: subscriptionId
value: string
description: Required parameter for the workspace_products resource.
- name: properties
value: object
description: |
Product entity contract properties.
- name: If-Match
value: string
description: ETag of the Entity. Not required when creating an entity, but required when updating an entity.
UPDATE
examples
- update
Update existing product details.
UPDATE azure.api_management.workspace_products
SET
data__properties = '{{ properties }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}' --required
AND serviceName = '{{ serviceName }}' --required
AND workspaceId = '{{ workspaceId }}' --required
AND productId = '{{ productId }}' --required
AND If-Match = '{{ If-Match }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
RETURNING
properties;
DELETE
examples
- delete
Delete product.
DELETE FROM azure.api_management.workspace_products
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND serviceName = '{{ serviceName }}' --required
AND workspaceId = '{{ workspaceId }}' --required
AND productId = '{{ productId }}' --required
AND If-Match = '{{ If-Match }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
AND deleteSubscriptions = '{{ deleteSubscriptions }}'
;