Skip to main content

Introduction

Overview

The Morpho Stack comprises a suite of SDKs designed to facilitate interaction with the Morpho and Morpho Vaults ecosystems. These SDKs are framework-agnostic and provide a robust foundation for building applications that integrate with Morpho's offchain and onchain components. The SDKs in the Morpho Stack include:

  1. blue-sdk
  2. blue-sdk-ethers
  3. blue-sdk-viem
  4. morpho-test
  5. morpho-ts

Each of these SDKs serves a specific purpose and can be used independently or together to create comprehensive solutions.

blue-sdk

The blue-sdk is the core SDK in the Morpho Stack. It provides the foundational components necessary to interact with Morpho's offchain ecosystem. This SDK is framework-agnostic, making it versatile for various applications. Key features include:

  • Market configuration management
  • Market data manipulation
  • User position management

blue-sdk-ethers

The blue-sdk-ethers extends the capabilities of the blue-sdk by integrating with the Ethers.js library. This SDK allows developers to interact with the Morpho ecosystem using an Ethers provider. Key enhancements include:

  • Fetching market configurations
  • Fetching and accruing market data
  • Managing user positions with Ethers.js

blue-sdk-viem

Similar to blue-sdk-ethers, the blue-sdk-viem extends the blue-sdk functionalities but with integration to the Viem client. This SDK is optimized for applications leveraging the Viem client for blockchain interactions. Key features include:

  • Fetching and managing market data using Viem
  • Enhanced performance for Viem-based applications
  • Consistent API with the blue-sdk for easy integration

morpho-test

The morpho-test SDK is designed for developers who need to test their applications efficiently. This SDK includes helpers to run tests using Hardhat and Jest, making it easier to set up and execute tests for Morpho and Morpho Vaults related projects. Key features include:

  • Hardhat testing utilities
  • Jest testing helpers
  • Simplified test environment setup

morpho-ts

The morpho-ts SDK provides TypeScript helpers to streamline the development of applications around Morpho and Morpho Vaults. This SDK ensures type safety and reduces the likelihood of errors in your codebase. Key features include:

  • TypeScript definitions for Morpho entities
  • Utility functions for common tasks
  • Improved developer experience with type safety

How They Are Linked

The SDKs in the Morpho Stack are designed to work seamlessly together, providing a comprehensive toolkit for developers:

  • Core Functionality: blue-sdk provides the core functionalities needed to interact with Morpho and Morpho Vaults ecosystems.
  • Extended Capabilities: blue-sdk-ethers and blue-sdk-viem extend these capabilities by integrating with specific blockchain clients (Ethers.js and Viem, respectively).
  • Testing: morpho-test complements the stack by offering testing utilities to ensure your application runs smoothly and meets the required standards.
  • Type Safety: morpho-ts enhances the development experience by providing TypeScript support, ensuring that your application is robust and type-safe.

By combining these SDKs, developers can build, test, and deploy applications that leverage the full potential of the Morpho and Morpho Vaults ecosystems with ease and efficiency.