Skip to content
This repository was archived by the owner on Sep 3, 2025. It is now read-only.
This repository was archived by the owner on Sep 3, 2025. It is now read-only.

Integrate Specific Module for Soroswap #27

Description

@celadari

Proposed Implementation:

Ideally, I envision being able to use the library as follows:

const mercury = new Mercury(...);
mercury.soroswap.getAllLiquidityPools;
mercury.soroswap.getProvidedLiquidityOperations({filters});

The above methods are just examples, but the key idea is to be able to parse specific events from Soroswap contracts seamlessly.

Additionally, considering that contract addresses may change and that other AMM should be added (Phoenix, Comet, ...), I propose the Soroswap module should adhere to the following design principles:

  1. Lazy Initialization: The Soroswap module should be lazy, meaning it doesn't need to be instantiated unless the user specifically intends to use the Soroswap functionalities.
  2. Configurable Contract Addresses: Users should have the option to specify contract addresses when instantiating the Mercury client. This adds flexibility and future-proofs the module against changes in contract addresses.
  3. Default Endpoint Utilization: If no contract addresses are provided by the user, the module should default to using standard Soroswap endpoints to retrieve the necessary information.

Motivation:

Integrating a dedicated Soroswap module into the Mercury SDK would significantly streamline the development process for projects targeting Soroswap.

I believe this addition could represent a valuable collaboration opportunity and further the SDK's adoption and utility for the Stellar/Soroban developer community.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions