← Public packages
@tannerlinsley/imessage
Read, search, draft, and explicitly send iMessages on a Mac, using only built-in macOS tools.
Files
import { native, object } from "./core.ts";
import type { Status } from "./types.ts";
/**
* Check whether this Mac can read Messages before using history or search.
* @param input - An empty object. Run on a Mac execution context with host commands enabled.
* @returns macOS version, database readiness, and permission instructions if needed. Does not prompt for Automation or return messages.
* @example
* import status from 'kody:@tannerlinsley/imessage';
* const readiness = await status({});
*/
export default async function status(input: Record<string, never> = {}): Promise<Status> {
object(input, []);
return native<Status>({ action: "status" });
}