JavaScript SDK for Webex Teams
Switch branches/tags
Clone or download
Failed to load latest commit information.
.circleci chore(tooling): fix deprecation list and eslint --quiet Aug 30, 2018
.github docs: add GitHub SUPPORT file Jul 12, 2018
.vscode chore(tooling): add vscode config for monorepo Jun 23, 2017
docker/builder chore(sparkd): remove sparkd references Jun 18, 2018
docs docs: update API docs root May 1, 2018
documentation docs: shorten "JavaScript" to "JS" May 1, 2018
packages/node_modules v1.43.0 Oct 5, 2018
scripts feat(tooling): add checker to detect sauce tunnel failures May 12, 2017
tooling docs(proxies): update Service references Oct 4, 2018
wdio.helpers.d test(samples): add extra describe to clean up reports Jul 2, 2018
webpack chore(plugin-meetings): remove unnecessary env var Sep 7, 2018
.babelrc feat(@ciscospark/media-engine-webrtc): implement webrtc media engine Nov 17, 2017
.codeclimate.yml chore(tooling): update paths to point at new package location Apr 7, 2017
.coveralls.yml chore(build): configure coveralls Jul 22, 2016
.editorconfig feat(ciscospark): Initial commit for Jul 7, 2016
.env.default chore(defaults): add default org id for jwt tests Aug 10, 2017
.eslintignore style(all): update all code to be lintable Apr 11, 2017
.eslintrc.yml build(lint): adjust lint override order and update deps Jan 29, 2018
.gitattributes chore(tooling): tell github where our code is Apr 7, 2017
.github-todos feat(ciscospark): Initial commit for Jul 7, 2016
.gitignore chore: ignore .orig files Oct 2, 2018
.gitmodules feat(ciscospark): Initial commit for Jul 7, 2016
.jscsrc feat(ciscospark): Initial commit for Jul 7, 2016
.jsdoc.json docs(general): update copyright notices Mar 2, 2017
.tern-project feat(ciscospark): Initial commit for Jul 7, 2016
.yo-rc.json feat(ciscospark): Initial commit for Jul 7, 2016 docs(build): add instruction regarding latest node lts Jun 25, 2018 docs(npm): update contributing doc Sep 5, 2018
Gruntfile.concurrent.js chore(tooling): update github link to webex Apr 19, 2018
Jenkinsfile chore(npm publish): add newline to fix secrets Aug 14, 2018
LICENSE docs(general): update copyright notices Mar 2, 2017 docs(general): remove references to ciscospark/env from README + tweaks Oct 16, 2018 docs(scripts): add snapshots example Oct 4, 2018
appveyor.yml chore(tooling): do not build samples on windows Nov 21, 2017
browsers-ng.js chore(testing): update to latest macOS version Aug 1, 2018
browsers.js style(all): apply eslint autofixes Dec 9, 2017
commitlint.config.js chore(tooling): upgrade commitlint Apr 5, 2018
deps.js fix(tooling): update to new builtins() behavior Jan 29, 2018
jsconfig.json fix(plugin-phone): update video toggle flow Jul 2, 2018
karma-ng.conf.js test(m-e-w): stabilize by clearing remotePC, lower retries Jul 2, 2018
netlify.toml fix(samples): build samples with correct NODE_ENV Jan 24, 2018
package-lock.json chore(plugin-teams): create custom hash for yakbak - working! Oct 3, 2018
package.json chore(plugin-teams): create custom hash for yakbak - working! Oct 3, 2018 chore(build): use specific version of npm Sep 5, 2018
wdio.conf.js chore(tooling): enable extended debugging on sauce Aug 16, 2018
webpack.config.js chore(webpack): add default URLs Jul 6, 2018


Greenkeeper badge

npm license Build status

The Cisco Webex JS SDK

Cisco Spark is now Webex Teams! You will notice changes to our documentation and packages as we update over the next several weeks. Read why this is more than just a rebrand.

This is a monorepo containing all officially maintained Cisco Webex JS SDK modules in the same repo.

ciscospark is a collection of node modules targeting our external APIs.


We test against the Active LTS (Long Term Support) version of Node.js and use npm@6 to run security audits.

To install the latest stable version of the SDK from NPM:

npm install --save ciscospark


To use the SDK, you will need Cisco Webex credentials. If you do not already have a Cisco Webex account, visit Cisco Webex for Developers to create your account and retrieve your access token.

See the detailed docs for more usage examples.

const ciscospark = require(`ciscospark`);
const teams = ciscospark.init({
  credentials: {
    access_token: <your webex teams access token>

// Create a room with the title "My First Room"
// Add Alice and Bob to the room
// Send a **Hi Everyone** message to the room
teams.rooms.create({ title: `My First Room` }).then(room => {
  return Promise.all([
      personEmail: ``
      personEmail: ``
  ]).then(() =>
      markdown: `**Hi Everyone**`,

A note on browser usage

We do not provide a built version of the SDK that includes window.ciscospark. In-browser usage is almost the same as Node.js, but it handles the user authentication flow for you. See the browser guide for more information.

If you're already using a bundler (like Webpack or Rollup) you can simply import/require the package and use the above snippet and assign the initialized team variable to window.webexteams. For a quick example, we'll use Parcel to bundle the SDK for a website. For any more information and questions on how to use Parcel, please head to their website.

  1. Create index.js.
import { init as initTeams } from 'ciscospark';

// Initialize the SDK and make it available to the window
const teams = (window.webexteams = initTeams({
  credentials: {
    access_token: <your webex teams access token>

// Create a room with the title "My First Room"
    title: 'My First Room!'
  .catch((error) => {

// Filter for "My First Room" from the last 10 rooms
    max: 10
  .then((rooms) => {
    // Destructure room properties for it's id (aliased to roomId) and title
    const { id: roomId, title } = rooms.items.filter(
      room => room.title === 'My First Room!'

    // Post message "Hello World!" to "My First Room!"
      text: 'Hello World!'

    // Log the the room name and the message we created
    return teams.messages
      .list({ roomId, max: 1 })
      // Destructure promised value to get text property from first item in items array
      .then(({ items: [{ text }] }) =>
        console.log(`Last message sent to room "${title}": ${text}`)
  .catch((error) => {
  1. Create index.html .
    <title>Webex SDK for Browsers</title>
    <script src="./index.js"></script>
  1. Run parcel index.html in your terminal.
  2. Go to http://localhost:1234 and open the developer console to see the output.

Still using ciscospark/env?


Sample code can be found in packages/node_modules/samples. You can run them yourself with the following commands:

Note: This installs all of the SDK's tooling dependencies, so you'll need libgcrypt and (possibly) graphicsmagick. On a mac, you can install these with brew install graphicsmagick libgcrypt.

git clone
cd spark-js-sdk
npm install
npm run samples:serve

You'll be able to load the samples by visiting https://localhost:8000/packages/node_modules/samples/<PACKAGE NAME>.

Available Samples

Sample App Link Source
Implicit Grant Flow local app code
Single Party Calling local app code
Single Party Calling with Mute local app code
Multi Party Calling local app code
Call with Content Sharing local app code


Pull requests welcome. Please see for more details about building the packages and submitting pull requests for suggested changes.


© 2016-2018 Cisco and/or its affiliates. All Rights Reserved.

See LICENSE for details.