Skip to main content
Glama
movie.py947 B
"""Movie models for the Trakt MCP server.""" from typing import Any from pydantic import BaseModel, Field class TraktMovie(BaseModel): """Represents a Trakt movie.""" title: str year: int | None = None ids: dict[str, str | int | None] = Field( description="Various IDs for the movie (trakt, slug, tmdb, imdb)" ) overview: str | None = None class TraktTrendingMovie(BaseModel): """Represents a trending movie from Trakt API.""" watchers: int = Field(description="Number of people watching this movie") movie: TraktMovie class TraktPopularMovie(BaseModel): """Represents a popular movie from Trakt API.""" movie: TraktMovie = Field(description="The movie information") @classmethod def from_api_response(cls, api_data: dict[str, Any]) -> "TraktPopularMovie": """Create a TraktPopularMovie instance from raw API data.""" return cls(movie=TraktMovie(**api_data))

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/wwiens/trakt_mcpserver'

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