BLAQclouds API
DRM-as-a-Service for content licensing and forensic watermarking
https://api.blaqclouds.ioAuthorization: Bearer blk_live_***application/jsonX-RateLimit-Limit / Remaining / Reset๐ฐ Pricing Plans
Three plans built for every stage โ from early studio tests to full white-label platforms.
All prices in APUSD (1 APUSD = $1 USD). No free tier.
Save 15% with annual billing.
Paid
- โ$99/month per product (Videos, Music, Flipbooks, Cards, Tickets)
- โSubscribe to multiple products independently
- โFull watermarking + forensics access
- โMarketplace access
- โCommunity + theAlley included
- โPer-product billing (separate invoices)
- โStripe + APUSD payments
- โAPI key with product scoping (single or multi-product)
- โWebhook notifications
- โStandard support
White-Label
- โCustom pricing per product
- โComplete white-label (custom domain, branding, documentation)
- โPer-viewer wallet + permanent forensic fingerprint
- โWebhook system with HMAC-SHA256 signing
- โFull Forensics API (leak detection + evidence chain)
- โRemove "Powered by BLAQclouds" badge
- โDedicated support + SLA
- โCustom overage rates and volume commitments
๐ฆ Product API Routes
Each product has its own set of API routes with independent billing. Subscribe to one or multiple products.
Videos API
/api/videos/v1/Video upload, HLS streaming, collections, PPV/rental, watermarking, forensics
Music API
/api/music/v1/Music upload, GPU watermarking, albums, playlists, marketplace, forensics
Flipbooks API
/api/flipbooks/v1/Flipbook creation, digital passes, resale, athlete templates
Digital Cards API
/api/cards/v1/Card creation, DTCWT watermarking, collections, marketplace
Tickets/Events API
/api/tickets/v1/Event creation, ticket sales, Stripe checkout, check-in
๐ฌ Video Processing Options
Two processing options for video uploads:
HLS + Encryption (Free)
HLS segmentation + AES-128-CBC encryption + IPFS upload. No forensic watermarking.
HLS + Encryption + Watermarking (Premium)
GPU DTCWT forensic watermarking + encryption + IPFS. Priced by resolution:
Watermark Pass holders bypass the premium cost. Prices in APUSD (1 APUSD = $1 USD).
Why teams choose BLAQclouds
- EVM wallet verification โ every viewer is cryptographically tied to a wallet.
- Segmented & encrypted IPFS โ content is split, encrypted, and delivered via IPFS.
- 40-bit dual-variant watermarking โ each viewer receives a unique pair of stream variants determined by their ID.
- Forensic leak attribution โ identify exactly which viewer leaked the content.
All prices in APUSD. No setup fees. Cancel anytime on monthly plans. Annual plans are prepaid and non-refundable except as required by law.
๐ Getting Started
Register your organization and start using the BLAQclouds DRM-as-a-Service API.
/api/v1/auth/registerRegister a new organization. Returns an API key (shown once), wallet address, organization ID, and webhook secret. If no wallet address is provided, one is auto-generated.
{
"name": "Your Organization Inc.",
"email": "contact@yourorg.com",
"walletAddress": "0x...", // optional, auto-generated if omitted
"signingPublicKey": "-----BEGIN PUBLIC KEY-----\n...", // for signed viewer tokens
"signingAlgorithm": "RS256", // RS256 or ES256, default: RS256
"webhookUrl": "https://yourorg.com/webhooks/blaqclouds" // optional
}{
"apiKey": "blk_live_a1b2c3d4e5f6...",
"walletAddress": "0xABC123...",
"organizationId": "uuid-here",
"webhookSecret": "f7e8d9c0b1a2..."
}curl -X POST https://api.blaqclouds.io/api/v1/auth/register \
-H "Content-Type: application/json" \
-d '{
"name": "Your Organization Inc.",
"email": "contact@yourorg.com",
"signingPublicKey": "-----BEGIN PUBLIC KEY-----\n...",
"webhookUrl": "https://yourorg.com/webhooks/blaqclouds"
}'/api/v1/auth/verifyVerify that your API key is valid. Returns your organization details, plan, scopes, and rate limits.
{
"organization": {
"name": "Your Organization Inc.",
"plan": "paid",
"walletAddress": "0xABC123..."
},
"scopes": ["catalog", "stream", "billing", "forensics"],
"rateLimits": {
"perHour": 1000,
"remaining": 987
}
}curl -X GET https://api.blaqclouds.io/api/v1/auth/verify \
-H "Authorization: Bearer blk_live_xxx"/api/v1/auth/rotateRotate your API key. The old key is immediately revoked. Returns a new API key. Minimum 1 hour cooldown between rotations.
{
"apiKey": "blk_live_newkey...",
"oldKeyRevoked": true
}curl -X POST https://api.blaqclouds.io/api/v1/auth/rotate \
-H "Authorization: Bearer blk_live_oldkey"๐ฐ Pricing
Three plans for every scale. All prices in APUSD (1 APUSD = $1 USD). No free tier. Upgrade or downgrade anytime.
/api/v1/billing/plansReturns all available billing plans with pricing details. No authentication required.
{
"plans": [
{
"name": "Paid",
"basePriceApusd": 1000,
"pricePerStream": 10,
"pricePerGb": 1,
"revenueSharePct": 10,
"includedStreams": 1000,
"includedGb": 10,
"watermarkingIncluded": false,
"whiteLabelAllowed": false,
"poweredByRemovable": false
},
{
"name": "Enterprise",
"basePriceApusd": 25000,
"pricePerStream": 1,
"pricePerGb": 0.50,
"revenueSharePct": 5,
"includedStreams": 50000,
"includedGb": 500,
"watermarkingIncluded": true,
"whiteLabelAllowed": true,
"poweredByRemovable": true
},
{
"name": "White-Label",
"basePriceApusd": 50000,
"pricePerStream": 0.50,
"pricePerGb": 0.25,
"revenueSharePct": 2,
"includedStreams": 500000,
"includedGb": 2000,
"watermarkingIncluded": true,
"whiteLabelAllowed": true,
"poweredByRemovable": true
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/billing/plans๐ Content Catalog
Browse licensed content available for streaming through your organization.
/api/v1/catalogList all content licensed to your organization. Returns videos and music tracks with metadata.
{
"content": [
{
"id": "uuid",
"title": "Video Title",
"type": "video",
"duration": 300,
"resolution": "1080p",
"thumbnail": "https://...",
"previewUrl": "https://..."
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/catalog \
-H "Authorization: Bearer blk_live_xxx"/api/v1/catalog/{contentId}Get detailed metadata for a specific content item. Verify your organization has a license for this content.
{
"id": "uuid",
"title": "Video Title",
"description": "Full description...",
"type": "video",
"duration": 300,
"resolution": "1080p",
"isWatermarked": true,
"thumbnail": "https://...",
"previewUrl": "https://..."
}curl -X GET https://api.blaqclouds.io/api/v1/catalog/content-uuid \
-H "Authorization: Bearer blk_live_xxx"๐ฌ Streaming
Create watermarked stream sessions for your viewers. Each stream gets a unique 40-bit forensic fingerprint.
/api/v1/stream/{contentId}Create a stream session for a viewer. If a signed viewer token is provided, the platform verifies the token, auto-generates a viewer wallet (if new), and assigns a permanent 40-bit binary_id. If no viewer token is provided, a random viewer ID is generated (backward compatible).
{
"viewerToken": "eyJhbGciOi...", // JWT signed by your org's private key
"walletAddress": "0x..." // optional, if you already have a wallet for this viewer
}{
"sessionId": "uuid",
"playlistUrl": "/api/v1/stream/content-uuid/playlist?session=xxx",
"binaryId": "0100111100000111101001011000000101101111",
"walletAddress": "0xABC123...",
"isNewViewer": true,
"expiresAt": "2026-08-02T00:00:00Z"
}curl -X POST https://api.blaqclouds.io/api/v1/stream/content-uuid \
-H "Authorization: Bearer blk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"viewerToken": "eyJhbGciOi..."
}'/api/v1/stream/{contentId}/playlistFetch the HLS playlist for a stream session. For watermarked content, segment URLs are rewritten to serve A/B variants based on the viewer's binary_id.
#EXTM3U
#EXT-X-KEY:METHOD=AES-128,URI="..."
#EXT-X-TARGETDURATION:10
#EXTINF:10.000000,
/api/v1/stream/content-uuid/segment/0?session=xxx
#EXTINF:10.000000,
/api/v1/stream/content-uuid/segment/1?session=xxx
...curl -X GET "https://api.blaqclouds.io/api/v1/stream/content-uuid/playlist?session=session-uuid" \
-H "Authorization: Bearer blk_live_xxx"/api/v1/stream/{contentId}/segment/{seg}Fetch a watermarked HLS segment. The platform serves variant A or B based on the viewer's 40-bit binary_id โ bit 0 = segment 0, bit 1 = segment 1, etc. (repeating every 40 segments). This is the forensic watermark fingerprint.
Binary data (video/mp2t)curl -X GET "https://api.blaqclouds.io/api/v1/stream/content-uuid/segment/0?session=session-uuid" \
-H "Authorization: Bearer blk_live_xxx" \
-o segment0.ts/api/v1/stream/sessions/{sessionId}End a stream session. Marks the session as ended and stops serving segments for it.
{ "success": true }curl -X DELETE https://api.blaqclouds.io/api/v1/stream/sessions/session-uuid \
-H "Authorization: Bearer blk_live_xxx"๐๏ธ Viewer Tracking
Manage viewers, their wallets, and forensic fingerprints. Each viewer has a permanent EVM wallet and 40-bit binary_id for leak tracing.
/api/v1/viewersList all viewers for your organization. Supports pagination and filtering by blocked status.
{
"viewers": [
{
"id": "uuid",
"externalViewerId": "user-42718",
"walletAddress": "0xABC123...",
"binaryId": "0100111100...",
"email": "john@yourorg.com",
"totalStreams": 42,
"isBlocked": false,
"firstSeen": "2026-08-01T...",
"lastSeen": "2026-08-01T..."
}
],
"total": 1,
"page": 1
}curl -X GET https://api.blaqclouds.io/api/v1/viewers \
-H "Authorization: Bearer blk_live_xxx"/api/v1/viewers/{viewerId}Get detailed information about a specific viewer, including their wallet, binary_id, and stream history.
{
"id": "uuid",
"externalViewerId": "user-42718",
"walletAddress": "0xABC123...",
"binaryId": "0100111100...",
"email": "john@yourorg.com",
"totalStreams": 42,
"isBlocked": false,
"firstSeen": "2026-08-01T...",
"lastSeen": "2026-08-01T...",
"streamSessions": [...]
}curl -X GET https://api.blaqclouds.io/api/v1/viewers/viewer-uuid \
-H "Authorization: Bearer blk_live_xxx"/api/v1/viewers/{viewerId}/blockBlock a viewer. Blocked viewers cannot create new stream sessions. Use this when a viewer is suspected of leaking content.
{ "reason": "Suspected content leak" }{ "success": true }curl -X POST https://api.blaqclouds.io/api/v1/viewers/viewer-uuid/block \
-H "Authorization: Bearer blk_live_xxx" \
-H "Content-Type: application/json" \
-d '{ "reason": "Suspected content leak" }'/api/v1/viewers/{viewerId}/unblockUnblock a previously blocked viewer.
{ "success": true }curl -X POST https://api.blaqclouds.io/api/v1/viewers/viewer-uuid/unblock \
-H "Authorization: Bearer blk_live_xxx"/api/v1/viewers/search?binaryId={binaryId}Search for a viewer by their 40-bit forensic fingerprint. Used after forensic analysis of leaked content to identify the source.
{
"viewer": {
"id": "uuid",
"externalViewerId": "user-42718",
"walletAddress": "0xABC123...",
"binaryId": "0100111100...",
"organizationName": "Your Organization Inc.",
"email": "john@yourorg.com",
"totalStreams": 42,
"firstSeen": "2026-08-01T..."
}
}curl -X GET "https://api.blaqclouds.io/api/v1/viewers/search?binaryId=0100111100000111101001011000000101101111" \
-H "Authorization: Bearer blk_live_xxx"๐ Webhooks
Receive notifications when viewer wallets are created, streams start, or viewers are blocked. Webhooks are signed with HMAC-SHA256.
/api/v1/webhookUpdate your webhook URL and/or regenerate your webhook secret. The secret is used to sign all webhook deliveries for verification.
{
"webhookUrl": "https://yourorg.com/webhooks/blaqclouds",
"regenerateSecret": true
}{
"webhookUrl": "https://yourorg.com/webhooks/blaqclouds",
"webhookSecret": "newsecret..."
}curl -X PUT https://api.blaqclouds.io/api/v1/webhook \
-H "Authorization: Bearer blk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"webhookUrl": "https://yourorg.com/webhooks/blaqclouds",
"regenerateSecret": true
}'/api/v1/webhook/deliveriesView webhook delivery history, including status, response codes, and retry attempts.
{
"deliveries": [
{
"id": "uuid",
"eventType": "viewer.created",
"status": "delivered",
"attempts": 1,
"responseCode": 200,
"createdAt": "2026-08-01T...",
"deliveredAt": "2026-08-01T..."
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/webhook/deliveries \
-H "Authorization: Bearer blk_live_xxx"/api/v1/webhook/testSend a test webhook to your configured URL. Useful for verifying your endpoint is working.
{
"success": true,
"responseCode": 200
}curl -X POST https://api.blaqclouds.io/api/v1/webhook/test \
-H "Authorization: Bearer blk_live_xxx"๐ฐ Billing
Track usage, view invoices, fund your balance, and manage autopay settings.
/api/v1/billing/usageGet your current billing period usage โ total streams, bandwidth consumed, and amount due.
{
"totalStreams": 1542,
"totalBytes": 53687091200,
"amountDue": 15420,
"balance": 50000,
"periodStart": "2026-08-01T...",
"periodEnd": "2026-09-01T..."
}curl -X GET https://api.blaqclouds.io/api/v1/billing/usage \
-H "Authorization: Bearer blk_live_xxx"/api/v1/billing/invoicesView your invoice history with payment status.
{
"invoices": [
{
"id": "uuid",
"periodStart": "2026-07-01T...",
"periodEnd": "2026-08-01T...",
"totalStreams": 1200,
"amountApusd": 12000,
"paymentStatus": "paid",
"paidAt": "2026-08-01T..."
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/billing/invoices \
-H "Authorization: Bearer blk_live_xxx"/api/v1/billing/fundFund your account balance. For APUSD: returns the wallet address to send payment to. For Stripe: creates a payment intent and returns the client secret. Max amount: $1,000,000.
{
"method": "apusd", // or "stripe"
"amount": 50000
}// APUSD:
{
"method": "apusd",
"walletAddress": "0x...",
"amount": 50000,
"status": "pending"
}
// Stripe:
{
"method": "stripe",
"clientSecret": "pi_xxx_secret_xxx",
"amount": 50000
}curl -X POST https://api.blaqclouds.io/api/v1/billing/fund \
-H "Authorization: Bearer blk_live_xxx" \
-H "Content-Type: application/json" \
-d '{ "method": "stripe", "amount": 50000 }'/api/v1/billing/balanceGet your current APUSD and Stripe balances, plus any pending charges.
{
"apusdBalance": 50000,
"stripeBalance": 0,
"pendingCharges": 15420
}curl -X GET https://api.blaqclouds.io/api/v1/billing/balance \
-H "Authorization: Bearer blk_live_xxx"/api/v1/billing/autopayEnable or disable automatic payment when invoices are generated. Supports APUSD (on-chain) or Stripe (fiat).
{
"enabled": true,
"method": "stripe"
}{ "success": true }curl -X PUT https://api.blaqclouds.io/api/v1/billing/autopay \
-H "Authorization: Bearer blk_live_xxx" \
-H "Content-Type: application/json" \
-d '{ "enabled": true, "method": "stripe" }'๐ Forensics
Analyze leaked content to trace it back to the specific viewer. The forensic chain provides legally defensible evidence.
/api/v1/forensics/analyzeSubmit leaked content for forensic analysis. The platform extracts the 40-bit binary_id from the watermarked content (DTCWT for video, STFT for music) and traces it to the viewer, organization, and stream session.
// Multipart form:
// - file: leaked content file (video or audio)
// - contentId: UUID of the original content
// - contentType: "video" or "music"{
"binaryId": "0100111100000111101001011000000101101111",
"confidence": 1.0,
"matchedSession": {
"sessionId": "uuid",
"viewerId": "uuid",
"externalViewerId": "user-42718",
"walletAddress": "0xABC123...",
"ipAddress": "203.0.113.50",
"streamDate": "2026-08-01T14:32:00Z"
},
"evidenceChain": {
"organization": "Your Organization Inc.",
"viewer": "user-42718",
"wallet": "0xABC123...",
"content": "Video Title",
"streamDate": "2026-08-01T14:32:00Z",
"ipAddress": "203.0.113.50",
"confidence": 1.0
},
"caseId": "uuid"
}curl -X POST https://api.blaqclouds.io/api/v1/forensics/analyze \
-H "Authorization: Bearer blk_live_xxx" \
-F "file=@leaked-video.mp4" \
-F "contentId=content-uuid" \
-F "contentType=video"/api/v1/forensics/casesList all forensic cases for your organization.
{
"cases": [
{
"id": "uuid",
"contentId": "content-uuid",
"binaryId": "010011...",
"confidence": 1.0,
"status": "completed",
"matchedViewer": "user-42718",
"createdAt": "2026-08-01T..."
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/forensics/cases \
-H "Authorization: Bearer blk_live_xxx"/api/v1/forensics/cases/{caseId}Get full details of a forensic case, including the complete evidence chain.
{
"id": "uuid",
"contentId": "content-uuid",
"binaryId": "0100111100...",
"confidence": 1.0,
"status": "completed",
"evidenceChain": {
"organization": "Your Organization Inc.",
"viewer": "user-42718",
"wallet": "0xABC123...",
"content": "Video Title",
"streamDate": "2026-08-01T14:32:00Z",
"ipAddress": "203.0.113.50",
"confidence": 1.0
}
}curl -X GET https://api.blaqclouds.io/api/v1/forensics/cases/case-uuid \
-H "Authorization: Bearer blk_live_xxx"โ๏ธ Admin (Platform Owner)
Platform administration endpoints. These use wallet auth (SIWE), not API keys. Only platform admins can access these.
/api/v1/admin/organizationsList all registered organizations with usage stats. Admin-only (wallet auth + isAdmin check).
{
"organizations": [
{
"id": "uuid",
"name": "Your Organization Inc.",
"email": "contact@yourorg.com",
"plan": "paid",
"isActive": true,
"streamsThisMonth": 1542,
"apusdBalance": 50000,
"totalApiKeys": 1,
"activeLicenses": 3
}
]
}curl -X GET https://api.blaqclouds.io/api/v1/admin/organizations \
-H "Authorization: Bearer <siwe_jwt_token>"/api/v1/admin/organizations/{id}/licenseAssign a content license to an organization. Supports "all" (access to all content) or "specific" (individual content ID).
{
"contentId": "*", // or specific UUID
"contentType": "video", // or "music"
"licenseScope": "all", // or "specific"
"watermarkingEnabled": true,
"pricePerStream": 10
}{ "success": true, "licenseId": "uuid" }curl -X POST https://api.blaqclouds.io/api/v1/admin/organizations/org-uuid/license \
-H "Authorization: Bearer <siwe_jwt_token>" \
-H "Content-Type: application/json" \
-d '{ "contentId": "*", "contentType": "video", "licenseScope": "all" }'/api/v1/admin/organizations/{id}/rate-limitSet rate limits for an organization. Both org-level and per-key limits are supported.
{
"rateLimitPerHour": 10000,
"monthlyStreamLimit": 100000
}{ "success": true }curl -X POST https://api.blaqclouds.io/api/v1/admin/organizations/org-uuid/rate-limit \
-H "Authorization: Bearer <siwe_jwt_token>" \
-H "Content-Type: application/json" \
-d '{ "rateLimitPerHour": 10000 }'๐ Webhook Events
Webhooks are sent as POST requests to your configured URL. Each delivery is signed with HMAC-SHA256 using your webhook secret.
X-BLAQClouds-Signature: HMAC-SHA256(webhook_secret, body)
X-BLAQClouds-Event: viewer.created
// Verify in Python:
import hmac, hashlib
expected = hmac.new(secret.encode(), body, hashlib.sha256).hexdigest()
hmac.compare_digest(signature, expected)| Event | Description |
|---|---|
| viewer.created | A new viewer wallet was auto-generated. Payload includes viewerId, walletAddress, and binaryId. |
| viewer.stream | A viewer started a new stream. Payload includes viewerId, contentId, and sessionId. |
| viewer.blocked | A viewer was blocked (by admin or organization). Payload includes viewerId and reason. |
| organization.suspended | An organization was suspended by the platform admin. Payload includes organizationId and reason. |
โ ๏ธ Error Codes
All error responses follow a consistent format with an error code for programmatic handling.
{
"error": "Human-readable message",
"code": "ERROR_CODE",
"status": 403
}| Code | Status | Description |
|---|---|---|
| INVALID_API_KEY | 401 | API key is missing, invalid, or revoked. |
| INSUFFICIENT_SCOPE | 403 | API key does not have the required scope for this endpoint. |
| RATE_LIMIT_EXCEEDED | 429 | Rate limit exceeded. Check X-RateLimit-Reset header for when the window resets. |
| NOT_FOUND | 404 | Requested resource (content, viewer, session) was not found. |
| LICENSE_REQUIRED | 403 | Your organization does not have a license for this content. |
| INSUFFICIENT_BALANCE | 402 | Your account balance is insufficient for this operation. |
| BAD_REQUEST | 400 | Malformed request โ missing required fields or invalid values. |
| INTERNAL_ERROR | 500 | Internal server error. Contact support if persistent. |
Powered by BLAQclouds โ Forensic DRM for content licensing