패키지, 저장소 및 앱 카테고리 검색

패키지 상세v2.0.0

youtube

YouTube 동영상 정보와 여러 품질의 썸네일을 가져오는 패키지입니다.

AndroidiOSWebmacOSWindowsLinux
30일 다운로드
136
좋아요
60
Pub 점수
140

패키지 설치

flutter pub add youtube

패키지 개요

공개 정보를 바탕으로 생성한 선택 가이드입니다.

youtube 패키지는 YouTube 동영상 정보와 다양한 품질 수준의 썸네일을 간편하게 가져오는 방법을 제공합니다. 안드로이드, iOS, 웹, 맥OS, 윈도우, 리눅스 등 여러 플랫폼을 지원합니다. 개발자는 제목, 설명, 재생 시간, 조회수 등의 메타데이터와 고화질 썸네일 URL을 얻을 수 있습니다. 복잡한 API 설정 없이 앱에 YouTube 콘텐츠를 통합하는 데 이상적입니다. 내부적으로 YouTube Data API를 활용하여 동영상 미리보기 표시나 미디어 탐색 기능 구현에 매우 효율적입니다.

사용 사례

  • YouTube 비디오 미리보기 삽입
  • 미디어 탐색 앱 구축
  • 비디오 메타데이터 표시
  • 비디오 플레이리스트 뷰어 만들기
  • 품질별 썸네일 가져오기

주요 기능

  • 비디오 세부 정보 가져오기
  • 여러 썸네일 품질 옵션
  • 크로스 플랫폼 지원
  • 간단한 API 인터페이스
  • API 키 설정이 필요하지 않습니다

적합한 대상

  • YouTube 데이터가 필요한 앱
  • 미디어가 풍부한 애플리케이션
  • 콘텐츠 미리보기 기능
  • 빠른 통합을 원하는 플러터 개발자

고려 사항

  • 인터넷 연결이 필요합니다
  • 공개 비디오 데이터에 한정
  • YouTube의 API 사용 가능 여부에 따라 다릅니다
  • 고용량 사용 시 속도 제한 처리가 필요할 수 있습니다

원본 README

연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.

This Flutter package provides functionalities to retrieve and manage YouTube video information, including details about the video and the uploader, as well as various thumbnail resolutions.

GitHub Sponsor

Configuration

Before fetching video details, you need to configure the package with the video ID:

await Youtube.config(videoId: 'your_video_id');

Accessing Video Information

You can access the video and channel details using the provided getters:

var channelDetails = Youtube.channelDetails;
var videoDetails = Youtube.videoDetails;
var thumbnails = Youtube.thumbnails;
ChannelDetails

Holds details about the YouTube channel.

  • Properties
    • String name: The name of the uploader.
    • String id: The ID of the channel.
    • String username: The username of the uploader.
  • Example
var channelDetails = Youtube.channelDetails;
print('Channel Name: ${channelDetails.name}');
print('Channel ID: ${channelDetails.id}');
print('Channel Username: ${channelDetails.username}');
VideoDetails

Holds details about the YouTube video.

  • Properties
    • String title: The title of the video.
    • int duration: The duration of the video in seconds.
    • int viewCount: The view count of the video.
    • String defaultThumbnail: The URL of the default thumbnail.
  • Example
var videoDetails = Youtube.videoDetails;
print('Video Title: ${videoDetails.title}');
print('Video Duration: ${videoDetails.duration} seconds');
print('Video View Count: ${videoDetails.viewCount}');
print('Default Thumbnail: ${videoDetails.defaultThumbnail}');
Thumbnails

Holds URLs for different resolutions of the video's thumbnails.

  • Properties
    • String fullhd: URL for the Full HD thumbnail.
    • String hd: URL for the HD thumbnail.
    • String sd: URL for the SD thumbnail.
    • String hq: URL for the HQ thumbnail.
    • String lq: URL for the LQ thumbnail.
  • Example
var thumbnails = Youtube.thumbnails;
print('Full HD Thumbnail: ${thumbnails.fullhd}');
print('HD Thumbnail: ${thumbnails.hd}');
print('SD Thumbnail: ${thumbnails.sd}');
print('HQ Thumbnail: ${thumbnails.hq}');
print('LQ Thumbnail: ${thumbnails.lq}');
Video Infortimation
  • String url - URL of the video for allquality with direct streaming and downloading
  • int fps - Frames per second
  • String resolution - Resolution of the video
  • String audio - Audio of the video
  • int filesize - Filesize of the video
  • String quality - Quality of the video
  • String videoExtension - Video extension
  • int height - Height of the video
  • int width - Width of the video

Example

👉 For a complete example, refer to the Youtube package documentation.

Report bugs or issues

You are welcome to open a ticket on github if any 🐞 problems arise. New ideas are always welcome.

Note: This package uses third-party api to fetch data.

카테고리

의존성

의존성 목록 1 개

소스 저장소

이 패키지를 사용하는 프로젝트

아직 데이터가 없습니다.