telewebion-mcp 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- telewebion_mcp-0.1.0/.github/ISSUE_TEMPLATE/bug_report.yml +43 -0
- telewebion_mcp-0.1.0/.github/ISSUE_TEMPLATE/config.yml +5 -0
- telewebion_mcp-0.1.0/.github/banner.png +0 -0
- telewebion_mcp-0.1.0/.github/dependabot.yml +10 -0
- telewebion_mcp-0.1.0/.github/workflows/ci.yml +22 -0
- telewebion_mcp-0.1.0/.github/workflows/publish.yml +51 -0
- telewebion_mcp-0.1.0/.gitignore +6 -0
- telewebion_mcp-0.1.0/LICENSE +21 -0
- telewebion_mcp-0.1.0/PKG-INFO +149 -0
- telewebion_mcp-0.1.0/README.md +121 -0
- telewebion_mcp-0.1.0/pyproject.toml +56 -0
- telewebion_mcp-0.1.0/server.json +32 -0
- telewebion_mcp-0.1.0/src/telewebion_mcp/__init__.py +5 -0
- telewebion_mcp-0.1.0/src/telewebion_mcp/http.py +229 -0
- telewebion_mcp-0.1.0/src/telewebion_mcp/registry.py +16 -0
- telewebion_mcp-0.1.0/src/telewebion_mcp/server.py +92 -0
- telewebion_mcp-0.1.0/src/telewebion_mcp/tv.py +274 -0
- telewebion_mcp-0.1.0/tests/conftest.py +78 -0
- telewebion_mcp-0.1.0/tests/fixtures/channels.json +63 -0
- telewebion_mcp-0.1.0/tests/fixtures/episode.json +101 -0
- telewebion_mcp-0.1.0/tests/fixtures/live_events.json +97 -0
- telewebion_mcp-0.1.0/tests/fixtures/program.json +67 -0
- telewebion_mcp-0.1.0/tests/fixtures/schedule.json +166 -0
- telewebion_mcp-0.1.0/tests/fixtures/search.json +102 -0
- telewebion_mcp-0.1.0/tests/test_live_telewebion.py +35 -0
- telewebion_mcp-0.1.0/tests/test_telewebion.py +96 -0
- telewebion_mcp-0.1.0/uv.lock +1361 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
name: Bug report
|
|
2
|
+
description: A tool failed or returned wrong data
|
|
3
|
+
labels: [bug]
|
|
4
|
+
body:
|
|
5
|
+
- type: input
|
|
6
|
+
id: tool
|
|
7
|
+
attributes:
|
|
8
|
+
label: Tool
|
|
9
|
+
description: Which tool, e.g. tv_search
|
|
10
|
+
validations:
|
|
11
|
+
required: true
|
|
12
|
+
- type: textarea
|
|
13
|
+
id: input
|
|
14
|
+
attributes:
|
|
15
|
+
label: Arguments and result
|
|
16
|
+
description: The arguments the agent sent and the error or wrong output. Remove anything personal.
|
|
17
|
+
render: json
|
|
18
|
+
validations:
|
|
19
|
+
required: true
|
|
20
|
+
- type: textarea
|
|
21
|
+
id: expected
|
|
22
|
+
attributes:
|
|
23
|
+
label: What you expected
|
|
24
|
+
description: e.g. what telewebion.ir shows for the same input
|
|
25
|
+
- type: input
|
|
26
|
+
id: client
|
|
27
|
+
attributes:
|
|
28
|
+
label: MCP client and OS
|
|
29
|
+
placeholder: Claude Desktop 1.x on Windows 11
|
|
30
|
+
- type: dropdown
|
|
31
|
+
id: network
|
|
32
|
+
attributes:
|
|
33
|
+
label: Network
|
|
34
|
+
options:
|
|
35
|
+
- Direct connection from Iran
|
|
36
|
+
- Direct connection outside Iran
|
|
37
|
+
- VPN or proxy
|
|
38
|
+
- TELEWEBION_MCP_PROXY set
|
|
39
|
+
- type: input
|
|
40
|
+
id: version
|
|
41
|
+
attributes:
|
|
42
|
+
label: telewebion-mcp version
|
|
43
|
+
placeholder: "0.1.0"
|
|
Binary file
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
test:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
strategy:
|
|
12
|
+
matrix:
|
|
13
|
+
python: ["3.10", "3.11", "3.12", "3.13"]
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v7
|
|
16
|
+
- uses: astral-sh/setup-uv@v10.2.0
|
|
17
|
+
with:
|
|
18
|
+
python-version: ${{ matrix.python }}
|
|
19
|
+
- run: uv sync --locked
|
|
20
|
+
- run: uv run ruff check .
|
|
21
|
+
- run: uv run ruff format --check .
|
|
22
|
+
- run: uv run pytest -q
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
name: Publish
|
|
2
|
+
|
|
3
|
+
# Tag a release (git tag v0.1.0 && git push --tags) after bumping the version in
|
|
4
|
+
# pyproject.toml and server.json.
|
|
5
|
+
on:
|
|
6
|
+
push:
|
|
7
|
+
tags: ["v*"]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
pypi:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
environment: pypi
|
|
13
|
+
permissions:
|
|
14
|
+
id-token: write # PyPI trusted publishing
|
|
15
|
+
contents: write # GitHub Release
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v7
|
|
18
|
+
- uses: astral-sh/setup-uv@v10.2.0
|
|
19
|
+
- name: Check versions match the tag
|
|
20
|
+
run: |
|
|
21
|
+
TAG=${GITHUB_REF_NAME#v}
|
|
22
|
+
grep -q "^version = \"$TAG\"" pyproject.toml
|
|
23
|
+
test "$(jq -r .version server.json)" = "$TAG"
|
|
24
|
+
test "$(jq -r '.packages[0].version' server.json)" = "$TAG"
|
|
25
|
+
- run: uv sync --locked && uv run pytest -q
|
|
26
|
+
- run: uv build
|
|
27
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
28
|
+
- run: gh release create "$GITHUB_REF_NAME" dist/* --generate-notes --title "$GITHUB_REF_NAME"
|
|
29
|
+
env:
|
|
30
|
+
GH_TOKEN: ${{ github.token }}
|
|
31
|
+
|
|
32
|
+
mcp-registry:
|
|
33
|
+
needs: pypi
|
|
34
|
+
runs-on: ubuntu-latest
|
|
35
|
+
permissions:
|
|
36
|
+
id-token: write # MCP Registry login via GitHub OIDC
|
|
37
|
+
contents: read
|
|
38
|
+
steps:
|
|
39
|
+
- uses: actions/checkout@v7
|
|
40
|
+
- name: Wait for PyPI to serve the new version
|
|
41
|
+
run: |
|
|
42
|
+
for i in $(seq 1 30); do
|
|
43
|
+
curl -sf "https://pypi.org/pypi/telewebion-mcp/${GITHUB_REF_NAME#v}/json" >/dev/null && exit 0
|
|
44
|
+
sleep 10
|
|
45
|
+
done
|
|
46
|
+
exit 1
|
|
47
|
+
- name: Install mcp-publisher
|
|
48
|
+
run: |
|
|
49
|
+
curl -L "https://github.com/modelcontextprotocol/registry/releases/download/v1.8.1/mcp-publisher_$(uname -s | tr '[:upper:]' '[:lower:]')_$(uname -m | sed 's/x86_64/amd64/;s/aarch64/arm64/').tar.gz" | tar xz mcp-publisher
|
|
50
|
+
- run: ./mcp-publisher login github-oidc
|
|
51
|
+
- run: ./mcp-publisher publish
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Sepehr Radmard
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: telewebion-mcp
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Unofficial read-only MCP server for Telewebion (تلوبیون, telewebion.ir), IRIB live TV: channels, what aired, programs, episodes, live sports.
|
|
5
|
+
Project-URL: Homepage, https://github.com/sepehr071/telewebion-mcp
|
|
6
|
+
Project-URL: Repository, https://github.com/sepehr071/telewebion-mcp
|
|
7
|
+
Project-URL: Issues, https://github.com/sepehr071/telewebion-mcp/issues
|
|
8
|
+
Project-URL: Website, https://mcpfarsi.ir/
|
|
9
|
+
Author-email: Sepehr Radmard <sepehrr80@gmail.com>
|
|
10
|
+
License-Expression: MIT
|
|
11
|
+
License-File: LICENSE
|
|
12
|
+
Keywords: ai-agents,claude,epg,farsi,iran,irib,live-tv,mcp,mcp-server,model-context-protocol,persian,sports,streaming,talaviyon,telewebion,telewebion-ir,tv,tv-schedule
|
|
13
|
+
Classifier: Development Status :: 4 - Beta
|
|
14
|
+
Classifier: Intended Audience :: Developers
|
|
15
|
+
Classifier: Operating System :: OS Independent
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
|
|
22
|
+
Requires-Python: >=3.10
|
|
23
|
+
Requires-Dist: curl-cffi>=0.16.3
|
|
24
|
+
Requires-Dist: httpx-curl-cffi>=0.1.5
|
|
25
|
+
Requires-Dist: httpx>=0.27
|
|
26
|
+
Requires-Dist: mcp<3,>=2.2
|
|
27
|
+
Description-Content-Type: text/markdown
|
|
28
|
+
|
|
29
|
+
<!-- mcp-name: io.github.sepehr071/telewebion-mcp -->
|
|
30
|
+
|
|
31
|
+
<div align="center">
|
|
32
|
+
|
|
33
|
+
<img src="https://raw.githubusercontent.com/sepehr071/telewebion-mcp/main/.github/banner.png" alt="telewebion-mcp: unofficial Telewebion (تلوبیون) MCP server that lists live IRIB TV channels, what aired, programs, episodes and live sports for Claude, Cursor and Copilot" width="100%">
|
|
34
|
+
|
|
35
|
+
# telewebion-mcp: Telewebion (تلوبیون) IRIB live TV MCP server for AI agents
|
|
36
|
+
|
|
37
|
+
**telewebion-mcp is an unofficial, read-only MCP server that lets an AI agent list live TV channels, see what aired, and search programs, episodes and live sports on Telewebion (تلوبیون, telewebion.ir), the streaming site of Iran's state broadcaster IRIB.**<br>
|
|
38
|
+
Its 7 tools list live TV and radio channels, show what aired on a channel on a day, scan the national channels for their latest program, search programs and movies/series, list a program's episodes, show one episode, and list live sports broadcasts. Every result links to its page on telewebion.ir.<br>
|
|
39
|
+
No API key or account is needed; it works in Claude, Cursor, Copilot and any other MCP client.
|
|
40
|
+
|
|
41
|
+
[](https://pypi.org/project/telewebion-mcp/)
|
|
42
|
+
[](https://pypi.org/project/telewebion-mcp/)
|
|
43
|
+
[](https://github.com/sepehr071/telewebion-mcp/actions/workflows/ci.yml)
|
|
44
|
+
[](https://github.com/sepehr071/telewebion-mcp/blob/main/LICENSE)
|
|
45
|
+
|
|
46
|
+
[For AI agents](#for-ai-agents) · [Quick start](#quick-start) · [Tools](#tools) · [Limits](#limits) · [فارسی](#فارسی)
|
|
47
|
+
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
## For AI agents
|
|
53
|
+
|
|
54
|
+
- **What:** unofficial MCP server (model context protocol) for telewebion.ir (the old .com domain is dead): live channels, recorded schedules, programs, episodes and live sports events.
|
|
55
|
+
- **Install:** `uvx telewebion-mcp` or `claude mcp add telewebion -- uvx telewebion-mcp`. Transport: stdio. Needs [uv](https://docs.astral.sh/uv/getting-started/installation/) (Python 3.10+).
|
|
56
|
+
- **Auth:** none. Optional `TELEWEBION_MCP_PROXY` (HTTP proxy URL, or a comma-separated list); system proxy settings are ignored.
|
|
57
|
+
- **Access:** read-only. No login, no playback. Stream and download tokens are never returned, only page URLs.
|
|
58
|
+
- **Tools:** 7, all prefixed `tv_`. Typical sequences: `tv_search` -> `tv_program` -> `tv_episode`; `tv_channels` -> `tv_channel_schedule`; `tv_live_now` for a quick look at the national channels.
|
|
59
|
+
- **Use when:** the user asks what is on or was on an Iranian TV channel, wants to find a program, series or episode on Telewebion, or asks whether there is a live sports broadcast today.
|
|
60
|
+
- **Output:** compact JSON, Persian text, Gregorian dates, Tehran time.
|
|
61
|
+
|
|
62
|
+
## Quick start
|
|
63
|
+
|
|
64
|
+
You need [uv](https://docs.astral.sh/uv/getting-started/installation/). No API key or account.
|
|
65
|
+
|
|
66
|
+
Claude Code:
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
claude mcp add telewebion -- uvx telewebion-mcp
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Claude Desktop, Cursor, VS Code and other clients:
|
|
73
|
+
|
|
74
|
+
```json
|
|
75
|
+
{
|
|
76
|
+
"mcpServers": {
|
|
77
|
+
"telewebion": { "command": "uvx", "args": ["telewebion-mcp"] }
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
Example prompts:
|
|
83
|
+
|
|
84
|
+
- "What aired on Network 3 this morning?"
|
|
85
|
+
- "Find the series Paytakht and list its latest episodes."
|
|
86
|
+
- "Is there football on TV today?"
|
|
87
|
+
- <span dir="rtl">الان در شبکههای سراسری چه برنامهای پخش میشود؟</span>
|
|
88
|
+
- <span dir="rtl">امروز چه مسابقههای ورزشیای از تلوبیون پخش میشود؟</span>
|
|
89
|
+
|
|
90
|
+
Real answer (17 Nov 2026): `tv_live_now()` returned the latest program on TV1 as "بلندای همت" (08:48, 4 min), on TV2 "ایران جان (شبکه 2)" (06:05) and on TV3 "ایران ما (شبکه ۳)" (06:49, 66 min).
|
|
91
|
+
|
|
92
|
+
## Tools
|
|
93
|
+
|
|
94
|
+
| Tool | What it returns |
|
|
95
|
+
|---|---|
|
|
96
|
+
| `tv_channels` | Live channels (TV, provincial, radio) with the id the other tools take and live page URLs |
|
|
97
|
+
| `tv_channel_schedule` | What aired on a channel on a day, with start and end times (Tehran time) and episode URLs |
|
|
98
|
+
| `tv_live_now` | The most recent program on each channel of a group (national TV by default) |
|
|
99
|
+
| `tv_search` | Programs and movies/series matching a title, with page URLs |
|
|
100
|
+
| `tv_program` | A program's summary and its episodes, newest first |
|
|
101
|
+
| `tv_episode` | One episode: title, program, channel, air time, duration, quality variants, page URL |
|
|
102
|
+
| `tv_live_events` | Sports broadcasts (football, volleyball, ...) scheduled or live on a day |
|
|
103
|
+
|
|
104
|
+
## Limits
|
|
105
|
+
|
|
106
|
+
- Telewebion publishes **no future TV guide**. `tv_channel_schedule` and `tv_live_now` are the recorded log of what already aired and can trail the broadcast by an hour or two.
|
|
107
|
+
- Search is a loose substring match on the site's side, so a query can return unrelated titles after the best hit.
|
|
108
|
+
- Movies and series are on-demand product pages: search returns their page URLs, but their detail is not read.
|
|
109
|
+
- Playback, stream links, downloads and anything behind a login are not covered.
|
|
110
|
+
- Telewebion answers both Iranian and foreign networks in testing; if yours is blocked, set `TELEWEBION_MCP_PROXY`. The server ignores system proxy variables on purpose.
|
|
111
|
+
|
|
112
|
+
## How it works
|
|
113
|
+
|
|
114
|
+
Telewebion has no public API documentation. The endpoints behind telewebion.ir were mapped by watching the site in Chrome, and each tool was checked in Chrome against the real rendered pages (channel list, schedule, live now, search, program, episode, live events) on 16 Nov 2026. That check found live-event times in UTC where the site shows Tehran time; the tool converts them. The server calls the public gateway through a Chrome-impersonating HTTP client, with a short cache and at most two requests at a time.
|
|
115
|
+
|
|
116
|
+
## فارسی
|
|
117
|
+
|
|
118
|
+
<div dir="rtl">
|
|
119
|
+
|
|
120
|
+
**telewebion-mcp** یک سرور MCP غیررسمی و فقطخواندنی برای تلوبیون (telewebion.ir)، سایت پخش زندهٔ صدا و سیما است. با آن یک عامل هوش مصنوعی میتواند شبکههای زنده را فهرست کند، ببیند در یک روز چه چیزی روی آنتن رفته، برنامهها و سریالها را جستوجو کند، قسمتهای یک برنامه را بخواند و پخش زندهٔ رویدادهای ورزشی را ببیند. بدون حساب کاربری و کلید API کار میکند. تلوبیون برنامهٔ پخش آینده را منتشر نمیکند؛ جدول شبکهها فقط آنچه را که پخش شده نشان میدهد. نصب در Claude Code:
|
|
121
|
+
|
|
122
|
+
</div>
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
claude mcp add telewebion -- uvx telewebion-mcp
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
## Development
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
uv sync
|
|
132
|
+
uv run ruff check . && uv run ruff format --check .
|
|
133
|
+
uv run python -m pytest -q # offline tests on recorded fixtures
|
|
134
|
+
uv run python -m pytest -m live -q # live calls to telewebion.ir
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
Releases: bump the version in `pyproject.toml` and `server.json`, run `uv lock`, then push a `v*` tag; GitHub Actions publishes to PyPI.
|
|
138
|
+
|
|
139
|
+
## Disclaimer
|
|
140
|
+
|
|
141
|
+
Unofficial and not affiliated with or endorsed by IRIB or Telewebion. It is read-only and uses the public gateway of telewebion.ir, which can change without notice.
|
|
142
|
+
|
|
143
|
+
## Author
|
|
144
|
+
|
|
145
|
+
Built and maintained by **Sepehr Radmard** (سپهر رادمرد). [LinkedIn](https://www.linkedin.com/in/sepehr-radmard) · [GitHub](https://github.com/sepehr071) · more servers in [iran-mcp](https://github.com/sepehr071/iran-mcp).
|
|
146
|
+
|
|
147
|
+
## License
|
|
148
|
+
|
|
149
|
+
[MIT](https://github.com/sepehr071/telewebion-mcp/blob/main/LICENSE)
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
<!-- mcp-name: io.github.sepehr071/telewebion-mcp -->
|
|
2
|
+
|
|
3
|
+
<div align="center">
|
|
4
|
+
|
|
5
|
+
<img src="https://raw.githubusercontent.com/sepehr071/telewebion-mcp/main/.github/banner.png" alt="telewebion-mcp: unofficial Telewebion (تلوبیون) MCP server that lists live IRIB TV channels, what aired, programs, episodes and live sports for Claude, Cursor and Copilot" width="100%">
|
|
6
|
+
|
|
7
|
+
# telewebion-mcp: Telewebion (تلوبیون) IRIB live TV MCP server for AI agents
|
|
8
|
+
|
|
9
|
+
**telewebion-mcp is an unofficial, read-only MCP server that lets an AI agent list live TV channels, see what aired, and search programs, episodes and live sports on Telewebion (تلوبیون, telewebion.ir), the streaming site of Iran's state broadcaster IRIB.**<br>
|
|
10
|
+
Its 7 tools list live TV and radio channels, show what aired on a channel on a day, scan the national channels for their latest program, search programs and movies/series, list a program's episodes, show one episode, and list live sports broadcasts. Every result links to its page on telewebion.ir.<br>
|
|
11
|
+
No API key or account is needed; it works in Claude, Cursor, Copilot and any other MCP client.
|
|
12
|
+
|
|
13
|
+
[](https://pypi.org/project/telewebion-mcp/)
|
|
14
|
+
[](https://pypi.org/project/telewebion-mcp/)
|
|
15
|
+
[](https://github.com/sepehr071/telewebion-mcp/actions/workflows/ci.yml)
|
|
16
|
+
[](https://github.com/sepehr071/telewebion-mcp/blob/main/LICENSE)
|
|
17
|
+
|
|
18
|
+
[For AI agents](#for-ai-agents) · [Quick start](#quick-start) · [Tools](#tools) · [Limits](#limits) · [فارسی](#فارسی)
|
|
19
|
+
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## For AI agents
|
|
25
|
+
|
|
26
|
+
- **What:** unofficial MCP server (model context protocol) for telewebion.ir (the old .com domain is dead): live channels, recorded schedules, programs, episodes and live sports events.
|
|
27
|
+
- **Install:** `uvx telewebion-mcp` or `claude mcp add telewebion -- uvx telewebion-mcp`. Transport: stdio. Needs [uv](https://docs.astral.sh/uv/getting-started/installation/) (Python 3.10+).
|
|
28
|
+
- **Auth:** none. Optional `TELEWEBION_MCP_PROXY` (HTTP proxy URL, or a comma-separated list); system proxy settings are ignored.
|
|
29
|
+
- **Access:** read-only. No login, no playback. Stream and download tokens are never returned, only page URLs.
|
|
30
|
+
- **Tools:** 7, all prefixed `tv_`. Typical sequences: `tv_search` -> `tv_program` -> `tv_episode`; `tv_channels` -> `tv_channel_schedule`; `tv_live_now` for a quick look at the national channels.
|
|
31
|
+
- **Use when:** the user asks what is on or was on an Iranian TV channel, wants to find a program, series or episode on Telewebion, or asks whether there is a live sports broadcast today.
|
|
32
|
+
- **Output:** compact JSON, Persian text, Gregorian dates, Tehran time.
|
|
33
|
+
|
|
34
|
+
## Quick start
|
|
35
|
+
|
|
36
|
+
You need [uv](https://docs.astral.sh/uv/getting-started/installation/). No API key or account.
|
|
37
|
+
|
|
38
|
+
Claude Code:
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
claude mcp add telewebion -- uvx telewebion-mcp
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Claude Desktop, Cursor, VS Code and other clients:
|
|
45
|
+
|
|
46
|
+
```json
|
|
47
|
+
{
|
|
48
|
+
"mcpServers": {
|
|
49
|
+
"telewebion": { "command": "uvx", "args": ["telewebion-mcp"] }
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Example prompts:
|
|
55
|
+
|
|
56
|
+
- "What aired on Network 3 this morning?"
|
|
57
|
+
- "Find the series Paytakht and list its latest episodes."
|
|
58
|
+
- "Is there football on TV today?"
|
|
59
|
+
- <span dir="rtl">الان در شبکههای سراسری چه برنامهای پخش میشود؟</span>
|
|
60
|
+
- <span dir="rtl">امروز چه مسابقههای ورزشیای از تلوبیون پخش میشود؟</span>
|
|
61
|
+
|
|
62
|
+
Real answer (17 Nov 2026): `tv_live_now()` returned the latest program on TV1 as "بلندای همت" (08:48, 4 min), on TV2 "ایران جان (شبکه 2)" (06:05) and on TV3 "ایران ما (شبکه ۳)" (06:49, 66 min).
|
|
63
|
+
|
|
64
|
+
## Tools
|
|
65
|
+
|
|
66
|
+
| Tool | What it returns |
|
|
67
|
+
|---|---|
|
|
68
|
+
| `tv_channels` | Live channels (TV, provincial, radio) with the id the other tools take and live page URLs |
|
|
69
|
+
| `tv_channel_schedule` | What aired on a channel on a day, with start and end times (Tehran time) and episode URLs |
|
|
70
|
+
| `tv_live_now` | The most recent program on each channel of a group (national TV by default) |
|
|
71
|
+
| `tv_search` | Programs and movies/series matching a title, with page URLs |
|
|
72
|
+
| `tv_program` | A program's summary and its episodes, newest first |
|
|
73
|
+
| `tv_episode` | One episode: title, program, channel, air time, duration, quality variants, page URL |
|
|
74
|
+
| `tv_live_events` | Sports broadcasts (football, volleyball, ...) scheduled or live on a day |
|
|
75
|
+
|
|
76
|
+
## Limits
|
|
77
|
+
|
|
78
|
+
- Telewebion publishes **no future TV guide**. `tv_channel_schedule` and `tv_live_now` are the recorded log of what already aired and can trail the broadcast by an hour or two.
|
|
79
|
+
- Search is a loose substring match on the site's side, so a query can return unrelated titles after the best hit.
|
|
80
|
+
- Movies and series are on-demand product pages: search returns their page URLs, but their detail is not read.
|
|
81
|
+
- Playback, stream links, downloads and anything behind a login are not covered.
|
|
82
|
+
- Telewebion answers both Iranian and foreign networks in testing; if yours is blocked, set `TELEWEBION_MCP_PROXY`. The server ignores system proxy variables on purpose.
|
|
83
|
+
|
|
84
|
+
## How it works
|
|
85
|
+
|
|
86
|
+
Telewebion has no public API documentation. The endpoints behind telewebion.ir were mapped by watching the site in Chrome, and each tool was checked in Chrome against the real rendered pages (channel list, schedule, live now, search, program, episode, live events) on 16 Nov 2026. That check found live-event times in UTC where the site shows Tehran time; the tool converts them. The server calls the public gateway through a Chrome-impersonating HTTP client, with a short cache and at most two requests at a time.
|
|
87
|
+
|
|
88
|
+
## فارسی
|
|
89
|
+
|
|
90
|
+
<div dir="rtl">
|
|
91
|
+
|
|
92
|
+
**telewebion-mcp** یک سرور MCP غیررسمی و فقطخواندنی برای تلوبیون (telewebion.ir)، سایت پخش زندهٔ صدا و سیما است. با آن یک عامل هوش مصنوعی میتواند شبکههای زنده را فهرست کند، ببیند در یک روز چه چیزی روی آنتن رفته، برنامهها و سریالها را جستوجو کند، قسمتهای یک برنامه را بخواند و پخش زندهٔ رویدادهای ورزشی را ببیند. بدون حساب کاربری و کلید API کار میکند. تلوبیون برنامهٔ پخش آینده را منتشر نمیکند؛ جدول شبکهها فقط آنچه را که پخش شده نشان میدهد. نصب در Claude Code:
|
|
93
|
+
|
|
94
|
+
</div>
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
claude mcp add telewebion -- uvx telewebion-mcp
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## Development
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
uv sync
|
|
104
|
+
uv run ruff check . && uv run ruff format --check .
|
|
105
|
+
uv run python -m pytest -q # offline tests on recorded fixtures
|
|
106
|
+
uv run python -m pytest -m live -q # live calls to telewebion.ir
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
Releases: bump the version in `pyproject.toml` and `server.json`, run `uv lock`, then push a `v*` tag; GitHub Actions publishes to PyPI.
|
|
110
|
+
|
|
111
|
+
## Disclaimer
|
|
112
|
+
|
|
113
|
+
Unofficial and not affiliated with or endorsed by IRIB or Telewebion. It is read-only and uses the public gateway of telewebion.ir, which can change without notice.
|
|
114
|
+
|
|
115
|
+
## Author
|
|
116
|
+
|
|
117
|
+
Built and maintained by **Sepehr Radmard** (سپهر رادمرد). [LinkedIn](https://www.linkedin.com/in/sepehr-radmard) · [GitHub](https://github.com/sepehr071) · more servers in [iran-mcp](https://github.com/sepehr071/iran-mcp).
|
|
118
|
+
|
|
119
|
+
## License
|
|
120
|
+
|
|
121
|
+
[MIT](https://github.com/sepehr071/telewebion-mcp/blob/main/LICENSE)
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "telewebion-mcp"
|
|
3
|
+
version = "0.1.0"
|
|
4
|
+
description = "Unofficial read-only MCP server for Telewebion (تلوبیون, telewebion.ir), IRIB live TV: channels, what aired, programs, episodes, live sports."
|
|
5
|
+
readme = "README.md"
|
|
6
|
+
license = "MIT"
|
|
7
|
+
license-files = ["LICENSE"]
|
|
8
|
+
authors = [{ name = "Sepehr Radmard", email = "sepehrr80@gmail.com" }]
|
|
9
|
+
requires-python = ">=3.10"
|
|
10
|
+
keywords = ["mcp", "model-context-protocol", "telewebion", "telewebion-ir", "talaviyon", "irib", "iran", "tv", "live-tv", "epg", "tv-schedule", "streaming", "sports", "claude", "persian", "farsi", "ai-agents", "mcp-server"]
|
|
11
|
+
classifiers = [
|
|
12
|
+
"Development Status :: 4 - Beta",
|
|
13
|
+
"Intended Audience :: Developers",
|
|
14
|
+
"Operating System :: OS Independent",
|
|
15
|
+
"Programming Language :: Python :: 3",
|
|
16
|
+
"Programming Language :: Python :: 3.10",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
"Programming Language :: Python :: 3.12",
|
|
19
|
+
"Programming Language :: Python :: 3.13",
|
|
20
|
+
"Topic :: Scientific/Engineering :: Artificial Intelligence",
|
|
21
|
+
]
|
|
22
|
+
dependencies = [
|
|
23
|
+
"mcp>=2.2,<3",
|
|
24
|
+
"httpx>=0.27",
|
|
25
|
+
"httpx-curl-cffi>=0.1.5",
|
|
26
|
+
"curl-cffi>=0.16.3",
|
|
27
|
+
]
|
|
28
|
+
|
|
29
|
+
[project.urls]
|
|
30
|
+
Homepage = "https://github.com/sepehr071/telewebion-mcp"
|
|
31
|
+
Repository = "https://github.com/sepehr071/telewebion-mcp"
|
|
32
|
+
Issues = "https://github.com/sepehr071/telewebion-mcp/issues"
|
|
33
|
+
Website = "https://mcpfarsi.ir/"
|
|
34
|
+
|
|
35
|
+
[project.scripts]
|
|
36
|
+
telewebion-mcp = "telewebion_mcp.server:main"
|
|
37
|
+
|
|
38
|
+
[dependency-groups]
|
|
39
|
+
dev = ["pytest>=8", "ruff>=0.6"]
|
|
40
|
+
|
|
41
|
+
[build-system]
|
|
42
|
+
requires = ["hatchling"]
|
|
43
|
+
build-backend = "hatchling.build"
|
|
44
|
+
|
|
45
|
+
[tool.pytest.ini_options]
|
|
46
|
+
testpaths = ["tests"]
|
|
47
|
+
addopts = "-m 'not live'"
|
|
48
|
+
markers = ["live: calls the real Telewebion APIs (run with -m live)"]
|
|
49
|
+
|
|
50
|
+
[tool.ruff]
|
|
51
|
+
line-length = 120
|
|
52
|
+
target-version = "py310"
|
|
53
|
+
|
|
54
|
+
[tool.ruff.lint]
|
|
55
|
+
select = ["E", "F", "I", "B", "UP"]
|
|
56
|
+
ignore = ["E501"] # long Field(description=...) strings read better on one line
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
|
|
3
|
+
"name": "io.github.sepehr071/telewebion-mcp",
|
|
4
|
+
"title": "Telewebion TV",
|
|
5
|
+
"description": "Read-only Telewebion (telewebion.ir) IRIB TV: channels, what aired, programs, episodes, live sports.",
|
|
6
|
+
"repository": {
|
|
7
|
+
"url": "https://github.com/sepehr071/telewebion-mcp",
|
|
8
|
+
"source": "github"
|
|
9
|
+
},
|
|
10
|
+
"websiteUrl": "https://github.com/sepehr071/telewebion-mcp",
|
|
11
|
+
"version": "0.1.0",
|
|
12
|
+
"packages": [
|
|
13
|
+
{
|
|
14
|
+
"registryType": "pypi",
|
|
15
|
+
"registryBaseUrl": "https://pypi.org",
|
|
16
|
+
"identifier": "telewebion-mcp",
|
|
17
|
+
"version": "0.1.0",
|
|
18
|
+
"runtimeHint": "uvx",
|
|
19
|
+
"transport": {
|
|
20
|
+
"type": "stdio"
|
|
21
|
+
},
|
|
22
|
+
"environmentVariables": [
|
|
23
|
+
{
|
|
24
|
+
"name": "TELEWEBION_MCP_PROXY",
|
|
25
|
+
"description": "Optional HTTP proxy URL for the Telewebion requests; system proxy settings are ignored. Also accepts a comma-separated list: one is used until it gets blocked or fails to connect, then the next.",
|
|
26
|
+
"isRequired": false,
|
|
27
|
+
"isSecret": false
|
|
28
|
+
}
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
]
|
|
32
|
+
}
|