bilibili
MCP server from ssrskl/bilibili-mcp-server
claude mcp add --transport stdio ssrskl-bilibili-mcp-server uv --directory /Users/maoyan/Codes/Python/mcps/bilibili-mcp-server run server.py \ --env BILI_JCT="your bili_jct" \ --env SESSDATA="your sessdata" \ --env DEDEUSERID="your deuserid"
How to use
This MCP server provides Bilibili-related MCP endpoints for video and user data. It can fetch basic video information (title, description, upload time), allow liking videos, retrieve user profiles (username, avatar), follow users, and report the number of user coins. To test locally, configure credentials in your environment and run the server using the MCP runner. You can then query the server via the MCP Inspector or other FastMCP clients to verify that the endpoints behave as described and return the expected data structures.
To operate, ensure you have the environment variables filled (SESSDATA, BILI_JCT, DEDEUSERID) so the underlying Bilibili API requests can authenticate. The server exposes standard MCP endpoints under the configured server name (bilibili-mcp-server in the example). Use the MCP Inspector provided by FastMCP to send requests and inspect responses, such as fetching video metadata, liking a video, retrieving a user profile, following a user, or querying a user's coin balance.
How to install
Prerequisites:
- Python 3.8+ (or the version required by your environment)
- uv (the MCP runner) installed in your environment
- Access credentials for Bilibili (SESSDATA, BILI_JCT, DEDEUSERID)
Installation steps:
-
Clone the MCP server repository or prepare your project directory: git clone https://github.com/your-org/bilibili-mcp-server.git cd bilibili-mcp-server
-
Install dependencies using uv: uv install
-
Create and configure the environment file (.env) or export the variables in your shell:
.env
SESSDATA=your sessdata BILI_JCT=your bili_jct DEDEUSERID=your deuserid
or export in shell
export SESSDATA=your sessdata export BILI_JCT=your bili_jct export DEDEUSERID=your deuserid
-
Run the MCP server through the MCP runner (as configured in mcp_config): fastmcp dev server.py
or via the configured uv command if you are deploying manually
uv --directory /path/to/your/project run server.py
-
Verify operation with the MCP Inspector or your preferred MCP client by targeting the bilibili-mcp-server endpoint.
Additional notes
Tips and common issues:
- Ensure the credentials (SESSDATA, BILI_JCT, DEDEUSERID) are valid for the Bilibili API; invalid credentials will result in authentication errors when calling endpoints.
- The environment file (.env) or shell exports must be available to the process running the MCP server; missing vars will cause requests to fail.
- If you encounter timeouts, consider increasing the timeout in the mcp_config and ensure the network path to Bilibili APIs is reachable from your host.
- When testing with FastMCP Inspector, verify the request paths match the MCP endpoints exposed by this server (e.g., video info, like video, user info, follow user, coins).
- If you update credentials or endpoints, restart the MCP server to pick up changes.
Related MCP Servers
mcp-vegalite
MCP server from isaacwasserman/mcp-vegalite-server
github-chat
A Model Context Protocol (MCP) for analyzing and querying GitHub repositories using the GitHub Chat API.
nautex
MCP server for guiding Coding Agents via end-to-end requirements to implementation plan pipeline
pagerduty
PagerDuty's official local MCP (Model Context Protocol) server which provides tools to interact with your PagerDuty account directly from your MCP-enabled client.
futu-stock
mcp server for futuniuniu stock
mcp -boilerplate
Boilerplate using one of the 'better' ways to build MCP Servers. Written using FastMCP