# llbuxudong/nonebot-plugin-bfvgrouptools architecture

> Architecture diagram of the GitHub repository llbuxudong/nonebot-plugin-bfvgrouptools, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/llbuxudong/nonebot-plugin-bfvgrouptools
- Repository: https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools

## Overview

This is a NoneBot plugin for Battlefield V group administration. Its main flows are player-status and ban-record commands, plus automatic group-request screening and welcome handling for configured groups. The graph separates event handling, player identity/cache, status and ban-record presentation, and external API access. Relationships are based on the README and shown source; external API calls are grouped because the excerpts do not establish separate service ownership for every endpoint.

Main entry points: [`nonebot_plugin_grouptools/__init__.py`](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py) (Plugin handlers), [`nonebot_plugin_grouptools/data.py`](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py) (Player ID lookup), [`nonebot_plugin_grouptools/utils.py`](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/utils.py) (API helpers), [`nonebot_plugin_grouptools/pb.py`](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/pb.py) (Ban-list image)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_events["Bot events"]
  node_handlers["Plugin handlers<br/>[__init__.py]"]
  node_joinflow["Join screening<br/>[__init__.py]"]
  node_jointracker[("Pending join records<br/>[__init__.py]")]
end

subgraph group_players["Player data"]
  node_identity["Player ID lookup<br/>[data.py]"]
  node_playercache[("Player ID cache<br/>[data.py]")]
end

subgraph group_presentation["Query results"]
  node_playerinfo["Player information<br/>[player_status.py]"]
  node_community["Community status<br/>[player_status.py]"]
  node_banimage["Ban-list image<br/>[pb.py]"]
  node_imagerender["Text image renderer<br/>[pb.py]"]
end

subgraph group_integrations["Storage and APIs"]
  node_pluginstore[("Plugin data files<br/>[data.py]")]
  node_apihelpers["API helpers<br/>[utils.py]"]
  node_bfvapis["BFV data APIs"]
  node_botplatform["OneBot platform"]
end

node_member(("Group members"))

node_member -->|"sends commands"| node_handlers
node_handlers -->|"queries status"| node_community
node_handlers -->|"requests ban list"| node_banimage
node_handlers -->|"handles requests"| node_joinflow
node_joinflow -->|"resolves player"| node_identity
node_joinflow -->|"checks rank"| node_apihelpers
node_joinflow -->|"records applicant"| node_jointracker
node_handlers -->|"removes applicant"| node_jointracker
node_handlers -->|"approves or replies"| node_botplatform
node_handlers -->|"gets welcome details"| node_playerinfo
node_playerinfo -->|"adds community status"| node_community
node_community -->|"resolves player"| node_identity
node_community -->|"fetches status data"| node_apihelpers
node_banimage -->|"resolves player"| node_identity
node_banimage -->|"fetches ban records"| node_apihelpers
node_banimage -->|"renders records"| node_imagerender
node_identity -->|"reads and updates"| node_playercache
node_identity -->|"looks up uncached ID"| node_apihelpers
node_playercache -->|"loads and saves"| node_pluginstore
node_apihelpers -->|"requests player data"| node_bfvapis

click node_handlers "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py"
click node_joinflow "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py"
click node_jointracker "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py"
click node_playerinfo "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/player_status.py"
click node_community "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/player_status.py"
click node_banimage "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/pb.py"
click node_imagerender "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/pb.py"
click node_identity "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py"
click node_playercache "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py"
click node_pluginstore "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py"
click node_apihelpers "https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/utils.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_handlers,node_joinflow,node_jointracker toneBlue
class node_identity,node_playercache toneAmber
class node_playerinfo,node_community,node_banimage,node_imagerender toneMint
class node_pluginstore,node_apihelpers,node_bfvapis,node_botplatform toneRose
class node_member toneIndigo
```

## Components

### Bot events

- [Plugin handlers](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py): `nonebot_plugin_grouptools/__init__.py`
- [Join screening](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py): `nonebot_plugin_grouptools/__init__.py`
- [Pending join records](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/__init__.py): `nonebot_plugin_grouptools/__init__.py`

### Player data

- [Player ID lookup](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py): `nonebot_plugin_grouptools/data.py`
- [Player ID cache](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py): `nonebot_plugin_grouptools/data.py`

### Query results

- [Player information](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/player_status.py): `nonebot_plugin_grouptools/player_status.py`
- [Community status](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/player_status.py): `nonebot_plugin_grouptools/player_status.py`
- [Ban-list image](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/pb.py): `nonebot_plugin_grouptools/pb.py`
- [Text image renderer](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/pb.py): `nonebot_plugin_grouptools/pb.py`

### Storage and APIs

- [Plugin data files](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/data.py): `nonebot_plugin_grouptools/data.py`
- [API helpers](https://github.com/llbuxudong/nonebot-plugin-bfvgrouptools/blob/master/nonebot_plugin_grouptools/utils.py): `nonebot_plugin_grouptools/utils.py`
- **BFV data APIs**
- **OneBot platform**

### Other components

- **Group members**

## Connections

- Group members → Plugin handlers: sends commands (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → Community status: queries status (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → Ban-list image: requests ban list (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → Join screening: handles requests (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Join screening → Player ID lookup: resolves player (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Join screening → API helpers: checks rank (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Join screening → Pending join records: records applicant (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → Pending join records: removes applicant (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → OneBot platform: approves or replies (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Plugin handlers → Player information: gets welcome details (evidence: `nonebot_plugin_grouptools/__init__.py`)
- Player information → Community status: adds community status (evidence: `nonebot_plugin_grouptools/player_status.py`)
- Community status → Player ID lookup: resolves player (evidence: `nonebot_plugin_grouptools/player_status.py`)
- Community status → API helpers: fetches status data (evidence: `nonebot_plugin_grouptools/player_status.py`)
- Ban-list image → Player ID lookup: resolves player (evidence: `nonebot_plugin_grouptools/pb.py`)
- Ban-list image → API helpers: fetches ban records (evidence: `nonebot_plugin_grouptools/pb.py`)
- Ban-list image → Text image renderer: renders records (evidence: `nonebot_plugin_grouptools/pb.py`)
- Player ID lookup → Player ID cache: reads and updates (evidence: `nonebot_plugin_grouptools/data.py`)
- Player ID lookup → API helpers: looks up uncached ID (evidence: `nonebot_plugin_grouptools/data.py`)
- Player ID cache → Plugin data files: loads and saves (evidence: `nonebot_plugin_grouptools/data.py`)
- API helpers → BFV data APIs: requests player data (evidence: `nonebot_plugin_grouptools/utils.py`)
