@mapier/imsg-sdk 0.4.0 → 0.6.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.

Potentially problematic release.


This version of @mapier/imsg-sdk might be problematic. Click here for more details.

@@ -3,6 +3,7 @@ import { reportRuntimeIssue } from '../runtime-report.js';
3
3
  import { imsgBinary } from './binary.js';
4
4
  export const NO_PATCHED_GATEWAY_CAPABILITIES = {
5
5
  emojiTapback: false,
6
+ tapbackPart: false,
6
7
  stickerSend: false,
7
8
  groupPhoto: false,
8
9
  groupParticipants: false,
@@ -13,11 +14,19 @@ export const NO_PATCHED_GATEWAY_CAPABILITIES = {
13
14
  mentionFormatting: false,
14
15
  sharedLocations: false,
15
16
  locationRequest: false,
17
+ extensionCardSend: false,
18
+ extensionCardUpdate: false,
16
19
  };
17
20
  export function patchedCapabilitiesFromStatus(status) {
18
21
  const selectors = status.selectors ?? {};
19
22
  return {
20
23
  emojiTapback: selectors.emojiTapbackSend === true && status.rpc_features?.includes('tapback.emoji') === true,
24
+ // M2B-45. Its own marker, and deliberately NOT inferred from any other:
25
+ // a helper without it does not reject `part_index`, it accepts it and
26
+ // writes a row that draws on every part for the recipient and leaves the
27
+ // sender nothing to read back. Absent marker = a part >= 1 is refused
28
+ // before anything is sent.
29
+ tapbackPart: selectors.tapbackPart === true,
21
30
  stickerSend: selectors.stickerSend === true,
22
31
  groupPhoto: selectors.groupPhotoUpdate === true,
23
32
  groupParticipants: selectors.groupAddParticipant === true && selectors.groupRemoveParticipant === true,
@@ -41,6 +50,12 @@ export function patchedCapabilitiesFromStatus(status) {
41
50
  // initializer (IMsgInjected.m `locationRequest`).
42
51
  sharedLocations: selectors.sharedLocations === true,
43
52
  locationRequest: selectors.locationRequest === true,
53
+ // M2B-46 extension cards: sending needs the same extension-balloon
54
+ // initializer polls use, updating one in place also needs the
55
+ // associated-message initializer, so IMsgInjected.m advertises the two
56
+ // separately and neither is inferred from the other.
57
+ extensionCardSend: selectors.extensionCardSend === true,
58
+ extensionCardUpdate: selectors.extensionCardUpdate === true,
44
59
  };
45
60
  }
46
61
  export function readPatchedGatewayCapabilities() {
@@ -1 +1 @@
1
- {"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/imsg/status.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAOzC,MAAM,CAAC,MAAM,+BAA+B,GAAwB;IAClE,YAAY,EAAE,KAAK;IACnB,WAAW,EAAE,KAAK;IAClB,UAAU,EAAE,KAAK;IACjB,iBAAiB,EAAE,KAAK;IACxB,gBAAgB,EAAE,KAAK;IACvB,iBAAiB,EAAE,KAAK;IACxB,oBAAoB,EAAE,KAAK;IAC3B,WAAW,EAAE,KAAK;IAClB,iBAAiB,EAAE,KAAK;IACxB,eAAe,EAAE,KAAK;IACtB,eAAe,EAAE,KAAK;CACvB,CAAC;AAEF,MAAM,UAAU,6BAA6B,CAAC,MAAyB;IACrE,MAAM,SAAS,GAAG,MAAM,CAAC,SAAS,IAAI,EAAE,CAAC;IACzC,OAAO;QACL,YAAY,EAAE,SAAS,CAAC,gBAAgB,KAAK,IAAI,IAAI,MAAM,CAAC,YAAY,EAAE,QAAQ,CAAC,eAAe,CAAC,KAAK,IAAI;QAC5G,WAAW,EAAE,SAAS,CAAC,WAAW,KAAK,IAAI;QAC3C,UAAU,EAAE,SAAS,CAAC,gBAAgB,KAAK,IAAI;QAC/C,iBAAiB,EAAE,SAAS,CAAC,mBAAmB,KAAK,IAAI,IAAI,SAAS,CAAC,sBAAsB,KAAK,IAAI;QACtG,gBAAgB,EAAE,SAAS,CAAC,oBAAoB,KAAK,IAAI,IAAI,SAAS,CAAC,cAAc,KAAK,IAAI;QAC9F,yEAAyE;QACzE,yEAAyE;QACzE,iBAAiB,EAAE,SAAS,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I;YAC7C,SAAS,CAAC,eAAe,KAAK,IAAI;YAClC,SAAS,CAAC,WAAW,KAAK,IAAI;QAChC,gEAAgE;QAChE,oEAAoE;QACpE,iBAAiB,EAAE,SAAS,CAAC,iBAAiB,KAAK,IAAI;QACvD,mEAAmE;QACnE,uEAAuE;QACvE,kEAAkE;QAClE,kDAAkD;QAClD,eAAe,EAAE,SAAS,CAAC,eAAe,KAAK,IAAI;QACnD,eAAe,EAAE,SAAS,CAAC,eAAe,KAAK,IAAI;QACnD,mEAAmE;QACnE,8DAA8D;QAC9D,uEAAuE;QACvE,qDAAqD;QACrD,iBAAiB,EAAE,SAAS,CAAC,iBAAiB,KAAK,IAAI;QACvD,mBAAmB,EAAE,SAAS,CAAC,mBAAmB,KAAK,IAAI;KAC5D,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,8BAA8B;IAC5C,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,YAAY,CAAC,UAAU,EAAE,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE;YAC9D,QAAQ,EAAE,MAAM;YAChB,OAAO,EAAE,MAAM;SAChB,CAAC,CAAC;QACH,OAAO,6BAA6B,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAsB,CAAC,CAAC;IAChF,CAAC;IAAC,MAAM,CAAC;QACP,yEAAyE;QACzE,yEAAyE;QACzE,qEAAqE;QACrE,kBAAkB,CAAC,8BAA8B,CAAC,CAAC;QACnD,OAAO,EAAE,GAAG,+BAA+B,EAAE,CAAC;IAChD,CAAC;AACH,CAAC"}
package/dist/index.d.ts CHANGED
@@ -4,6 +4,7 @@ export * from './gateway/types.js';
4
4
  export * from './gateway/portable-chat.js';
5
5
  export * from './gateway/external-ids.js';
6
6
  export * from './gateway/locations.js';
7
+ export { reactionOnPart, reactionPart } from './gateway/tapback.js';
7
8
  export * from './polls.js';
8
9
  export * from './doctor.js';
9
10
  export { reportRuntimeIssue, setRuntimeIssueReporter, type RuntimeIssueReporter } from './runtime-report.js';
package/dist/index.js CHANGED
@@ -4,6 +4,10 @@ export * from './gateway/types.js';
4
4
  export * from './gateway/portable-chat.js';
5
5
  export * from './gateway/external-ids.js';
6
6
  export * from './gateway/locations.js';
7
+ // The absent-means-part-0 rule, exported because a consumer reading parts back
8
+ // has to apply it and it is the one piece of this that is easy to get wrong
9
+ // (M2B-45). The rest of gateway/tapback.ts stays internal.
10
+ export { reactionOnPart, reactionPart } from './gateway/tapback.js';
7
11
  export * from './polls.js';
8
12
  export * from './doctor.js';
9
13
  export { reportRuntimeIssue, setRuntimeIssueReporter } from './runtime-report.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,cAAc,oBAAoB,CAAC;AACnC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,wBAAwB,CAAC;AACvC,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,kBAAkB,EAAE,uBAAuB,EAA6B,MAAM,qBAAqB,CAAC;AAE7G,cAAc,yBAAyB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,cAAc,oBAAoB,CAAC;AACnC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,wBAAwB,CAAC;AACvC,+EAA+E;AAC/E,4EAA4E;AAC5E,2DAA2D;AAC3D,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpE,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,kBAAkB,EAAE,uBAAuB,EAA6B,MAAM,qBAAqB,CAAC;AAE7G,cAAc,yBAAyB,CAAC"}
@@ -82,11 +82,15 @@ const HOST_EXTENSION_CARD = {
82
82
  requiresRecipientInstall: true,
83
83
  correlation: 'message-guid',
84
84
  completionTransport: 'gateway-events',
85
- outbound: 'none',
85
+ // No longer a seam: Gateway.sendExtensionCard sends this card and updates it
86
+ // in place (M2B-46). `status` is `fake-only`, not `host-smoked` — the native
87
+ // layer was proven on real phones 2026-09-20, the SDK verb has not run on a
88
+ // host — so it stays out of agentUsable().
89
+ outbound: 'agent',
86
90
  inboundReadback: false,
87
- status: 'unbuilt',
91
+ status: 'fake-only',
88
92
  fallback: 'web-url',
89
- notes: 'Photon Spectrum model: install the host once, mini-app URLs render live in-bubble. Unbuilt seam.',
93
+ notes: 'Photon Spectrum model: install the host once, mini-app URLs render live in-bubble. Built as Gateway.sendExtensionCard (M2B-46); the install wall is real but only gates LIVE rendering.',
90
94
  };
91
95
  export function defaultCatalog() {
92
96
  const registry = new InteractionRegistry();
@@ -1 +1 @@
1
- {"version":3,"file":"catalog.js","sourceRoot":"","sources":["../../src/interactions/catalog.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,8EAA8E;AAC9E,6EAA6E;AAC7E,0EAA0E;AAC1E,mDAAmD;AACnD,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAGpD,MAAM,OAAO,GAA0B;IACrC,EAAE,EAAE,SAAS;IACb,IAAI,EAAE,gBAAgB;IACtB,wBAAwB,EAAE,KAAK;IAC/B,WAAW,EAAE,cAAc;IAC3B,mBAAmB,EAAE,gBAAgB;IACrC,QAAQ,EAAE,OAAO;IACjB,eAAe,EAAE,IAAI;IACrB,MAAM,EAAE,aAAa;IACrB,QAAQ,EAAE,YAAY;IACtB,KAAK,EAAE,oGAAoG;CAC5G,CAAC;AAEF,MAAM,QAAQ,GAA0B;IACtC,E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rB,QAAQ,EAAE,YAAY;IACtB,KAAK,EACH,0NAA0N;CAC7N,CAAC;AAEF,MAAM,QAAQ,GAA0B;IACtC,EAAE,EAAE,UAAU;IACd,IAAI,EAAE,UAAU;IAChB,wBAAwB,EAAE,KAAK,EAAE,iDAAiD;IAClF,WAAW,EAAE,WAAW;IACxB,mBAAmB,EAAE,aAAa;IAClC,QAAQ,EAAE,MAAM;IAChB,eAAe,EAAE,KAAK;IACtB,MAAM,EAAE,SAAS;IACjB,QAAQ,EAAE,SAAS;IACnB,KAAK,EAAE,qFAAqF;CAC7F,CAAC;AAEF,MAAM,mBAAmB,GAA0B;IACjD,EAAE,EAAE,qBAAqB;IACzB,IAAI,EAAE,WAAW;IACjB,wBAAwB,EAAE,IAAI;IAC9B,WAAW,EAAE,cAAc;IAC3B,mBAAmB,EAAE,gBAAgB;IACrC,6EAA6E;IAC7E,6EAA6E;IAC7E,4EAA4E;IAC5E,2CAA2C;IAC3C,QAAQ,EAAE,OAAO;IACjB,eAAe,EAAE,KAAK;IACtB,MAAM,EAAE,WAAW;IACnB,QAAQ,EAAE,SAAS;IACnB,KAAK,EACH,yLAAyL;CAC5L,CAAC;AAEF,MAAM,UAAU,cAAc;IAC5B,MAAM,QAAQ,GAAG,IAAI,mBAAmB,EAAE,CAAC;IAC3C,KAAK,MAAM,UAAU,IAAI,CAAC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,mBAAmB,CAAC,EAAE,CAAC;QAC1G,QAAQ,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;IAChC,CAAC;IACD,OAAO,QAAQ,CAAC;AAClB,CAAC"}
package/dist/types.d.ts CHANGED
@@ -5,6 +5,7 @@ export interface MessageReaction {
5
5
  is_from_me: boolean;
6
6
  sender?: string;
7
7
  created_at?: string;
8
+ target_part?: number;
8
9
  }
9
10
  export interface PollOption {
10
11
  id: string;
@@ -64,6 +65,7 @@ export interface ImsgMessage {
64
65
  reaction_type?: string;
65
66
  reaction_emoji?: string;
66
67
  is_reaction_add?: boolean;
68
+ reaction_target_part?: number;
67
69
  reacted_to_guid?: string;
68
70
  }
69
71
  export interface SendResult {
package/docs/api.md CHANGED
@@ -19,7 +19,7 @@ const gateway: Gateway = new ImsgGateway((code) => {
19
19
  | --- | --- |
20
20
  | Read and routing | `subscribe`, `history`, `historyRange`, `listChats`, `resolveDmChat`, `resolveGroupChat`, `recentReactions`, `sendStatus`, `checkHandle` |
21
21
  | Standard actions | `send`, `react`, `createGroup` |
22
- | Bridge actions | `tapback`, `emojiTapback`, `sendRich`, `sendAttachment`, `sendSticker`, `sendPoll`, `sendRichLink` |
22
+ | Bridge actions | `tapback`, `emojiTapback`, `sendRich`, `sendAttachment`, `sendSticker`, `sendPoll`, `sendRichLink`, `sendExtensionCard` |
23
23
  | Mutation | `editMessage`, `unsendMessage`, `deleteMessage`, `setTyping`, `markRead` |
24
24
  | Group and identity | `renameGroup`, `setGroupPhoto`, `addParticipant`, `removeParticipant`, `leaveGroup`, `shareNamePhoto` |
25
25
  | Chat backgrounds | `chatBackgroundStatus`, `setChatBackground`, `removeChatBackground` |
@@ -15,6 +15,8 @@ contract; “capability-gated” means the selected binary must prove it at star
15
15
  | Chat background set (Gradient) / remove | Available, capability-gated (host-verified 2026-09-03) | `chatBackgroundSetGradient` / `chatBackgroundRemove` selector markers present (imsg#12 build); `tier2-smoke.ts <chatId> --only-chat-background` on the host, recorded in the contract ledger; status read needs no marker |
16
16
  | Find My shared locations read / live updates (`readSharedLocations`, `watchLocations`) | Available, capability-gated (host-verified 2026-09-13: SDK read leg; live fix and update stream verified at the native layer on a second Mac, `watchLocations()` end to end pending the relay e2e) | `sharedLocations` selector marker present (M2B-31 helper); `tier2-smoke.ts <chatId> --only-location` on the host, recorded in the contract ledger |
17
17
  | Find My "Request Location" card (`sendLocationRequest`) | Available, capability-gated (host-verified 2026-09-13, receiver-visible card with a Share button observed) | `locationRequest` selector marker present (M2B-31 helper); `tier2-smoke.ts <chatId> --only-location --location-request` on the host, chat.db Find My balloon row, recorded in the contract ledger |
18
+ | Third-party iMessage app card, and updating one in place (`sendExtensionCard`) | Present, capability-gated, **SDK half NOT host-verified** (M2B-46): the native layer was proven on real phones 2026-09-20 — card sends, delivers, draws, opens the installed app, updates in place — but this verb has never run against a host Mac | `extensionCardSend` marker for a send, `extensionCardSend` + `extensionCardUpdate` for an update (neither implies the other); a host run must confirm a first send returns a `guid`, that an update driven by the returned handle restamps the first card, and both markers on the current build, then be recorded in the contract ledger. No smoke leg yet — driven by hand |
19
+ | Tapback on one part of a message (`tapback`/`emojiTapback` `partIndex`) | Available, capability-gated (host-verified 2026-09-20 through the SDK verbs on macOS 26.6.2, a real iPhone watching: part-1 reaction lands alone, part 0 and part 1 coexist as two reactions, per-part remove, out-of-range refused with no row, `target_part` read back, chat.db prefix and range agree) | `tapbackPart` selector marker present, and NO other tapback marker substitutes for it — a helper without it corrupts the row silently rather than refusing, so a part above 0 is refused, never downgraded to part 0. No smoke leg yet — driven by hand |
18
20
  | Rich links | Present but conservative | Build must carry the rich-link fix; receiver-visible release smoke required |
19
21
  | Leave group | Present but unavailable on the verified host | Do not advertise until a native build restores and smokes it |
20
22
  | Mark unread, force notify, delete chat | Not exposed by this SDK | Current upstream `imsg` has RPC actions; first port them into the Mapier fork, then host-verify, capability-gate, document, and add conformance coverage |