Agent Skill Definitions, Reference Docs, and Payment Guidance for TDM DaOS
Agent skill definitions, contract reference docs, and payment guidance for TDM DaOS (Decentralized Agent Operating System).
Documentation • API Reference • GitHub • X/Twitter
████████╗ ██████╗ ███╗ ███╗ ╚══██╔══╝ ██╔══██╗ ████╗ ████║ ██║ ██║ ██║ ██╔████╔██║ ██║ ██║ ██║ ██║╚██╔╝██║ ██║ ██████╔╝ ██║ ╚═╝ ██║ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ TDM DaOS Agent [V0.1.0] DaOS Agent Guidance + Skills + References Mode: local-first | Docs: todealmarket.com/docs
Agent guidance repository for TDM DaOS. This is not a package to install -- it is a collection of skill definitions, reference docs, and utility scripts that teach AI agents how to work with the TDM payment and agent runtime system.
What it provides:
SKILL.md-- agent skill definition for Claude, GPT-4, and other AI runtimesreferences/-- detailed contract docs (authorize API, MCP runtime, sweep capabilities, vault scenarios)scripts/-- utility scripts for price lookups and sweep execution
What it is not:
- Not the TDM SDK (use
npm install -g tdm-sdk) - Not a runnable application
- Not a separate package operators need to install
npm install -g tdm-sdk
tdm connectThen configure your agent with the skill definition in SKILL.md or agents/openai.yaml.
|
|
|
|
tdm connect # One-time wallet + gateway setup
tdm login --gateway <url> --api-key <k> # Manual headless setuptdm fuel --amount 5 --yes # Top up Session Gas Tank
tdm fuel --amount 10 --session-id <id> # Fund specific sessiontdm sweep --network solana --resume-burner --deposit-address <addr>
tdm sweep statustdm cashout # Withdraw earned revenuetdm vault create photos --use # Named vault for isolation
tdm agent list # List agents
tdm agent spawn worker-1 --type DISCRETE --limit 5
tdm agent boot worker-1 # Issue session tokentdm allowlist add api.example.com --scope vault --vault photos --verified
tdm allowlist check https://api.example.com/private/route --vault photossequenceDiagram
participant Agent as Agent Runtime
participant SDK as TDM SDK
participant Payment as TDM Payment Surface
participant User as User
Agent->>SDK: Call protected operation
SDK->>Payment: Check whether the request can proceed
Payment-->>SDK: Top-up needed
SDK-->>Agent: Payment required
Agent->>User: "Suggest: tdm fuel --amount 5"
User->>User: Run tdm fuel
User-->>Agent: Ready
Agent->>SDK: Retry operation
SDK->>Payment: Check again
Payment-->>SDK: Access approved
SDK-->>Agent: Success
import { createFetchHookClient, makePayable, LocalPaymentRequiredError } from 'tdm-sdk';
const hooks = createFetchHookClient({
baseUrl: 'https://tdm.todealmarket.com',
apiKey: 'your-api-key'
});
const payableFunction = makePayable(
async (input: string) => {
return `Tool result: ${input}`;
},
{
operation: 'agent:tool-call',
tokenOrUuid: 'user-123',
hooks
}
);
try {
await payableFunction('hello');
} catch (error) {
if (error instanceof LocalPaymentRequiredError && error.statusCode === 402) {
// Suggest: tdm fuel --amount 5
}
}A prepaid budget for agent workflows:
- Operator funds with
tdm fuel - Agent gets a session token via
tdm agent boot <name> - Paid requests go through
POST /authorize - Spending enforced by the Session Gas Tank contract
| Sweep (Recovery) | Cashout (Seller Payout) | |
|---|---|---|
| Purpose | Convert dust to stablecoin | Withdraw earned revenue |
| Who | User-initiated | Seller-initiated |
| Command | tdm sweep |
tdm cashout |
| Networks | Solana, Base | Solana |
Keep them separate. Sweep recovers small balances; cashout withdraws revenue.
The public tdm-sdk surface around this contract:
| Export | Purpose |
|---|---|
makePayable() |
Wrap any function with payment hooks |
createFetchHookClient() |
Live gateway authorize + telemetry |
createGatewayClients() |
Composed client: authorize + sessionTanks + checkout |
createSessionTanksClient() |
Session gas tank management |
createCheckoutClient() |
Buyer-facing checkout |
LocalPaymentRequiredError |
402 error with retry-after, balance, payment options |
tdm-daos-agent/
├── README.md ← You are here
├── SKILL.md ← Agent skill definition (primary artifact)
├── agents/
│ └── openai.yaml ← OpenAI agent configuration
├── references/
│ ├── authorize-contract.md ← /authorize API contract
│ ├── mcp-runtime.md ← MCP integration guide
│ ├── sdk-sweep-capabilities.md ← Sweep flow documentation
│ ├── vault-scenarios.md ← Vault usage scenarios
│ └── adaptation-map.md ← SDK adaptation guide
└── scripts/
├── fetch_x402_price.mjs ← Price lookup utility
└── run_tdm_sweep.mjs ← Sweep execution script
- No private keys in this repo -- this is guidance only
- OS keyring required -- CLI stores keys securely
- Session tokens expire -- short-lived by design
- Review local automations carefully -- especially when using advanced signer flows
MIT License - see LICENSE for details
Built by the TDM team
Website • Documentation • GitHub • X/Twitter