Skip to main content
A complete custom module integration brings together registry types, query extensions, and Amino converters into a single cohesive package. This page walks through the full structure for a hypothetical blog module.

Module File Structure

A well-organized module integration follows the same pattern CosmJS uses internally for its built-in modules:

End-to-End Example

Combining Multiple Modules

Real applications often integrate types from several modules. Aggregate module registrations into a single setup:
Each module follows the same structure: export xxxTypes for the registry, createXxxAminoConverters() for Amino support, and setupXxxExtension() for queries. This pattern scales cleanly regardless of how many custom modules your chain has.

Next Steps

Supporting New Chains

Configure CosmJS for a new Cosmos SDK chain with custom parameters.

Code Generation

Automate type generation with Telescope or ts-proto instead of hand-writing modules.