DocumentationLedger LiveExchange providerBuy IntegrationArchitecture

Overview

The integration process ensures a seamless flow of data between Ledger Live, Ledger Backend, and the provider’s systems. Providers are expected to implement specific endpoints and adhere to the following workflow to support the Buy feature in Ledger Live.

Workflow Diagram

Step 1: Open Buy App

Action: The user opens the Buy App in Ledger Live.

Ledger Live:
  • Fetches capabilities data from the Ledger Backend, which caches responses from the provider’s /capabilities endpoint.

  • Fetches supported cryptocurrencies from the Ledger Backend, which caches responses from the provider’s /crypto-currencies endpoint.

Step 2: User Input and Validation

User Interaction: The user selects the cryptocurrency, fiat currency, and the amount they wish to buy.

User Interaction: The user selects their country and preferred payment method (e.g., PayPal, bank transfer).

Validation Process: Ledger Live validates user input. Validation is performed using cached data from /capabilities, ensuring the user’s input aligns with provider-supported limitations (e.g., minimum/maximum amounts, supported countries).

If the input is invalid, Ledger Live displays an error message to the user.

Step 3: Get Quotes and Select Provider

User Interaction: User request quote.

Backend Process: Ledger Backend identifies eligible providers based on the user’s input.

For each eligible provider, the Ledger Backend sends a [GET] /quotes request to the provider backend to retrieve pricing details (e.g., the amount of fiat currency the user will receive after fees).

The provider backend returns quotes, which are aggregated by the Ledger Backend and displayed in Ledger Live.

User Decision: The user selects a provider from the list of quotes.

Step 4: Redirect to Provider Widget

Action: Once a provider is selected, Ledger Live redirects the user to the provider’s widget.

Redirection Details: The redirection includes required parameters as specified in the LiveApp URL documentation, such as the selected cryptocurrency, fiat currency, amount, and user-specific details.

The user lands on the provider widget to complete the transaction details.

Step 5: Initiate Transaction

Provider Widget Interaction: The user finishes the transaction in the provider widget and providers sends funds to user wallet.

Ledger
Copyright © Ledger SAS. All rights reserved. Ledger, Ledger Nano S, Ledger Vault, Ledger OS are registered trademarks of Ledger SAS