FEAT: Plugin API - account info API
Is your feature request related to a problem?
Plugins have no way to query account information. There is no matcha.accounts() or matcha.current_account() API. Multi-account setups can't have account-specific plugin behavior (e.g. different signatures per account, different auto-BCC rules, account-specific workflows).
Describe the solution you'd like
Add API functions:
-- Get the currently active account
local acct = matcha.current_account()
-- acct.email, acct.name, acct.id
-- List all configured accounts
local accounts = matcha.accounts()
for _, acct in ipairs(accounts) do
matcha.log(acct.email)
end
Only expose safe, read-only fields (email, display name, account ID). Do not expose passwords, tokens, or server credentials.
Describe alternatives you've considered
Using the account_id field already present in hook email tables and hardcoding known IDs. This is fragile and doesn't let plugins discover accounts dynamically.
Additional context
N/A
This has had no activity for 30 days. It will be closed in 14 days unless updated. Comment or remove the stale label to keep it open.
Closing due to inactivity. Reopen if still relevant.