← Back to Home
Getting Started
WebDB provides a simple REST API for deploying static sites to the blockchain. All sites are stored immutably on Golem DB and served via subdomains.
Authentication
No authentication required for the free tier. Simply start uploading!
Endpoints
POST
/api/upload/:siteId
Deploy a new site with multiple files
Upload Your Site
curl -X POST https://webdb.usecases.arkiv.network/api/upload/mysite \ -F "files=@index.html;filename=index.html" \ -F "files=@style.css;filename=style.css" \ -F "files=@script.js;filename=script.js"
Response
{
"success": true,
"siteId": "mysite",
"url": "https://mysite.webdb.usecases.arkiv.network",
"files": [
{ "path": "index.html", "size": 2048, "txHash": "0x..." },
{ "path": "style.css", "size": 1024, "txHash": "0x..." }
]
}
GET
/api/sites/:siteId
Get site metadata and file information
curl https://webdb.usecases.arkiv.network/api/sites/mysite
GET
/health
Check service status
curl https://webdb.usecases.arkiv.network/health
File Upload
Upload multiple files in a single request:
HTML + CSS + JS Example
curl -X POST https://webdb.usecases.arkiv.network/api/upload/my-portfolio \ -F "files=@index.html;filename=index.html" \ -F "files=@styles/main.css;filename=main.css" \ -F "files=@js/app.js;filename=app.js" \ -F "files=@images/logo.png;filename=logo.png"
Using JavaScript
const formData = new FormData();
formData.append('files', file1, 'index.html');
formData.append('files', file2, 'style.css');
const response = await fetch('/api/upload/mysite', {
method: 'POST',
body: formData
});
const result = await response.json();
Limits
- Maximum file size: 2 MB
- Maximum site size: 50 MB
- Sites expire after 30 days (BTL)
- Subdomain format: yoursite.webdb.usecases.arkiv.network
Examples
Deploy NFT Gallery
curl -X POST https://webdb.usecases.arkiv.network/api/upload/nft-gallery \ -F "files=@gallery.html;filename=index.html" \ -F "files=@gallery.css;filename=style.css"
Deploy Documentation
curl -X POST https://webdb.usecases.arkiv.network/api/upload/project-docs \ -F "files=@docs/index.html;filename=index.html" \ -F "files=@docs/api.html;filename=api.html"
Blockchain Integration
All files are stored on Golem DB blockchain. View transactions at:
https://explorer.kaolin.hoodi.arkiv.network