Integration Guide

This guide outlines recommended practices for integrating with PananaSwap in a secure, predictable, and future-compatible manner.

PananaSwap is a non-custodial, on-chain protocol. Integrations should be designed to respect this architecture.


Integration Overview

A typical PananaSwap integration involves:

  1. Connecting a user wallet

  2. Displaying swap parameters and estimates

  3. Executing swaps via smart contracts

  4. Reading execution results from on-chain data

  5. Using APIs for analytics and display purposes

All value transfer and execution occurs on-chain.


PananaSwap recommends the following flow:

1. Wallet Interaction

  • Use standard Web3 wallet providers

  • Require explicit user approval for transactions

  • Do not abstract or hide transaction signing


2. Swap Execution

  • Execute swaps directly via PananaSwap smart contracts

  • Handle reverted transactions gracefully

  • Do not assume execution success


3. Fee and VIP Awareness

  • Do not hardcode fee assumptions

  • Allow protocol logic to apply VIP tiers automatically

  • Display fees as informational, not guaranteed


4. Analytics and Display

  • Use API endpoints for convenience

  • Treat API data as non-authoritative

  • Always defer to on-chain records for verification


Network and Chain Handling

Integrators should:

  • Detect and handle network mismatches

  • Prompt users to switch networks when required

  • Use correct contract addresses per network

PananaSwap does not support cross-chain execution within a single transaction.


Error Handling and UX

Robust integrations should:

  • Handle transaction reverts clearly

  • Inform users about gas costs and slippage

  • Avoid misleading confirmations

User experience should reflect on-chain realities.


Security Best Practices

Integrators are responsible for:

  • Securing frontend infrastructure

  • Avoiding malicious script injection

  • Managing API usage responsibly

PananaSwap cannot secure third-party applications.


Versioning and Updates

Integrations should:

  • Monitor documentation for updates

  • Avoid assumptions about future behavior

  • Design for graceful upgrades

Backward compatibility is not guaranteed.


Testing and Validation

Before deploying integrations:

  • Test against supported networks

  • Validate edge cases and failures

  • Verify on-chain execution paths

Testing should include adverse scenarios.


Compliance and Disclosure

Integrators should:

  • Disclose protocol risks clearly to users

  • Avoid misrepresenting PananaSwap behavior

  • Comply with applicable local regulations

PananaSwap does not provide compliance guidance.


Support and Communication

For integration-related questions:

  • Refer to official documentation

  • Monitor published updates

  • Use designated communication channels

Avoid relying on unofficial sources.


Final Notes

PananaSwap integrations work best when they:

  • Respect non-custodial principles

  • Trust on-chain execution

  • Treat APIs as convenience layers

  • Avoid hidden assumptions

Proper integration ensures long-term stability for both users and partners.

Last updated