ECCP

Layered Docs

Reference material for protocol builders, operators, and client teams.

ECCP separates messaging basics, server operations, protocol concepts, and implementation guides so each layer stays understandable.

Static export ready

Static MDX guides, Shiki code fences, sidebar navigation, and bilingual routing for English and Traditional Chinese readers.

Messaging Basics

Bootstrap an ECCP account, connect a client, and verify your first encrypted exchange.

Updated 2026-04-08/docs/getting-started

Getting Started

ECCP works best when the roles stay clear: Layer 1 defines the contract, Layer 2 hosts the node, Layer 3 handles user experience, and Layer 4 adds optional ecosystem surfaces.

What You Need

  • An ECCP-capable homeserver, either hosted by your team or provided by a trusted operator
  • One client, such as PrivChat for mainstream UX or exine for operator-focused workflows
  • A stable device identity so end-to-end keys survive session refreshes

Create the First Account

An ECCP account is always attached to a homeserver namespace. The provider can be public, private, invite-only, or self-hosted.

Bash snippet

Bash

1
2
3
4
5
6
7
8
curl -X POST https://chat.example.org/_eccp/client/v1/register \
  -H "Content-Type: application/json" \
  -d '{
    "username": "ada",
    "display_name": "Ada",
    "password": "replace-me",
    "device_name": "Ada Laptop"
  }'

Verify Device Identity

When the account is created, the client generates device keys and starts the first X25519 handshake. ECCP keeps account credentials and device identity separate so rotating a password does not silently replace your cryptographic state.

Send the First Encrypted Event

TypeScript snippet

TypeScript

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import { ECCPClient } from "@eccp/sdk";

const client = new ECCPClient({
  baseUrl: "https://chat.example.org",
  accessToken: process.env.ECCP_ACCESS_TOKEN!
});

const room = await client.rooms.create({
  visibility: "private",
  name: "First encrypted room"
});

await client.rooms.send(room.id, {
  type: "m.room.encrypted",
  algorithm: "eccp.megolm.v1",
  body: "Handshake complete."
});

Check Cross-Device Sync

Open the same account on a second client and confirm that:

  1. The room appears without manual import.
  2. The device list is visible.
  3. The message history decrypts after key exchange completes.

Next Steps