Coyns Wallet

v1.0.0

Integrate any OpenClaw agent with the Coyns virtual currency platform. Use this skill whenever an agent needs to register a wallet, check Coyns balances, cla...

0· 72·0 current·0 all-time

Install

OpenClaw Prompt Flow

Install with OpenClaw

Best for remote or guided setup. Copy the exact prompt, then paste it into OpenClaw for patrickbluehill/coyns-wallet.

Previewing Install & Setup.
Prompt PreviewInstall & Setup
Install the skill "Coyns Wallet" (patrickbluehill/coyns-wallet) from ClawHub.
Skill page: https://clawhub.ai/patrickbluehill/coyns-wallet
Keep the work scoped to this skill only.
After install, inspect the skill metadata and help me finish setup.
Required env vars: COYNS_AGENT_ID, COYNS_PRIVATE_KEY
Use only the metadata you can verify from ClawHub; do not invent missing requirements.
Ask before making any broader environment changes.

Command Line

CLI Commands

Use the direct CLI path if you want to install manually and keep every step visible.

OpenClaw CLI

Bare skill slug

openclaw skills install coyns-wallet

ClawHub CLI

Package manager switcher

npx clawhub@latest install coyns-wallet
Security Scan
Capability signals
CryptoRequires walletCan make purchasesRequires sensitive credentials
These labels describe what authority the skill may exercise. They are separate from suspicious or malicious moderation verdicts.
VirusTotalVirusTotal
Pending
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description (Coyns wallet ops) match the declared env vars and the SKILL.md: the skill needs an agent ID and an Ed25519 private key to sign API requests to api.coyns.com. Nothing requested appears unrelated to the stated purpose.
Instruction Scope
SKILL.md contains explicit API paths, header/signature construction, and registration flows limited to the Coyns API (base URL https://api.coyns.com/v1). It does not instruct the agent to read unrelated files or call other external endpoints. Examples include key generation/loading and signing logic which are appropriate for producing required signatures.
Install Mechanism
There is no install spec and no code files (instruction-only), so nothing is downloaded or written to disk by the skill itself — this minimizes install-time risk.
Credentials
The required env vars (COYNS_AGENT_ID, COYNS_PRIVATE_KEY) are appropriate for a wallet integration, but COYNS_PRIVATE_KEY is highly sensitive: it enables signing authenticated requests (including payments). Storing this secret in an env var is common but grants full transactional authority to the skill/agent and should be treated with caution.
Persistence & Privilege
always is false and the skill is user-invocable; it does not request persistent system-wide privileges or modify other skills. Autonomous invocation is allowed (platform default) but is not combined with other privilege escalations here.
Assessment
This skill appears to do exactly what it says: sign and send requests to the Coyns API. Before installing, consider: (1) COYNS_PRIVATE_KEY is equivalent to money-control — only provide a key you trust the agent to use (prefer a dedicated/limited account or test key). (2) Keep the key in a secure secret store and rotate it if exposed. (3) Review and confirm the endpoint (https://api.coyns.com/v1) and the skill's trigger phrases so you understand when the agent may attempt payments. (4) For safety, test with staging credentials (OTP '000000') and small amounts first. (5) If you need stricter controls, require manual confirmation before any outgoing payment/escrow action.

Like a lobster shell, security has layers — review code before you run it.

Runtime requirements

🪙 Clawdis
EnvCOYNS_AGENT_ID, COYNS_PRIVATE_KEY
Primary envCOYNS_AGENT_ID
latestvk97egaa0bjx9rfx22scwmx4r8584xw6s
72downloads
0stars
1versions
Updated 1w ago
v1.0.0
MIT-0

Coyns Wallet

Coyns is the financial layer for AI agents. It provides a complete payment rail that lets agents register, earn currency, exchange between tiers, pay other agents directly, and create escrow-backed deals.

Full docs: https://coyns.com/docs Base URL: https://api.coyns.com/v1


Currency Hierarchy

Coyns has three currencies. Exchanges are one-way only, moving value upward:

CRYSTALS → COYNS → GOLD
  • 10 CRYSTALS = 100 COYNS
  • 10 COYNS = 100 GOLD

Reverse exchanges and cross-tier skips are disabled.


Authentication

Every authenticated request requires Ed25519 signature headers. POST requests also require an OTP.

Required Headers

HeaderDescription
X-Agent-IdYour agent ID (e.g. agt_01abc...)
X-TimestampUnix epoch seconds
X-SignatureEd25519 signature, base64-encoded
X-OTPRequired for POST requests. Use "000000" for staging.
X-Idempotency-KeyOptional, for replay protection

Canonical String

The signature is computed over this canonical string (parts joined with \n):

method           (lowercase: "post", "get")
path             (e.g. "/v1/payments")
sha256(body)     (hex-encoded hash of request body; empty string hash for GET)
timestamp        (same value as X-Timestamp)
idempotency_key  (empty string if not provided)

Sign the canonical string with your Ed25519 private key and base64-encode the result.

TypeScript Example

import { createHash } from "crypto";
import * as ed from "@noble/ed25519";
import { sha512 } from "@noble/hashes/sha512";

ed.etc.sha512Sync = (...m: Uint8Array[]) =>
  sha512(ed.etc.concatBytes(...m));

function signRequest(opts: {
  privateKey: Uint8Array;
  method: string;
  path: string;
  body: string;
  idempotencyKey?: string;
}) {
  const timestamp = Math.floor(Date.now() / 1000).toString();
  const bodyHash = createHash("sha256")
    .update(opts.body || "")
    .digest("hex");

  const canonical = [
    opts.method.toLowerCase(),
    opts.path,
    bodyHash,
    timestamp,
    opts.idempotencyKey || "",
  ].join("\n");

  const sig = ed.sign(Buffer.from(canonical), opts.privateKey);
  return {
    timestamp,
    signature: Buffer.from(sig).toString("base64"),
  };
}

function buildHeaders(opts: {
  agentId: string;
  privateKey: Uint8Array;
  method: string;
  path: string;
  body: string;
  idempotencyKey?: string;
  otp?: string;
}) {
  const { timestamp, signature } = signRequest(opts);
  return {
    "Content-Type": "application/json",
    "X-Agent-Id": opts.agentId,
    "X-Timestamp": timestamp,
    "X-Signature": signature,
    ...(opts.otp && { "X-OTP": opts.otp }),
    ...(opts.idempotencyKey && {
      "X-Idempotency-Key": opts.idempotencyKey,
    }),
  };
}

Python Example

from nacl.signing import SigningKey
import base64, hashlib, time

signing_key = SigningKey.generate()  # or load your existing key

def sign_request(method, path, body="", idempotency_key=""):
    ts = str(int(time.time()))
    body_hash = hashlib.sha256(body.encode()).hexdigest()
    canonical = f"{method.lower()}\n{path}\n{body_hash}\n{ts}\n{idempotency_key}"
    sig = signing_key.sign(canonical.encode()).signature
    return ts, base64.b64encode(sig).decode()

Registration

Registration has three stages: Register → Approval → Activate.

Step 1: Register

Submit public keys and profile. No authentication required.

POST /v1/agents/register
Content-Type: application/json

{
  "pub_spend_key": "<base64 Ed25519 public key>",
  "pub_guard_key": "<base64 Ed25519 public key>",
  "display_name":  "My Agent"
}

Required fields: pub_spend_key, pub_guard_key, display_name

Optional fields: agent_name (your @handle), description, owner, email, telegram, skills (string array), invite_code

Response:

{
  "agent_id": "agt_01abc...",
  "nonce": "random-nonce-string",
  "waitlist_position": 0,
  "status": "pending"
}

Save the agent_id and nonce — needed for Step 3.

Step 2: Wait for Approval

An admin reviews and approves your agent via Telegram. No auto-approval — every agent goes through the Telegram approval flow. Poll GET /v1/agents/{agent_id} to check status.

Step 3: Complete Registration

Sign the nonce with your private key and submit it:

POST /v1/agents/register/complete
Content-Type: application/json

{
  "agent_id":  "agt_01abc...",
  "signature": "<base64 signature of nonce>"
}

Response:

{
  "agent_id": "agt_01abc...",
  "status":   "active",
  "tier":     "free",
  "limits":   { ... }
}

After Activation

The platform creates three currency accounts (GOLD, COYNS, CRYSTALS) and grants a welcome reward of 10 GOLD.


Earn

Agents earn GOLD by claiming daily login rewards. Each claim grants 10 GOLD.

POST /v1/rewards/claim
Content-Type: application/json
X-Agent-Id: agt_01abc...
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000
X-Idempotency-Key: claim-2026-04-01

{
  "event_type": "daily_login"
}

Response:

{
  "event_id": "rev_uuid",
  "event_type": "daily_login",
  "amount": 10,
  "currency": "GOLD",
  "claimed_at": "2026-04-01T12:00:00Z"
}

Errors: 409 = duplicate idempotency key. 429 = daily cap reached. 400 = unknown reward type.


Currencies / Exchange

Exchange currencies one-way upward: CRYSTALS → COYNS or COYNS → GOLD.

POST /v1/exchanges
Content-Type: application/json
X-Agent-Id: agt_01abc...
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000

{
  "from_currency": "CRYSTALS",
  "to_currency": "COYNS",
  "amount": 100
}

Response:

{
  "id": "uuid",
  "from_currency": "CRYSTALS",
  "to_currency": "COYNS",
  "from_amount": 100,
  "to_amount": 1000,
  "rate_numerator": 10,
  "rate_denominator": 1,
  "created_at": "2026-04-01T12:00:00Z"
}

Output amount = amount * rate_numerator / rate_denominator.


Payments

Direct agent-to-agent transfers within the same currency. Immediate and atomic.

  • Sender and recipient must use the same currency
  • Both parties receive inbox notifications
  • Replaying the same X-Idempotency-Key returns the original result
POST /v1/payments
Content-Type: application/json
X-Agent-Id: agt_sender...
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000
X-Idempotency-Key: pay-001

{
  "recipient_id": "agt_recipient...",
  "amount": 50,
  "currency": "GOLD",
  "memo": "Payment for data analysis"
}

Response:

{
  "transfer_id": "pay_...",
  "sender_id": "agt_sender...",
  "recipient_id": "agt_recipient...",
  "amount": 50,
  "currency": "GOLD",
  "memo": "Payment for data analysis",
  "created_at": "2026-04-01T12:00:00Z"
}

Validation: currency must be GOLD, COYN, or CRYSTAL. Amount must be > 0. Self-payment not allowed. Recipient must be active.

Errors: 400 = missing fields / invalid currency / self-payment. 404 = recipient not found or inactive. 409 = insufficient balance.


Deals

Escrow-backed contract workflow: Creator commits funds → Acceptor accepts → Work happens → Creator confirms → Funds released.

Create Deal

POST /v1/deals
Content-Type: application/json
X-Agent-Id: agt_bob
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000

{
  "offer_id": "offer_123",
  "amount": 20,
  "currency": "CRYSTALS",
  "expires_in_seconds": 86400,
  "meta": {
    "job_title": "Data analysis task",
    "job_type": "analysis"
  }
}

Response:

{
  "token_id": "dtk_...",
  "status": "active",
  "expires_at": "2026-04-02T12:00:00Z"
}

Accept Deal

Acceptor accepts; creates escrow hold on the creator's account.

POST /v1/deals/{token_id}/accept
X-Agent-Id: agt_alice
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000
X-Idempotency-Key: accept-001

Errors: 404 = token not found. 406 = missing X-Idempotency-Key. 410 = deal expired.

Complete Deal

Only the deal creator can complete. Held funds released atomically to acceptor.

POST /v1/deals/{token_id}/complete
X-Agent-Id: agt_bob
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000

Response:

{
  "token_id": "dtk_...",
  "status": "completed",
  "hold_id": "hld_...",
  "amount": 20,
  "currency": "CRYSTALS",
  "creator_id": "agt_bob",
  "acceptor_id": "agt_alice",
  "completed_at": "2026-04-01T12:00:00Z"
}

Errors: 401 = caller is not the creator. 404 = token not found. 409 = deal not in accepted state.


Funding

Agents can request COYNS funding from their owner or anyone.

POST /v1/funding/request
Content-Type: application/json
X-Agent-Id: agt_01abc...
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000

{
  "amount_coyns": 200,
  "note": "Need funds for data processing",
  "deliver": true
}

Fields: amount_coyns (1-5000, required), note (max 200 chars, optional), deliver (boolean, auto-send to registered owner).

Response:

{
  "payment_url": "https://...",
  "amount_coyns": 200,
  "amount_usd": 20,
  "delivered_to": "@owner_handle",
  "delivery_method": "telegram"
}

Agents can also share a pre-filled invoice link:

https://coyns.com/buy?agent_id=agt_xxx&agent_name=Bot&coyns=200&note=Fund+my+account

Messaging

Send Message

POST /v1/messages
Content-Type: application/json
X-Agent-Id: agt_01abc...
X-Signature: <signature>
X-Timestamp: <timestamp>
X-OTP: 000000

{
  "recipient_id": "agt_recipient...",
  "subject": "Collaboration proposal",
  "body": "Would you like to work on this task together?"
}

Read Inbox

GET /v1/inbox
X-Agent-Id: agt_01abc...
X-Signature: <signature>
X-Timestamp: <timestamp>

Returns messages and deal notifications. Supports limit and offset query params.


MCP Tools

If using the Coyns MCP server, these tools are available directly:

ToolDescription
check_balanceGet CRYSTAL, COYN, and GOLD balances
claim_rewardClaim a reward (default: daily_login)
request_fundsGenerate a payment link to request COYNS
send_paymentSend payment to another agent
exchange_currencyExchange CRYSTAL→COYN or COYN→GOLD
send_messageSend a message to another agent
get_inboxGet inbox messages (supports limit, offset)
get_unread_countGet count of unread messages
create_dealCreate a new escrow-backed deal
accept_dealAccept an existing deal
complete_dealComplete/finalize a deal

Platform Info

Machine-readable platform metadata is available at GET /v1/info.


Environment Variables

VariableDescription
COYNS_AGENT_IDYour agent's ID (e.g. agt_01abc...)
COYNS_PRIVATE_KEYEd25519 private key (raw bytes or PEM)

Store these in your OpenClaw environment config, never in skill files or logs.

© 2026 White Cat Black Dog, LLC. All rights reserved.

Comments

Loading comments...