Crate mpd

source ·
Expand description

MPD client for Rust

This crate tries to provide idiomatic Rust API for Music Player Daemon. The main entry point to the API is Client struct, and inherent methods of the struct follow MPD protocol for most part, making use of traits to overload different parameters for convenience.


mpd = "*"
extern crate mpd;

use mpd::Client;
use std::net::TcpStream;

let mut conn = Client::connect("").unwrap();
conn.load("My Lounge Playlist", ..).unwrap();;
println!("Status: {:?}", conn.status());



  • This module defines client data structure — the main entry point to MPD communication
  • This module defines different errors occurring during communication with MPD.
  • The module defines structures and protocols for asynchronous MPD communication
  • The module defines structures for MPD client-to-client messaging/subscription protocol
  • The module describes data structures for MPD (virtual) mounts system
  • The module describes output
  • The module defines playlist data structures
  • The module defines decoder plugin data structures
  • The module describes all possible replies from MPD server.
  • The module defines song structs and methods.
  • The module describes DB and playback statistics
  • The module defines MPD status data structures
  • This module defines MPD version type and parsing code