Build and Run
# Clone the repository
git clone https://github.com/overclockdb/overclockdb.git
cd overclockdb
# Build in release mode
cargo build --release
# Run the server
cargo run --release
The server starts on http://localhost:8108 by default.
Create a Collection
POST /api/v1/collections
Content-Type: application/json
{
"name": "products",
"fields": [
{"name": "title", "type": "string"},
{"name": "description", "type": "string"},
{"name": "price", "type": "float", "sort": true},
{"name": "category", "type": "string", "facet": true}
]
}
Search
POST /api/v1/collections/products/search
Content-Type: application/json
{
"q": "wireless headphones",
"query_by": ["title", "description"],
"filter": "price:>=100 AND category:=electronics",
"facets": ["category"],
"sort_by": "price:asc",
"limit": 20
}