ClaimManager
The ClaimManager contract manages the lifecycle of claims from initiation to resolution. It coordinates interactions between users, the Liquidity Manager, and arbitration courts. This contracts ensures a fair and transparent system for cover holders to submit claims and receive compensation when eligible.
Enums info
ClaimStatus
RulingOptions
The neutral "refuse to arbitrate" option IS ALWAYS 0
Structs info
ClaimRead
Claim
State variables info
baseMetaEvidenceURI
coverToken
liquidityManager
arbitrator
evidenceGuardian
overruleGuardian
nextClaimId
claims
disputeIdToClaimId
claimIdToEvidence
claimIdToCounterEvidence
claimCollateral
klerosExtraData
challengePeriod
overrulePeriod
evidenceUploadPeriod
numberOfRulingOptions
courtClosed
Modifiers info
onlyArbitrator
Check that the caller is the arbitrator contract
coverExists
Check that the cover exists
Parameters:
Name | Type | Description |
---|---|---|
coverId_ | uint256 | The cover ID |
claimsExists
Check that the claim exists
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
Read Functions info
arbitrationCost
Returns the cost of arbitration for a Kleros dispute.
Return values:
Name | Type | Description |
---|---|---|
-- | uint256 | The arbitration cost |
metaEvidenceURI
Returns the URI of the meta-evidence for a claim
Parameters:
Name | Type | Description |
---|---|---|
claimId | uint256 | The claim ID |
Return values:
Name | Type | Description |
---|---|---|
-- | string | The URI of the meta-evidence |
coverIdToClaimIds
Returns all claim IDs associated with a cover.
Parameters:
Name | Type | Description |
---|---|---|
coverId_ | uint256 | The cover ID |
Return values:
Name | Type | Description |
---|---|---|
-- | uint256[] | All the claim IDs associated with the cover |
claimInfo
Get a claim by its ID.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
Return values:
Name | Type | Description |
---|---|---|
-- | struct ClaimManager.ClaimRead | The claim's data |
claimInfos
Returns multiple claims by their IDs.
Parameters:
Name | Type | Description |
---|---|---|
claimIds_ | uint256[] | The claim IDs |
Return values:
Name | Type | Description |
---|---|---|
result | struct ClaimManager.ClaimRead[] | All the claims' data |
claimsByCoverId
Returns all the claims associated with a cover.
Parameters:
Name | Type | Description |
---|---|---|
coverId_ | uint256 | The cover ID |
Return values:
Name | Type | Description |
---|---|---|
-- | struct ClaimManager.ClaimRead[] | All the cover's claims |
claimsByAccount
Returns all the claims of a user.
Parameters:
Name | Type | Description |
---|---|---|
account_ | address | The user's address |
Return values:
Name | Type | Description |
---|---|---|
result | struct ClaimManager.ClaimRead[] | All the user's claims |
getClaimEvidence
Returns the evidence submitted by claimant for a claim.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
Return values:
Name | Type | Description |
---|---|---|
-- | string[] | The evidence CIDs |
getClaimCounterEvidence
Returns the counter-evidence submitted by prosecutor or Athena for a claim.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
Return values:
Name | Type | Description |
---|---|---|
-- | string[] | The counter-evidence CIDs |
Write Functions info
submitEvidenceForClaim
Adds evidence IPFS CIDs for a claim.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
ipfsEvidenceCids_ | string[] | The IPFS CIDs of the evidence |
initiateClaim
Initiates a payment claim to Kleros by a cover holder.
Parameters:
Name | Type | Description |
---|---|---|
coverId_ | uint256 | The cover ID |
amountClaimed_ | uint256 | The amount claimed by the cover holder |
disputeClaim
Allows a user to challenge a pending claim by creating a dispute in Kleros.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
withdrawCompensation
Allows the claimant to withdraw the compensation after a dispute has been resolved in their favor or the challenge period has elapsed.
Intentionally public to prevent claimant from indefinitely blocking withdrawals from a pool by not executing the claims ruling.
Parameters:
Name | Type | Description |
---|---|---|
claimId_ | uint256 | The claim ID |
Events info
ClaimCreated
DisputeResolved
MetaEvidence
To be emitted when meta-evidence is submitted.
Parameters:
Name | Type | Description |
---|---|---|
metaEvidenceID_ | uint256 | Unique identifier of meta-evidence. |
evidence_ | string | IPFS path to metaevidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/metaevidence.json' |
Evidence
To be raised when evidence is submitted. Should point to the resource (evidences are not to be stored on chain due to gas considerations).
Parameters:
Name | Type | Description |
---|---|---|
arbitrator_ | contract IArbitrator | The arbitrator of the contract. |
evidenceGroupID_ | uint256 | Unique identifier of the evidence group the evidence belongs to. |
party_ | address | The address of the party submiting the evidence. Note that 0x0 refers to evidence not submitted by any party. |
evidence_ | string | IPFS path to evidence, example: '/ipfs/Qmarwkf7C9RuzDEJNnarT3WZ7kem5bk8DZAzx78acJjMFH/evidence.json' |
Dispute
To be emitted when a dispute is created to link the correct meta-evidence to the disputeID.
Parameters:
Name | Type | Description |
---|---|---|
arbitrator_ | contract IArbitrator | The arbitrator of the contract. |
disputeID_ | uint256 | ID of the dispute in the Arbitrator contract. |
metaEvidenceID_ | uint256 | Unique identifier of meta-evidence. |
evidenceGroupID_ | uint256 | Unique identifier of the evidence group that is linked to this dispute. |
Last updated