xmtp_proto: XIP-83 d14n binding — QueryApi.Subscribe (bidi mutable subscription)#338
Merged
Merged
Conversation
…bscription; vector-cursor topics; OriginatorEnvelope delivery; mutate_id waves; Started/CatchupComplete/TopicsLive; ping/pong; history_only) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
ApprovabilityVerdict: Approved Purely additive protobuf schema changes defining a new bidirectional subscription API. No existing definitions modified, and the author is the designated code owner for both files. You can customize Macroscope's approvability policy. Learn more. |
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.
Adds the decentralized-backend binding of XIP-83 — companion to the v3
MlsApi.Subscribebinding (#337, merged). A new bidirectionalSubscribe(stream SubscribeRequest) returns (stream SubscribeResponse)RPC onQueryApi, additive alongside the existing server-streamingSubscribeTopics.The control protocol is identical to the v3 binding —
Mutate(add/remove topics in place,history_only,mutate_id),Started,CatchupComplete,TopicsLive,Ping/Pong— adapted to the decentralized data model:Subscriptionresumes from axmtp.xmtpv4.envelopes.Cursor(the same typeSubscribeTopicsuses), not v3's scalarid_cursor.OriginatorEnvelopes; the client demultiplexes by topic.Bidirectional streaming requires HTTP/2; browser/connect-web clients stay on
SubscribeTopics.Spec: xmtp/XIPs#139 (the "Decentralized (d14n) binding" section).
🤖 Generated with Claude Code
Note
Add bidirectional
QueryApi.SubscribeRPC with mutable topic subscriptions and ping/pong livenessSubscribeRequestandSubscribeResponsemessages to message_api.proto defining the client→node and node→client framing for the new bidi subscription protocol (XIP-83 d14n binding).SubscribeRequest.V1.Mutatesupports atomic topic adds/removes, ahistory_onlycatch-up flag, and amutate_idfor correlatingCatchupCompleteresponses.SubscribeResponse.V1carries batchedEnvelopes, stream init metadata (Started), topic live-boundary markers (TopicsLive), per-mutation completion signals (CatchupComplete), andPing/Pongliveness frames.Subscribebidi-streaming RPC on theQueryApiservice in query_api.proto, alongside the existing server-streamingSubscribeTopics.Macroscope summarized 6ccd578.