Skip to main content
logo

ytnoti

Easy-to-use Python library for receiving real-time YouTube push notifications for video uploads, edits, deletions, and live streams.
PyPI version

ytnoti is designed to help you receive YouTube push notifications in real-time for video upload, edit, delete, and live stream easily and efficiently.

🛠️ How it works

This library uses YouTube Data API v3 via PubSubHubbub to receive push notifications, so you can receive notifications in real time without constantly polling the YouTube API.

In addition, this method doesn't require any API key for YouTube Data API, so you can use this library without any quota limit.

💻 Installation

This library requires Python 3.11 or higher.

pip install ytnoti

📖 Simple Example

Following is a simple example of how to use ngrok to receive push notifications (not recommended for production).

from pyngrok import ngrok
from ytnoti import YouTubeNotifier, Video

ngrok.set_auth_token("Your ngrok token here")

notifier = YouTubeNotifier()


@notifier.upload()
async def listener(video: Video) -> None:
    print(f"New video from {video.channel.name}: {video.title}")


notifier.subscribe("UCuFFtHWoLl5fauMMD5Ww2jA")  # Channel ID of CBC News
notifier.run()

Following is a simple example of how to use your domain to receive push notifications.

from ytnoti import YouTubeNotifier, Video

notifier = YouTubeNotifier(callback_url="https://yourdomain.com")


@notifier.upload()
async def listener(video: Video) -> None:
    print(f"New video from {video.channel.name}: {video.title}")


notifier.subscribe("UCuFFtHWoLl5fauMMD5Ww2jA")  # Channel ID of CBC News
notifier.run()

For more examples, please visit the examples folder.

📚 Documentation

Please read the documentation before asking questions. Your question may already be answered there.

👥 Community

If you are having any problems with using this library, please feel free to ask for help in the issues section or on my Discord server.

discord invite

📄 License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Metadata

Release files for ytnoti 3.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ytnoti 3.0.3
File Size Uploaded
ytnoti-3.0.3.tar.gz 19.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ytnoti 3.0.3
File Interpreter ABI Platform
ytnoti-3.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 35.1 kB

Release files / ytnoti-3.0.3.tar.gz

Download URL ytnoti-3.0.3.tar.gz
Size 19.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9b7015550c77aea4b7f379d77940f59fb49ea2e725fbf4a063c9ae40bdd710c7
BLAKE2b-256 checksum
How to use checksums
5561b7fee7f7dbe8eefd4b7ea8d1cb845d8577d04f46602eb9467229f55fbb98
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.12 {"installer":{"name":"uv","version":"0.12.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / ytnoti-3.0.3-py3-none-any.whl

Download URL ytnoti-3.0.3-py3-none-any.whl
Size 15.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
72e364d94c7ae8d6ed9c76305f6ca7db0fc4b7a26f96e2a950ace0986578d3dc
BLAKE2b-256 checksum
How to use checksums
5843ca58920ec88708aa4e225200ba0f2c6c44a2b12bf3e52ac4a57f51c8b993
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.12 {"installer":{"name":"uv","version":"0.12.12","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

3.0.4

2 release files

This release

3.0.3 This release

2 release files

3.0.2

2 release files

3.0.1

2 release files

3.0.0

2 release files

2.1.4

2 release files

2.1.3

2 release files

2.1.2

2 release files

2.1.1

2 release files

2.1.0

2 release files

2.0.1

2 release files

2.0.0

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page