How xittered/xitter works
Xitter is a self-hosted backend that serves a pinned X web client and implements its API using instance data. The main workflow is a browser using that client to send requests to Xitter, which authenticates the account, dispatches API operations, applies domain rules, and reads or writes PostgreSQL-backed state before returning client-shaped responses. The graph includes the documented social, media, messaging, discovery, and administration capabilities. Some subsystem links are documented in the README; unsampled implementation details and relationships are not inferred.
Main entry points: posts.ts Posts and timelines · graphql.ts GraphQL API · server.ts HTTP server · auth.ts Sessions and identity
Components 24
Request runtime
- HTTP server
src/server.ts - GraphQL API
src/graphql.ts - Public API
src/public-api.ts - Client response models
src/model.ts - Client asset archive
src/client-cache.ts - Client asset build
src/build.ts
Social content
- Posts and timelines
src/posts.ts - Long-form articles
src/articles.ts - Search and discovery
src/search.ts - Communities and lists
src/communities.ts - Community Notes
src/notes.ts
Accounts and safety
- Sessions and identity
src/auth.ts - Profiles and follows
src/users.ts - Blocks and mutes
src/blocks.ts - Moderation controls
src/moderation.ts
Media and messaging
- Media uploads
src/media.ts - Encrypted messaging
src/chat.ts
Instance operations
- Admin panel
src/admin.ts - Instance settings
src/settings.ts - Account analytics
src/analytics.ts - Notifications and push
src/notifications.ts
Other components
- Browser user
- Pinned X client
- PostgreSQL
Connections 27
- Browser user → Pinned X client: uses
- Pinned X client → HTTP server: sends API requests
- HTTP server → GraphQL API: routes requests
src/server.ts - HTTP server → Sessions and identity: uses sessions
src/server.ts - HTTP server → Admin panel: routes admin
src/server.ts - GraphQL API → Posts and timelines: dispatches operations
src/graphql.ts - GraphQL API → Encrypted messaging: dispatches operations
src/graphql.ts - GraphQL API → Communities and lists: dispatches operations
src/graphql.ts - GraphQL API → Account analytics: dispatches operations
src/graphql.ts - GraphQL API → Notifications and push: dispatches operations
src/graphql.ts - Posts and timelines → Media uploads: loads media
src/posts.ts - Posts and timelines → Profiles and follows: loads authors
src/posts.ts - Posts and timelines → Blocks and mutes: checks blocks
src/posts.ts - Posts and timelines → Moderation controls: checks content
src/posts.ts - Posts and timelines → Instance settings: checks blocked phrases
src/posts.ts - Posts and timelines → Client response models: uses response models
src/posts.ts - Long-form articles → Media uploads: uses media
src/articles.ts - Long-form articles → Client response models: uses response models
src/articles.ts - Sessions and identity → Moderation controls: expires sanctions
src/auth.ts - Admin panel → Instance settings: updates settings
src/admin.ts - Client asset build → Client asset archive: reads archive
src/build.ts - HTTP server → Public API: serves public API
src/server.ts - HTTP server → Client asset archive: serves client assets
src/server.ts - Posts and timelines → PostgreSQL: reads and writes
src/posts.ts - Sessions and identity → PostgreSQL: reads and writes
src/auth.ts - Admin panel → PostgreSQL: reads and writes
src/admin.ts - GraphQL API → Search and discovery: dispatches operations
src/graphql.ts