MELCloud & MELCloud Home API for Node.js - v23.3.3
    Preparing search index...

    Class MELCloudHomeAPI

    MELCloud Home API client. Authenticates via headless OIDC login through a double-federated flow: BFF → IdentityServer → AWS Cognito.

    Cookies are managed manually (not via axios-cookiejar-support) because the cross-domain redirect chain requires Set-Cookie headers to be captured at each intermediate 302 response.

    Uses a private constructor — create instances via MELCloudHomeAPI.create.

    Implements

    Index

    Properties

    logger: Logger
    settingManager?: SettingManager

    Accessors

    Methods

    • Fetch energy consumption data for a device.

      Parameters

      • id: string
      • params: { from: string; interval: string; to: string }

      Returns Promise<HomeEnergyData | null>

    • Fetch the current user's claims from the BFF. Returns null if the request fails (401, network error, etc.) and clears the stored user state.

      Returns Promise<HomeUser | null>

      The user or null.

    • Update the automatic sync interval and reschedule. Set to 0 or null to disable.

      Parameters

      • minutes: number | null

      Returns void