Layerswap-hosted page
The Layerswap-hosted page is the simplest integration method that allows you to redirect users from your Web or Mobile app directly to Layerswap. You can customize the user journey by providing URL parameters that configure the swap experience. This approach requires no code integration and is perfect for quick implementations or mobile apps where you want to leverage Layerswap’s full-featured interface.Try Live Demo
Click to see a live example of the hosted page with pre-configured parameters
Basic Implementation
Redirect users to the Layerswap hosted app with customization parameters:How It Works
- Construct the URL: Build a URL to
https://layerswap.io/app/with query parameters - Add Parameters: Include any configuration parameters you need
- Redirect Users: Send users to the constructed URL from your application
Example: Simple Link
The simplest implementation is using a standard HTML link:When the
destAddress parameter is included in the URL, a warning will be displayed in the UI and the user must confirm the destination address before proceeding with the transaction. This is a security measure to ensure users are aware of where their funds will be sent.If you want to bypass the destination address confirmation flow, you must integrate Layerswap via the Widget instead of the hosted page approach.