lifi-dev

Implement cross-chain swaps and bridges using LI.FI SDK, Widget, and API.

Updated Jan 29, 2026
One-click install
npx skills add https://github.com/mashharuki/lify-sample --skill lifi-dev
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: lifi-dev
Source: https://github.com/mashharuki/lify-sample/tree/main/.codex/skills/lifi-dev
Command: npx skills add https://github.com/mashharuki/lify-sample --skill lifi-dev

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @lifi/sdk, @lifi/widget, viem, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

LI.FI Development Skill provides a complete toolkit for building cross-chain swap and bridge applications using LI.FI, covering SDK, Widget, and API integrations, plus LI.Fuel gas subsidies and integrator monetization practices.

Core Features & Use Cases

  • Widget Integration: Drop-in UI for swaps and bridges with easy theming and configuration.
  • SDK Integration: Programmatic access to routes, execution, and wallet interactions across chains.
  • API Integration: REST endpoints for quoting, routing, and status checks in backend workflows.
  • Gas Subsidy (LI.Fuel): Substituting native gas on destination chains to improve onboarding on new chains.
  • Monetization: Configure integrator fees and track revenue across transactions.
  • Security & Best Practices: Slippage protection, precise approvals, rate limiting, error handling, and transaction monitoring.
  • Use Case: Rapidly spin up a DeFi dashboard or marketplace with multi-chain swaps across 60+ chains and 800+ protocols.

Quick Start

Use the scripts in the scripts directory (for example scripts/sdk_swap_example.ts, scripts/widget_integration.tsx, scripts/api_routes_example.ts) and consult the references (references/widget-guide.md, references/sdk-guide.md, references/api-reference.md) to implement your own LI.FI integration quickly.

Frequently Asked Questions about lifi-dev

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement cross-chain swaps using LI.FI SDK in a TypeScript app?

To implement cross-chain swaps with the LI.FI SDK, use the provided TypeScript scripts to access programmatic routing and wallet interactions across chains. The skill requires a JavaScript or TypeScript environment with dependencies on @lifi/sdk and viem for transaction handling.

Can I add a drop-in UI for cross-chain bridges without building from scratch?

You can add a drop-in UI for cross-chain bridges using the LI.FI Widget integration. The skill provides scripts and reference guides for easy theming and configuration, allowing you to rapidly spin up DeFi dashboards with multi-chain swaps.

Does the LI.FI API support backend routing and status checks for transactions?

The LI.FI API supports backend workflows by providing REST endpoints for quoting, routing, and status checks. You can use the API integration scripts to handle backend cross-chain transaction monitoring and execution across 60+ chains.

How do I configure integrator monetization and gas subsidies for cross-chain transactions?

To configure integrator monetization and gas subsidies, use the skill's guides on setting integrator fees and implementing LI.Fuel. LI.Fuel substitutes native gas on destination chains to improve user onboarding and allows you to track transaction revenue.

What security practices should I follow when integrating multi-chain routing protocols?

When integrating multi-chain routing, you must implement slippage protection, precise approvals, rate limiting, and error handling. The skill includes security and best practice references to ensure safe transaction monitoring across 800+ protocols.

Do I need viem to handle wallet connections for LI.FI SDK integrations?

You need viem to handle wallet connections and transaction execution for LI.FI SDK integrations. The skill relies on viem alongside @lifi/sdk and @lifi/widget to manage cross-chain wallet interactions within your JavaScript or TypeScript environment.