{"id":20093914,"url":"https://github.com/api3dao/claims-manager","last_synced_at":"2025-05-06T04:32:22.003Z","repository":{"id":39755644,"uuid":"488135499","full_name":"api3dao/claims-manager","owner":"api3dao","description":null,"archived":true,"fork":false,"pushed_at":"2023-09-27T22:09:25.000Z","size":2482,"stargazers_count":1,"open_issues_count":14,"forks_count":3,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-03-02T16:16:05.828Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/api3dao.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-05-03T08:44:21.000Z","updated_at":"2024-05-30T07:23:12.000Z","dependencies_parsed_at":"2024-11-13T16:48:55.549Z","dependency_job_id":"48ad7a42-6018-4083-a7b9-824666cdb3a8","html_url":"https://github.com/api3dao/claims-manager","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/api3dao%2Fclaims-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/api3dao%2Fclaims-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/api3dao%2Fclaims-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/api3dao%2Fclaims-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/api3dao","download_url":"https://codeload.github.com/api3dao/claims-manager/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252622424,"owners_count":21777988,"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":[],"created_at":"2024-11-13T16:48:48.331Z","updated_at":"2025-05-06T04:32:21.585Z","avatar_url":"https://github.com/api3dao.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @api3/claims-manager\n\nInstall the dependencies\n\n```sh\nyarn\n```\n\nBuild the contracts\n\n```sh\nyarn build\n```\n\nTest the contracts\n\n```sh\nyarn test\n```\n\n## Kleros notes\n\nhttps://kleros.gitbook.io/docs/integrations/types-of-integrations/1.-dispute-resolution-integration-plan/smart-contract-integration\n\nhttps://kleros.gitbook.io/docs/integrations/types-of-integrations/1.-dispute-resolution-integration-plan/integration-tools/centralized-arbitrator\n\nhttps://github.com/kleros/kleros/blob/master/contracts/kleros/KlerosLiquid.sol\n\nhttps://github.com/kleros/erc-792/blob/master/contracts/examples/CentralizedArbitratorWithAppeal.sol\n\nMainnet Arbitrator address: `0x988b3A538b618C7A603e1c11Ab82Cd16dbE28069`\n\nBlockchain subcourt: `1`\n\nScript to generate the arbitrator extra data:\n\n```js\ngenerateArbitratorExtraData = (subcourtID, noOfVotes) =\u003e 0x${parseInt(subcourtID, 10).toString(16).padStart(64, \"0\") + parseInt(noOfVotes, 10).toString(16).padStart(64, \"0\")};\n```\n\nIt also says extra data includes\n\n\u003e (If appeals are allowed) Stake multipliers representing multipliers of the appeal cost that a party must pay for a new\n\u003e round (in basis points)\n\nhowever, KlerosLiquid derives the appeal cost from the number of jurors.\n\n## Reads for frontend\n\nMostly static data:\n\n- `extraData`: `ClaimsManagerWithKlerosArbitration.klerosArbitratorExtraData()`\n- `subCourt` and `noOfVotes`: Parse `extraData`\n- `KlerosLiquid.getSubCourt(subCourt).timesPerPeriod`\n  (https://github.com/kleros/kleros/blob/master/contracts/kleros/KlerosLiquid.sol#L37)\n- `KlerosLiquid.arbitrationCost(extraData)`\n\nDispute-specific data\n\n- `KlerosLiquid.disputeStatus(disputeId)`\n  (https://github.com/kleros/kleros-interaction/blob/master/contracts/standard/arbitration/Arbitrator.sol#L23)\n- `KlerosLiquid.currentRuling(disputeId)`\n- `KlerosLiquid.disputes(disputeId).period`, `KlerosLiquid.disputes(disputeId).lastPeriodChange`,\n  `KlerosLiquid.disputes(disputeId).ruled`\n- `KlerosLiquid.appealCost(disputeId, extraData)`\n- Future appeal costs can be calculated using `KlerosLiquid.courts(subCourt).feeForJuror` and\n  https://github.com/kleros/kleros/blob/master/contracts/kleros/KlerosLiquid.sol#L797\n\n## Writes for frontend\n\n- `executeRuling(disputeId)`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapi3dao%2Fclaims-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fapi3dao%2Fclaims-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapi3dao%2Fclaims-manager/lists"}