Loading…
Loading documentation...
Provision serverless JSONB document, pgvector RAG and key-value databases with tunable consistency, key rotation and 100K free RUs.
Commands checked on 2026-11-12 with SAU Multi-Model Cloud Database v1.7, pgvector, sau CLI 0.2.0.
You will have a managed SAU Multi-Model Cloud Database instance on Home > Cloud databases (/dashboard/cloud-db)—supporting serverless JSONB document collections, pgvector cosine-similarity embeddings for AI Retrieval-Augmented Generation (RAG), and low-latency key-value lookups—configured with tunable consistency, optimistic ETag concurrency, zero-downtime dual-key rotation, and 100,000 Request Units (RU) per month included free ($0.25 per 1M RU thereafter).
/dashboard.cloud:read and cloud:write scopes (Account settings > API keys at /account/api-keys).sau CLI v0.2.0 or curl + jq to insert documents, run vector queries, and inspect RU consumption.Open Home > Cloud databases (/dashboard/cloud-db) and click Create database, or provision from the terminal with sau cosmosdb create:
DOCUMENT_NOSQL: Schema-flexible JSONB collections with indexed property filters and ETag optimistic locking.VECTOR_AI: JSON documents paired with dense floating-point embedding vectors (embeddings: number[]) for RAG semantic search.KEY_VALUE: Sub-millisecond point reads and TTL-capable state storage for sessions, rate counters, and agent memory.STRONG, BOUNDED_STALENESS, SESSION [default], or EVENTUAL).# Create a Vector AI database for RAG document chunks
sau cosmosdb create rag-knowledge-db --model VECTOR_AI --consistency SESSION
# List your active Multi-Model Cloud Databases
sau cosmosdb list -o table
Save the returned id (for example cdb_01j...) for subsequent document and vector operations.
Insert or update items in named collections using sau cosmosdb item-upsert or POST /api/v1/cosmos. Every mutation returns the consumed requestUnits (RU) and a fresh etag version string:
# Upsert a structured document via sau CLI
sau cosmosdb item-upsert YOUR_DATABASE_ID "doc-pricing-faq" \
'{"title":"Cloud Storage Pricing","category":"storage","summary":"250 GiB plan starts at $9/mo hosted via Microsoft Azure."}' \
--collection "kb_chunks"
# Upsert a document with an embedding vector via REST API v1
curl -fsSL -X POST "https://serversareup.com/api/v1/cosmos" \
-H "Authorization: Bearer sau_your_token_here" \
-H "Content-Type: application/json" \
-d '{
"action": "upsert-item",
"databaseId": "YOUR_DATABASE_ID",
"collectionName": "kb_chunks",
"itemKey": "doc-worm-locks",
"document": {
"title": "Immutable WORM Retention",
"category": "security",
"text": "Time-bound WORM locks protect compliance blobs up to 10 years."
},
"embedding": [0.12, -0.04, 0.88, 0.31, -0.19, 0.45, 0.09, 0.62]
}' | jq .
To prevent lost updates when two workers modify the same order or session document concurrently, pass "ifMatchEtag": "<previous-etag>" in your upsert-item payload; stale writes fail cleanly with 412 Precondition Failed instead of clobbering newer state.
Query JSON collections from the CLI or run hybrid metadata + cosine vector searches over HTTP:
# Query all items in a collection via CLI
sau cosmosdb items-query YOUR_DATABASE_ID --collection kb_chunks -o json
# Run a vector similarity search for RAG context retrieval
curl -fsSL -X POST "https://serversareup.com/api/v1/cosmos" \
-H "Authorization: Bearer sau_your_token_here" \
-H "Content-Type: application/json" \
-d '{
"action": "vector-search",
"databaseId": "YOUR_DATABASE_ID",
"collectionName": "kb_chunks",
"queryVector": [0.11, -0.05, 0.86, 0.29, -0.18, 0.44, 0.10, 0.60],
"topK": 3
}' | jq .
Each Multi-Model Cloud Database issues both a Primary Key and a Secondary Key:
/dashboard/app-config) or Access > Key vault & KMS (/dashboard/key-vault).sau cosmosdb keys-rotate YOUR_DATABASE_ID), verify app health, and store the new Primary Key in Key Vault.Verify your stored item count, consistency setting, and cumulative Request Unit consumption on /dashboard/cloud-db or via the API:
curl -fsSL "https://serversareup.com/api/v1/cosmos?databaseId=YOUR_DATABASE_ID" \
-H "Authorization: Bearer sau_your_token_here" | jq '{
database: .database | {id, name, engineModel, consistencyLevel, totalRuConsumed},
itemCount: (.items | length)
}'
Check Operations > Governance & FinOps (/dashboard/governance) (sau governance show) to see your CLOUD_DB_RU meter usage against your free 100,000 RU/mo allowance.
412 Precondition Failed on upsert-item. Another worker updated the item after you read its etag. Re-fetch the item, re-apply your business delta, and retry with the latest etag.0 or dimension mismatch. Ensure every document in a single collection uses embeddings generated by the same embedding model and vector dimension (for example 768 or 1536 floats)—never mix two different embedding models inside one collection.sau cosmosdb delete blocked with 409 Conflict. A CanNotDelete lock is active on the database or its Resource Group (sau lock list -o table).collectionName (kb_chunks, chat_sessions, job_checkpoints) and attach a CanNotDelete lock (sau lock create ...) to every production database immediately after creation.STRONG consistency for financial balances and inventory counters, SESSION consistency for user-facing web apps and chat history, and EVENTUAL for high-throughput telemetry or analytics caches./dashboard/recovery-vault) for scheduled immutable recovery points.Every Servers Are Up virtual machine and container includes an integrated HTML5 browser-based SSH, RDP, and VNC console in your dashboard, default-off inbound firewall rules with per-IP allow-lists, and full programmatic control via REST API v1 and Model Context Protocol (MCP). Explore our Virtual Datacenter Plans or reach out to Servers Are Up Support.