{"id":46729773,"url":"https://github.com/paritytech/dotns-sdk","last_synced_at":"2026-06-11T03:01:32.452Z","repository":{"id":338257632,"uuid":"1145518155","full_name":"paritytech/dotns-sdk","owner":"paritytech","description":"A suite of tools used to interact with dotns","archived":false,"fork":false,"pushed_at":"2026-06-10T06:31:59.000Z","size":88365,"stargazers_count":6,"open_issues_count":7,"forks_count":2,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-10T08:14:51.950Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paritytech.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md ","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-29T22:10:19.000Z","updated_at":"2026-06-08T12:42:32.000Z","dependencies_parsed_at":"2026-03-09T15:01:02.988Z","dependency_job_id":null,"html_url":"https://github.com/paritytech/dotns-sdk","commit_stats":null,"previous_names":["paritytech/dotns-sdk"],"tags_count":25,"template":false,"template_full_name":null,"purl":"pkg:github/paritytech/dotns-sdk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paritytech%2Fdotns-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paritytech%2Fdotns-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paritytech%2Fdotns-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paritytech%2Fdotns-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paritytech","download_url":"https://codeload.github.com/paritytech/dotns-sdk/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paritytech%2Fdotns-sdk/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34180147,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-11T02:00:06.485Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-03-09T15:00:17.716Z","updated_at":"2026-06-11T03:01:32.440Z","avatar_url":"https://github.com/paritytech.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003e [!WARNING]\n\u003e This open source code is provided for research, experimentation, and developer education only. This code has not been audited, is actively experimental, and may contain bugs, vulnerabilities, or incomplete features. Use at your own risk.\n\n# dotns-sdk\n\nThis repository is the home for dotns developer CLIent tooling. The goal is to make DotNS interactions reproducible, auditable, and consistent across environments and languages.\n\n**DotNS** refers to the protocol. Repository, package, and binary names use lowercase (for example `dotns-sdk`, `@dotns/*`).\n\nDotNS will be accessed from multiple surfaces: scripts, command-line tools, web apps, backend services, indexers. If each surface re-implements name parsing, ABI handling, network configuration, and transaction encoding, behaviour drifts. Drift shows up as subtle incompatibilities: a name that validates in one place but not another, a call encoded differently across clients, or a release that “works” for one consumer and breaks another.\n\nThis monorepo exists to concentrate shared logic in one place, with explicit boundaries, shared primitives, and a small set of versioned artefacts that multiple runtimes can consume.\n\n## Status\n\nThis is reference and proof-of-concept tooling for the DotNS protocol, intended for reference and experimentation rather than as a production-ready artefact. Unless a specific release states otherwise, it has not received a full security audit; see [SECURITY.md](./SECURITY.md) for the security status and disclosure process. The defaults target Paseo and its Bulletin chain; point the configuration at your own network before relying on it elsewhere.\n\n## Scope\n\n**Client-side** here means off-chain code that reads and writes DotNS contracts. The repository is cross-platform:\n\n- TypeScript packages are the primary surface, using Bun workspaces under `packages/*`.\n- Rust crates may exist when they reduce duplication or provide tooling that should not depend on Node, under `crates/*` as a Cargo workspace.\n- Shared artefacts that must be consistent across languages (ABIs, deployment addresses, schemas) live in `shared/*` (for example `shared/abi/`, `shared/deployments/`, `shared/schemas/`) and are treated as the source of truth for cross-runtime consumers. The contracts themselves live in the main DotNS repository can be found [here](https://github.com/paritytech/dotns)\n\n## What belongs here\n\nExamples:\n- name parsing, normalisation, and validation\n- namehash helpers and deterministic encodings\n- contract call wrappers and typed interfaces\n- network configuration and deployment address sets\n- scripts that operate across networks (smoke tests, migrations, verification)\n- higher-level flows (register, set resolver records, set reverse, Store writes) as composable functions\n\nNon-goals:\n- the contracts themselves\n- UI code that is primarily presentation\n- one-off scripts that are not expected to be maintained\n- ad hoc protocol extensions that are not implemented in the contracts\n\n## Repository structure\n\n- `packages/*`: TypeScript packages (Bun workspace)\n- `crates/*`: Rust crates (Cargo workspace, optional)\n- `shared/*`: cross-language artefacts (ABIs, deployments, schemas)\n- `scripts/*`: repo-level scripts (fetch / generate / check)\n\nThe intent is to keep a small set of packages and crates with clear boundaries:\n- **core** modules are pure and dependency-light\n- **integration** modules talk to networks and contracts\n- **apps** (if any) compose the above but do not duplicate protocol logic\n\nThe repository may start with a single package. The structure exists to make growth predictable rather than ad hoc.\n\n## ABIs and contract releases\n\nThis repository consumes ABIs published from the DotNS contracts repository as release assets. Tooling must not depend on local build artefacts from the contracts repository.\n\nThis is required for reproducibility: a given `dotns-sdk` commit should be able to target a specific contracts release without requiring a developer to compile contracts locally or infer which artefact set is current.\n\nABIs are treated as generated inputs and must not be edited by hand. Updates must be performed by a script that fetches a specific contracts release tag and writes the results into `shared/abi/` (or a dedicated ABI package if needed). Consumers across languages must read from the same canonical ABI bundle.\n\n## Development (TypeScript)\n\nInstall dependencies:\n\n```bash\nbun install\n````\n\nRun typechecking and tests:\n\n```bash\nbun run typecheck\nbun test\n```\n\nBuild all workspace packages:\n\n```bash\nbun run build\n```\n\nIf you add repo-level scripts, keep them in `scripts/` and make them callable via the root `package.json` scripts. Prefer deterministic inputs (explicit network, explicit release tag).\n\n## Development (Rust, if present)\n\nRust crates live under `crates/*` and are built with Cargo. They should treat `shared/*` as the canonical input for ABIs and deployments and must not duplicate protocol rules in an incompatible way.\n\nTypical commands:\n\n```bash\ncargo test --workspace\ncargo build --workspace\n```\n\n## Adding a new package or crate\n\nAdd a new module only when you can state a clear boundary. **I want a new package** is not a boundary. **This code is pure name parsing and should not depend on RPC clients** is a boundary.\n\nRules of thumb:\n\n* If it can be pure, make it pure. Put it in its own package or crate with minimal dependencies.\n* Avoid circular dependencies. If two modules need shared types, extract the shared types.\n* Do not import contract JSON from arbitrary paths. Use the canonical ABI bundle under `shared/*`.\n* Keep APIs small and testable without a live chain.\n\n### TypeScript package checklist\n\n1. Create a directory under `packages/\u003cname\u003e`.\n2. Add a `package.json` with a scoped name (for example `@dotns/\u003cname\u003e`), `type: \"module\"`, and standard scripts (`build`, `test`, `typecheck` if needed).\n3. Add a local `tsconfig.json` extending the root `tsconfig.base.json`.\n4. Wire internal dependencies using `workspace:*`.\n5. Add at least one test that asserts behaviour at the boundary you are introducing.\n\nMinimal `package.json` template:\n\n```json\n{\n  \"name\": \"@dotns/\u003cname\u003e\",\n  \"version\": \"0.1.0\",\n  \"type\": \"module\",\n  \"exports\": {\n    \".\": \"./dist/index.js\"\n  },\n  \"types\": \"./dist/index.d.ts\",\n  \"scripts\": {\n    \"build\": \"bunx tsc -p tsconfig.json\",\n    \"test\": \"bun test\"\n  }\n}\n```\n\nThen run:\n\n```bash\nbun install\nbun run build\nbun test\n```\n\n### Rust crate checklist (if adding Rust)\n\n1. Create `crates/\u003cname\u003e` and add it to the Cargo workspace.\n2. Keep dependencies minimal and avoid embedding network assumptions that belong in `shared/*`.\n3. Prefer consuming ABIs and deployments from `shared/*` rather than copying them.\n4. Add unit tests for parsing, encoding, and invariants.\n\n## Quality bar\n\nThis repository exists to reduce protocol drift, not to create a new source of drift.\n\nPrefer:\n\n* Deterministic behaviour over convenience defaults\n* Explicit inputs over environment magic\n* Small modules with tests over large **kitchen sink** helpers\n* Changes accompanied by invariant-style tests, especially when touching name parsing, hashing, or transaction encoding\n\nIf a change alters how a name is interpreted or how a transaction is encoded, treat it like a consensus change for clients: document it, test it, and assume downstream consumers will break if it is ambiguous.\n\n## Security\n\nBefore deploying it for real use cases, you are responsible for:\n\n- Reviewing the code yourself, we publish a reference, not a hardened production build\n- Checking that the dependencies are up to date and free of known vulnerabilities\n- Securing your own fork or deployment environment (keys, secrets, network configuration)\n- Tracking the latest tagged release/commits for security fixes; older releases are not backported (exceptions might apply)\n\nFor Parity's security disclosure process, and Bug Bounty program, feel free to visit:  https://parity.io/bug-bounty\n\n## License\n\nLicensed under the MIT License. See [LICENSE](./LICENSE). Security policy and disclosure: see [SECURITY.md](./SECURITY.md).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparitytech%2Fdotns-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparitytech%2Fdotns-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparitytech%2Fdotns-sdk/lists"}