https://github.com/henrique-coder/streamsnapper
StreamSnapper is an intuitive library designed to simplify, improve, and organize YouTube and Youtube Music media streams. It offers scraping functions with higher speed extraction and efficiency with the latest tools to perform such processes.
https://github.com/henrique-coder/streamsnapper
downloader merger scraper snapper stream youtube
Last synced: 27 days ago
JSON representation
StreamSnapper is an intuitive library designed to simplify, improve, and organize YouTube and Youtube Music media streams. It offers scraping functions with higher speed extraction and efficiency with the latest tools to perform such processes.
- Host: GitHub
- URL: https://github.com/henrique-coder/streamsnapper
- Owner: henrique-coder
- License: mit
- Created: 2024-09-25T02:05:58.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2025-04-23T17:26:46.000Z (about 1 month ago)
- Last Synced: 2025-04-23T18:36:09.553Z (about 1 month ago)
- Topics: downloader, merger, scraper, snapper, stream, youtube
- Language: Python
- Homepage:
- Size: 465 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## StreamSnapper




StreamSnapper is an intuitive library designed to simplify, improve, and organize YouTube and Youtube Music media streams. It offers scraping functions with higher speed extraction and efficiency with the latest tools to perform such processes.
#### Installation (from [PyPI](https://pypi.org/project/streamsnapper))
```bash
# Install the stable version of StreamSnapper from PyPI (recommended)
pip install --upgrade streamsnapper# Install the development version of StreamSnapper from GitHub
pip install --upgrade git+https://github.com/henrique-coder/streamsnapper.git@main
```> [!Note]
> If you already have a version installed and want to switch to a different branch (for example, to test new features or fix bugs), you will need to use the `--force-reinstall` parameter to ensure the upgrade occurs correctly.### Example Usage
```python
from streamsnapper import YouTubeyoutube = YouTube(logging=False)
youtube.extract(url="https://www.youtube.com/watch?v=***********", ytdlp_data=None)
youtube.analyze(check_thumbnails=False, retrieve_dislike_count=False)
youtube.analyze_video_streams(preferred_quality="all")
youtube.analyze_audio_streams(preferred_language="source")
youtube.analyze_subtitle_streams()from streamsnapper import YouTubeExtractor
youtube_extractor = YouTubeExtractor()
print(youtube_extractor.identify_platform(url="https://music.youtube.com/watch?v=***********"))
print(youtube_extractor.extract_video_id(url="https://www.youtube.com/watch?v=***********"))
print(
youtube_extractor.extract_playlist_id(
url="https://www.youtube.com/playlist?list=**********************************", include_private=False
)
)print(youtube_extractor.search(query="A cool music name", sort_by="relevance", results_type="video", limit=1))
print(
youtube_extractor.get_playlist_videos(
url="https://www.youtube.com/playlist?list=**********************************", limit=None
)
)print(
youtube_extractor.get_channel_videos(
channel_id="************************",
channel_url="https://www.youtube.com/@********",
channel_username="********",
sort_by="newest",
content_type="videos",
limit=None,
)
)# All functions are documented and have detailed typings, use your development IDE to learn more.
```
```python
from streamsnapper import Mergermerger = Merger(
logging=False
)merger.merge(
video_path='path/to/video',
audio_path='path/to/audio',
output_path='path/to/output',
ffmpeg_path='local'
)# All functions are documented and have detailed typings, use your development IDE to learn more.
```
### Contributing
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.
If you have a suggestion that would make this better, fork the repository and create a pull request. You can also simply open an issue and describe your ideas or report bugs. **Don't forget to give the project a star if you like it!**
1. Fork the project;
2. Create your feature branch ・ `git checkout -b feature/{feature_name}`;
3. Commit your changes ・ `git commit -m "{commit_message}"`;
4. Push to the branch ・ `git push origin feature/{feature_name}`;
5. Open a pull request, describing the changes you made and wait for a review.### Disclaimer
Please note that downloading copyrighted content from some media services may be illegal in your country. This tool is designed for educational purposes only. Use at your own risk.