-
Notifications
You must be signed in to change notification settings - Fork 7
SenseMap Login on a Local Environment
For a Video Demonstration and Tutorial please follow this Link: Video
- Visit Google Developers API Console and Register for their services.
- Click on Library on the left sideboard and Scroll down to Google Social API's and select Google+ API
- Enable the Google+ Social API by registering and clicking on ENABLE.
- On the left sideboard click on Credentials
- On the Top Navigation bar you will be able to see the following : Credentials | Oauth Consent Screen | Domain Verification
- Choose Oauth Consent Screen and add in a Name and fill out the remaining Required fields (they only ask for basic information such as Name and email)
- Save this and click on Credentials on the top Navigation
- Click on the Create New Credentials button
- Select Create Client ID on the drop down menu
- As for application type we will have to select Web application.
- Give a random name (irrelevant)
- For Authorised JavaScript origins we do NOT have to fill that out so please ignore
- Authorised redirect URIs is what we need. For that we need to reference our local background.html (history map page of SenseMap). Since were loading the application locally, Our Path to that page is unique per machine. This will not be the case when the Application is hosted on the Chrome Web Store.
- To Find your Application ID for SenseMap running locally, go to chrome://extensions and click on SenseMap. On there you will see a field called ID. It will look like this ID Example.
- Run chrome.identity.getRedirectURL("src/background/backgroud.html") in Chrome console
- It should look like this https://lajblbdkejaddpihfeeihnicfkmiojem/src/background/backgroud.html. (Please note the ID for you would be different)
- Add this new URL to your Authorised redirect URI's list.
- Copy the Client ID on the top of the PAGE and click on save.
- On the SenseMap/src/js Source Location you will find a folder called /login.
- In that folder you will find a file called "initHelloOauth.js"
- Open that file and replace the Client ID with your Local ID and the redirect URI with your redirect URI.
- Save that file.
- Open Manifest.JSON and replace on line 53 the CLIENT ID with your Client ID.
Save, exit reload the extension and the Login should work for you locally.
Please Note : All of the above is not required for you to do, this is only a tutorial with the purpose for you to set it up from scratch. You could also let me know ur Application ID for SenseMap on your machine and I can whitelist ur URI to access the login. Once it is whitelisted the only thing you need to do is to replace the Application ID in the redirect URI in "initHelloOauth.js" with your id and then it should work.
Thank you for reading and watching :)
Missing Features for Online Study
Behaviour: Node and Edge Creation
Testing and Behaviour Driven Development (BDD)
Video: Testing with Jasmine and Sinon-Chrome
Video: overview of SenseMap code
Video: browser features in the old 'master' branch
How browserProvenance.js works
Video: create REST API for MongoDB using Node.js