Skip to main content

Azure Cloud Query

Background

The Run Azure Cloud Query Action performs Steampipe queries on Azure resources with a powerful and simple PostgreSQL syntax.

For example, fetching all Active Directory guest users:

select
display_name,
user_principal_name,
mail,
user_type,
usage_location
from
azure_ad_user
where
user_type = 'Guest';

A complicated action such as fetching the Active Directory Password Profiles of each users in your account:

select
display_name,
user_principal_name,
additional_properties -> 'passwordProfile' -> 'enforceChangePasswordPolicy' as enforce_change_password_policy,
additional_properties -> 'passwordProfile' -> 'forceChangePasswordNextLogin' as change_password_next_login
from
azure_ad_user;

A query to get a list of compute images where disk storage type is Premium_LRS:

select
name,
split_part(disk -> 'managedDisk' ->> 'id', '/', 9) as disk_name,
disk ->> 'storageAccountType' as storage_account_type,
disk ->> 'diskSizeGB' as disk_size_gb,
disk ->> 'caching' as caching
from
azure_compute_image
cross join jsonb_array_elements(storage_profile_data_disks) as disk
where
disk ->> 'storageAccountType' = 'Premium_LRS';

A full description of all existing tables and official examples are provided here:

info

Blink's supported Steampipe version is: v0.45.0.

Action Parameters

ParameterDescription
SQL statementThe SQL statement we wish to use to query the resource.
Output formatRepresentation of the output result. The possible options are "Table", "CSV" or "JSON".

RunAzureCloudQuery

note

This action does not support Azure Oauth connections.