Stremio / stremio-addon-sdk

🧙 A Node.js SDK for creating and publishing Stremio add-ons
https://www.stremio.com/addon-sdk
MIT License
656 stars 175 forks source link

Is it possible to add another section on movie details? #251

Closed guybrush-threepwood-the-third closed 9 months ago

guybrush-threepwood-the-third commented 9 months ago

I'm looking to create an add-on that will create a new section on a movie's /details page.

For example, adding a "Parents Guide" section below Summary, with data fetched from a third-party API to display a short sentence or two. image

Is this possible?

I thought this might have been achievable via creating a new defineMetaHandler, but I think I've misunderstood the docs, overall. I'm assuming the meta data shown in the screen shot is coming from Cinemeta, and I was hoping by defining a new defineMetaHandler I'd be able to append more meta data to the view, somehow. This doesn't seem to be the case, at least not in anything I've tried implementing so far. It seems defineMetaHandler is meant for meta data for items provided by a whole new catalog of items (via defineCatalogHandler)

dexter21767-dev commented 9 months ago

u can't append new data to the response of another addon. for meta responses, stremio checks the addons that support that type and id then request the meta from the first addon that supports it. which for imdb ids is always cinemeta. imo, you can either create a catalog using defineCatalogHandler then serve your own meta for that catalog. or you can provide a stream response with a dummy URL and the data you wanna provide as title and description.