Ship Steem Apps Faster: Meet @steempro/sds-api, the Typed Client SDS

in Steem Dev • yesterday

Introducing @steempro/sds-api — A Fully Typed TypeScript Client for the Steem SDS API

Today I'm publishing @steempro/sds-api — a JavaScript/TypeScript client for the Steem Blockchain Data Services (SDS) REST API.

sds-api.jpg

SDS exposes the entire Steem API surface — accounts, posts, history, rewards, RocksDB queries and more — as plain REST routes, but its parameters and column-based responses are easy to misuse. This package wraps 22 modules and 285 methods with types generated directly from the live API reference.

Highlights

  • Parameter autocomplete — write fields: [' and your editor suggests every allowed value (name, json_metadata, reputation, …). Typos become compile-time errors that mirror the runtime's allow-list validation.
  • Smart timestamps — pass a Date, a date string, or unix seconds; values are converted automatically before the request.
  • Response mapping — SDS answers with { cols, rows } tables; one mapSds() call turns them into plain objects.
  • Structured errors — SDSValidationError, SDSNetworkError, SDSApiError, … each with a stable code plus the failing module, method and URL.
  • Flexible runtime — promise or callback style, custom SDS instances, retries, ESM + CommonJS builds, zero runtime dependencies.

Quick start

npm i @steempro/sds-api
import { SDS, mapSds } from "@steempro/sds-api";

const sds = new SDS();

const rows = mapSds(
  await sds.accounts.getAccount("faisalamin", ["name", "reputation"]),
);

star.jpg

Links

MIT licensed — issues and PRs welcome!

Sort:  
 5 hours ago 

Congratulations!

Your post has been selected and upvoted by the SteemPro Team 🚀

Explore more on SteemPro:
🌐 https://www.steempro.com
🎮 Play SteemHeights: https://www.steempro.com/games/steem-heights
💬 Join our Discord: https://discord.gg/Bsf98vMg6U

💪 Supporting the growth of the Steem ecosystem together.

🟩 Vote for witness faisalamin:
https://steemitwallet.com/~witnesses
https://www.steempro.com/witnesses#faisalamin

steempro-cover-black.png
This is an automated message.