A Model Context Protocol (MCP) server for interacting with AppFlowy Cloud API, providing tools for workspace, database, and row operations.
- Authentication: Login and refresh token management
- Workspace Operations: List all workspaces
- Database Operations: List databases, get database fields
- Row Operations: List rows, get row details, create rows, upsert rows
The server uses in-memory token storage. To authenticate:
- Use
appflowy_loginwith your email and password - The tokens are stored automatically
- Use
appflowy_refresh_tokenwhen the access token expires
appflowy_login(request: LoginRequest)- Login to AppFlowy Cloudappflowy_refresh_token(request: RefreshTokenRequest)- Refresh access token
appflowy_list_workspaces()- List all workspaces
appflowy_list_databases(workspace_id: str)- List databases in a workspaceappflowy_get_database_fields(workspace_id: str, database_id: str)- Get database fields
appflowy_list_rows(workspace_id: str, database_id: str)- List row IDsappflowy_get_row_details(workspace_id: str, database_id: str, row_ids: str, with_doc: bool = False)- Get row detailsappflowy_create_row(workspace_id: str, database_id: str, request: RowCreateRequest)- Create a new rowappflowy_upsert_row(workspace_id: str, database_id: str, request: RowUpdateRequest)- Update or create row
uv run python main.py- Login:
request = LoginRequest(email="your@example.com", password="your_password")
response = appflowy_login(request)- List workspaces:
workspaces = appflowy_list_workspaces()- Get database fields:
fields = appflowy_get_database_fields("workspace_id", "database_id")- Create a row:
row_request = RowCreateRequest(cells={"Field_Name": "Value"}, document="Optional markdown")
result = appflowy_create_row("workspace_id", "database_id", row_request)The server maintains tokens in memory. For production use, consider adding persistent storage (Redis, database, etc.) and proper error handling.