openapi: 3.2.0 info: title: Sell Provider Server Sell Redirect API version: '1.0' tags: - name: Sell Redirect paths: /sell-redirect: get: operationId: sell-redirect summary: Retrieve a redirect URL description: Returns the URL of the off-ramp widget, including the specified Sell parameters, to which the user will be redirected. security: - defaultApiKey: [] parameters: - name: accountId in: query description: User’s selected account id, where the crypto he wants to sell is stored. required: true schema: type: string example: d7e79746-e40c-5fab-9012-3c0bc04e8a13 - name: cryptoCurrency in: query description: The crypto currency that the user wants to sell. It will contain the [LedgerID](https://developers.ledger.com/docs/ledger-live/exchange/sell/providers-backend#ledger-ids-mapping) value to identify the crypto. required: true schema: type: string example: bitcoin - name: fiatCurrency in: query description: The FIAT currency that the user wants to be paid with. required: true schema: type: string example: EUR - name: cryptoAmount in: query description: The crypto amount that the user wants to sell. required: true schema: type: string example: 0.001 - name: paymentMethod in: query description: The payment method selected by the user. required: true schema: type: string example: card - name: mode in: query description: In this case always `sell`. required: true schema: type: string example: sell - in: query name: bankResidency description: User's Country Code (ALPHA-2). required: true schema: type: string example: FR - in: query name: customParameters description: Used to include additional URL-encoded key-value parameters in the widget URL. required: false schema: type: string example: widgetid%3D247312%26ledgerlive%3Dtrue - in: query name: ledgerTransactionId description: Ledger Wallet transaction ID. Used by Ledger to track transactions and their completion statuses. required: false schema: type: string example: 9649d677-f201-45b2-8130-0317065743de - in: query name: deeplinkUrl description: Deeplink URL to Ledger Wallet. required: false schema: type: string example: ledgerlive://buy - in: query name: language description: 'The language chosen by the user in Ledger Wallet. Valid values: ar, de, en, es, fr, ja, ko, pt, ru, th, tr, zh.' required: false schema: type: string example: es - in: query name: theme description: 'The theme chosen by the user in Ledger Wallet. Valid values: light, dark.' required: false schema: type: string example: dark responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/RampRedirectUrl' '400': description: Bad Request content: text/plain: schema: type: string tags: - Sell Redirect components: schemas: RampRedirectUrl: type: object description: Redirect URL to Ramp UI widget required: - rampRedirectUrl properties: rampRedirectUrl: type: string format: uri description: The URL of the off-ramp widget, including the specified Sell parameters, to which the user will be redirected. example: rampRedirectUrl: https://widget.crypto-partner.com/?product=SELL&cryptoAmount=20&fiatCurrency=EUR&network=polygon&paymentMethod=credit_debit_card&cryptoCurrencyCode=USDC&countryCode=GB&partnerOrderId=test-order-id&partnerCustomerId=12342&theme=dark securitySchemes: defaultApiKey: type: apiKey name: x-api-key in: header