Skip to main content

web_pub_subs

Creates, updates, deletes, gets or lists a web_pub_subs resource.

Overview

Nameweb_pub_subs
TypeResource
Idazure.web_pubsub.web_pub_subs

Fields

The following fields are returned by SELECT queries:

Success. The response describes the corresponding resource.

NameDatatypeDescription
identityobjectA class represent managed identities used for request and response
kindstringThe kind of the service
locationstringThe geo-location where the resource lives
propertiesobjectA class that describes the properties of the resource
skuobjectThe billing information of the resource.
tagsobjectResource tags.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, resourceNameGet the resource and its properties.
list_by_resource_groupselectsubscriptionId, resourceGroupNameHandles requests to list all resources in a resource group.
list_by_subscriptionselectsubscriptionIdHandles requests to list all resources in a subscription.
create_or_updateinsertsubscriptionId, resourceGroupName, resourceNameCreate or update a resource.
updateupdatesubscriptionId, resourceGroupName, resourceNameOperation to update an exiting resource.
deletedeletesubscriptionId, resourceGroupName, resourceNameOperation to delete a resource.
check_name_availabilityexeclocation, subscriptionId, name, typeChecks that the resource name is valid and is not already in use.
regenerate_keyexecsubscriptionId, resourceGroupName, resourceNameRegenerate the access key for the resource. PrimaryKey and SecondaryKey cannot be regenerated at the same time.
restartexecsubscriptionId, resourceGroupName, resourceNameOperation to restart a resource.

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.

NameDatatypeDescription
locationstringthe region
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
resourceNamestringThe name of the resource.
subscriptionIdstring (uuid)The ID of the target subscription. The value must be an UUID.

SELECT examples

Get the resource and its properties.

SELECT
identity,
kind,
location,
properties,
sku,
tags
FROM azure.web_pubsub.web_pub_subs
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND resourceName = '{{ resourceName }}' -- required
;

INSERT examples

Create or update a resource.

INSERT INTO azure.web_pubsub.web_pub_subs (
data__tags,
data__location,
data__sku,
data__properties,
data__kind,
data__identity,
subscriptionId,
resourceGroupName,
resourceName
)
SELECT
'{{ tags }}',
'{{ location }}',
'{{ sku }}',
'{{ properties }}',
'{{ kind }}',
'{{ identity }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ resourceName }}'
RETURNING
identity,
kind,
location,
properties,
sku,
tags
;

UPDATE examples

Operation to update an exiting resource.

UPDATE azure.web_pubsub.web_pub_subs
SET
data__tags = '{{ tags }}',
data__location = '{{ location }}',
data__sku = '{{ sku }}',
data__properties = '{{ properties }}',
data__kind = '{{ kind }}',
data__identity = '{{ identity }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND resourceName = '{{ resourceName }}' --required
RETURNING
identity,
kind,
location,
properties,
sku,
tags;

DELETE examples

Operation to delete a resource.

DELETE FROM azure.web_pubsub.web_pub_subs
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND resourceName = '{{ resourceName }}' --required
;

Lifecycle Methods

Checks that the resource name is valid and is not already in use.

EXEC azure.web_pubsub.web_pub_subs.check_name_availability 
@location='{{ location }}' --required,
@subscriptionId='{{ subscriptionId }}' --required
@@json=
'{
"type": "{{ type }}",
"name": "{{ name }}"
}'
;