mesgd-sdk

A messaging client has two separate responsibilities: prove which account it is using, and protect the messages it exchanges. mesgd-sdk separates these into an account client and a PKI library, so an application can use either without taking on the other's state. Logging in does not require loading a key file, and signing a payload does not require storing an account password.

The account clients wrap signup, authenticator confirmation, login, password reset, public-key management, and logout. The PKI libraries generate and load keys, sign and verify messages, and encrypt and decrypt payloads. Account clients exist in eighteen languages, with different levels of built-in HTTPS and cryptographic support; consult Languages before choosing an implementation.

Application taskSDK componentReference
Enroll an account, log in, manage public keys, or log outAuth clientAuthentication
Generate keys, sign, verify, encrypt, or decryptPKI libraryKeys
Examine a language's cryptographic message loopPing/pong sampleSamples and run commands
Coordinate work between application agentsProposed topic conventionAgents

The intended application interface is small: send a message to a recipient, or register a callback for messages from a sender. Signing and encryption would sit behind those operations. The current SDK provides the underlying pieces, with experimental samples, rather than a uniform implementation of that interface in every language.

For mesgd integration, start with the account client and the server's JSON WebSocket format. The encrypted registration handshake used by the samples is not implemented by the current server. Publishing keys with PUT /auth/keys is a working account operation; the sample register function is a separate cryptographic operation.

Language guides

Each guide includes setup, HTTPS and WSS support status, account examples, method names, and available cryptographic examples. The guides are ranked by current completeness, starting with Erlang, then Go, C, and Ruby. The support matrix distinguishes built-in HTTPS from application transports and pending WSS integration.

Check an implementation

Run these targets from the mesgd-sdk source. A test target's language coverage is listed in Languages; unavailable toolchains may be skipped.

TargetCoverage
make test-authOffline request contracts for seven account operations, OTP strings, public-key validation, and HTTP errors
make test-auth-liveAccount operations over HTTPS against a temporary mesgd on loopback
make testsThe default language PKI suites, followed by protocol tests
make test-mesgdClient-side protocol tests for Erlang, Python, JavaScript, Go, Ruby, Rust, and C

The live auth suite uses installed code from ~/.beamer, a temporary database and keys, and a localhost certificate. It requires Erlang, OpenSSL, the relevant language runtimes, and libcurl headers for C. The protocol suite exercises cryptographic message construction; passing it does not establish that the sample registration handshake works with a running mesgd.

Shared cryptographic fixtures are in fixtures/jwks.json, fixtures/sig_*.json, and fixtures/ct_*.json.