darksol-random-oracle
Bankr-compatible skill for DARKSOL Random Oracle, an on-chain verifiable RNG API on Base. Use when an agent needs random numbers, coin flips, dice rolls, random sequences, shuffles, raffles, loot drops, games, simulations, casino mechanics, or auditable randomness. Supports DARKSOL holder free access and x402 USDC payments on Base.
- License 许可
- AGPL-3.0
- 最近更新
- 2026-11-15
- Stars
- ★ 81
- Forks
- 17
01 前言 Front Matter
- name
- darksol-random-oracle
- metadata
- { "bankr": { "chains": [ "base" ], "apiBase": "https://acp.darksol.net/oracle", "payment": "x402-usdc-base", "category": "oracle", "homepage": "https://acp.darksol.net/oracle" }, "openclaw": { "emoji": "?" } }
- description
- Bankr-compatible skill for DARKSOL Random Oracle, an on-chain verifiable RNG API on Base. Use when an agent needs random numbers, coin flips, dice rolls, random sequences, shuffles, raffles, loot drops, games, simulations, casino mechanics, or auditable randomness. Supports DARKSOL holder free access and x402 USDC payments on Base.
02 资源文件 3
- 参考文档catalog.json1.3 KB
- 参考文档SOURCE.md331 B
- 参考文档TRUST.auto.yaml2.1 KB
03 SKILL.md 正文
DARKSOL Random Oracle
On-chain verifiable randomness for agents, games, raffles, simulations, and apps.
Bankr can use this skill when a user asks for fair random numbers, coin flips, dice rolls, shuffles, giveaway winners, loot outcomes, or any randomness that should be publicly auditable.
Service
- UI:
https://acp.darksol.net/oracle - API base:
https://acp.darksol.net/oracle - Chain: Base
8453 - Oracle contract:
0x4d2f471ae67b129bAda9cfC6224f0343c5C8fB5D - DARKSOL token:
0x00cb1fbca324d51325a7264d54072bc073c28ba3 - x402 payment token: USDC on Base
0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 - x402 pay-to:
0x8f9fa2bfd50079c1767d63effbfe642216bfcb01
When To Use
Use this skill for:
- coin flips
- dice rolls
- random integers
- random sequences
- shuffling a list
- raffle or giveaway winner selection
- loot tables and game outcomes
- simulation seeds
- casino/game mechanics that need verifiable RNG
- agent workflows that need proof-backed randomness with a Base transaction receipt
Do not use this skill for private key generation, wallet seed generation, passwords, cryptographic nonces, or secrets. The oracle returns public verifiable randomness, not private entropy.
Access Model
DARKSOL Holder Free Access
If the caller controls a wallet holding at least 10,000,000 DARKSOL on Base, calls are free.
The caller signs this exact message, replacing the wallet address:
DARKSOL Oracle free access
Wallet: 0xYourAgentWallet
Chain: Base (8453)
Purpose: prove token-holder access without payment
Send the proof headers:
x-darksol-wallet: 0xYourAgentWallet
x-darksol-signature: 0xSignature
x402 Paid Access
Without a valid holder proof, oracle endpoints require x402 payment:
- basic endpoints:
$0.05USDC on Base - premium endpoints:
$0.25USDC on Base
A normal unauthenticated request returns HTTP 402 with payment requirements. Pay using an x402-compatible client, then retry with the x402 payment header.
Endpoints
Health
GET https://acp.darksol.net/oracle/health
Returns health, contract, block number, pricing, and free-access details.
Random Number
GET https://acp.darksol.net/oracle/random/number?min=1&max=100
Params:
min: integer, default1max: integer, default10
Price: $0.05 or free for eligible DARKSOL holders.
Coin Flip
GET https://acp.darksol.net/oracle/random/coin
Returns heads or tails.
Price: $0.05 or free for eligible DARKSOL holders.
Dice Roll
GET https://acp.darksol.net/oracle/random/dice?sides=20&count=3
Params:
sides: integer2..1000, default6count: integer1..100, default2
Price: $0.05 or free for eligible DARKSOL holders.
Random Sequence
GET https://acp.darksol.net/oracle/random/sequence?count=6&min=1&max=49
Params:
count: integer1..100, default5min: integer, default1max: integer, default50
Price: $0.25 or free for eligible DARKSOL holders.
Shuffle
GET https://acp.darksol.net/oracle/random/shuffle?items=alice,bob,carol,dave
Params:
items: comma-separated list with at least 2 items
Price: $0.25 or free for eligible DARKSOL holders.
Response Shape
{
"result": 77,
"access": {
"mode": "x402_settled",
"paymentRequired": true
},
"proof": {
"txHash": "0x...",
"blockNumber": 45168397,
"contract": "0x4d2f471ae67b129bAda9cfC6224f0343c5C8fB5D",
"chain": "base",
"chainId": 8453
},
"timestamp": "2026-04-25T14:09:01.905Z"
}
Always surface the proof.txHash when reporting results to a user. That is the audit trail.
If the endpoint returns HTTP 202 with status: "pending", payment has settled but oracle confirmation exceeded the request window. Surface access.payment.transaction as the payment proof and pending.txHash as the oracle tx to check/retry shortly. Do not submit another payment just because the oracle response is pending.
Bankr Prompt Examples
Use DARKSOL Random Oracle to roll 3 d20 dice and show me the Base proof tx.
Use DARKSOL Random Oracle to pick a giveaway winner from alice,bob,carol,dave. Return the shuffled list and proof hash.
Use DARKSOL Random Oracle to generate 6 lottery numbers from 1 to 49 and include the on-chain verification link.
Flip a verifiable coin using DARKSOL Random Oracle.
Agent Procedure
- Parse the user request into one endpoint and query params.
- Prefer holder-free access if the user provides a wallet and signature.
- Otherwise use x402 USDC payment on Base.
- Call the endpoint.
- Return the result plus the proof transaction link:
https://basescan.org/tx/<txHash> - If the endpoint returns HTTP 402, complete the x402 payment flow and retry.
- If the endpoint returns HTTP 202/status pending, report the payment tx and pending oracle tx; do not pay again.
Curl Examples
curl https://acp.darksol.net/oracle/health
curl "https://acp.darksol.net/oracle/random/number?min=1&max=100"
curl "https://acp.darksol.net/oracle/random/dice?sides=20&count=3"
curl "https://acp.darksol.net/oracle/random/shuffle?items=alice,bob,carol,dave"
Safety Notes
- Results are public and verifiable. Do not use for secrets.
- For regulated gambling, check jurisdictional requirements before use.
- For fairness-sensitive apps, store the returned proof tx with the application record.
Built with teeth. ?
04 同仓库更多 Skills
troves
Deposit and withdraw from Troves DeFi yield vault strategies on Starknet. View available strategies, check positions, and manage vault deposits. Use this skill when the user mentions Troves, vault, yield vault, DeFi vault, strategy, yield farming, vault deposit, vault withdraw, earning yield through vaults, passive yield strategies, or wants to deposit into or withdraw from a yield strategy — even if they don't say "Troves" explicitly.
trade
Swap tokens on Starknet via Fibrous DEX aggregator. Supports per-provider selection (avnu, ekubo, or auto to race all). Use this skill when the user wants to swap, exchange, trade, convert, buy, or sell one token for another on Starknet. Also use when the user asks about token prices, exchange rates, DEX routing, best swap route, or wants to check how much they would receive for a given amount — even if they don't explicitly say "swap".
staking
Stake, unstake, claim, and compound rewards for STRK, WBTC, tBTC, SolvBTC, and LBTC on Starknet. View validators, pools, and staking positions. Use this skill when the user mentions staking, delegating, validators, staking pools, rewards, compounding, unstaking, earning yield, passive income on crypto, or wants to earn on their STRK or BTC tokens — even if they don't say "stake" explicitly.
send
Send STRK, ETH, or any ERC-20 token to a Starknet address. Supports simulation (dry-run) before execution. Use this skill when the user wants to send, transfer, pay, tip, or move tokens to another wallet address on Starknet. Also trigger when the user mentions sending funds to someone, making a payment, transferring assets, or moving crypto to a specific address — even if they just say "pay 10 STRK to 0x...".
portfolio
View a comprehensive DeFi portfolio dashboard and optimize portfolio allocation via automated rebalancing. Use this skill when the user wants an overview, summary, dashboard, total value, net worth, portfolio rebalancing, target allocation, or wants to see all their DeFi positions across Starknet at once. Also trigger when the user asks "what do I have", "show me everything", "how much am I worth", "my positions", "my investments", "rebalance my portfolio", "I want 50% ETH", "optimize my holdings", or any request for a holistic view of their Starknet holdings — even if they don't explicitly say "portfolio".
multi-swap
Execute multiple token swaps in a single Starknet transaction via Fibrous (default). Supports per-provider selection (avnu, ekubo, or auto to race all). Supports 2-3 swap pairs bundled into one multicall. Use this skill when the user wants to swap multiple token pairs at once, do batch swaps, execute several trades simultaneously, perform parallel swaps, or do bulk trading in one transaction. Also trigger when the user mentions "two swaps", "three swaps", "swap X and Y at the same time", or wants to convert multiple tokens in a single call.