1.0.13 • Published 4 years ago

@apnex/vmw-sdk v1.0.13

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

vmw-sdk

A promises-based Node.JS SDK for programmatic access to my.vmware.com

This SDK implements a login workflow and provides a structured wrapper for REST API calls.

Highlights

Install

$ npm install @apnex/vmw-sdk

Usage

Promise
// load and create new client instance
const vmwClient = require('@apnex/vmw-sdk');
const vmw = new vmwClient();

// run
(async() => {
	try {
		// login to my.vmware.com
		await vmw.login({
			username: "my.username",
			password: "my.password"
		});

		// get product index
		let products = await vmw.getProducts();

		// print to console
		console.log(JSON.stringify(products, null, "\t"));
		//=> '[ { name: "VMware vSphere", actions: [ ... ] } ]'

	} catch (error) {
		console.log(error.message);
	}
})();

API Methods

.getProducts
const vmwClient = require('@apnex/vmw-sdk');

(async() => {
	// create new client instance
	const vmw = new vmwClient();

	try {
		// login to my.vmware.com
		await vmw.login({
			username: "my.username",
			password: "my.password"
		});

		// get product index
		let products = await vmw.getProducts();

		// print to console
		console.log(JSON.stringify(products, null, "\t"));
		//=> '[ { name: "VMware vSphere", actions: [ ... ] } ]'

	} catch (error) {
		console.log(error.message);
	}
})();
1.0.13

4 years ago

1.0.12

4 years ago

1.0.11

4 years ago

1.0.10

4 years ago

1.0.9

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago