7 stable releases

new 3.0.2 Dec 7, 2024
3.0.1 Dec 6, 2024
3.0.0 Oct 25, 2024
2.0.0 Oct 18, 2024
1.1.1 Oct 18, 2024

#125 in Video

Download history 272/week @ 2024-10-07 265/week @ 2024-10-14 158/week @ 2024-10-21 13/week @ 2024-10-28 3/week @ 2024-11-04 234/week @ 2024-12-02

234 downloads per month

GPL-3.0-or-later

30KB
555 lines

pf_lib

A Rust library to retrieve WordPress MP4 videos. Supports filtering by date and including/excluding specific IDs, categories, and tags.

Example

use pf_lib::{FinderConfig, FinderTarget};

let config = FinderConfig {
    url: "http://example.com".to_string(),
    target: FinderTarget::Media,
    ..Default::default()
};

for url in pf_lib::find(&config) {
    println!("{}", url);
}

lib.rs:

This library provides functionality to find and fetch existing video URLs from a WordPress website.

The main components of this library are:

  • api: Handles interactions with the paginated WordPress API.
  • config: Defines configuration options for the Finder.
  • finder: Implements the logic to find and fetch existing video URLs.
  • link_utils: Utility functions for handling links.
  • mime_types: Defines supported MIME types for scraping.
  • url_extractor: Functions to extract URLs from WordPress API responses.

Dependencies

~7–19MB
~251K SLoC