Skip to main content

loggers

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

Overview

Nameloggers
TypeResource
Idazure.api_management.loggers

Fields

NameDatatypeDescription
descriptiontextfield from the properties object
credentialstextfield from the properties object
is_bufferedtextfield from the properties object
loggerIdtextfield from the properties object
logger_typetextfield from the properties object
resourceGroupNametextfield from the properties object
resource_idtextfield from the properties object
serviceNametextfield from the properties object
subscriptionIdtextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTloggerId, resourceGroupName, serviceName, subscriptionIdGets the details of the logger specified by its identifier.
list_by_serviceSELECTresourceGroupName, serviceName, subscriptionIdLists a collection of loggers in the specified service instance.
create_or_updateINSERTloggerId, resourceGroupName, serviceName, subscriptionIdCreates or Updates a logger.
deleteDELETEIf-Match, loggerId, resourceGroupName, serviceName, subscriptionIdDeletes the specified logger.
updateUPDATEIf-Match, loggerId, resourceGroupName, serviceName, subscriptionIdUpdates an existing logger.

SELECT examples

Lists a collection of loggers in the specified service instance.

SELECT
description,
credentials,
is_buffered,
loggerId,
logger_type,
resourceGroupName,
resource_id,
serviceName,
subscriptionId
FROM azure.api_management.vw_loggers
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new loggers resource.

/*+ create */
INSERT INTO azure.api_management.loggers (
loggerId,
resourceGroupName,
serviceName,
subscriptionId,
properties
)
SELECT
'{{ loggerId }}',
'{{ resourceGroupName }}',
'{{ serviceName }}',
'{{ subscriptionId }}',
'{{ properties }}'
;

UPDATE example

Updates a loggers resource.

/*+ update */
UPDATE azure.api_management.loggers
SET
properties = '{{ properties }}'
WHERE
If-Match = '{{ If-Match }}'
AND loggerId = '{{ loggerId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified loggers resource.

/*+ delete */
DELETE FROM azure.api_management.loggers
WHERE If-Match = '{{ If-Match }}'
AND loggerId = '{{ loggerId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}';