API Docs

Programmatic analysis for Dispel.cloud

Use bearer-authenticated endpoints to submit content, receive normalized verdicts, and integrate Dispel into a future API product surface. Scores are calibrated product heuristics, not absolute truth.

Mode
Local single-user MVP
Authentication

Analyze endpoints require an API key in the Authorization header.

Authorization: Bearer dsp_live_1234abcd_xxxxxxxxxxxxxxxxxxxxxxxx

API access is gated to Pro. Key management routes currently use the local single-user workspace identity in the dashboard. Raw tokens are never stored after creation.

v1 programmatic endpoints currently cover text and image. Voice, music, and video remain available in the web app while the API surface stays intentionally small.

Endpoints
POST/api/v1/analyze/text

Submit text content for scam-risk, AI-likelihood, provenance, and claim-consistency scoring.

POST/api/v1/analyze/image

Submit an image file with multipart form data for file inspection, OCR-assisted scoring, and provider-backed checks when configured.

GET/api/v1/me/usage

Return the local workspace usage summary used by the dashboard settings screen.

GET/api/v1/me/keys

List the current user’s API keys, prefixes, statuses, and usage counts.

POST/api/v1/me/keys

Create a new API key and reveal the raw token one time.

POST/api/v1/me/keys/:id/revoke

Revoke an issued API key. Revocation is immediate and cannot be undone.

Examples
Text analysis request
curl -X POST https://your-host/api/v1/analyze/text \
  -H "Authorization: Bearer $DISPEL_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Suspicious payroll note",
    "text": "Urgent final notice. Pay the onboarding fee today by gift card."
  }'
Image analysis request
curl -X POST https://your-host/api/v1/analyze/image \
  -H "Authorization: Bearer $DISPEL_API_KEY" \
  -F "title=Listing screenshot" \
  -F "file=@suspicious-image.png"
Representative response
{
  "analysisId": "cm123...",
  "type": "TEXT",
  "verdict": "HIGH_RISK",
  "overallTrustScore": 14,
  "aiLikelihoodScore": 58,
  "scamRiskScore": 92,
  "manipulationRiskScore": 71,
  "provenanceScore": 28,
  "claimConsistencyScore": 35,
  "confidenceLabel": "Moderate",
  "summary": "Multiple payment-pressure and impersonation signals were found.",
  "recommendedAction": "Do not pay or click links until you verify the source independently.",
  "uncertaintyNote": "Provider-backed AI checks can remain unknown when adapters are inactive.",
  "evidence": [],
  "warnings": [
    "Remote image provider is unavailable, so AI-likelihood remains unknown."
  ],
  "provider": {
    "key": "openai-compatible",
    "status": "inactive"
  },
  "reportUrl": "https://your-host/report/...",
  "receiptUrl": "https://your-host/report/...?view=receipt"
}