Skip to main content
Glama

discover_by_provider

Find movies and TV shows available on specific streaming services in your region to help you discover content you can watch immediately.

Instructions

Discovers movies or TV shows available on specific streaming providers in a region. Input: type (optional: tv|movie, default tv), with_watch_providers (required comma-separated provider IDs), watch_region (required ISO 3166-1), language (optional ISO 639-1, default en), page (optional), sort_by (optional). Output: JSON with paginated results. Purpose: Personalized content discovery based on streaming availability for AI agents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
languageNoISO 639-1 language (e.g., en)
pageNoPage number
sort_byNoSort order (e.g., release_date.desc, first_air_date.desc, popularity.desc)
typeNoMedia type to discover: tv (default) or movie
watch_regionYesISO 3166-1 region code (e.g., IS)
with_watch_providersYesProvider ID(s), comma-separated (e.g., '8'), from service get_watch_providers

Implementation Reference

  • The async handler function that executes the tool logic by calling the TMDB /discover/{type} API endpoint with parameters for filtering by watch providers in a specific region.
    handler: async ({ type = "tv", with_watch_providers, watch_region, language = "en", page = 1, sort_by = "release_date.desc" }) => { const data = await tmdbFetch(`/discover/${type}`, { language, page, with_watch_providers, sort_by, watch_region }); return {content: [{type: "text", text: JSON.stringify(data, null, 2)}]}; }
  • The inputSchema JSON Schema object defining the expected input parameters, types, descriptions, and requirements for the tool.
    inputSchema: { type: "object", properties: { type: { type: "string", enum: ["tv", "movie"], description: "Media type to discover: tv (default) or movie" }, with_watch_providers: { type: "string", description: "Provider ID(s), comma-separated (e.g., '8'), from service get_watch_providers" }, watch_region: {type: "string", description: "ISO 3166-1 region code (e.g., IS)"}, language: {type: "string", description: "ISO 639-1 language (e.g., en)"}, page: {type: "number", minimum: 1, description: "Page number"}, sort_by: { type: "string", description: "Sort order (e.g., release_date.desc, first_air_date.desc, popularity.desc)" } }, required: ["with_watch_providers", "watch_region"], additionalProperties: false },
  • The complete tool object definition within the 'tools' array, which serves as the registration point for the MCP server to list and invoke this tool via name matching.
    { name: "discover_by_provider", description: "Discovers movies or TV shows available on specific streaming providers in a region. Input: type (optional: tv|movie, default tv), with_watch_providers (required comma-separated provider IDs), watch_region (required ISO 3166-1), language (optional ISO 639-1, default en), page (optional), sort_by (optional). Output: JSON with paginated results. Purpose: Personalized content discovery based on streaming availability for AI agents.", inputSchema: { type: "object", properties: { type: { type: "string", enum: ["tv", "movie"], description: "Media type to discover: tv (default) or movie" }, with_watch_providers: { type: "string", description: "Provider ID(s), comma-separated (e.g., '8'), from service get_watch_providers" }, watch_region: {type: "string", description: "ISO 3166-1 region code (e.g., IS)"}, language: {type: "string", description: "ISO 639-1 language (e.g., en)"}, page: {type: "number", minimum: 1, description: "Page number"}, sort_by: { type: "string", description: "Sort order (e.g., release_date.desc, first_air_date.desc, popularity.desc)" } }, required: ["with_watch_providers", "watch_region"], additionalProperties: false }, handler: async ({ type = "tv", with_watch_providers, watch_region, language = "en", page = 1, sort_by = "release_date.desc" }) => { const data = await tmdbFetch(`/discover/${type}`, { language, page, with_watch_providers, sort_by, watch_region }); return {content: [{type: "text", text: JSON.stringify(data, null, 2)}]}; } },

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/drakonkat/wizzy-mcp-tmdb'

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