Request
Attribute | PK? | Type |
---|---|---|
Claimer | true | string |
Humanity | true | string |
Vouches ID | Vouch[] |
Vouch
Attribute | PK? | Type |
---|---|---|
ID | true | ID |
Voucher | string | |
Signature | string | |
Expiration Timestamp | number |
Adds a signature generated by voucher for vouched address corresponds to humanity. Signed typed data using EIP-712. Message data of the signature is of following structure:
POST request should have the following body:
Voucher address is recovered using some library. Here's how's done in current version.
Here's an example of how you can generate signature using ethers.js
but will probably be different with other libraries (this would be done on the frontend anyway):
Additional checks before putting the vouch in db:
isHuman(voucherAddress)
getClaimerRequestId(address)
voucherAddress != vouchedHuman
Return non-resolved requests with some of the following params:
claimer
- for this claimer (vouched address)
humanity
- for this humanity (vouched for humanity)
minVouches
- with this number of vouches; should be used as only param
Possible additional checks:
minVouches
does not take into account expired vouchesDelete request table (with vouches) corresponding to claimer and humanity. Body:
If this is called only
RenewHumanity
event is emited? not urgent