API Access
Use the Deiza API for programmatic access
# API Access
The Deiza API allows you to programmatically access your data and integrate with external tools.
Requirements
API access is available on the Scale plan only.
Creating an API Key
Using Your API Key
Include your API key in the Authorization header:
curl -X GET https://yourdomain.deiza.io/api/v1/contacts \
-H "Authorization: Bearer dza_your_api_key_here" \
-H "Content-Type: application/json"
Available Endpoints
Core Endpoints
| Endpoint | Methods | Description |
|----------|---------|-------------|
| /api/v1/contacts | GET, POST | Manage contacts |
| /api/v1/invoices | GET, POST | Manage invoices |
| /api/v1/websites | GET | Get website info |
Website Builder Endpoints
| Endpoint | Methods | Description |
|----------|---------|-------------|
| /api/generate-section | POST | Generate a new section with AI content |
| /api/process-instruction | POST | Process natural language design instructions |
| /api/regenerate-section | POST | Regenerate an existing section with new AI content |
Generate Section API
Create a new section for your website:
curl -X POST https://yourdomain.deiza.io/api/generate-section \
-H "Authorization: Bearer dza_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"sectionType": "testimonials",
"layout": "cards",
"columns": 3,
"itemCount": 3,
"businessContext": {
"businessName": "Your Business",
"businessType": "consulting"
}
}'
Available section types: about, services, features, testimonials, team, faq, gallery, stats, pricing, timeline, partners, newsletter, contact, cta, hours.
Process Instruction API
Send natural language commands to modify website design:
curl -X POST https://yourdomain.deiza.io/api/process-instruction \
-H "Authorization: Bearer dza_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"instruction": "Move the testimonials section to the top",
"websiteData": { ... },
"sections": [...]
}'
Supported instructions include: