Edge Storage
Edge Storage
Two lightweight storage primitives for your app: a key–value store for hot data and blob storage for files. Each is reachable over a simple REST API from anywhere your code runs.
Both live under Project → Storage in the dashboard and share the same base URL. Replace my-project with your project slug in every example below.
KV Store
A fast key–value store for session data, counters, feature state, or any small hot value. Values are strings; optional TTL expiry is supported.
Authentication
Create a store in the dashboard to get a token shaped like dpx_kv_…. Send it as a Bearer token on every request. Each token is scoped to one store within one project.
Authorization: Bearer dpx_kv_xxxxxxxxxxxxxxxxxxxx
Endpoints
| Method | Path | Purpose |
|---|---|---|
GET | /api/kv/my-project | List all keys (no values) |
POST | /api/kv/my-project | Set a key (body: key, value) |
GET | /api/kv/my-project/{key} | Read one key |
PUT | /api/kv/my-project/{key} | Set one key |
DELETE | /api/kv/my-project/{key} | Delete one key |
Write a value
# Set with PUT (key in the path)
curl -X PUT https://deploxa.com/api/kv/my-project/greeting \
-H "Authorization: Bearer dpx_kv_xxx" \
-H "Content-Type: application/json" \
-d '{ "value": "hello", "ttl": 3600 }'
# Or POST with the key in the body
curl -X POST https://deploxa.com/api/kv/my-project \
-H "Authorization: Bearer dpx_kv_xxx" \
-H "Content-Type: application/json" \
-d '{ "key": "greeting", "value": "hello" }'ttl is optional and in seconds — the key auto-expires after that window. Omit it for a value that never expires.
Read a value
const res = await fetch("https://deploxa.com/api/kv/my-project/greeting", {
headers: { Authorization: `Bearer ${process.env.KV_TOKEN}` },
});
const { key, value, type, expiresAt } = await res.json();
// → { key: "greeting", value: "hello", type: "string", expiresAt: null }A missing or expired key returns 404.
Blob Storage
Store files — images, downloads, generated assets — and serve them over a stable public URL backed by S3. Upload files from the dashboard; read them programmatically or link them directly from your frontend.
Read a file
A GET to the file's path issues a short-lived signed redirect to the underlying object. No auth header is needed — the URL itself is the capability, so treat blob contents as public.
GET https://deploxa.com/api/blob/my-project/images/logo.png → 302 redirect to a signed, time-limited file URL
<!-- Use it anywhere a URL is expected --> <img src="https://deploxa.com/api/blob/my-project/images/logo.png" alt="Logo" />

