macr0dev / Audiobooks.bundle

Plex metadata scraper for Audiobooks
600 stars 65 forks source link

plex is not able to find authors at all #50

Open shedman214 opened 4 years ago

shedman214 commented 4 years ago

my plex is not able to find any authors at all. as soon as I click search it says not found. the books work just fine, but the authors cant be found. is there a way to fix that

jjmulenex commented 4 years ago

I am experiencing the same issue

macr0dev commented 4 years ago

Until very recently, Audible didn't have author details so there has been nothing to pull or 'match' to. It's being worked on, but it is not something that is supposed to be working at this time.

They've recently added some author pages, but not for everyone.

jjmulenex commented 4 years ago

Until very recently, Audible didn't have author details so there has been nothing to pull or 'match' to. It's being worked on, but it is not something that is supposed to be working at this time.

They've recently added some author pages, but not for everyone.

Thanks for the update. I read in the notes that the Author was being pulled from last.fm.. go to know

macr0dev commented 4 years ago

They've changed from last.fm to something else now (I forget what, musicbrainz maybe?) during the last big music library update late last year. So even that info is a little out of date. Either way, it's crowd sourced information if it's even there.

romanoh commented 4 years ago

There is an author pages: https://www.audible.com/author/Douglas-E-Richards/B001K7WURS?ref=a_search_c3_lAuthor_1_1_1&pf_rd_p=e81b7c27-6880-467a-b5a7-13cef5d729fe&pf_rd_r=TN4V571PAH7HSJ72GH4D

just for the most famous artists i guess.

shedman214 commented 4 years ago

The link doesn't work

On Fri, Apr 24, 2020 at 7:37 PM romanoh notifications@github.com wrote:

There is an author pages: https://www.audible.com/author/Douglas-E-Richards/B001K7WURS?ref=a_search_c3_lAuthor_1_1_1&pf_rd_p=e81b7c27-6880-467a-b5a7-13cef5d729fe&pf_rd_r=TN4V571PAH7HSJ72GH4D http://url

just for the most famous artists i guess.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/macr0dev/Audiobooks.bundle/issues/50#issuecomment-619291960, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHYXZCNFSB4QBYYVZJN3GBDROIWE7ANCNFSM4KJWSG7A .

mcqweb commented 3 years ago

Looking at the Author "issue" and also the availability of the Audible API. This is very rough and ready but here's some example code to grab the info from Audible

import requests
import json
from bs4 import BeautifulSoup 

author_search_url = "https://api.audible.com/1.0/catalog/search?image_sizes=1215,558,900&keywords={0}&locale=en-GB&marketplace=AF2M0KC94RCEA&page=1&response_groups=contributors,product_desc,media,product_attrs,product_extended_attrs,product_plan_details,product_plans,relationships,sku"
headers={'User-Agent': 'Audible/652 CFNetwork/1209 Darwin/20.2.0'}
respJSON = requests.get(author_search_url.format("Earnest%20Cline"),headers=headers).json()
author_asin = respJSON['products'][0]['authors'][0]['asin']
author_url = 'https://www.audible.com/author/{0}?ipRedirectOverride=true&overrideBaseCountry=true'
author_html = requests.get(author_url.format(author_asin),headers=headers)
author_content = BeautifulSoup(author_html.text,"html.parser")
for img in author_content.select('img[class*="author-image-outline"]'):
    print(img['src'].replace('120','900'))

for p in author_content.select('p[class*="adbl-author-desc"]'):
    print(p.getText().strip())

It doesn't need authentication to access these parts of the API, I haven't found an author API call (The app can't do it) and the Author page appears to be .com only (well not .co.uk at least)

I'm going to hack away for my purposes but I'm happy to help if you want to look at building this in