mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-03-02 22:46:56 -05:00
[Feature Request] Amazon Echo skill for AudiobookShelf #181
Labels
No labels
authentication
awaiting release
backlog
bug
chapter editor
config-issue
ebooks
encoding/embedding
enhancement
help wanted
listening sessions & progress
planned
possible plugin
progress sync
sorting/filtering/searching
unable to reproduce
upload
users & permissions
waiting
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/audiobookshelf#181
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @lukc82 on GitHub (Jan 15, 2022).
Hi,
It would be great to be able to control the audiobookshelf using Alexa :)
Thanks,
Luke
@advplyr commented on GitHub (Jan 15, 2022):
This sounds like a fun project. I just skimmed through the documentation since I'm not familiar with Alexa.
Have you used Alexa for other self-hosted media servers? If so, I'm curious how the setup is handled. How does Alexa get your server address and login credentials for the media server?
@lukc82 commented on GitHub (Jan 15, 2022):
Yes. I'm using MyMedia for Alexa (https://www.mymediaalexa.com/) and I'm
surprised that since the launch of this project, it has been the only
mature alternative for listeners of self hosted audiobook files. Especially
for kids it's a wonderful tool. One word or sentence and there you go -
your audiobook continues :)
On Sat, Jan 15, 2022, 21:05 advplyr @.***> wrote:
@mx03 commented on GitHub (Jan 15, 2022):
Alexa needs a public audiobookshelf instance, additional it needs a central system ( e.g. audiobookshelf.org with oauth thats linked to the instance of the user).
An alternative is that everyone deploy an skill with the alexa developer console that direct linked to the audiobookshelf instance.
But alexa always need the audiofiles on an public url even the abs and the alexa is on the intranet.
@advplyr commented on GitHub (Jan 15, 2022):
Yeah I thought that might be the case. Although if Alexa knew your server url and audiobookshelf login then I don't see why it would require a central server.
@mx03 commented on GitHub (Jan 15, 2022):
Yes thats the problem, alexa don't know the server url, if you publish an alexa skill you can link your amazon account with the server url that's in the skill.
Problem you can't pass the url to the server as a alexa user. There are two options:
@advplyr commented on GitHub (Jan 16, 2022):
Sounds like this one will be something to look at again once the project is more mature.
I'm open to hosting a central server if it allows us to add certain features as long as it is opt-in only and transparent.
@oboe45 commented on GitHub (May 7, 2023):
Very pleased with Audiobookshelf - works perfectly for me except for the lack of Alexa or Siri operability. Happy to contribute as a tester, but have no current skills to offer, unless you can make use of an IBM 360 assembler programmer from the 60’s!
@adocampo commented on GitHub (Jul 3, 2023):
Just my two cents, I'm not a developer or whatsoever, but I set up a Lambda function to manage my Home Assistant, so I think there is no need at all for a "central server", if we, the users, have the steps to configure our own AWS Developer account and create a program with the free tier with a lambda function which connects to our ABS instance.
We will need, besides the logic of the lambda function, which can be done in python or another programming language, a domain (I guess it can be done with free domains like no-ip.org) and publish ABS via https (which can be get with letsencrypt).
It would be great to let alexa play any book or podcast on our ABS, and start reading where it left (MyMediaForAlexa doesn't do that).
@zimler commented on GitHub (Jul 29, 2023):
This would be a really cool addition to an already amazing project.
@yann-papouin commented on GitHub (Sep 30, 2023):
I've already made a self-hosted python's Alexa skill to play my children bed-stories and since I've now started self-hosting audiobookshelf (amazing app by the way) I was looking for a way to replace my http-files backend with it.
I took a look on https://api.audiobookshelf.org but I didn't found a way to get all titles/authors in the library (
api/items/batch/get?) or to make a content fuzzy search: convert user query to phonetic and compare it with all titles/authors (stored in phonetic too) using a levenshtein distance.@dathbe commented on GitHub (Dec 20, 2023):
I too would love this functionality. Plex is able to play self-hosted files through Alexa, though they obviously have a central point they can direct Alexa to and then distribute out to the specific server based on login information.
Some creative folks have come up with a way you can develop your own personal Alexa skill to link with the Subsonic API. https://github.com/rosskouk/asknavidrome . This could presumably be done for ABS as well.
The challenge would be, as others have pointed out, scaling this to a single production app that works for everyone's self-hosted server.
I don't have a lot of experience developing Alexa skills (I was able to get the asknavidrome skill working, but that's it). I know you can log in to skills. So it would presumably be possible to keep a central database of user logins that associate with self-hosted urls that allow connection to a skill. This has some privacy (and hosting) implications. So it would be interesting to know if, instead of just logging in, it is possible to develop a production alexa skill that requires configuration with a server address...like we do with the iOS app now. Not sure.
@DavidPesticcio commented on GitHub (Apr 11, 2024):
Perhaps Alexa could be decoupled from the ABS server by using some no-code like Zapier in between, additionally using the cloudflared tool to expose the ABS server for added security/proivacy...?
@amwmedia commented on GitHub (Sep 12, 2024):
Does anyone here have experience with getting an Echo device to play from ABS? I'm exploring into making an ABS skill and I've been able to get the Alexa app on my phone to play the HLS stream, but when I try the same skill on an echo dot there's no audio. I'm wondering if there's something incompatible with the transport stream, codec being used, etc? Anyway, thought I'd ask here in case someone else has run into this before.
@oboe45 commented on GitHub (Sep 12, 2024):
I would love to see a skill that works for ABS access - I asked about this
several times and the feedback was that it was relatively simple, but no
one actually provided the "simple" solution. Good luck, happy to test any
solution provided.
On Thu, Sep 12, 2024 at 8:59 AM Andrew Worcester @.***>
wrote:
@oboe45 commented on GitHub (Sep 13, 2024):
This was a comment from a couple of years back on this thread. Audiobookshelf is presumable sufficiently "more mature" now! Alexa is also very mature.
Is there anything that can be done to promote activity on an Alexa voice command set to Audiobookshlef?
@dathbe commented on GitHub (Sep 13, 2024):
It's not the easiest thing in the world to do because there's no central hub to register with Amazon (e.g., audible.com). It is possible, but it generally requires getting an Amazon dev account and setting up your own integration. That's cumbersome and has its own limitations. There are some theoretical workarounds, but it's not as straightforward as you might assume. Some folks have tried it with music and Navidrome. It works, but not really well.
@amwmedia commented on GitHub (Sep 13, 2024):
The problem is made even more difficult when you consider that the skill would need to be setup for every account that wants to listen on Alexa using ABS. Meaning that it can't just be setup once and used by my nieces and nephews... we would need to setup a separate skill for THEM as well.
What I'm planning to build (if I can get the darn thing to play on devices) is a system that would make it simple to install the skill and link it to your ABS instance and credentials. This wouldn't be an OSS project but rather a service for a minimal cost. Hopefully something like this would be welcomed by the ABS community even though it goes against the "self-hosted", free, and open source nature of the project.
@oboe45 commented on GitHub (Sep 13, 2024):
Depends on the price, but likely to subscribe here
On Fri, Sep 13, 2024 at 3:10 PM Andrew Worcester @.***>
wrote:
@P-Hoep commented on GitHub (Sep 19, 2024):
Hm, actually have something like this close to ready for beta testing (assuming amazon lets me get that far). Nothing super fancy but seems to work alright. Having difficulty with fast forwarding/skipping chapters though (probably need to rewrite some of the url handling or find another stream option) Could probably clean up and share code if anyone is interested. It's fairly basic rn. Am using 0auth to store credentials and have it linked to the app.
@amwmedia commented on GitHub (Sep 19, 2024):
@P-Hoep I'd love to take a look. I'd be very interested to see how you got the stream to play on an echo device. I'm sort of stuck there right now. It plays fine on the Alexa app but I get nothing on a real device. 😭
@oboe45 commented on GitHub (Sep 19, 2024):
Cool, I'll check it out!
On Thu, Sep 19, 2024 at 4:29 PM P-Hoep @.***> wrote:
@mx03 commented on GitHub (Oct 5, 2024):
Do you use the transcoded hls stream from abs?
Every echo dot I tried has issues with m3u8 files that are bigger than 1MB (independent of http compression).
I can upload my skill and everything around if you want some input.
@amwmedia commented on GitHub (Oct 5, 2024):
@mx03 I'd be happy to take a look. Interesting info about the file size. I might do some testing to verify if that's actually the issue with the playback issues
@mx03 commented on GitHub (Oct 5, 2024):
This is only a simple demo for alexa skill and abs, dont use it in production it may delete your audiobook progress.
The ABS mirror server must run in public with tls on port 443, as its not secured with authentication only run it while testing. (i use a wildcard cert like https://9f9d118ded5842475203d0d199143767b19a7a55.mydomain.com against random bot calls, with caddy in front)
ABS Mirror: https://gist.github.com/mx03/6ada5ce72d3389bc386086aafa1e627e
Alexa Lambda Skill: https://gist.github.com/mx03/56da94b7c7598e0d80eff9e48673c9e6
This skill play the lastest unfinished item, can be paused and resumed progess is synced with abs.
The problem with abs m3u8 is the token parameter e.g.
abs original (1,5MB for a 15h book):
https://gist.github.com/mx03/02d9628415d3a051a01e7ab355207c08
without token (232KB for 15h)
https://gist.github.com/mx03/fc83949b8d5f899062cf2610b7a63295
The main part of the mirror rewrites the m3u8 and return the file within a subfolder with the token, and every output-X.ts get requested with the path with the token without bloating the m3u8.
https:/example.com/hls/c4ce22cf-6623-446e-bedb-84d6c0d6e56b/MffwI1aRX0iRaVGxRf9YQJVXsLxnSUHZAYJkbVfXxFMk2MFH690patqXcJ1mpVR4jMndnxGtNOII3IwcQCTqSNxujjS2qE8qWzeizQfOz95nMO5Wics1rgfOpYe8KWFuYCxXEbsKVsAhzw2BypRMco/output.m3u8@mxdalchau commented on GitHub (Dec 15, 2024):
nice ideas .. is there a solution for the problem?
@amwmedia commented on GitHub (Dec 15, 2024):
There are some open source projects out there (some referenced here) that will work. I'm working on a project to solve this. I'll post here once I'm ready for beta testers 😉
@adocampo commented on GitHub (Dec 15, 2024):
I would be glad to betatest it ;)
@alaenghits commented on GitHub (Dec 18, 2024):
Would love to see this.
@sdholden28 commented on GitHub (Dec 19, 2024):
I'll add to the chorus. Would love to see this.
@eastoncrafter commented on GitHub (Dec 30, 2024):
Another!
Willing to beta test, have quite a few echo's and the dev console
@ajlennon commented on GitHub (Jan 6, 2025):
Yes please !!!
@CephandriusMaxtori commented on GitHub (Mar 28, 2025):
I can beta test too. i have multiple alexa and one at a diffrent home.
@neuther commented on GitHub (Oct 10, 2025):
I have plexamp and it isn't good for paying audiobooks. I love audiobookshelf but I don't like that I don't have my books when I'm not at home. I was wondering if there's a way to have audiobookshelf use my plexamp library?