.. versionadded:: 2019.2.0

    List all tenants for your account.

    CLI Example:

    .. code-block:: bash

        salt-call azurearm_resource.tenants_list

def tenants_list(**kwargs):
    '''
    .. versionadded:: 2019.2.0

    List all tenants for your account.

    CLI Example:

    .. code-block:: bash

        salt-call azurearm_resource.tenants_list

    '''
    result = {}
    subconn = __utils__['azurearm.get_client']('subscription', **kwargs)
    try:
        tenants = __utils__['azurearm.paged_object_to_list'](subconn.tenants.list())

        for tenant in tenants:
            result[tenant['tenant_id']] = tenant
    except CloudError as exc:
        __utils__['azurearm.log_cloud_error']('resource', str(exc), **kwargs)
        result = {'error': str(exc)}

    return result