Gainium icon

Gainium

Operates with official Gainium API

Overview

This node operation allows you to clone an existing DCA (Dollar-Cost Averaging) bot on the Gainium platform by creating a new bot with customized settings. It is useful when you want to replicate a bot's configuration but modify certain parameters without starting from scratch.

Typical use cases include:

  • Quickly duplicating a successful DCA bot strategy with slight adjustments.
  • Creating multiple bots with similar base configurations for different trading pairs or risk profiles.
  • Experimenting with variations of a bot’s settings while preserving the original.

For example, you might clone a DCA bot that trades BTC_USDT and adjust the order size or take profit percentage in the cloned version.

Properties

Name Meaning
Bot Id The unique identifier of the existing DCA bot you want to clone. This is required to specify which bot to duplicate.
Bot Settings JSON object defining the settings for the new cloned bot. This includes all configurable parameters such as name, trading pairs, order counts, take profit and stop loss percentages, risk reduction options, cooldowns, multi TP/SL, DCA steps, and more. Refer to Gainium API documentation for full schema details.
Paper Trading Boolean flag indicating whether the cloned bot should operate in paper trading mode (simulated trading) or real trading mode.

Output

The node outputs a JSON object containing the response data from the Gainium API after cloning the DCA bot. This typically includes details about the newly created bot instance, such as its ID, status, and applied settings.

No binary data output is involved.

Dependencies

  • Requires an API key credential for authenticating requests to the Gainium API.
  • The node uses HMAC SHA-256 signing for request authentication.
  • Network access to the Gainium API endpoint specified in the credentials is necessary.

Troubleshooting

  • Common issues:

    • Invalid or missing Bot Id will cause the API call to fail.
    • Malformed JSON in the "Bot Settings" property can lead to parsing errors.
    • Insufficient API permissions (write access) will prevent cloning operations.
    • Network connectivity problems or incorrect API base URL may cause request failures.
  • Error messages:

    • Error: <reason> — Indicates an error returned by the Gainium API; check the reason message for specifics.
    • HMAC generation failed: Web Crypto API not available — Occurs if the environment does not support the required cryptographic functions; ensure running in a compatible environment.
    • Invalid JSON in filterModel — If using filters elsewhere, indicates malformed JSON input.
  • Resolutions:

    • Verify the Bot Id is correct and corresponds to an existing DCA bot.
    • Validate the JSON structure of Bot Settings before input.
    • Ensure the API key has write permissions enabled.
    • Confirm network connectivity and correct API base URL configuration.

Links and References

Discussion