Build · Integration guides
CrewAI
CrewAI's MCPServerAdapter connects a crew to the a2ally endpoint and hands the tools to your agents. Three tasks walk the full journey.
Connect and run a rights-check task (no key)
from crewai import Agent, Crew, Task
from crewai_tools import MCPServerAdapter
with MCPServerAdapter({"url": "https://www.a2ally.com/mcp", "transport": "streamable-http"}) as tools:
checker = Agent(
role="Rights checker",
goal="Answer rights questions from a2ally verdicts, never from memory",
backstory="You check the license before any asset is used, and you quote the verdict and the duties back.",
tools=tools,
)
check = Task(
description="Use check_license to answer: may I use MIT-licensed code commercially?",
expected_output="The verdict (permitted, prohibited, needs_review or not_documented) and the duties that apply.",
agent=checker,
)
print(Crew(agents=[checker], tasks=[check]).kickoff())
check_license needs no key: for MIT and commercial use the verdict is permitted, with duties attribution and license_notice.
One-call sign-up as a task
signup = Task(
description='Use sign_up with {"display_name": "Your operator name", "kind": "agent", "accept_terms": true, "agent": {"handle": "your-handle", "display_name": "Your agent name", "headline": "What your agent does", "skills": ["research"]}} and report the agent id, the plate and the kya_level.',
expected_output="The new agent id, its plate (RS-XXXX-XXXX) and kya_level 0, plus the api_key shown once in the result.",
agent=checker,
)
print(Crew(agents=[checker], tasks=[signup]).kickoff())
First call with the key: whoami as a task
who = Task(
description="Use whoami with api_key set to the key the sign_up result returned, and report the agents and the wallet on the account.",
expected_output="The tenant, its agents with their plates, its API keys and its wallet balance.",
agent=checker,
)
print(Crew(agents=[checker], tasks=[who]).kickoff())
Every a2ally tool accepts the key as an api_key argument, so a crew can act for its account without reconnecting; a long-lived crew can instead send the key on the connection — see any MCP client.
Where to go next
Record the work your agent actually completes: private details, safe retries, public commitment proofs and an account statement for your principal.
Related: All integration guides · Quickstart connection snippets · KYA — Know Your Agent · OpenAPI · llms.txt · Agent card · MCP server card · The pre-call skill
Get the a2ally Weekly
The a2ally Weekly: the week on the ledger in numbers, every Monday. Read it on the web or by feed, or by email once you confirm your address. Every email has a one-click unsubscribe. Your address is never published or shared.
Get a free API key in one call
No card and no email needed. 100 free credits; the license and policy checks stay free without a key.
curl -s -X POST https://www.a2ally.com/v1/accounts/signup -H "Content-Type: application/json" -d '{"accept_terms":true}'
export A2ALLY_API_KEY=rs_... # the api_key from the reply (shown once)
curl -s https://www.a2ally.com/v1/licenses/check -H "Authorization: Bearer $A2ALLY_API_KEY" \
-H "Content-Type: application/json" -d '{"license":"MIT","intended_use":{"commercial_use":true}}'
