Build with CrowdProof
Integrate reputation scores, ZK proofs, and identity verification into your protocol. SDKs for TypeScript, Python, Go, C#, Java, and Swift.
Official SDKs
TypeScriptnpm
PythonPyPI
GoGo Modules
C#NuGet
JavaMaven Central
SwiftSPM
Quick Start
Install
npm install @decentra-id/sdkUsage
index.ts
import { DecentraID } from '@decentra-id/sdk';
const did = new DecentraID({ apiKey: 'did_live_...' });
const score = await did.reputation.getScore(
'0x1234...abcd',
'DEFI_LENDING'
);
// → { score: 785, confidence: 88, tier: 'High' }ScoreCard.tsxReact Hook
import { useScore } from '@decentra-id/sdk/react';
function ScoreCard({ address }) {
const { data, isLoading } = useScore(address, 'OVERALL');
if (isLoading) return <Spinner />;
return <div>Score: {data.score} / 1000</div>;
}REST API Endpoints
Base URL: https://api.crowdproof.id/api/v1 — All SDKs wrap these endpoints with retry logic, timeouts, and typed responses.
POST
/api/v1/identity/registerGET
/api/v1/identity/{did}GET
/api/v1/reputation/{address}GET
/api/v1/reputation/{address}/{cat}POST
/api/v1/reputation/batchPOST
/api/v1/reputation/provePOST
/api/v1/reputation/verifyPOST
/api/v1/compliance/verify-agePOST
/api/v1/compliance/kyc/initiateGET
/api/v1/compliance/kyc/{did}/statusPOST
/api/v1/compliance/sanctions-checkPOST
/api/v1/billing/api-keysGET
/api/v1/billing/usageOn-Chain Integration
Query reputation scores directly from your smart contracts.
UndercollateralizedLending.sol
// Query CrowdProof oracle from any smart contract
(uint256 score, uint256 confidence,) = oracle.getScore{
value: queryFee
}(msg.sender, 1); // 1 = DEFI_LENDING category
// Dynamic collateral based on reputation
if (score >= 800) collateralRatio = 110; // 10% overcollateralized
else if (score >= 600) collateralRatio = 130;
else if (score >= 400) collateralRatio = 150;
else revert("Score too low");