feat: expose destination_caller_id in message output#29
Merged
steipete merged 1 commit intosteipete:mainfrom Feb 16, 2026
Merged
Conversation
commander-alexander
added a commit
to commander-alexander/openclaw
that referenced
this pull request
Jan 31, 2026
…umber
When the Mac has multiple iMessage numbers (e.g., dual-SIM setup), messages
to ALL numbers are received. This adds a myNumbers config option that filters
messages by destination_caller_id, so the bot only responds to messages sent
to the configured number(s).
Config example:
{
channels: {
imessage: {
myNumbers: ["+16466128299"]
}
}
}
Requires imsg to expose destination_caller_id (see steipete/imsg#29).
commander-alexander
added a commit
to commander-alexander/openclaw
that referenced
this pull request
Jan 31, 2026
…umber
When the Mac has multiple iMessage numbers (e.g., dual-SIM setup), messages
to ALL numbers are received. This adds a myNumbers config option that filters
messages by destination_caller_id, so the bot only responds to messages sent
to the configured number(s).
Config example:
{
channels: {
imessage: {
myNumbers: ["+16466128299"]
}
}
}
Requires imsg to expose destination_caller_id (see steipete/imsg#29).
commander-alexander
added a commit
to commander-alexander/openclaw
that referenced
this pull request
Jan 31, 2026
…umber
When the Mac has multiple iMessage numbers (e.g., dual-SIM setup), messages
to ALL numbers are received. This adds a myNumbers config option that filters
messages by destination_caller_id, so the bot only responds to messages sent
to the configured number(s).
Config example:
{
channels: {
imessage: {
myNumbers: ["+16466128299"]
}
}
}
Requires imsg to expose destination_caller_id (see steipete/imsg#29).
This field helps distinguish between messages actually sent by the local user vs messages received on a secondary phone number registered with the same Apple ID. When is_from_me is true but destination_caller_id differs from the user's own numbers, the message was actually received from another device/person messaging that secondary number. This enables tools like Clawdbot to properly detect inbound messages on secondary iMessage phone numbers.
d396cb2 to
2262e16
Compare
Owner
|
Landed via temp rebase onto main. Thanks @commander-alexander! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Exposes the
destination_caller_idfield in message output. This field indicates which phone number/Apple ID received the message, which is essential for multi-SIM setups where a single Mac receives messages for multiple numbers.Use Case
When a Mac is linked to an iPhone with dual-SIM (or multiple Apple IDs), all messages arrive in the same Messages database. Without
destination_caller_id, there's no way to know which number/account a message was sent to.Example: User has personal number (+1555-111-1111) and a second number (+1555-222-2222). An automation tool needs to only respond to messages sent to the second number.
Changes
src/messages/mod.rs: Addeddestination_caller_idfield toMessagestructdestination_caller_idfrom themessagetableOutput Example
{ "id": 12345, "sender": "+15551234567", "destination_caller_id": "+15559876543", "text": "Hello!", ... }Testing
Tested with dual-SIM setup. Messages correctly show the destination number they were sent to.
This PR was developed with AI assistance.