Discord Bot Platform  ·  View 10 of 19  ·  Data

Data Model

Installation, not application, is the unit of permission.

Editable source SVG draw.io All views
application application_id PK owner_id FK -> developer public_key review_state suspended_at developer developer_id PK email verified_at installation installation_id PK application_id FK server_id permissions_bitset granted_by revoked_at command command_id PK application_id FK server_id nullable name, options version token token_id PK application_id FK hash (salted) created_at revoked_at gateway_session session_id PK application_id FK shard_id, shard_count last_seq intents intent_approval application_id FK intent approved_at reviewer 1 : N 1 : N 1 : N 1 : N 1 : N N : M Discord Bot Platform — Data Model v 1.0 · owner Integration Platform Architecture · date 2026-10

Decisions

  • Permissions bitset lives on the installation and is evaluated at request time (ADR-06).
  • Tokens are hashes; there is no table from which a token can be recovered.

Assumption

  • Message and member entities belong to the chat service and are deliberately absent.