Swig TypeScript SDK v1.0 Release Notes
The v1.0 release of the Swig TypeScript SDK represents a complete architectural overhaul designed to improve developer experience, maintainability, and extensibility.๐ Whatโs New
Modular Architecture
@swig-wallet/lib: Core business logic and functionality@swig-wallet/classic: High-level wrapper for Web3.js 1.x compatibility@swig-wallet/kit: High-level wrapper for Web3.js 2.0 (Solana Kit) compatibility@swig-wallet/coder: Low-level encoding/decoding utilities
Instruction-Based API
All functions now returnTransactionInstruction[] for better composability:
Enhanced Type Safety
- Better TypeScript support throughout the SDK
- Clearer function signatures and return types
- Improved error handling
๐ฅ Breaking Changes
Package Structure
- Core functionality moved from
@swig-wallet/classicto@swig-wallet/lib @swig-wallet/classicnow acts as a thin wrapper layer- All exports available through
@swig-wallet/classicvia re-exports
Function Signatures
| Beta Version | v1.0 Version |
|---|---|
createSwig() | getCreateSwigInstruction() |
addAuthorityInstruction() | getAddAuthorityInstructions() |
signInstruction() | getSignInstructions() |
removeAuthorityInstruction() | getRemoveAuthorityInstructions() |
Authority Creation
PDA Derivation
Dependencies
- Removed:
@solana/spl-token - Added:
@solana-program/token@^0.5.1 - Added:
@swig-wallet/lib(workspace dependency) - Added:
bn.js@^5.2.2
๐ฆ Installation
๐ Migration Guide
See the complete Migration Guide for detailed instructions on upgrading from beta versions.Quick Migration Checklist
- Update package dependencies
- Replace single instruction functions with instruction array functions
- Update authority creation from classes to info functions
- Update PDA derivation calls
- Use spread operator when adding instructions to transactions
- Test all functionality with new API
๐ Updated Documentation
- TypeScript SDK Reference - Updated for v1.0 API
- Getting Started Tutorial - Completely rewritten for v1.0
- Migration Guide - Step-by-step migration instructions
๐ Bug Fixes
- Improved error handling across all instruction builders
- Better validation of input parameters
- More consistent return types
๐ฎ Whatโs Next
- Enhanced session management
- Additional authority types
- Integration with Gill
- Performance optimizations for both Web3.js versions
๐ Resources
๐ Acknowledgments
Thank you to all beta users who provided feedback that shaped this v1.0 release. The new architecture provides a solid foundation for future development while maintaining the powerful features that make Swig unique.For questions or support, please open an issue on our GitHub repository.

