feat: Phase 4 A2A Autonomous Lead Generation and P2P DHT Discovery
Some checks failed
Deploy to 110 WOOO Server / deploy (push) Failing after 7s

This commit is contained in:
OG T
2026-06-08 20:34:56 +08:00
parent 5529098c25
commit ead38a37f9
63 changed files with 7636 additions and 3605 deletions

View File

@@ -0,0 +1,46 @@
import os
from vibework_agent_sdk import VibeWorkAgentSDK
from vibework_agent_sdk.models import AgentCard
sdk = VibeWorkAgentSDK(
base_url="https://agent.wooo.work",
api_key="super-secret-mcp-key"
)
agent_id = "test-hunter-bot-py-001"
wallet = "0x9999999999abcdef1234567890abcdef12345678"
# 1. Register Agent
card = AgentCard(
agent_id=agent_id,
name="HunterBot-Py-Test",
description="Python SDK test agent",
skills=["python"],
x402_wallet_address=wallet
)
print("Registering...")
print(sdk.identity.register_agent(card))
# 2. List Tasks
print("\nListing bounties...")
bounties = sdk.a2a.list_open_bounties(limit=5)
print(f"Found {len(bounties.tasks)} tasks.")
if bounties.tasks:
task = bounties.tasks[0]
print(f"Claiming {task.task_id}...")
claim = sdk.tasks.claim_bounty(
task_id=task.task_id,
agent_id=agent_id,
developer_wallet=wallet
)
print(f"Claim status: {claim.status}, token: {claim.claim_token[:10]}...")
print("\nSubmitting solution...")
submit = sdk.tasks.submit_solution(
task_id=task.task_id,
claim_token=claim.claim_token,
deliverables={"test.py": "print('hello from python')"},
github_pr_url="https://github.com/agent-bounty-protocol/pr/py"
)
print(f"Submit status: {submit.status}")