From product-sdk
End-to-end scaffolding and implementation of Polkadot applications using @parity/product-sdk packages. Use when: creating a new Polkadot project, building a dApp, scaffolding chain interactions, choosing which @parity/product-sdk packages to install, or when a user says "build me a Polkadot app". Handles both developer-guided and fully autonomous (non-developer) workflows.
How this skill is triggered — by the user, by Claude, or both
Slash command
/product-sdk:product-sdk-app-builderThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Orchestrator skill for building applications with the `@parity/product-sdk` package ecosystem.
Orchestrator skill for building applications with the @parity/product-sdk package ecosystem.
import { getChainAPI } from "@parity/product-sdk-chain-client";
const client = await getChainAPI("paseo");
const balance = await client.assetHub.query.System.Account.getValue("5GrwvaEF...");
client.destroy();
import { createChainClient } from "@parity/product-sdk-chain-client";
import { paseo_asset_hub } from "@parity/product-sdk-descriptors/paseo-asset-hub";
const client = await createChainClient({
chains: { assetHub: paseo_asset_hub },
});
const balance = await client.assetHub.query.System.Account.getValue("5GrwvaEF...");
client.destroy();
Determine what the app needs:
Use the decision tree in references/package-selector.md.
Every app needs:
@parity/product-sdk-chain-client # Connect to chains
@parity/product-sdk-descriptors # Chain type definitions (peer dep of chain-client)
polkadot-api # Core runtime (peer dep of descriptors)
Add based on features:
| Feature | Package | Skill |
|---|---|---|
| Smart contracts (PolkaVM/Solidity) | @parity/product-sdk-contracts | product-sdk-contracts |
| Submit transactions | @parity/product-sdk-tx | product-sdk-transactions |
| Wallet connection (Talisman, Polkadot.js, Host API) | @parity/product-sdk-signer | product-sdk-transactions |
| Key derivation | @parity/product-sdk-keys | product-sdk-transactions |
| Decentralized storage | @parity/product-sdk-cloud-storage | product-sdk-cloud-storage |
| Pub/sub messaging | @parity/product-sdk-statement-store | product-sdk-statement-store |
| Address encoding | @parity/product-sdk-address | product-sdk-utilities |
| Encryption | @parity/product-sdk-crypto | product-sdk-utilities |
| KV storage | @parity/product-sdk-local-storage | product-sdk-utilities |
| Logging | @parity/product-sdk-logger | product-sdk-utilities |
Use templates in references/project-templates.md.
mkdir my-polkadot-app && cd my-polkadot-app
npm init -y
package.json essentials:
{
"type": "module",
"dependencies": {
"@parity/product-sdk-chain-client": "latest",
"polkadot-api": "^2.0.2"
}
}
tsconfig.json essentials:
{
"compilerOptions": {
"target": "ES2022",
"module": "ESNext",
"moduleResolution": "bundler",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true,
"resolveJsonModule": true,
"isolatedModules": true,
"outDir": "./dist",
"rootDir": "./src"
},
"include": ["src"]
}
Install:
npm install
Invoke the relevant domain skill(s) based on the selected packages:
npx tsc # Compile TypeScript
node dist/index.js # Run the app
@parity/product-sdk-chain-client offers two paths for connecting to chains:
getChainAPI (Preset) | createChainClient (BYOD) | |
|---|---|---|
| When | Known environments (paseo, polkadot, kusama) | Custom chains or a subset of chains |
| Descriptors | Built-in, lazy-loaded | You import and provide them |
| Chains | Always assetHub + bulletin + individuality | Any combination you choose |
| Bundle size | Slightly larger (all 3 chains loaded) | Minimal (only what you import) |
Use getChainAPI when you want zero-config connection to a standard environment.
Use createChainClient when you need:
Both return the same ChainClient type with .raw access for advanced use (e.g., createContractRuntime).
See references/chains.md for full details.
WARNING: Only the
"paseo"environment is currently available. Using"polkadot"or"kusama"will throw an error.
| Environment | Asset Hub | Bulletin | Individuality |
|---|---|---|---|
| paseo (testnet) | Yes | Yes | Yes |
| polkadot (mainnet) | Planned | Planned | Planned |
| kusama (canary) | Planned | Planned | Planned |
polkadot-api — It's a peer dependency of @parity/product-sdk-descriptors. Always install it.@parity/product-sdk-descriptors/paseo-bulletin, NOT @parity/product-sdk-descriptors."paseo" works. "polkadot" and "kusama" throw.await — getChainAPI() and createChainClient() return a Promise. Always await it.client.destroy() or destroyAll() when done to close WebSocket connections.api.contracts — There is no .contracts property on chain clients. Create ContractRuntime yourself: createContractRuntime(client.raw.assetHub, { atBest: true }), or use ContractManager.fromClient() for convenience.createDevSigner("Alice") is testnet-only. Use SignerManager for production.PolkadotSigner (tx), StatementSignerWithKey (statement-store), and SignerManager (wallet UI) are distinct.When building autonomously for a non-technical user:
When assisting a developer:
npx claudepluginhub paritytech/product-sdk --plugin product-sdkCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.