Skip to main content

workspace_certificates

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

Overview

Nameworkspace_certificates
TypeResource
Idazure.api_management.workspace_certificates

Fields

NameDatatypeDescription
certificateIdtextfield from the properties object
expiration_datetextfield from the properties object
key_vaulttextfield from the properties object
resourceGroupNametextfield from the properties object
serviceNametextfield from the properties object
subjecttextfield from the properties object
subscriptionIdtextfield from the properties object
thumbprinttextfield from the properties object
workspaceIdtextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTcertificateId, resourceGroupName, serviceName, subscriptionId, workspaceIdGets the details of the certificate specified by its identifier.
list_by_workspaceSELECTresourceGroupName, serviceName, subscriptionId, workspaceIdLists a collection of all certificates in the specified workspace.
create_or_updateINSERTcertificateId, resourceGroupName, serviceName, subscriptionId, workspaceIdCreates or updates the certificate being used for authentication with the backend.
deleteDELETEIf-Match, certificateId, resourceGroupName, serviceName, subscriptionId, workspaceIdDeletes specific certificate.
refresh_secretEXECcertificateId, resourceGroupName, serviceName, subscriptionId, workspaceIdFrom KeyVault, Refresh the certificate being used for authentication with the backend.

SELECT examples

Lists a collection of all certificates in the specified workspace.

SELECT
certificateId,
expiration_date,
key_vault,
resourceGroupName,
serviceName,
subject,
subscriptionId,
thumbprint,
workspaceId
FROM azure.api_management.vw_workspace_certificates
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_certificates resource.

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

DELETE example

Deletes the specified workspace_certificates resource.

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