{"id":23107837,"url":"https://github.com/kleros/cross-chain-realitio-proxy-polygon","last_synced_at":"2026-03-20T00:37:26.370Z","repository":{"id":46187624,"uuid":"415804057","full_name":"kleros/cross-chain-realitio-proxy-polygon","owner":"kleros","description":null,"archived":false,"fork":false,"pushed_at":"2023-02-17T00:14:10.000Z","size":7491,"stargazers_count":0,"open_issues_count":10,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2023-02-26T18:16:06.049Z","etag":null,"topics":["arbitrable","backend","dapps","oracles","reality","smart-contracts","web3"],"latest_commit_sha":null,"homepage":null,"language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kleros.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-10-11T06:28:35.000Z","updated_at":"2022-06-30T15:05:31.000Z","dependencies_parsed_at":"2023-02-15T10:15:44.773Z","dependency_job_id":null,"html_url":"https://github.com/kleros/cross-chain-realitio-proxy-polygon","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kleros%2Fcross-chain-realitio-proxy-polygon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kleros%2Fcross-chain-realitio-proxy-polygon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kleros%2Fcross-chain-realitio-proxy-polygon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kleros%2Fcross-chain-realitio-proxy-polygon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kleros","download_url":"https://codeload.github.com/kleros/cross-chain-realitio-proxy-polygon/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230047186,"owners_count":18164575,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arbitrable","backend","dapps","oracles","reality","smart-contracts","web3"],"created_at":"2024-12-17T01:16:17.920Z","updated_at":"2026-03-20T00:37:26.336Z","avatar_url":"https://github.com/kleros.png","language":"Solidity","funding_links":[],"categories":[],"sub_categories":[],"readme":"### ⚠️ The content has been moved to [kleros/cross-chain-realitio-proxy](https://github.com/kleros/cross-chain-realitio-proxy)\n\n# Cross-Chain Realitio Proxy\n\nEnables cross-chain arbitration for Realition (Reality.eth) on Polygon using Kleros as arbitrator.\n\n## Intro\n\nWe use Polygon Fx-Portal mechanism for cross chain communication.\nYou can find out more about how Fx-Portal works from here:\n\n- https://docs.polygon.technology/docs/develop/l1-l2-communication/fx-portal/\n- https://github.com/fx-portal/contracts\n\n## High-Level Flow Description\n\n1. Alice requests arbitration on the main chain paying the arbitration fee to the ETH proxy and indicates the maximum value of the bond for the question (A.K.A. `max_previous`).\n1. The ETH proxy communicates the request to the Polygon proxy through the Fx-Portal.\n1. The Polygon tries to notify Realitio of the arbitration request and forwards the `max_previous` value:\n   1. If the bond has not changed, the arbitration request will be accepted.\n      1. Notify the ETH proxy through the Fx-Portal.\n      1. Call the receiveMessage function with Polygon Tx hash on Ethereum\n   1. Otherwise, if it changed then:\n      1. Notify the ETH proxy through the Fx-Portal.\n      1. Call the receiveMessage function with Polygon Tx hash on Ethereum\n      1. The ETH proxy refunds Alice. **END**\n1. In the mean time while Realitio was being notified of the arbitration request, the arbitration fees might have changed:\n   1. If the fees stayed the same (most common case) then:\n      1. Create a dispute on Kleros Court.\n   1. If the fees have decreased then:\n      1. Create a dispute on Kleros Court.\n      1. Refund Alice of the difference.\n   1. If the fees have increased, then the arbitration request will fail:\n      1. Refund Alice of the value paid so far.\n      1. The ETH proxy notifies the Polygon proxy through the Fx-Portal that the arbitration failed to be created.\n      1. The Polygon proxy notifies Realitio of the failed arbitration. **END**\n1. The Kleros court gives a ruling. It is relayed to the Polygon proxy through the Fx-Portal.\n   1. If the ruling is the current answer, Bob, the last answerer, is the winner. **END**\n   1. If it is not, Alice is the winner. **END**\n\n## Relaying Messages from Polygon to Ethereum\n\nPolygon-to-Ethereum communication requires manual intervention, the exact mechanism\nfor it is described [here](https://github.com/UMAprotocol/protocol/tree/master/packages/fx-tunnel-relayer#why-is-a-bot-needed-to-relay-messages-from-polygon-to-ethereum)\n\nThere is also a [fx-tunnel-relayer](https://github.com/UMAprotocol/protocol/tree/master/packages/fx-tunnel-relayer) bot developed by the UMAProtocol for this purpose that can either be\nused as is or as a reference for our own bot.\n\n## Deployed Addresses\n\nSee [contracts/README.md](contracts/README.md#deployed-addresses).\n\n## Contributing\n\n### Repo Structure\n\nEach directory at the root of this repository contains code for each individual part that enables this integration:\n\n- **`bots/`**: service to automate some steps of the flow which otherwise would required manual intervention from users.\n  - **Notice:** while this is a centralized service, it exists only for convenience. Users can fulfill the role of the bots if they wish to.\n- **`contracts/`**: Smart contracts to enable cross-chain arbitration for Realitio (Reality.eth). [Learn more](contracts/README.md).\n- **`dynamic-script/`**: allows fetching the dynamic content for the arbitration, as described by [ERC-1497: Evidence Standard](https://github.com/ethereum/EIPs/issues/1497).\n- **`evidence-display/`**: display interface that should be used to render the evidence for arbitrators, as described by [ERC-1497: Evidence Standard](https://github.com/ethereum/EIPs/issues/1497).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkleros%2Fcross-chain-realitio-proxy-polygon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkleros%2Fcross-chain-realitio-proxy-polygon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkleros%2Fcross-chain-realitio-proxy-polygon/lists"}