← 返回
未分类 Key 中文

YYClaw

Access and call 50+ AI models via YYClaw API with on-chain stablecoin payments; check balance, usage, models, and make API calls using one API key.
通过YYClaw API访问50+AI模型,支持链上稳定币支付;单一API密钥查询余额、使用量、模型并调用API。
geniustimee geniustimee 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 需要
★ 0
Stars
📥 493
下载
💾 0
安装
1
版本
#latest

概述

YYClaw — Pay-Per-Call AI Gateway Skill

Description

Use YYClaw API to call 50+ AI models (Claude, Gemini) with on-chain stablecoin payments. Check balance, usage, list models, and make API calls — all with a single API key.

Setup

Required Environment

  • YYCLAW_API_KEY — Your API key (starts with sk-yy-). Get one at https://crypto.yyclaw.cc by connecting your wallet.

Optional

  • YYCLAW_BASE_URL — Override gateway URL (default: https://crypto.yyclaw.cc)

API Reference

Base URL: https://crypto.yyclaw.cc

All endpoints use Authorization: Bearer header.

Check Balance & Remaining Credit

GET /v1/balance

Returns on-chain allowance (authorized amount), spent, remaining, call count, per-chain breakdown, and wallet address.

Response:

{
  "balance": 50.00,
  "spent": 2.34,
  "remaining": 47.66,
  "calls": 28,
  "chains": { "bsc": 50.00, "base": 0 },
  "wallet": "0x..."
}

Check Usage & Logs

GET /v1/usage?limit=20

Returns total calls, total spent, and recent call logs.

Response:

{
  "total_calls": 28,
  "total_spent": 2.34,
  "logs": [
    { "model": "gemini-3-flash-fixed", "cost": 0.02, "status": "success:0xabc...", "created_at": "2026-03-18 12:00:00" }
  ]
}

List Available Models

GET /v1/models

Returns all enabled models with per-call pricing. No auth required.

Call a Model (OpenAI-compatible)

POST /v1/chat/completions
Content-Type: application/json

{
  "model": "gemini-3-flash",
  "messages": [{"role": "user", "content": "Hello"}],
  "stream": false
}

The -fixed suffix is auto-appended if omitted. Supports streaming ("stream": true).

Model Aliases (shorthand → full name)

ShortModelPrice/call
-------------------------
gemini-3-flashgemini-3-flash-fixed$0.020
gemini-2.5-flashgemini-2.5-flash-fixed$0.010
gemini-3-pro-previewgemini-3-pro-preview-fixed$0.080
claude-haiku-4.5claude-haiku-4.5-fixed$0.064
claude-sonnet-4-6claude-sonnet-4-6-fixed$0.100
claude-opus-4.6claude-opus-4.6-fixed$0.160

Instructions for Agent

When this skill is active, use curl or any HTTP client to interact with YYClaw.

Reading API Key

echo $YYCLAW_API_KEY

If not set, ask the user to provide it or direct them to https://crypto.yyclaw.cc to get one.

Check Balance

curl -s -H "Authorization: Bearer $YYCLAW_API_KEY" https://crypto.yyclaw.cc/v1/balance | python3 -m json.tool

Check Usage

curl -s -H "Authorization: Bearer $YYCLAW_API_KEY" https://crypto.yyclaw.cc/v1/usage?limit=10 | python3 -m json.tool

List Models

curl -s https://crypto.yyclaw.cc/v1/models | python3 -m json.tool

Call a Model

curl -s -X POST https://crypto.yyclaw.cc/v1/chat/completions \
  -H "Authorization: Bearer $YYCLAW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"gemini-3-flash","messages":[{"role":"user","content":"Hello"}]}'

OpenAI SDK (Python)

from openai import OpenAI
import os

client = OpenAI(
    api_key=os.environ["YYCLAW_API_KEY"],
    base_url="https://crypto.yyclaw.cc/v1"
)

response = client.chat.completions.create(
    model="gemini-3-flash",
    messages=[{"role": "user", "content": "Hello"}]
)
print(response.choices[0].message.content)

OpenAI SDK (JavaScript)

import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env.YYCLAW_API_KEY,
  baseURL: 'https://crypto.yyclaw.cc/v1'
});

const res = await client.chat.completions.create({
  model: 'gemini-3-flash',
  messages: [{ role: 'user', content: 'Hello' }]
});
console.log(res.choices[0].message.content);

Error Handling

CodeMeaningAction
-----------------------
401Invalid API keyCheck YYCLAW_API_KEY
402Insufficient balance/allowanceUser needs to approve more tokens at dashboard
404Model not foundCheck /v1/models for available models
503Model upstream not configuredContact admin

Triggers

  • "check yyclaw balance" / "查看 yyclaw 余额"
  • "yyclaw usage" / "yyclaw 用量"
  • "list yyclaw models" / "yyclaw 模型列表"
  • "call yyclaw model" / "用 yyclaw 调用模型"
  • "yyclaw remaining credit" / "yyclaw 剩余额度"
  • Any mention of calling AI models through YYClaw

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-02 10:11 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-agent

Agent Browser

rez0
用于 AI 代理的浏览器自动化 CLI。当用户需要与网站交互(包括浏览页面、填写表单、点击按钮、截图等)时使用。
★ 875 📥 351,320
ai-agent

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,451 📥 329,714
ai-agent

self-improving agent

pskoett
记录自身发现以实现自我改进的技能
★ 4,176 📥 947,036