Socket
Socket
Sign inDemoInstall

azure-arm-powerbiembedded

Package Overview
Dependencies
68
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    azure-arm-powerbiembedded

Microsoft Azure Power BI Embedded Client Library for node


Version published
Maintainers
1
Install size
14.7 MB
Created

Changelog

Source

2016.09.07 Version 1.2.0-preview

  • Added client libraries for following ARM services
    • Servicebus management
    • Trafficmanager
    • Powerbiembedded
    • Eventhub management
    • IotHub Management
  • Regenerated following services with the latest (api-version) swagger spec
    • KeyVaultManagement and KeyVault data plane
    • ResourceManagement
    • DevTestLabs
    • NotificationHubManagement
    • Commerce
  • Removed ApiAppManagement library as the service is no longer deployed on Azure
  • Updated the rollup file (lib/azure.js) to be in sync with the latest changes
  • Updated License Info
    • All the Autorest generated client libraries are under MIT license
    • All the old codegenerator generated client libraries are under Apache-2.0
  • Bumped up the request library to 2.74.0

Readme

Source

Microsoft Azure SDK for Node.js - Power BI Embedded

This project provides a Node.js package for managing Azure Power BI Embedded.

Features

  • Manage Power BI Embedded:
    1. Create new Workspace Collection
    2. Get workspace collections by subscription
    3. Get workspace collections by resource group
    4. Get workspace collection by resource group & name
    5. Get access keys for workspace collection
    6. Regenerate access key for workspace collection
    7. Get workspaces within workspace collection

How to Install

npm install azure-arm-powerbiembedded

How to Use

Authentication, client creation and listing workspaces within a workspace collection in a resource group as an example

var msRestAzure = require('ms-rest-azure');
var PowerBIEmbeddedManagementClient = require('azure-arm-powerbiembedded');

// Interactive Login
// It provides a url and code that needs to be copied and pasted in a browser and authenticated over there. If successful, 
// the user will get a DeviceTokenCredentials object.
msRestAzure.interactiveLogin(function(err, credentials) {
 var client = new PowerBIEmbeddedManagementClient(credentials, subscriptionId);
 client.workspaces.list(resourceGroupName, workspaceCollectionName, function(err, result, request, response) {
   if (err) console.log(err);
   console.log(result);
 });
});

Create new Workspace Collection

const creationOptions = {
  location: "southcentral",
  tags: {
    key1: 'value1',
    key2: 'value2'
  },
  sku: {
    name: "S1",
    teir: "Standard"
  }
};

client.workspaceCollections.create(resourceGroupName, workspaceCollectionName, creationOptions, (error, result, request, response) => {
  ...
});

workspaceCollection:

{
  id: "...",
  name: "...",
  type: "...",
  location: "...",
  tags: { ... },
  sku: {
    name: "S1",
    teir: "Standard"
  },
  properties: {
    ...
  }
}

Update Workspace Collection

const updateBody = {
  tags: {
    newTag: 'newValue',
    removeTag: ''
  }
};

client.workspaceCollections.update(resourceGroupName, workspaceCollectionName, updateBody, (error, result, request, response) => {
  ...
});

Delete Workspace Collection

client.workspaceCollections.deleteMethod(resourceGroupName, workspaceCollectionName, (error, result, request, response) => {
  ...
});

Get workspace collections by subscription

client.workspaceCollections.listBySubscription((error, result, request, response) => {
  ...
});

Get workspace collections by resource group

client.workspaceCollections.listByResourceGroup(resourceGroupName, (error, result, request, response) => {
  ...
});

Get workspace collection by resource group & workspace collection name

client.workspaceCollections.getByName(resourceGroupName, workspaceCollectionName, (error, result, request, response) => {
  ...
});

Get access keys for workspace collection

client.workspaceCollections.getAccessKeys(resourceGroupName, workspaceCollectionName, (error, result, request, response) => {
  ...
});

accessKeys:

{
  key1: "...",
  key2: "..."
}

Regenerate access key for workspace collection

const body = {
  keyName: "key1"
};

client.workspaceCollections.regenerateKey(resourceGroupName, workspaceCollectionName, body, (error, result, request, response) => {
  ...
});

accessKeys:

{
  key1: "...", // Regenerated
  key2: "..."
}

Get workspaces within workspace collection

client.workspaces.list(resourceGroupName, workspaceCollectionName, (error, result, request, response) => {
  ...
});

workspaces:

[
  {
    id: "...",
    name: "...",
    type: "...",
    properties: { ... }
  },
  {
    id: "...",
    name: "...",
    type: "...",
    properties: { ... }
  },
  ...
]
  • Microsoft Azure SDK for Node.js
  • AutoRest

Keywords

FAQs

Last updated on 07 Nov 2018

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc