Giter Club home page Giter Club logo

alexapi's Introduction

AlexAPI

Integrating xAPI with amazon Alexa

What you'll need

Install Raspbian Jessie

If you havent installed Raspbian on your Pi, follow install instructions here

Setup

1.) Sign into Amazon developer console and navigate to the Alexa tab.

2.) Once there click 'Get Started' On the Alexa Voice Service option.

3.) Now Register a product type. Register as Device, not application.

  • Enter Device Type ID, and Display name. Make note of spelling and capitolization, you'll need these names later. Click next
  • Under Security Profile, select 'Create a new profile', give your profile a name (I recommend using the same name as Device ID) and description (Use the same name again). Click next. Keep this page open for later use
  • Navigate to the Web Settings tab. Next to 'Allowed Orgins', click 'Add Another' and type http://localhost:5000. Again click add another and enter the ip address of your raspberry pi like so: http://your.rpi.ip.addr:5000
  • Now on the page, find 'Allowed Return URLs' and click 'Add Another'. Copy the same two fields from above, but this time add /code after. For example http://localhost:5000 would now be http://localhost:5000/code and http://your.rpi.ip.addr:5000 would be http://your.rpi.ip.addr:5000/code. Click next
  • Complete required fields as necessary, nothing really to change here, use Category: Other. Click next.
  • Go back to security profile by clicking edit on your newly created product.

4.) SSH into Pi and get ready to run some commands.

Installing Alexa

1.) Clone this project git clone https://github.com/pauliejes/AlexAPI.git

2.) cd into new directory cd AlexAPI

3.) run sudo ./setup.sh

  • From here you will be promped for the ProductID you set up earlier. Enter it exactly as it appears in your developer console.
  • Next you will be asked to enter your Security Profile Description. Enter it exactly as it appears in your developer console.
  • Next, copy and paste your Security Profile ID, Client ID, and Client Secrete as promped.
  • Now open up a web browser and enter your PI's Ip address followed by :5000, you should be greeted by a login from amazon.
  • Login and agree to terms and conditions. You should see a long refresh token which is automatically added to the configuration so you do not need it. Exit the browser, then exit the setup script.

4.) Type python main.py

5.) If eveything goes smoothly, you should be greeted by Alexa.

How to use

To prompt Alexa, hold down the Joystick and ask your question.

##xAPI

Everytime you ask Alexa a question, she will send a statement to the ADL LRS using xAPI.

Currently the statement is generic and more proof of concept, but will be expanded to hold more information in the future.

Check out the python code in main.py

alexapi's People

Contributors

pauliejes avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.