imsg
Use imsg to read and send Messages.app iMessage/SMS on macOS.
Requirements
Messages.app signed in
Full Disk Access for your terminal
Automation permission to control Messages.app (for sending)
Common commands
List chats:
imsg chats --limit 10 --jsonHistory:
imsg history --chat-id 1 --limit 20 --attachments --jsonWatch:
imsg watch --chat-id 1 --attachmentsSend:
imsg send --to "+14155551212" --text "hi" --file /path/pic.jpg
Notes
--service imessage|sms|autocontrols delivery.Confirm recipient + message before sending.