richiey1-stacks-helpers-types
v1.0.1
Published
Type definitions, constants, and network configs for Stacks L2 development
Downloads
1,698
Maintainers
Readme
richiey1-stacks-helpers-types
Type definitions, network configs, and SIP standard constants for Stacks L2 development.
Install
npm install richiey1-stacks-helpers-typesUsage
import { MAINNET, TESTNET, API_URLS, CHAIN_IDS, SIP010_TRAIT } from "richiey1-stacks-helpers-types";
import type { ContractCallOptions, WalletAccount, BatchResult } from "richiey1-stacks-helpers-types";
// Use network configs
const apiUrl = API_URLS.mainnet; // "https://api.hiro.so"
const network = MAINNET;
// Use SIP trait constants
const trait = SIP010_TRAIT;Exports
Networks
MAINNET— Mainnet network configTESTNET— Testnet network configAPI_URLS—{ mainnet: "https://api.hiro.so", testnet: "https://api.testnet.hiro.so" }CHAIN_IDS—{ mainnet: 1, testnet: 2147483648 }
SIP Standards
SIP010_TRAIT— SIP-010 fungible token trait addressSIP009_TRAIT— SIP-009 NFT trait addressSIP013_TRAIT— SIP-013 semi-fungible token trait addressCLARITY_TYPE_IDS— Clarity value type identifiers
Types
ContractCallOptions— Options for contract callsReadOnlyOptions— Options for read-only callsWalletAccount—{ address, privateKey, index }FundTransfer—{ recipient, amount }BatchResult—{ txid, success, error }NonceInfo—{ nonce, balance, locked }NetworkName—"mainnet" | "testnet"
License
MIT
Author
Richiey1
