creation_sourcecode: {{
    "language": "Solidity",
    "sources": {
      "contracts/interfaces/IStateSender.sol": {
        "content": "// SPDX-License-Identifier: MIT\npragma solidity 0.8.19;\n\ninterface IStateSender {\n    function syncState(address receiver, bytes calldata data) external;\n}\n"
      },
      "contracts/root/StateSender.sol": {
        "content": "// SPDX-License-Identifier: MIT\npragma solidity 0.8.19;\n\nimport \"../interfaces/IStateSender.sol\";\n\ncontract StateSender is IStateSender {\n    uint256 public constant MAX_LENGTH = 2048;\n    uint256 public counter;\n\n    event StateSynced(uint256 indexed id, address indexed sender, address indexed receiver, bytes data);\n\n    /**\n     *\n     * @notice Generates sync state event based on receiver and data.\n     * Anyone can call this method to emit an event. Receiver on Polygon should add check based on sender.\n     *\n     * @param receiver Receiver address on Polygon chain\n     * @param data Data to send on Polygon chain\n     *\n     */\n    function syncState(address receiver, bytes calldata data) external {\n        // check receiver\n        require(receiver != address(0), \"INVALID_RECEIVER\");\n        // check data length\n        require(data.length <= MAX_LENGTH, \"EXCEEDS_MAX_LENGTH\");\n\n        // State sync id will start with 1\n        emit StateSynced(++counter, msg.sender, receiver, data);\n    }\n\n    // slither-disable-next-line unused-state,naming-convention\n    uint256[50] private __gap;\n}\n"
      }
    },
    "settings": {
      "optimizer": {
        "enabled": true,
        "runs": 115
      },
      "outputSelection": {
        "*": {
          "*": [
            "evm.bytecode",
            "evm.deployedBytecode",
            "devdoc",
            "userdoc",
            "metadata",
            "abi"
          ]
        }
      },
      "libraries": {}
    }
  }}