browserstack-api
BrowserStack REST API Wrapper
(C) Pradeep Mishra pradeep23oct@gmail.com
A JavaScript REST wrapper for BrowserStack service for node.js (0.6.x and up). Hides most of the complexity of creating, maintaining BrowserStack workers and sessions.
Features
- Currently Work on servers (NodeJS)
- Simple service wrapper that allows you to easily put together All BrowserStack REST API libraries
- Easy create Workers, Sessions
- Automatic User credential injection on all REST calls
- Take Session screenshot.
- Model binding for each BrowserStack server response
Example usage
var BS = ; // instantiate browserstack-api with userName and keyvar BrowserStack = 'userName' 'myKey'; // an alternate method to set username and key after creating an instance of browserstack-api var BrowserStack = ;BrowserStack;BrowserStack; // get all supported browsers list//{all : true, flat : true} optional parametersBrowserStack; // get status of an accountBrowserStack; // get all workers created in accountBrowserStack; // methods available in BrowserStack instance;; //'myKey'; // 'username'; //{user : 'username', key : 'myKey}; // 3;;; // Worker Instance// Worker class extend DataModel or responseModelvar worker = ;worker; // create new worker on browserStackworker; // get status of workerworker; // for taking screenshot of workerworker; // for destroying workerworker; // methods available in Worker instance; //'windows'; // '7'; // 'chrome'; //'ios'; //'20.0'; //http://in.linkedin.com/in/ipradeepmishra/; // 'pradeep'; ;; // 30;;;; // DataModel or responseModel class// methods available; // name // name, value; // name // key, value; // return JSON representation of model
npm install browserstack-api --save