QUICKSTART

Quickstart for Arabic-ready, container-based GPU compute

This guide walks you from account setup to workload submission, including model selection for Arabic AI use cases.

1
2
3
4
5

DCP job execution runs via Ollama (Windows/Linux) or MLX (macOS Apple Silicon) inference engines.

Choose your role path

Start from the flow that matches your role. DCP keeps one consistent trust model: sovereign Saudi-hosted compute, Arabic-first model support, and OpenAI-compatible API.

I am a renter

Follow the renter checklist and ship your first workload.

Open renter checklist

I am a provider

Register your GPU (NVIDIA or Apple Silicon), download the 4 MB app, and go online. No Docker needed.

Start provider onboarding

I am integrating API

Use auth and endpoint contracts for production-safe integration.

Open API integration start

How DCP Billing Works

  • 1. Before execution, DCP places an estimate hold in halala from your wallet.
  • 2. After completion, final cost is settled from actual runtime (not the estimate).
  • 3. Any unused hold is returned to wallet balance in halala automatically.

100 halala = 1 SAR.

Current flow: wallet top-up in SAR, estimate hold before execution, completion-based settlement, and automatic return of any unused hold.

Renter onboarding checklist

  1. 1. Register accountOpen
  2. 2. Add wallet balanceOpen
  3. 3. Choose GPU in marketplaceOpen
  4. 4. Submit workloadOpen
  5. 5. Monitor output and logsOpen
1

Get your API key

Prepare

Register a renter account at dcp.sa/renter/register. You'll receive a renter API key — copy it from the dashboard and keep it private.

Keep your key safe. It authenticates all API calls and is shown once.
2

Top up your balance

Fund

Fund wallet in SAR. Use the dashboard at dcp.sa/renter/billing, or call the API directly:

# Check available models (no auth needed)
curl https://api.dcp.sa/v1/models

Response

{
  "data": [
    {
      "id": "qwen3-30b-a3b",
      "name": "Qwen3 30B-A3B (MoE)",
      "provider_count": 1,
      "context_length": 32768,
      "max_vram_gb": 18
    }
  ]
}
Billing in every flow is the same: estimate hold in halala before start, runtime settlement after completion, unused hold returned automatically.
3

Browse available GPUs

Select

Fetch live providers from the marketplace and note the id for the compatible provider you choose:

# Run inference (OpenAI-compatible)
curl -X POST https://api.dcp.sa/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_RENTER_KEY" \
  -d '{
    "model": "qwen3-30b-a3b",
    "messages": [{"role": "user", "content": "What is the capital of Saudi Arabia?"}],
    "max_tokens": 100
  }'

Response

{
  "id": "chatcmpl-abc123",
  "model": "qwen3-30b-a3b",
  "choices": [{
    "message": {
      "role": "assistant",
      "content": "The capital of Saudi Arabia is Riyadh."
    }
  }],
  "usage": {
    "prompt_tokens": 15,
    "completion_tokens": 12,
    "total_tokens": 27
  }
}
Save the provider.id for your job submit request.
4

Submit a job

Submit

Submit an LLM job and pass your renter key in the x-renter-key header:

# Python (drop-in OpenAI replacement)
from openai import OpenAI

client = OpenAI(
    base_url="https://api.dcp.sa/v1",
    api_key="YOUR_RENTER_KEY"
)

response = client.chat.completions.create(
    model="qwen3-30b-a3b",
    messages=[{"role": "user", "content": "Hello"}],
    max_tokens=100
)
print(response.choices[0].message.content)

Response

# Node.js
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://api.dcp.sa/v1",
  apiKey: "YOUR_RENTER_KEY"
});

const response = await client.chat.completions.create({
  model: "qwen3-30b-a3b",
  messages: [{ role: "user", content: "Hello" }]
});
console.log(response.choices[0].message.content);
DCP holds an estimate before execution and reconciles against actual runtime when the job completes.
5

Monitor job status

Track

Poll the job endpoint until status reaches completed, then fetch the output:

# Poll status
curl https://api.dcp.sa/api/jobs/job-abc123

# Fetch output (returns 202 while running, 200 when completed)
curl https://api.dcp.sa/api/jobs/job-abc123/output

Response

{
  "type": "text",
  "response": "Transformers are a neural network architecture...",
  "billing": {
    "actual_cost_halala": 188,
    "refunded_halala": 12
  }
}
Status flow: pending → queued → running → completed
Logs are available at GET /api/jobs/:id/logs

SDK Quickstarts (Node, Python, CLI)

Use one SDK track at a time and verify key, connectivity, and completion before scaling.

Node.js SDK

Typed renter workflows from backend services.

Install

npm install openai

Submit + wait

import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://api.dcp.sa/v1",
  apiKey: process.env.DCP_RENTER_KEY,
});

const response = await client.chat.completions.create({
  model: "qwen3-30b-a3b",
  messages: [{ role: "user", content: "Explain transformer attention in 2 lines." }],
  max_tokens: 100,
});

console.log(response.choices[0].message.content);

Verify connectivity

// Check balance
const res = await fetch("https://api.dcp.sa/api/renters/me", {
  headers: { "x-renter-key": process.env.DCP_RENTER_KEY }
});
const data = await res.json();
console.log(data.name, data.balance_halala + " halala");

Expected: your renter profile JSON with email and balance fields.

Verification checklist

  • Confirm your API key starts with dcp-renter-
  • Confirm top-up response includes success=true and new_balance_halala
  • Capture job_id from submit response before polling status