Skip to main content

🔎 Search for videos, channels and playlists on YouTube quickly and easily.

Project description

Tube Search - Youtube fast and practical search engine in Python

Tube Search

Tube Search is an asynchronous, constantly up-to-date and written python library, aiming to do research simply, practically and quickly on YouTube.

Search for Video (1 Video):

from asyncio import run
from tube_search import VideoSearch

async def main() -> None:
    video = await VideoSearch().video(
        query="Elektronomia",
        language="en-US",
        region="US"
    )
    print(video)
    print()
    print(video.videoTitle)

run(main())

Output from search video (1 video):

$ TubeVideoInfo(videoID='TW9d8vYrVFQ', videoTitle='Elektronomia - Sky High | Progressive House | NCS - Copyright Free Music', videoDuration='3:58', publishedTime='8 years ago', videoViewCount=TubeViewsInfo(view_count='264,461,922 views', view_abbr_count='264M views'), thumbnails=[TubeThumbnailsInfo(url='https://i.ytimg.com/vi/TW9d8vYrVFQ/hqdefault.jpg?sqp=-oaymwEcCOADEI4CSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLDzHv6boRaBnEoZWSNFdZRGVdUmJw', width=480, height=270)], descriptionSnippet='#nocopyrightsounds #copyrightfree #music #song #edm #dancemusic #royaltyfreemusic #copyrightfreemusic #nocopyrightmusic\xa0...', channel=TubeChannelInfo(title='NoCopyrightSounds', id='UC_aEa8K-EOJ3D6gOs7HcyNg', thumbnails=[TubeThumbnailsInfo(url='https://yt3.ggpht.com/opGwWu2ScRBy-OA81LIzKwSatxlVKjjNyAdt4fWh4LoLzldx05Sdf3OGQz0Fz78ziZ9RLP4=s68-c-k-c0x00ffffff-no-rj', width=68, height=68)], url='https://www.youtube.com/channel/UC_aEa8K-EOJ3D6gOs7HcyNg'), accessibility=TubeAccessibilityInfo(title='Elektronomia - Sky High | Progressive House | NCS - Copyright Free Music 3 minutes, 58 seconds', duration='3 minutes, 58 seconds'), url='https://www.youtube.com/watch?v=TW9d8vYrVFQ', shelfTitle=None)

$ Elektronomia - Sky High | Progressive House | NCS - Copyright Free Music

Search for Videos (2 or more videos):

from asyncio import run
from tube_search import VideoSearch

async def main() -> None:
    video = await VideoSearch().videos(
        query="Elektronomia",
        language="en-US",
        region="US",
        limit=3
    )
    print(len(video))
    print(video)

run(main())

Output fron search videos (2 or more vídeos):

$ 2
$ [TubeVideoInfo(videoID='TW9d8vYrVFQ', videoTitle='Elektronomia - Sky High | Progressive House | NCS - Copyright Free Music', videoDuration='3:58', publishedTime='8 years ago', videoViewCount=TubeViewsInfo(view_count='264,729,531 views', view_abbr_count='264M views'), thumbnails=[TubeThumbnailsInfo(url='https://i.ytimg.com/vi/TW9d8vYrVFQ/hqdefault.jpg?sqp=-oaymwEcCOADEI4CSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLDzHv6boRaBnEoZWSNFdZRGVdUmJw', width=480, height=270)], descriptionSnippet='#nocopyrightsounds #copyrightfree #music #song #edm #dancemusic #royaltyfreemusic #copyrightfreemusic #nocopyrightmusic\xa0...', channel=TubeChannelInfo(title='NoCopyrightSounds', id='UC_aEa8K-EOJ3D6gOs7HcyNg', thumbnails=[TubeThumbnailsInfo(url='https://yt3.ggpht.com/opGwWu2ScRBy-OA81LIzKwSatxlVKjjNyAdt4fWh4LoLzldx05Sdf3OGQz0Fz78ziZ9RLP4=s68-c-k-c0x00ffffff-no-rj', width=68, height=68)], url='https://www.youtube.com/channel/UC_aEa8K-EOJ3D6gOs7HcyNg'), accessibility=TubeAccessibilityInfo(title='Elektronomia - Sky High | Progressive House | NCS - Copyright Free Music 3 minutes, 58 seconds', duration='3 minutes, 58 seconds'), url='https://www.youtube.com/watch?v=TW9d8vYrVFQ', shelfTitle=None), TubeVideoInfo(videoID='IvVgQHZtpQE', videoTitle='Best of Elektronomia 2018 | Top 20 Songs of Elektronomia', videoDuration='1:19:17', publishedTime='6 years ago', videoViewCount=TubeViewsInfo(view_count='3,551,520 views', view_abbr_count='3.5M views'), thumbnails=[TubeThumbnailsInfo(url='https://i.ytimg.com/vi/IvVgQHZtpQE/hq720.jpg?sqp=-oaymwEcCOgCEMoBSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLDMuVnG1n3vFCydcS25IoGFeATqiA', width=360, height=202), TubeThumbnailsInfo(url='https://i.ytimg.com/vi/IvVgQHZtpQE/hq720.jpg?sqp=-oaymwEcCNAFEJQDSFXyq4qpAw4IARUAAIhCGAFwAcABBg==&rs=AOn4CLA3EB6Wp6JT-cDSieyTiTqWcFTCVA', width=720, height=404)], descriptionSnippet='Elektronomia Top 20 | Best of Elektronomia 2018 Please help Musicbot reach 100k subscriber by join at\xa0...', channel=TubeChannelInfo(title='Musicbot', id='UCDsbBjIl0lYZB4IokDLyWIQ', thumbnails=[TubeThumbnailsInfo(url='https://yt3.ggpht.com/ytc/AIdro_nqKHLecROII_Q_UJTkPI6W7C-6hlXCPzpVwDwBU7E4x2o=s68-c-k-c0x00ffffff-no-rj', width=68, height=68)], url='https://www.youtube.com/channel/UCDsbBjIl0lYZB4IokDLyWIQ'), accessibility=TubeAccessibilityInfo(title='Best of Elektronomia 2018 | Top 20 Songs of Elektronomia 1 hour, 19 minutes', duration='1 hour, 19 minutes, 17 seconds'), url='https://www.youtube.com/watch?v=IvVgQHZtpQE', shelfTitle=None)]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tube_search-0.0.2.1.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tube_search-0.0.2.1-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file tube_search-0.0.2.1.tar.gz.

File metadata

  • Download URL: tube_search-0.0.2.1.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.1

File hashes

Hashes for tube_search-0.0.2.1.tar.gz
Algorithm Hash digest
SHA256 391cc41548ff2be25d5dd1fb6ec321f0a7669d13453cab0ce172866ee4e53418
MD5 38c82c38bccdaf0fa2fa893151cad377
BLAKE2b-256 6235fb6abe85cf1501e9ef7f3e28958d7fe2cce41474c487a7ef75876452b954

See more details on using hashes here.

File details

Details for the file tube_search-0.0.2.1-py3-none-any.whl.

File metadata

  • Download URL: tube_search-0.0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 5.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.1

File hashes

Hashes for tube_search-0.0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 37ddaae2f29903a4f736d682cc45f37083812c76d5ae012127f0944ee31b6916
MD5 999f334695b0da4d8a3a0621d6f43c71
BLAKE2b-256 7edf5ac1581fc5e969f9ca5aa3069d590a8b1dfbdce2ba8bd44d0ff2f60af8ae

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page