ts-sdk-address

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

A reference for creating, validating, comparing, and deriving Aptos account addresses in the Aptos TypeScript SDK. An account address is the identifier of a blockchain account, and derived addresses identify related objects or resources.

In plain words
What is it for?
Use it when TypeScript code parses Aptos addresses, needs strict address formatting, compares accounts, or calculates object, resource, token, or user-derived addresses.
Why use it?
It prevents malformed addresses, inconsistent comparisons, and hand-written derivation logic that could produce the wrong blockchain identifier.

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 when TypeScript code parses Aptos addresses, needs strict address formatting, compares accounts, or calculates object, resource, token, or user-derived addresses.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aptos-labs/aptos-agent-skills/ts-sdk-address
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-address
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-address

README.md
[![agentmods](https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-address/github.svg)](https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-address)
Your own site
<a href="https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-address"><img src="https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-address/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-address

Your own site · 80×15
<a href="https://agentmods.dev/skills/aptos-labs/aptos-agent-skills/ts-sdk-address"><img src="https://agentmods.dev/badge/skills/aptos-labs/aptos-agent-skills/ts-sdk-address.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 95 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,897 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.00095 $0.01897
Opus 5 $0.00048 $0.00949
Sonnet 5 $0.00019 $0.00379
Haiku 4.5 $0.00010 $0.00190

Measured 11d ago against content hash a961529aef08, 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-address 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-address/SKILL.md · 211 lines

How it starts

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

TypeScript SDK: AccountAddress

Purpose

Guide correct creation, parsing, and formatting of account addresses in @aptos-labs/ts-sdk. Addresses are 32-byte values; string format follows AIP-40.

ALWAYS

  1. Use AccountAddress.from() for flexible input – accepts string (with or without 0x), Uint8Array, or existing AccountAddress.
  2. Use addresses as AccountAddress or string in API – SDK accepts AccountAddressInput (string or AccountAddress) in most APIs.
  3. Use AccountAddress.fromStringStrict() / AccountAddress.fromStrict() when you need AIP-40 strict: LONG (0x + 64 hex chars) or SHORT only for special (0x0–0xf).
  4. Use derived address helpers from the SDK for object/resource/token addresses – do not hand-roll hashing.

NEVER

  1. Do not use raw strings for comparison – use addr.equals(other) or normalize with AccountAddress.from().
  2. Do not assume SHORT form for non-special addresses – non-special addresses must be LONG (64 hex chars) in strict mode.
  3. Do not use the Hex class for account addresses – use AccountAddress only (per SDK docs).

Address format (AIP-40)

  • Length: 32 bytes (64 hex chars in LONG form).
  • String: Must start with 0x. LONG = 0x + 64 hex chars; SHORT = shortest form (e.g. 0x1, 0xf).
  • Special addresses: 0x00xf (last byte < 16, rest zero). These may be written in SHORT form (0x1, 0xa).
  • Reference: AIP-40.

Creating AccountAddress

From string (recommended: relaxed)

import { AccountAddress } from "@aptos-labs/ts-sdk";

// Relaxed: accepts with or without 0x, SHORT or LONG
const addr1 = AccountAddress.from("0x1");
const addr2 = AccountAddress.from("0xaa86fe99004361f747f91342ca13c426ca0cccb0c1217677180c9493bad6ef0c");
const addr3 = AccountAddress.from("1"); // no 0x ok

From string (strict AIP-40)

// Strict: LONG (0x + 64 chars) or SHORT only for special (0x0–0xf)
const addrStrict = AccountAddress.fromStringStrict(
  "0x0000000000000000000000000000000000000000000000000000000000000001"
);
// Or use fromStrict for any AccountAddressInput
const a = AccountAddress.fromStrict("0x1"); // ok: special address in SHORT form

Read the full file on GitHub · 211 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 · 211 lines · 95 tokens per session scan A a961529aef08

Subscribe to this mod's changes

ts-sdk-address is a skill published in the GitHub repository aptos-labs/aptos-agent-skills (19 stars, last pushed 2mo ago), licensed MIT. It adds 95 tokens to every session and 1,897 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