Skip to main content

Crate moneymoney

Crate moneymoney 

Source
Expand description

§MoneyMoney Rust Interface

A safe, ergonomic Rust interface to the MoneyMoney macOS application via AppleScript.

§Overview

This library provides typed Rust bindings to MoneyMoney’s AppleScript API, enabling programmatic access to your financial data on macOS. All operations communicate with the MoneyMoney application via OSA (Open Scripting Architecture).

§Requirements

  • macOS: MoneyMoney is a macOS-only application
  • MoneyMoney app: Must be installed and running
  • Permissions: Appropriate accessibility permissions for script execution

§Features

  • Type-safe API: All data structures use proper Rust types
  • Serde integration: All types support serialization/deserialization
  • Zero unsafe code: Pure safe Rust implementation

§Quick Start

use moneymoney::export_transactions::ExportTransactionsParams;
use chrono::NaiveDate;

// Export all accounts
let accounts = moneymoney::export_accounts()?;
for account in accounts {
    if let Some(balance) = &account.balance {
        println!("{}: {} {}", account.name, balance.amount, balance.currency.code());
    }
}

// Export transactions from a specific date
let params = ExportTransactionsParams::new(
    NaiveDate::from_ymd_opt(2024, 1, 1).expect("valid date")
);
let response = moneymoney::export_transactions(params)?;

§Available Operations

§Export Operations

§Transaction Management

§Payment Operations (Experimental)

  • create_bank_transfer() - Create SEPA bank transfers (requires experimental feature)
  • create_direct_debit() - Create SEPA direct debit orders (requires experimental feature)

§Feature Flags

  • experimental - Enables experimental APIs like create_bank_transfer that may change
  • test-utils - Enables test utilities for integration testing (see the test_utils module)

§MoneyMoney API Documentation

For details on the underlying AppleScript API, see: https://moneymoney-app.com/api/

Modules§

add_transaction
Add transactions to offline accounts in MoneyMoney.
create_bank_transfer
Create bank transfers in MoneyMoney (experimental).
create_direct_debit
Create SEPA direct debit orders in MoneyMoney (experimental).
export_accounts
Export accounts from MoneyMoney.
export_categories
Export categories and budgets from MoneyMoney.
export_portfolio
Export securities portfolio holdings from MoneyMoney.
export_transactions
Export transactions from MoneyMoney.
set_transaction
Modify existing transactions in MoneyMoney.
test_utils
Test utilities for integration testing with MoneyMoney.

Enums§

Error
Errors that can occur when interacting with MoneyMoney.
MoneymoneyActions

Functions§

add_transaction
Add a transaction to an offline account in MoneyMoney.
call_action
call_action_plist
call_action_void
Call a MoneyMoney action that doesn’t return data (void operations).
create_bank_transfer
Create a bank transfer in MoneyMoney.
create_direct_debit
Create a SEPA direct debit order in MoneyMoney.
export_accounts
Export all accounts from MoneyMoney.
export_categories
Export all categories from MoneyMoney.
export_portfolio
Export portfolio holdings from MoneyMoney.
export_transactions
Export transactions from MoneyMoney with filtering.
set_transaction
Modify an existing transaction in MoneyMoney.