Skip to content

Commit

Permalink
Add development steps to README
Browse files Browse the repository at this point in the history
  • Loading branch information
thorpelawrence committed Apr 25, 2018
1 parent 519fbcf commit 2a50449
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,21 @@
**UK**: https://www.amazon.co.uk/Lawrence-Thorpe-Connect-Control-Spotify/dp/B074KFNWFD
**US**: https://www.amazon.com/Lawrence-Thorpe-Connect-Control-Spotify/dp/B074KFNWFD

## Contribution
The utility script `skill.js` is provided to generate the intent schema and sample utterances from source
## Contribution and development
To generate the skillBuilder JSON required for the skill in Amazon Developer console
1. Make a Spotify developer app at developer.spotify.com, get a client ID and client secret
2. Make a new Amazon Alexa skill, custom. Lots of details omitted here, but: once you get to the part in the Alexa developer console where you can upload/paste in JSON, then run `skill/skill.js` to generate the JSON required
```
node skill/skill.js
```
3. Account linking on Alexa skill: turn it on, choose "Auth Code Grant", set Authorization URI to "https://accounts.spotify.com/authorize", set "Access Token URI" to "https://accounts.spotify.com/api/token", set client ID and secret, add scopes "user-read-playback-state" and "user-modify-playback-state", add three redirect URIs:
```
https://alexa.amazon.co.jp/api/skill/link/M1OP8C9N8NBYP7
https://pitangui.amazon.com/api/skill/link/M1OP8C9N8NBYP7
https://layla.amazon.com/api/skill/link/M1OP8C9N8NBYP7
```
4. Deploy this webapp to somewhere that supports HTTPS (required for Alexa skills), for example Heroku
5. Configure the skill to use an HTTPS endpoint of `https://<your-url>/<app-name>` where `app-name` is the name specified in `alexa.app('app-name')`, `connect` by default

[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)

Expand Down

0 comments on commit 2a50449

Please sign in to comment.