Skip to main content
Version: 10 - Vanillekipferl

ConnectorTypeAZURE

class connector_types.connector_type_azure.ConnectorTypeAZURE

Call the Azure API.

See https://learn.microsoft.com/en-us/python/api/?view=azure-python

Input Schema

  • schema_version

    Type: string

  • authentication

    Type: anyOf

  • subscription_id

    The Azure subscription ID.

    Type: string

  • mode

    Type: anyOf

Output Schema

  • result

    Data

Constants

SUPPORTED_CLIENTS = ['compute', 'network', 'resource', 'storage']

Example

import flow_api

def handler(system: flow_api.System, this: flow_api.Execution, inputs: dict):
virtual_machine = this.connect(
connector_type='AZURE',
authentication={
'authentication_method': 'azure_ad',
client_id='...',
client_secret='...',
tenant_id='...',
},
subscription_id='...',
mode={
'mode_name': 'call_client_collection_method',
'client': 'compute',
'collection': 'virtual_machines',
'method': 'begin_create_or_update',
'kwargs': {
'resource_group_name': '...',
'vm_name': '...',
'parameters': ...
},
},
).get('output_value')['result']
this.log(vm_id=virtual_machine['id'])
return this.success('all done')