Understanding the OAuth Flow of a Cisco Spark Integration
- Sign up for Cisco Spark - take a tour!
- Register a new custom Spark 'integration' type application with Cisco
Download the complete sample code project for this lab on GitHub.com CiscoDevNet/spark-auth-sample
Cisco Spark is a cloud service providing persistent chat, room-based collaboration, WebRTC video conferencing, and more. Developers can easily integrate solutions with Spark via the Spark REST API - for example to add Spark messaging features to an app user interface, or to automate sending Spark messages to rooms based on business system or real-world events.
Application developers integrating with Spark that wish to use OAuth/SSO for authenticating user and performing API requests on their behalf must register their app via the Cisco Spark for Developers portal - defining the application name, permissions, and OAuth2 redirect URL (more on this later). During registration, the system generates a Client ID and Client Secret pair, which are later used by the application to access the Spark OAuth2 authentication service. During this lab, you will create a new custom app registration, and generate a Client ID and Secret.
Note, if your application does not need to 'impersonate' end users, and will only be performing Spark API calls on its own behalf, you may want to create a Spark 'bot' and use its access token, rather than implementing OAuth.
Step 1: Sign up for Cisco Spark and take a tour
If you already have a Spark account, skip to Step 2
- From the Spark home page at https://web.ciscospark.com enter your email address, and follow the instructions for creating a Spark account. Note: you will need to access your email account, as Spark will send a 'You have a Cisco Spark account' email message with a 'Create Password' verification link - this must be completed in order to login to Spark.
Cisco Spark homepage (link)
Log in to Spark and take a quick look around. Feel free to create a new room and invite a friend (note: they will need to complete the email verification step, too.)
For more information on Spark features and benefits, check out http://www.webex.com/ciscospark/