Voltaire Effect Schemas & Branded Types

Decode and validate Ethereum data into branded Uint8Array types in TypeScript using Voltaire primitives and Effect Schema workflows.

Updated Feb 6, 2026
One-click install
npx skills add https://github.com/cyotee/voltaire-skill --skill voltaire-effect-schemas-branded-types
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Voltaire Effect Schemas & Branded Types
Source: https://github.com/cyotee/voltaire-skill/tree/main/.opencode/skills/voltaire-effect-schemas
Command: npx skills add https://github.com/cyotee/voltaire-skill --skill voltaire-effect-schemas-branded-types

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Branded schemas provide compile-time type safety for Ethereum data by decoding raw inputs into distinct branded Uint8Array types, eliminating confusion between addresses, hashes, and other primitives.

Core Features & Use Cases

  • Branded types: distinct AddressType, HashType at the type level for safer code.
  • Decode/encode utilities: boundary validation with ParseError support.
  • Interoperability: works with Voltaire primitives and Effect Schema workflows in TypeScript.

Quick Start

Decode inputs with Address.Hex and Hash.Hex to obtain branded types ready for safe Ethereum workflows.

Frequently Asked Questions about Voltaire Effect Schemas & Branded Types

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I prevent type confusion between Ethereum addresses and hashes in TypeScript?

Branded types prevent type confusion by decoding raw Ethereum inputs into distinct AddressType and HashType at the type level. This ensures compile-time safety, stopping invalid assignments between addresses, hashes, and primitives.

How do I decode Ethereum data into branded types using Effect Schema?

Decode Ethereum data into branded types using Address.Hex and Hash.Hex utilities. These prebuilt schemas validate raw inputs and output distinct branded Uint8Array types, ensuring strict type safety across boundary layers.

Do I need TypeScript 5.x and Effect 3.x to use branded schemas for Ethereum data?

Yes, you need TypeScript 5.x and Effect 3.x. Branded schemas for Ethereum data also require Voltaire primitives to decode inputs and enforce strict type safety across boundary layers in your workflow.

What's the best way to handle ParseError when decoding Ethereum addresses?

Handle ParseError during Ethereum address decoding using built-in decode utilities. These utilities validate inputs against prebuilt schemas, returning branded types or a ParseError to guarantee runtime safety.

Can I use Voltaire branded types for Ethereum data validation in both frontend and backend workflows?

Yes, Voltaire branded types support Ethereum data validation in both frontend and backend TypeScript workflows. They decode addresses, hashes, and signatures into distinct types for strict boundary layer safety.

Why does decoding Ethereum hashes with branded schemas prevent runtime errors?

Decoding Ethereum hashes with branded schemas prevents runtime errors by enforcing compile-time type safety. Distinct branded Uint8Array types eliminate type confusion, while ParseError handling guarantees runtime validation safety.