{
    "Function": "_executeWithToken",
    "File": "contracts/test/gmp/DestinationChainSwapExecutable.sol",
    "Parent Contracts": [
        "contracts/interfaces/IAxelarExecutable.sol"
    ],
    "High-Level Calls": [
        "IAxelarGateway",
        "IERC20",
        "IAxelarGateway",
        "IAxelarGateway",
        "IERC20",
        "DestinationChainTokenSwapper"
    ],
    "Internal Calls": [
        "abi.decode()"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function _executeWithToken(\n        string memory sourceChain,\n        string memory,\n        bytes calldata payload,\n        string memory tokenSymbolA,\n        uint256 amount\n    ) internal override {\n        (string memory tokenSymbolB, string memory recipient) = abi.decode(payload, (string, string));\n\n        address tokenA = gateway.tokenAddresses(tokenSymbolA);\n        address tokenB = gateway.tokenAddresses(tokenSymbolB);\n\n        IERC20(tokenA).approve(address(swapper), amount);\n        uint256 convertedAmount = swapper.swap(tokenA, tokenB, amount, address(this));\n\n        IERC20(tokenB).approve(address(gateway), convertedAmount);\n        gateway.sendToken(sourceChain, recipient, tokenSymbolB, convertedAmount);\n    }"
}