TruthCam Developer API
Integrate blockchain-verified image authenticity into your applications
Blockchain Verified
Every image proof is cryptographically secured on Solana blockchain with Merkle tree verification
Fast & Reliable
RESTful API with sub-second response times and 99.9% uptime guarantee
Simple Authentication
OAuth-based login with GitHub/Google and secure API key management
Quick Start
Get Your API Key
Navigate to your dashboard and create a new API key. Free tier includes 1,000 credits.
tc_live_aBcDeFgHiJkLmNoPqRsTuVwXyZ123456Make Your First Request
Verify an image by hash using a simple POST request:
curl -X POST https://truthcam.net/api/v1/public/verify/hash \
-H "X-API-Key: tc_live_YOUR_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"image_hash": "abc123..."
}'API Endpoints
/api/v1/public/verify/hashVerify image authenticity by SHA-256 hash. Supports both original and watermarked versions. Returns file_type to indicate if it's the original HEIC or watermarked JPG copy.
View Example Response
{
"verified": true,
"image_hash": "abc123...",
"file_type": "original", // or "watermarked_copy"
"batch_id": "batch-uuid",
"merkle_root": "root-hash",
"solana_txid": "tx-id",
"solana_network": "mainnet",
"ipfs_cid": "Qm...",
"timestamp": "2024-01-01T00:00:00",
"message": "Image verified successfully"
}/api/v1/public/verify/hash/batchNEWVerify multiple images in a single request. Maximum 100 hashes per request. Each hash costs 1 credit.
View cURL Example
curl -X POST https://truthcam.net/api/v1/public/verify/hash/batch \
-H "X-API-Key: tc_live_YOUR_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"hashes": [
"abc123...",
"def456...",
"ghi789..."
]
}'View Example Response
{
"results": [
{
"image_hash": "abc123...",
"verified": true,
"file_type": "original",
"batch_id": "batch-uuid",
"solana_txid": "tx-id",
"timestamp": "2024-01-01T00:00:00",
"message": "Image verified successfully"
},
{
"image_hash": "def456...",
"verified": false,
"message": "Image not found in TruthCam database"
}
],
"summary": {
"total": 3,
"verified": 2,
"not_found": 1,
"credits_used": 3
}
}/api/v1/public/verify/uploadVerify image authenticity by uploading file (multipart/form-data)
View cURL Example
curl -X POST https://truthcam.net/api/v1/public/verify/upload \ -H "X-API-Key: tc_live_YOUR_KEY_HERE" \ -F "file=@/path/to/image.jpg"
/api/v1/public/verify/printNEWVerify a re-photographed printout. Detects photo region, applies perspective correction, and uses pHash similarity search to find matching registered images.
View cURL Example
curl -X POST https://truthcam.net/api/v1/public/verify/print \ -H "X-API-Key: tc_live_YOUR_KEY_HERE" \ -F "file=@/path/to/printed_photo.jpg"
View Example Response
{
"verified": true,
"verification_type": "print",
"region_detection": {
"detected": true,
"perspective_corrected": true,
"area_ratio": 0.75
},
"similar_matches": [
{
"image_hash": "abc123...",
"similarity_level": "very_similar",
"timestamp": "2024-01-01T00:00:00",
"location_address": "Seoul, Korea",
"blockchain_verified": true
}
],
"qr_check": {
"qr_detected": true,
"qr_matches_image": true,
"message": "QR matches printed image"
},
"message": "Print verified - matches registered image",
"credits_used": 1
}/api/v1/public/register/uploadRegister image/video to blockchain (requires write permission, costs 10 credits)
View cURL Example
# Register original file curl -X POST https://truthcam.net/api/v1/public/register/upload \ -H "X-API-Key: tc_live_YOUR_KEY_HERE" \ -F "file=@photo.jpg" \ -F "proof_type=original" # Register edited version (linked to original) curl -X POST https://truthcam.net/api/v1/public/register/upload \ -H "X-API-Key: tc_live_YOUR_KEY_HERE" \ -F "file=@photo_edited.jpg" \ -F "parent_hash=abc123..." \ -F "proof_type=final" \ -F "edit_description=Color correction"
View Example Response
{
"success": true,
"proof_id": "550e8400-e29b-41d4-a716-446655440000",
"short_id": "abc12345",
"image_hash": "abc123def456...",
"timestamp": "2024-01-01T00:00:00",
"batch_id": null,
"status": "queued_for_blockchain",
"message": "Image registered successfully and queued for blockchain",
"verify_url": "https://truthcam.net/verify/abc12345"
}/api/v1/public/verify/tree/:hashGet complete original-final tree for a proof (1 credit)
View Example Response
{
"original": {
"image_hash": "abc123...",
"short_id": "abc12345",
"proof_type": "original",
"timestamp": "2024-01-01T00:00:00Z",
"gps_lat": 37.5,
"gps_lng": 127.0,
"location_address": "Seoul, South Korea",
"verify_url": "https://truthcam.net/verify/abc12345",
"parent_hash": null,
"edit_description": null,
"edit_metadata": null,
"solana_txid": "tx123...",
"batch_id": "batch-uuid",
"created_at": "2024-01-01T00:00:00Z"
},
"finals": [
{
"image_hash": "def456...",
"short_id": "def45678",
"proof_type": "final",
"parent_hash": "abc123...",
"edit_description": "Color correction",
"edit_metadata": {"brightness": 1.2, "contrast": 1.1},
"timestamp": "2024-01-02T10:00:00Z",
"solana_txid": "tx456...",
"batch_id": "batch-uuid-2",
"verify_url": "https://truthcam.net/verify/def45678"
}
],
"depth": 1,
"total_nodes": 2
}/api/v1/public/verify/creditsCheck your current credit balance (requires API Key, does NOT deduct credits)
View Example Response
{
"available_credits": 950,
"tier": "free",
"period": "lifetime",
"message": "Each API call costs 1 credit. Credits never expire."
}TruthDesk Integration (New!)
Desktop applications can now register files to blockchain and track original-final relationships. Perfect for photo editing workflows where you want to link edited versions back to originals.
Credit Packages
Purchase API credits with no expiration. Use them anytime, at your own pace.
Need Help?
Download our bulk verification app or reach out to our support team