workspace_loggers
Creates, updates, deletes, gets or lists a workspace_loggers
resource.
Overview
Name | workspace_loggers |
Type | Resource |
Id | azure.api_management.workspace_loggers |
Fields
- vw_workspace_loggers
- workspace_loggers
Name | Datatype | Description |
---|---|---|
description | text | field from the properties object |
credentials | text | field from the properties object |
is_buffered | text | field from the properties object |
loggerId | text | field from the properties object |
logger_type | text | field from the properties object |
resourceGroupName | text | field from the properties object |
resource_id | text | field from the properties object |
serviceName | text | field from the properties object |
subscriptionId | text | field from the properties object |
workspaceId | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
properties | object | The Logger entity in API Management represents an event sink that you can use to log API Management events. Currently the Logger entity supports logging API Management events to Azure Event Hubs. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | loggerId, resourceGroupName, serviceName, subscriptionId, workspaceId | Gets the details of the logger specified by its identifier. |
list_by_workspace | SELECT | resourceGroupName, serviceName, subscriptionId, workspaceId | Lists a collection of loggers in the specified workspace. |
create_or_update | INSERT | loggerId, resourceGroupName, serviceName, subscriptionId, workspaceId | Creates or Updates a logger. |
delete | DELETE | If-Match, loggerId, resourceGroupName, serviceName, subscriptionId, workspaceId | Deletes the specified logger. |
update | UPDATE | If-Match, loggerId, resourceGroupName, serviceName, subscriptionId, workspaceId | Updates an existing logger. |
SELECT
examples
Lists a collection of loggers in the specified workspace.
- vw_workspace_loggers
- workspace_loggers
SELECT
description,
credentials,
is_buffered,
loggerId,
logger_type,
resourceGroupName,
resource_id,
serviceName,
subscriptionId,
workspaceId
FROM azure.api_management.vw_workspace_loggers
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';
SELECT
properties
FROM azure.api_management.workspace_loggers
WHERE 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_loggers
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.api_management.workspace_loggers (
loggerId,
resourceGroupName,
serviceName,
subscriptionId,
workspaceId,
properties
)
SELECT
'{{ loggerId }}',
'{{ resourceGroupName }}',
'{{ serviceName }}',
'{{ subscriptionId }}',
'{{ workspaceId }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: loggerType
value: string
- name: description
value: string
- name: credentials
value: object
- name: isBuffered
value: boolean
- name: resourceId
value: string
UPDATE
example
Updates a workspace_loggers
resource.
/*+ update */
UPDATE azure.api_management.workspace_loggers
SET
properties = '{{ properties }}'
WHERE
If-Match = '{{ If-Match }}'
AND loggerId = '{{ loggerId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';
DELETE
example
Deletes the specified workspace_loggers
resource.
/*+ delete */
DELETE FROM azure.api_management.workspace_loggers
WHERE If-Match = '{{ If-Match }}'
AND loggerId = '{{ loggerId }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND workspaceId = '{{ workspaceId }}';