Closes TOO-192 <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Adds a Figma OAuth2 auth provider and wires it through TDK and MCP server, with tests updated and package versions bumped. > > - **Auth**: > - Add `Figma` OAuth2 provider in `libs/arcade-core/arcade_core/auth.py`. > - **Exports**: > - Expose `Figma` in `libs/arcade-mcp-server/arcade_mcp_server/auth/__init__.py` and `libs/arcade-tdk/arcade_tdk/auth/__init__.py` (`__all__`). > - **Tests**: > - Add Figma auth requirement test case in `libs/tests/tool/test_create_tool_definition.py` and import `Figma`. > - **Versioning**: > - Bump `arcade-mcp-server` to `1.10.2` and `arcade-tdk` to `3.2.0`. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit 2bacfdc5695b3e7fc5e4532dbd360c3b2263130e. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY --> --------- Co-authored-by: Francisco Liberal <francisco@arcade.dev> |
||
|---|---|---|
| .. | ||
| arcade_tdk | ||
| pyproject.toml | ||
| README.md | ||
Arcade TDK (Toolkit Development Kit)
Toolkit Development Kit for building and testing Arcade tools.
Overview
Arcade TDK provides the essential tools and utilities for building Arcade tools:
- Tool Decorator: Simple
@tooldecorator for creating Arcade tools - Authentication: Auth providers and helpers for tool security
- Annotations: Type annotations and parameter validation
- Core Integration: Seamless integration with arcade-core components
Installation
pip install arcade-tdk
Usage
from typing import Annotated
from arcade_tdk import tool
@tool
def hello_world(name: Annotated[str, "The name of the person to greet"]) -> str:
"""Say hello to someone."""
return f"Hello, {name}!"
# The tool is automatically registered and available for use
Advanced Usage
from typing import Annotated
from arcade_tdk import tool, ToolCatalog, Toolkit
from arcade_tdk.auth import Reddit
# Create tools with auth requirement
@tool(requires_auth=Reddit(scopes=["read"]))
def get_posts_in_subreddit(
subreddit: Annotated[str, "The name of the subreddit"],
limit: Annotated[int, "The number of posts to return]
) -> dict:
"""Get posts from a specific subreddit"""
# TODO: Implement your Reddit tool
return {}
License
MIT License - see LICENSE file for details.