openclaw-imessage-photon 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +167 -0
- package/README.zh-CN.md +141 -0
- package/dist/index.js +8 -0
- package/dist/setup-entry.js +3 -0
- package/dist/src/actions.js +331 -0
- package/dist/src/channel.js +247 -0
- package/dist/src/inbound.js +280 -0
- package/dist/src/spectrum.js +92 -0
- package/openclaw.plugin.json +102 -0
- package/package.json +49 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "imessage-photon",
|
|
3
|
+
"name": "iMessage (Photon)",
|
|
4
|
+
"description": "iMessage channel via Photon Spectrum Cloud — no Mac required. Register at https://photon.codes, create a project, and paste the Project ID and Secret.",
|
|
5
|
+
"icon": "https://cdn.simpleicons.org/imessage",
|
|
6
|
+
"channels": ["imessage-photon"],
|
|
7
|
+
"channelEnvVars": {
|
|
8
|
+
"imessage-photon": [
|
|
9
|
+
"SPECTRUM_PROJECT_ID",
|
|
10
|
+
"SPECTRUM_PROJECT_SECRET",
|
|
11
|
+
"SPECTRUM_ALLOWED_NUMBERS"
|
|
12
|
+
]
|
|
13
|
+
},
|
|
14
|
+
"configSchema": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"additionalProperties": false,
|
|
17
|
+
"properties": {}
|
|
18
|
+
},
|
|
19
|
+
"channelConfigs": {
|
|
20
|
+
"imessage-photon": {
|
|
21
|
+
"schema": {
|
|
22
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
23
|
+
"type": "object",
|
|
24
|
+
"properties": {
|
|
25
|
+
"enabled": { "type": "boolean" },
|
|
26
|
+
"dmPolicy": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"enum": ["allowlist", "pairing", "open", "disabled"]
|
|
29
|
+
},
|
|
30
|
+
"dmSecurity": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"enum": ["allowlist", "pairing", "open", "disabled"]
|
|
33
|
+
},
|
|
34
|
+
"projectId": { "type": "string" },
|
|
35
|
+
"projectSecret": { "type": "string" },
|
|
36
|
+
"allowFrom": {
|
|
37
|
+
"type": "array",
|
|
38
|
+
"items": { "type": "string" },
|
|
39
|
+
"description": "Allowed sender phone numbers in E.164 form, e.g. +8613800138000. Empty = allow everyone."
|
|
40
|
+
},
|
|
41
|
+
"ackReaction": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"default": "👀",
|
|
44
|
+
"description": "Emoji reacted to inbound messages while the agent is processing. Empty string disables. Uses messages.ackReaction as fallback."
|
|
45
|
+
},
|
|
46
|
+
"tapbackNotifications": {
|
|
47
|
+
"type": "string",
|
|
48
|
+
"enum": ["off", "all"],
|
|
49
|
+
"default": "all",
|
|
50
|
+
"description": "off = ignore inbound tapbacks; all = forward them to the agent as system events."
|
|
51
|
+
},
|
|
52
|
+
"enableMedia": {
|
|
53
|
+
"type": "boolean",
|
|
54
|
+
"default": false,
|
|
55
|
+
"description": "Agent can send/receive media attachments (spectrum-ts native)."
|
|
56
|
+
},
|
|
57
|
+
"enablePoll": {
|
|
58
|
+
"type": "boolean",
|
|
59
|
+
"default": false,
|
|
60
|
+
"description": "Agent can create polls (spectrum-ts native)."
|
|
61
|
+
},
|
|
62
|
+
"enableEffects": {
|
|
63
|
+
"type": "boolean",
|
|
64
|
+
"default": false,
|
|
65
|
+
"description": "Agent can send full-screen effects (balloons, lasers, confetti, ...)."
|
|
66
|
+
},
|
|
67
|
+
"enableContact": {
|
|
68
|
+
"type": "boolean",
|
|
69
|
+
"default": false,
|
|
70
|
+
"description": "Agent can share contacts (vCard)."
|
|
71
|
+
},
|
|
72
|
+
"enableVoice": {
|
|
73
|
+
"type": "boolean",
|
|
74
|
+
"default": false,
|
|
75
|
+
"description": "Agent can send voice messages."
|
|
76
|
+
},
|
|
77
|
+
"enableGroups": {
|
|
78
|
+
"type": "boolean",
|
|
79
|
+
"default": false,
|
|
80
|
+
"description": "Handle group chats (spectrum-ts native). Requires inbound group routing; off by default."
|
|
81
|
+
},
|
|
82
|
+
"enableTyping": {
|
|
83
|
+
"type": "boolean",
|
|
84
|
+
"default": false,
|
|
85
|
+
"description": "Send typing indicators while the agent is processing."
|
|
86
|
+
},
|
|
87
|
+
"enableReadReceipts": {
|
|
88
|
+
"type": "boolean",
|
|
89
|
+
"default": false,
|
|
90
|
+
"description": "Mark inbound messages as read (read receipts)."
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
"additionalProperties": false
|
|
94
|
+
},
|
|
95
|
+
"uiHints": {
|
|
96
|
+
"projectId": { "label": "Photon project ID" },
|
|
97
|
+
"projectSecret": { "label": "Photon project secret", "sensitive": true },
|
|
98
|
+
"allowFrom": { "label": "Allowed phone numbers" }
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "openclaw-imessage-photon",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "iMessage channel for OpenClaw via Photon Spectrum Cloud (no Mac required).",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"keywords": ["openclaw", "imessage", "photon", "spectrum", "channel"],
|
|
8
|
+
"author": "ethanjtch",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://github.com/ethanjtch/openclaw-imessage-photon.git"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://github.com/ethanjtch/openclaw-imessage-photon#readme",
|
|
14
|
+
"files": [
|
|
15
|
+
"dist/",
|
|
16
|
+
"README.md",
|
|
17
|
+
"README.zh-CN.md",
|
|
18
|
+
"openclaw.plugin.json"
|
|
19
|
+
],
|
|
20
|
+
"engines": {
|
|
21
|
+
"node": ">=22"
|
|
22
|
+
},
|
|
23
|
+
"openclaw": {
|
|
24
|
+
"extensions": ["./dist/index.js"],
|
|
25
|
+
"setupEntry": "./dist/setup-entry.js",
|
|
26
|
+
"channel": {
|
|
27
|
+
"id": "imessage-photon",
|
|
28
|
+
"label": "iMessage (Photon)",
|
|
29
|
+
"selectionLabel": "iMessage via Photon Spectrum Cloud",
|
|
30
|
+
"detailLabel": "iMessage (Photon Cloud)",
|
|
31
|
+
"blurb": "Connect OpenClaw to iMessage through Photon Spectrum Cloud — no Mac or iMessage server required.",
|
|
32
|
+
"markdownCapable": false
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"dependencies": {
|
|
36
|
+
"spectrum-ts": "^12.8.0"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@types/node": "^22",
|
|
40
|
+
"typescript": "^5"
|
|
41
|
+
},
|
|
42
|
+
"scripts": {
|
|
43
|
+
"build": "tsc -p tsconfig.build.json",
|
|
44
|
+
"prepublishOnly": "npm run build"
|
|
45
|
+
},
|
|
46
|
+
"peerDependencies": {
|
|
47
|
+
"openclaw": "*"
|
|
48
|
+
}
|
|
49
|
+
}
|