ts-sdk-transactions

ts-sdk-transactions is a skill for Claude Code from aptos-labs/aptos-agent-skills. It costs 94 tokens per session (1,616 once invoked), scanned A, original, MIT.

A guide to creating, signing, submitting, simulating, and confirming transactions on the Aptos blockchain with its TypeScript SDK.

In plain words
What is it for?
Use it to build Aptos entry-function transactions, test important transactions before submission, handle fee-sponsored or multi-agent transactions, and wait for confirmation.
Why use it?
It helps prevent transactions from being treated as complete before the network commits them, and avoids common type and signing errors.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the aptos-agent-skills plugin — 16 skills shipped together

Good fit Use it to build Aptos entry-function transactions, test important transactions before submission, handle fee-sponsored or multi-agent transactions, and wait for confirmation.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add aptos-labs/aptos-agent-skills --skill ts-sdk-transactions
Clone the repo
git clone --depth 1 https://github.com/aptos-labs/aptos-agent-skills

Made for: Claude Code.

Or install aptos-agent-skills, the plugin that ships this one along with the rest of its 16 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ts-sdk-transactions

README.md
[![agentmods](https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions/github.svg)](https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions)
Your own site
<a href="https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions"><img src="https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ts-sdk-transactions

Your own site · 80×15
<a href="https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions"><img src="https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-transactions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 94 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,616 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00094 $0.01616
Opus 5 $0.00047 $0.00808
Sonnet 5 $0.00019 $0.00323
Haiku 4.5 $0.00009 $0.00162

Measured 11d ago against content hash 91b2de8184e3, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

ts-sdk-transactions scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/sdk/typescript/ts-sdk-transactions/SKILL.md · 239 lines

How it starts

The opening of the file, as written. The whole thing — 239 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TypeScript SDK: Transactions

Purpose

Guide building, signing, submitting, and simulating transactions with @aptos-labs/ts-sdk. Use the build → sign → submit → wait pattern; optionally simulate before submit.

ALWAYS

  1. Call aptos.waitForTransaction({ transactionHash }) after submit – do not assume transaction is committed after signAndSubmitTransaction.
  2. Use aptos.transaction.build.simple() for entry function payloads – pass sender and data: { function, functionArguments, typeArguments? }.
  3. Simulate before submit for critical/high-value flows – use aptos.transaction.simulate.simple() and check success and vm_status.
  4. Use the same Account instance for signer that you use for sender address when building (e.g. account.accountAddress as sender, account as signer).

NEVER

  1. Do not skip waitForTransaction – submission returns when the tx is accepted, not when it is committed.
  2. Do not use deprecated scriptComposer (removed in v6) – use separate transactions or batch patterns.
  3. Do not use number for u64/u128/u256 in functionArguments – use bigint where required to avoid precision loss.

Standard flow (simple transaction)

import { Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk";

const aptos = new Aptos(new AptosConfig({ network: Network.TESTNET }));
const MODULE_ADDRESS = "0x...";

// 1. Build
const transaction = await aptos.transaction.build.simple({
  sender: account.accountAddress,
  data: {
    function: `${MODULE_ADDRESS}::counter::increment`,
    functionArguments: []
  }
});

// 2. Sign and submit
const pendingTx = await aptos.signAndSubmitTransaction({
  signer: account,
  transaction
});

// 3. Wait for commitment
const committedTx = await aptos.waitForTransaction({
  transactionHash: pendingTx.hash
});

if (!committedTx.success) {
  throw new Error(`Tx failed: ${committedTx.vm_status}`);
}

Build options

// With type arguments (e.g. coin type)
const transaction = await aptos.transaction.build.simple({
  sender: account.accountAddress,
  data: {
    function: "0x1::coin::transfer",
    typeArguments: ["0x1::aptos_coin::AptosCoin"],
    functionArguments: [recipientAddress, amount]
  }
});

// Optional: max gas, expiry, etc. (see SDK types for full options)
const transactionWithOptions = await aptos.transaction.build.simple({
  sender: account.accountAddress,
  data: { function: "...", functionArguments: [] },
  options: {
    maxGasAmount: 2000n,
    gasUnitPrice: 100n,
    expireTimestamp: BigInt(Math.floor(Date.now() / 1000) + 600)
  }
});

Read the full file on GitHub · 239 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 239 lines · 94 tokens per session scan A 91b2de8184e3

Subscribe to this mod's changes

ts-sdk-transactions is a skill published in the GitHub repository aptos-labs/aptos-agent-skills (19 stars, last pushed 2mo ago), licensed MIT. It adds 94 tokens to every session and 1,616 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

bnb-chain-toolkit-guide

Guide to the BNB Chain Toolkit — a modular TypeScript toolkit for building, deploying, and interacting with smart contracts on BNB Chain. Includes BEP-20 token utilities, DeFi integrations, wallet management, and cross-chain bridging. Built for BNB Chain Hackathon by the Sperax team.

nirholas/three.ws · 67 tokens

solana-toolkit-guide

Guide to the Solana Wallet Toolkit — vanity address generation with multi-threaded search, official Solana Labs libraries, Rust and TypeScript implementations. Includes wallet generation, custom address prefixes, and OG names on the blockchain.

nirholas/three.ws · 50 tokens

starknet-js

Use when writing or debugging JavaScript/TypeScript that interacts with Starknet through the starknet.js SDK — building Call objects or calldata, encoding/decoding Cairo types (felt252, u256, structs, arrays, spans, ByteArray, Option/Result/custom enums), or working with contracts, accounts, providers, transactions…

starknet-io/starknet.js · 79 tokens

adding-personhog-rpc

Guide for adding a new RPC to personhog-replica and personhog-router. Covers eligibility checks, proto definition, code generation for Python and Node.js clients, Rust implementation (storage trait, postgres queries, service handler, router wiring), and index compatibility validation. Use when adding a new gRPC…

PostHog/posthog · 88 tokens

viem-integration

Integrate EVM blockchains using viem. Use when user says "read blockchain data", "send transaction", "interact with smart contract", "connect to Ethereum", "use viem", "use wagmi", "wallet integration", "viem setup", or mentions blockchain/EVM development with TypeScript.

Uniswap/uniswap-ai · 69 tokens

wallet-cli

Operate the TypeScript TRON wallet CLI for accounts, transfers, staking, governance, contracts, signing, chain queries, and password input with wallet-cli 4.13.0. Refuse wallet passwords in argv and require the supported stdin channel. For Java REPL requests, refuse that entry and offer the TypeScript one-shot CLI…

BofAI/skills · 82 tokens