kmep 0.3.0 copy "kmep: ^0.3.0" to clipboard
kmep: ^0.3.0 copied to clipboard

A stable alternative to NewPipeExtractor for Dart and Flutter: YouTube extraction fully in-process (no JVM, no Python, no server). Multi-client InnerTube fallback (ANDROID_VR/WEB/IOS/TV), on-device pl [...]

kmep #

Dart CI License: GPLv3

Dart package for the KMEP YouTube extraction library. See the repository README for the full pitch, feature matrix, and platform integration guide — this file is just the pub package quick-reference.

Quick start #

import 'package:kmep/kmep.dart';

final kmep = Kmep.withOnDevicePoToken(
  jsRuntime: myPlayerJsRuntime,   // see ../flutter_integration or NodeProcessJsRuntime
  potJsRuntime: myBotGuardRuntime,
  fetchText: (url) => http.get(Uri.parse(url)).then((r) => r.body),
);

final video = await kmep.getVideo('dQw4w9WgXcQ');
final results = await kmep.search('lofi hip hop');

Runnable version: example/example.dart.

Layout #

lib/
├── kmep.dart              # public export barrel — start here
└── src/
    ├── kmep_client.dart   # the Kmep facade
    ├── models/            # VideoInfo, KMEPStream, VideoSearchResult, ...
    ├── search/            # search + shorts feed
    ├── channel/           # channels + playlists (browse endpoint)
    ├── comments/          # comments + thread replies (next endpoint)
    ├── clients/           # InnerTube client + per-client configs
    ├── parsers/           # player response parsing
    ├── resolvers/         # signature/n-parameter resolution (player.js)
    ├── runtimes/          # NodeProcessJsRuntime (server/CLI JsRuntime)
    └── core/              # orchestrator, PO tokens, cache, remote config

Development #

dart pub get
dart analyze
dart test

Diagnostic tools that hit live YouTube (not part of the public API, useful when working on the extractor itself) are in tool/ — see ../docs/AGENT_HANDOFF.md.

0
likes
140
points
64
downloads

Documentation

Documentation
API reference

Publisher

unverified uploader

Weekly Downloads

A stable alternative to NewPipeExtractor for Dart and Flutter: YouTube extraction fully in-process (no JVM, no Python, no server). Multi-client InnerTube fallback (ANDROID_VR/WEB/IOS/TV), on-device player.js execution, on-device PO token (BotGuard) generation. Videos up to 4K, live/HLS, search, shorts, channels, playlists, comments — behind a typed facade. 98% live-audited success rate.

Repository (GitHub)
View/report issues
Contributing

License

GPL-3.0 (license)

Dependencies

http

More

Packages that depend on kmep