Developers
SDK, REST, LangChain. Pick one.
Issue wallets, set spending policy, move USDC, get webhooks. Three lines to give an LLM agent a budgeted USDC wallet.
TypeScript SDK
Typed client. Works in Node, Bun, Deno and edge runtimes.
import { BlackSheep } from "@blacksheep/sdk";
const bs = new BlackSheep({ apiKey: process.env.BS_API_KEY! });
const agent = await bs.agents.create({
label: "research-bot",
policy: {
daily_limit_usdc: 200,
max_tx_usdc: 25,
approval_threshold_usdc: 50,
},
});
const r = await bs.agents.send(agent.id, {
to: "7xKX...recipient",
amount: 12.5,
memo: "data api invoice",
});
// → { status: "sent", signature: "5K..." }
// → { status: "pending_approval", approval_id: "..." }// LangChain — let the LLM pay, gated by policy
import { blackSheepTools } from "@blacksheep/sdk/langchain";
import { ChatOpenAI } from "@langchain/openai";
import { AgentExecutor, createToolCallingAgent }
from "langchain/agents";
const tools = blackSheepTools({
apiKey: process.env.BS_API_KEY!,
agentId: "uuid-of-the-agent-wallet",
});
const agent = await createToolCallingAgent({
llm: new ChatOpenAI({ model: "gpt-4o-mini" }),
tools,
prompt,
});
await new AgentExecutor({ agent, tools }).invoke({
input: "Pay 10 USDC to 7xKX... for the dataset",
});REST API
GET
List your agent wallets/v1/agentsPOST
Issue a new agent wallet (+ optional policy)/v1/agentsGET
Agent details, balance and policy/v1/agents/:idPOST
Send USDC — runs through policy + approvals/v1/agents/:id/sendGET
Paginated ledger of all agent activity/v1/transactionsGET
Live SOL + USDC balance for any wallet/v1/wallets/:id/balanceWebhooks
Signed with HMAC-SHA256. Slack-formatted option for one-click approvals from your ops channel.
approval.pendingPayment hit the approval threshold — human neededtx.sentPayment settled on-chaintx.blockedPayment denied by policy (cap or allowlist)approval.approvedPending approval was approved + sentapproval.rejectedPending approval was rejectedPOST https://your-app.com/hooks/blacksheep
X-BlackSheep-Event: approval.pending
X-BlackSheep-Signature: sha256=<hmac>
{
"event": "approval.pending",
"timestamp": "2026-06-02T18:24:11Z",
"data": {
"approval_id": "...",
"wallet_id": "...",
"amount": 75,
"to": "7xKX..."
}
}