get_movie_show_by_id
Retrieve detailed information about a specific TV show or movie using its MyShows ID, including episode lists and season data.
Instructions
Retrieves a show or movie by its MyShows ID. :param myshows_item_id: The MyShows ID of the show or movie to retrieve. :return: A dictionary containing the show's details, including episodes and season counts.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| myshows_item_id | Yes |
Implementation Reference
- src/myshows_mcp/server.py:53-60 (handler)The MCP tool handler for 'get_movie_show_by_id', registered via @mcp.tool(), executes the core logic by calling the MyShowsAPI client.@mcp.tool() @tool_handler async def get_movie_show_by_id(myshows_item_id: int): """Retrieves a show or movie by its MyShows ID. :param myshows_item_id: The MyShows ID of the show or movie to retrieve. :return: A dictionary containing the show's details, including episodes and season counts. """ return await api_client.get_by_id(myshows_item_id=myshows_item_id)
- Supporting API client method that performs the HTTP request to MyShows 'shows.GetById' endpoint to retrieve the movie/show details.async def get_by_id(self, myshows_item_id: int): """Retrieves a show by its MyShows ID, including episodes and season counts. :param myshows_item_id: The MyShows ID of the show to retrieve. :return: A dictionary containing the show's details, including episodes and season counts. """ return await self._make_request( method="shows.GetById", id=87, params={ "showId": int(myshows_item_id), "withEpisodes": True, "withSeasonCounts": True, }, )
- src/myshows_mcp/server.py:53-53 (registration)Registers the tool with FastMCP using the @mcp.tool() decorator.@mcp.tool()