CrewAI
Skytale integrates with CrewAI as standard BaseTool instances. Your agents get encrypted send/receive capabilities without any infrastructure changes.
Installation
Section titled “Installation”pip install skytale-sdk[crewai]This installs skytale-sdk and crewai.
Quick start
Section titled “Quick start”from crewai import Agent, Task, Crewfrom skytale_sdk.integrations import crewai as skytale_crew
# 1. Create a channel managermgr = skytale_crew.create_manager(identity=b"analyst")
# 2. Create or join a channel (see Invite Flow below)mgr.create("acme/analysis/pipeline")
# 3. Create an agent with Skytale toolsanalyst = Agent( role="Analyst", goal="Read and analyze data from the encrypted channel", backstory="You analyze data received via encrypted channels.", tools=skytale_crew.tools(mgr),)
# 4. Run a tasktask = Task( description="Check acme/analysis/pipeline for new data and summarize it.", expected_output="A summary of the data received.", agent=analyst,)
crew = Crew(agents=[analyst], tasks=[task])crew.kickoff()Invite flow
Section titled “Invite flow”One agent creates the channel and generates a token; the joining agent uses it. MLS key exchange happens automatically.
Same-process setup (demos)
Section titled “Same-process setup (demos)”from skytale_sdk.integrations import crewai as skytale_crew
researcher = skytale_crew.create_manager(identity=b"researcher")analyst = skytale_crew.create_manager(identity=b"analyst")
researcher.create("acme/demo/findings")token = researcher.invite("acme/demo/findings")analyst.join_with_token("acme/demo/findings", token)
# Both managers are ready — create Agents with tools and run a CrewPre-provisioned setup (production)
Section titled “Pre-provisioned setup (production)”Run a setup script before starting your crew:
# setup.py — run oncefrom skytale_sdk import SkytaleChannelManager
creator = SkytaleChannelManager(identity=b"creator", data_dir="/var/lib/creator")creator.create("acme/prod/pipeline")
# Generate a token and share it (env var, config file, etc.)token = creator.invite("acme/prod/pipeline")
# Joiner uses the token — no key package exchange neededjoiner = SkytaleChannelManager(identity=b"joiner", data_dir="/var/lib/joiner")joiner.join_with_token("acme/prod/pipeline", token)Tools reference
Section titled “Tools reference”| Tool | Args | Description |
|---|---|---|
skytale_send | channel, message | Send an encrypted message to a channel |
skytale_receive | channel, timeout (default 5s) | Receive buffered messages from a channel |
skytale_channels | — | List all active channels |
Environment variables
Section titled “Environment variables”| Variable | Default | Description |
|---|---|---|
SKYTALE_RELAY | https://relay.skytale.sh:5000 | Relay server URL |
SKYTALE_API_KEY | — | API key for authenticated access |
SKYTALE_API_URL | https://api.skytale.sh | API server URL |
Full example
Section titled “Full example”See sdk/examples/crewai_encrypted.py for a complete multi-agent crew demo.
Cross-framework communication
Section titled “Cross-framework communication”CrewAI agents and LangGraph agents on the same channel communicate automatically — Skytale is the pipe, not the framework. A CrewAI agent sends data and a LangGraph agent receives it, because both use the same SkytaleChannelManager under the hood.
For structured cross-protocol messaging, see the Envelope and Protocol Adapters documentation.