Skip to main content

workspace_api_diagnostics

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

Overview

Nameworkspace_api_diagnostics
TypeResource
Idazure.api_management.workspace_api_diagnostics

Fields

NameDatatypeDescription
always_logtextfield from the properties object
apiIdtextfield from the properties object
backendtextfield from the properties object
diagnosticIdtextfield from the properties object
frontendtextfield from the properties object
http_correlation_protocoltextfield from the properties object
log_client_iptextfield from the properties object
logger_idtextfield from the properties object
metricstextfield from the properties object
operation_name_formattextfield from the properties object
resourceGroupNametextfield from the properties object
samplingtextfield from the properties object
serviceNametextfield from the properties object
subscriptionIdtextfield from the properties object
verbositytextfield from the properties object
workspaceIdtextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTapiId, diagnosticId, resourceGroupName, serviceName, subscriptionId, workspaceIdGets the details of the Diagnostic for an API specified by its identifier.
list_by_workspaceSELECTapiId, resourceGroupName, serviceName, subscriptionId, workspaceIdLists all diagnostics of an API.
create_or_updateINSERTapiId, diagnosticId, resourceGroupName, serviceName, subscriptionId, workspaceIdCreates a new Diagnostic for an API or updates an existing one.
deleteDELETEIf-Match, apiId, diagnosticId, resourceGroupName, serviceName, subscriptionId, workspaceIdDeletes the specified Diagnostic from an API.
updateUPDATEIf-Match, apiId, diagnosticId, resourceGroupName, serviceName, subscriptionId, workspaceIdUpdates the details of the Diagnostic for an API specified by its identifier.

SELECT examples

Lists all diagnostics of an API.

SELECT
always_log,
apiId,
backend,
diagnosticId,
frontend,
http_correlation_protocol,
log_client_ip,
logger_id,
metrics,
operation_name_format,
resourceGroupName,
sampling,
serviceName,
subscriptionId,
verbosity,
workspaceId
FROM azure.api_management.vw_workspace_api_diagnostics
WHERE apiId = '{{ apiId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';

INSERT example

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

/*+ create */
INSERT INTO azure.api_management.workspace_api_diagnostics (
apiId,
diagnosticId,
resourceGroupName,
serviceName,
subscriptionId,
workspaceId,
properties
)
SELECT
'{{ apiId }}',
'{{ diagnosticId }}',
'{{ resourceGroupName }}',
'{{ serviceName }}',
'{{ subscriptionId }}',
'{{ workspaceId }}',
'{{ properties }}'
;

UPDATE example

Updates a workspace_api_diagnostics resource.

/*+ update */
UPDATE azure.api_management.workspace_api_diagnostics
SET
properties = '{{ properties }}'
WHERE
If-Match = '{{ If-Match }}'
AND apiId = '{{ apiId }}'
AND diagnosticId = '{{ diagnosticId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';

DELETE example

Deletes the specified workspace_api_diagnostics resource.

/*+ delete */
DELETE FROM azure.api_management.workspace_api_diagnostics
WHERE If-Match = '{{ If-Match }}'
AND apiId = '{{ apiId }}'
AND diagnosticId = '{{ diagnosticId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';