UNPKG

@dderevjanik/termux-api

Version:

This library allows you to interact with your Android device from Node.js using termux-api

31 lines (30 loc) 666 B
export interface MediaPlayerOptions { /** * Command to execute */ command: "player" | "pause" | "stop" | "stop"; /** * File to play, only if `command` is "player" * * @example "file_example_MP3_700KB.mp3" */ file: string; } /** * Displays current playback information * @returns * `Status: Playing` * * `Track: file_example_MP3_700KB.mp3` * * `Current Position: 00:06 / 00:42` * * or * * `No track currently!` */ export declare function mediaPlayerInfo(): Promise<string>; /** * Play specified file using Media Player API */ export declare function mediaPlayer(options: MediaPlayerOptions): Promise<void>;