Skip to content

What is Lexicon

Lexicon is a schema definition language used to describe atproto records, HTTP endpoints (XRPC), and event stream messages. The schema language is similar to JSON Schema and OpenAPI, but includes some atproto-specific features and semantics.

You can think of Lexicon as a specific sub-standard that clients and servers follow to communicate with each other. For example, Bluesky has proposed a Lexicon standard for general Twitter-like social network applications. You can also propose your own Lexicon files to build applications in specific domains.

In the Web5 ecosystem, most applications should follow the original Lexicons from the AT Protocol in the space of social network design. The difference is that Web5.fans proposes specific Lexicon files to interact with did:ckb and other Web5 components. These Lexicon files require extra attention when building Web5 applications.

For more information about the Lexicon specification, please check out the AT Protocol documents here.