az_rm: Azure Resource Manager

Description Format Methods Authentication Operations See Also Examples

Description

Base class for interacting with Azure Resource Manager.

Format

An R6 object of class az_rm.

Methods

Authentication

The recommended way to authenticate with ARM is via the get_azure_login function, which creates a new instance of this class.

To authenticate with the az_rm class directly, provide the following arguments to the new method:

Operations

The do_operation() method allows you to carry out arbitrary operations on the Resource Manager endpoint. It takes the following arguments:

Consult the Azure documentation for what operations are supported.

See Also

create_azure_login, get_azure_login

Azure Resource Manager overview, REST API reference

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
## Not run: 

# start a new Resource Manager session
az <- az_rm$new(tenant="myaadtenant.onmicrosoft.com", app="app_id", password="password")

# authenticate with credentials in a file
az <- az_rm$new(config_file="creds.json")

# authenticate with device code
az <- az_rm$new(tenant="myaadtenant.onmicrosoft.com", app="app_id", auth_type="device_code")

# retrieve a list of subscription objects
az$list_subscriptions()

# a specific subscription
az$get_subscription("subscription_id")


## End(Not run)

Hong-Revo/AzureSMRbase documentation built on Aug. 1, 2020, 7:32 p.m.