xmtp / xmtp-js

XMTP client SDKs for JavaScript applications.

Home Page:https://xmtp.org/docs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Wrap account public keys in protos and upload to XMTP topics

m-005 opened this issue · comments

commented

Wrap the account public keys into protos in rust-land, and upload them (likely from JS)
Proto generation is handled by xmtp-proto crate

Pre-requisites:
xmtp/proto#81
xmtp/libxmtp#73

May depend on or be duplicative with #355

This task also depends on #349 right? We need networking to upload to XMTP topics. I can get started on a Rust-land networking backend + a networking trait.

releasing this task

I've released this task back into the pool. I'll give a quick summary of my thoughts here, although I didn't really get to dig into it.

I merged a PR last week that wraps contact elements in protos: xmtp/libxmtp#89

To upload to XMTP topics we can:

  1. Choose the topic naming structure (could just append a new prefix and switch to /xmtp/1/ per the MudPup demo sprint.
  2. Publish to the topic. This can happen in one of two ways:
  • Via xmtp-js - can either try to consume it in bindings_js or have a branch in xmtp-js that consumes our wasm bundle. The latter requires running tests from xmtp-js.
  • Via Rust (xmtp_networking). xmtp_networking is well understood but does not work as it is for wasm land (tonic dependency doesn't build for wasm). We can still utilize it for unit tests if we keep enforce a well-defined Networking trait.

Either way, the first step may be to just define that Networking trait and mock it out. Then we can build various backends for it.

Okay, I won't start this for now and work on networking directly via #349