Developer Tools & API
Privacy-First Credential Management โข SD-JWT Playground โข Enterprise-Grade APIs
๐ Quick Start Guide
Get started with Aletheia AI in 3 simple steps. From authentication to your first auditable AI decision.
Authentication
Login and obtain an authentication token. Store it securely for subsequent API calls.
# 1. Login and get session token
curl -X POST http://localhost:8081/api/v1/auth/login \
-H "Content-Type: application/json" \
-d '{
"email": "your-email@example.com",
"password": "your-password"
}'
# Response:
# {
# "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
# "user": { ... }
# }
# 2. Use token in subsequent requests
export TOKEN="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
curl http://localhost:8081/api/v1/agents \
-H "Authorization: Bearer $TOKEN"Register AI Agent
Create your first AI agent with identity, capabilities, and compliance settings. Receive a cryptographically signed birth certificate.
# Register a new AI agent
curl -X POST http://localhost:8081/api/v1/agents \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "GPT-4 Assistant",
"agentType": "CONVERSATIONAL",
"riskClassification": "high",
"capabilities": ["text_generation", "qa"],
"primaryJurisdiction": "EU",
"dataRetentionDays": 90
}'
# Response:
# {
# "agentId": "urn:uuid:agent-123...",
# "name": "GPT-4 Assistant",
# "status": "active",
# "birthCertificateUrl": "/certificates/agent-123.pdf"
# }Log AI Decision
Log every AI decision with cryptographic proof (RSA + ML-DSA), RFC 3161 timestamp, and immutable audit trail. Download evidence packages for legal proceedings.
# Log an AI decision with cryptographic signature
curl -X POST http://localhost:8081/api/v1/audit/events \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"agentId": "urn:uuid:agent-123...",
"eventType": "DECISION_MADE",
"action": "loan_approval",
"resource": "application/loan-12345",
"outcome": "SUCCESS",
"metadata": {
"loanAmount": 50000,
"creditScore": 720,
"decision": "approved"
},
"riskLevel": "HIGH"
}'
# Response includes cryptographic proof:
# {
# "id": "84739",
# "timestamp": "2026-02-12T15:30:00Z",
# "timestampProof": "eyJ0eXAiOiJKV1QiLCJhbGc...", # RFC 3161
# "blockchainAnchor": "0x1a2b3c..."
# }๐จ UI Component LibraryNew
Unified, accessible, and consistent UI components built with Tailwind CSS and React. All components support dark mode, keyboard navigation, and ARIA attributes.
Buttons
Badges
Alerts
Information
Success
Warning
Error
Form Components
import { Button, Input, Badge, Alert }
from "@/app/components/ui";
<Button variant="primary">
Click me
</Button>Loading & Error States
Failed to load data
๐ฆ Official SDKs & Tools
Choose your preferred language and get started in minutes. All SDKs include authentication, error handling, and full TypeScript support.
Python SDK
pip install aletheia-aiJavaScript SDK
npm install @aletheia/sdkCLI Tool
npm install -g aletheia-cli๐ฎPostman Collection
Import all API endpoints into Postman with pre-configured examples and authentication.
๐ฏ Step 1: Select Agent & Credential
Choose which AI agent and credential you want to work with. Credentials contain verifiable claims that can be selectively disclosed.
Select Agent
Select Credential
๐ฏ SD-JWT Selective Disclosure Playground
Selective Disclosure lets you share only the specific data needed for each verification. Built with SD-JWT for cryptographic proof while minimizing data exposure.
Verifier Information
Select Claims to Disclose
๐ก Choose which claims to share. Fewer selections = higher privacy score.
- โข Reduce Legal Risk: Minimize data exposure = minimize liability
- โข Build Trust: Users appreciate privacy-first design
- โข GDPR Compliance: Automatic data minimization documentation
- โข Competitive Edge: Privacy as a differentiator
Privacy Score
Disclosure Summary
๐ Use Case Examples
Insurance Verification
Minimal disclosure for insurance eligibility check
Full Compliance Audit
Complete disclosure for regulatory audit
Anonymous Analysis
Zero personal data disclosure
๐ป SDK Examples
Python SDK
import requests
# Preview disclosure
response = requests.post(
"http://localhost:8081/api/v1/disclosures/preview",
json={
"credentialId": "urn:uuid:12345...",
"verifierId": "did:web:insurance-provider.eu",
"verifierName": "ACME Insurance Co.",
"claimsToDisclose": ["riskLevel", "insurance.coverage"],
"purpose": "Insurance eligibility verification",
"consentGiven": True
}
)
preview = response.json()
print(f"Privacy Score: {preview['privacyScore']}")
print(f"Presentation: {preview['presentation']}")
# Create actual disclosure (logs to audit trail)
disclosure = requests.post(
"http://localhost:8081/api/v1/disclosures/present",
json={...} # Same payload as preview
)
print(f"Disclosure ID: {disclosure.json()['disclosureId']}")TypeScript/JavaScript SDK
import axios from 'axios';
interface DisclosureRequest {
credentialId: string;
verifierId: string;
verifierName: string;
claimsToDisclose: string[];
purpose: string;
consentGiven: boolean;
}
const request: DisclosureRequest = {
credentialId: "urn:uuid:12345...",
verifierId: "did:web:insurance-provider.eu",
verifierName: "ACME Insurance Co.",
claimsToDisclose: ["riskLevel", "insurance.coverage"],
purpose: "Insurance eligibility verification",
consentGiven: true
};
// Preview
const preview = await axios.post(
'http://localhost:8081/api/v1/disclosures/preview',
request
);
console.log(`Privacy Score: ${preview.data.privacyScore}`);
console.log(`Compliance: ${preview.data.complianceFlags.join(', ')}`);
// Create disclosure
const disclosure = await axios.post(
'http://localhost:8081/api/v1/disclosures/present',
request
);
console.log(`Disclosure ID: ${disclosure.data.disclosureId}`);cURL
# Preview disclosure
curl -X POST http://localhost:8081/api/v1/disclosures/preview \
-H "Content-Type: application/json" \
-d '{
"credentialId": "urn:uuid:12345...",
"verifierId": "did:web:insurance-provider.eu",
"verifierName": "ACME Insurance Co.",
"claimsToDisclose": ["riskLevel", "insurance.coverage"],
"purpose": "Insurance eligibility verification",
"consentGiven": true
}'
# Create disclosure (logs to audit trail)
curl -X POST http://localhost:8081/api/v1/disclosures/present \
-H "Content-Type: application/json" \
-d '{...}' # Same payload
# Get disclosure history
curl http://localhost:8081/api/v1/disclosures/history/urn:uuid:agent-67890
# Get disclosure statistics
curl http://localhost:8081/api/v1/disclosures/stats/urn:uuid:agent-67890๐ API Endpoints
/api/v1/disclosures/previewPreview what would be disclosed without creating audit record
/api/v1/disclosures/presentCreate and log disclosure (permanent audit record)
/api/v1/disclosures/history/:agentIdGet complete disclosure audit trail for an agent
/api/v1/disclosures/stats/:agentIdGet disclosure statistics and analytics