lexstream
Alexa Music skill for streaming your own music.
Documentation links
Various documentation links that have been useful when building out this project
Prerequisites
Initialize Go Modules
- Use
go mod tidy
in the root of this repository to initialize dependencies
Run preflight check
go run cmd/preflight.go
will:
- Check that the minimum version of node is installed.
- Configure and test ask-cli in the .ask directory.
- This will prompt to run
ask configure
if no credentials are found
- Check that AWS credentials and configuration files are set up correctly.
- This performs read only api calls for S3, IAM, DynamoDB, and Lambda
- Check that the aws cli command is installed
Warning commands after this point start modifying things, so read warnings closely
Generate Login with Amazon Keys
Create settings.json
- Copy settings.json.example to settings.json and update with the appropriate content
{
"bucket": "<unique bucket name>",
"lambda_name": "lexstream_lambda",
"skill_name": "<skill name>"
}
Deploy Skill
- Run
go run infra/skill/create.go
to create the skill.
- TODO: instructions for creating catalog, uploading, and associating with skill
Create S3 bucket and Deploy Lambda
WARNING
if the provided bucket already exists the permissions will be re-set to no public access
Update Endpoint and Re-Validate
TODO: this should be able to be automated
- Back in the Alexa skills console, update the skill endpoint with the output of the previous command
Design Notes
- Use MusicBrainz_API for identifiers wherever possible.
- Completed
- Artist,Album, and Track are all directly supported and would be unique
- Prefix each since the MB Api uses GUIDs that are opaque
TODOs and other ramblings
-
Right now this just plays a single song on loop
-
Create a web interface / cli to upload new songs
- upload audio files and cover art to s3
- extract metadata from id tags in audio and create catalog files
- automate upload of catalog data
The ask cli
does a browser login to get the access token so this may not be possible
- more research
- This is possible using LWA tokens and calling the upload catalog api directly
- Add documentation on how this works
-
Metadata notes showing id -> api mappings
-
Saving whipper command whipper cd rip -p
Initial readme created by tigwen