Skip to main content
Glama

get_upcoming_releases

Retrieve upcoming movie and TV releases from IMDb for specific countries with paginated results.

Instructions

Get the upcoming releases from IMDb with pagination. Args: country_code: The country code to get the upcoming releases for. type: The type of the upcoming releases to get. Possible values: "TV", "MOVIE". start: The starting index (0-based) to retrieve releases from. Returns: JSON object containing 5 upcoming releases starting from the specified index.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
country_codeYes
typeYes
startYes

Implementation Reference

  • The main handler function for the 'get_upcoming_releases' tool. It is decorated with @mcp.tool() for automatic registration. Fetches upcoming releases data from the IMDb API using the provided country_code and type parameters, handles pagination with the start index using the paginated_response helper, and returns a JSON string of the results or an error message if data is unavailable.
    @mcp.tool() async def get_upcoming_releases(country_code: str, type: str, start: int, ctx: Context) -> str: """Get the upcoming releases from IMDb with pagination. Args: country_code: The country code to get the upcoming releases for. type: The type of the upcoming releases to get. Possible values: "TV", "MOVIE". start: The starting index (0-based) to retrieve releases from. Returns: JSON object containing 5 upcoming releases starting from the specified index. """ upcoming_releases_url = f"{BASE_URL}/upcoming-releases" upcoming_releases_data = await make_imdb_request(upcoming_releases_url, {"countryCode": country_code, "type": type}, ctx) if not upcoming_releases_data: return "Unable to fetch upcoming releases data." return json.dumps(paginated_response(upcoming_releases_data, start, len(upcoming_releases_data)), indent=4)

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/uzaysozen/imdb-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server