26/07
2018
This is package to use Chainpoint API.
This is not actively developed (2020-12-31)., (*1)
This is PHP package for request to Tierion Chainpoint. For Chainpoint, look at Chainpoint Node HTTP API., (*2)
Composer Package, (*3)
First, write use
statement., (*4)
use KenjiOtsuka\Chainpoint;
$c = new Chainpoint();
Post sha256 hash., (*5)
$c->submit('0xXXXXXX...');
Or post text, which is internally converted to hash., (*6)
$c->submitData("text");
Get hash id node from submit
result and post it.
This method execution may have to be called for the same Chainpoint
instanece
as submit
called for., (*7)
$c->getProof($hashIdNode);
Verify with proof, which is get from above request, getProof
, result., (*8)
// 2 ways are available. $c->verify($proof); Chainpoint::verify($proof);