Introduction
SWELLEnterprise API provides comprehensive access to all modules and features. Use API tokens for authentication and configure webhooks to receive real-time event notifications.
# SWELLEnterprise API Documentation
Welcome to the SWELLEnterprise API! This comprehensive REST API provides programmatic access to all modules and features in your SWELL account.
## Quick Start
1. **Create an API Token**: Go to Settings → API Tokens in your account
2. **Use the Token**: Include it in the `Authorization` header: `Bearer your-token-here`
3. **Make Requests**: All endpoints are prefixed with `/api/v1/`
## Authentication
All API requests require authentication using a Bearer token. You can create and manage API tokens in your account settings.
**Example Request:**
```bash
curl -H "Authorization: Bearer your-api-token-here" \
-H "Accept: application/json" \
https://your-domain.com/api/v1/crm/contacts
```
**JavaScript Example:**
```javascript
fetch('https://your-domain.com/api/v1/crm/contacts', {
headers: {
'Authorization': 'Bearer your-api-token-here',
'Accept': 'application/json'
}
})
```
## Rate Limiting
API requests are rate limited to **60 requests per minute** per token. If you exceed this limit, you'll receive a `429 Too Many Requests` response with a `Retry-After` header indicating when you can retry.
## Pagination
List endpoints support pagination with the following query parameters:
- `page`: Page number (default: 1)
- `per_page`: Items per page (default: 15, max: 100)
**Example:**
```
GET /api/v1/crm/contacts?page=2&per_page=50
```
## Filtering & Search
Most list endpoints support:
- `search`: Full-text search across relevant fields
- `sort`: Sort by field (e.g., `sort=name` or `sort=-created_at` for descending)
- Field-specific filters (e.g., `company_id`, `status_id`)
**Example:**
```
GET /api/v1/crm/contacts?search=john&company_id=1&sort=-created_at
```
## Bulk Operations
Some endpoints support bulk operations for creating, updating, or deleting multiple records at once. See individual endpoint documentation for details.
## Webhooks
Configure webhooks to receive real-time notifications when events occur in your account. Webhooks use HMAC signatures for security verification.
- **Create Subscriptions**: `POST /api/v1/webhooks/subscriptions`
- **Available Events**: `GET /api/v1/webhooks/events`
- **Test Webhooks**: Use the test endpoint to verify your webhook configuration
See the Webhooks section for complete documentation.
## Error Handling
The API uses standard HTTP status codes and returns detailed error messages:
- `400 Bad Request`: Invalid request parameters
- `401 Unauthorized`: Missing or invalid authentication token
- `403 Forbidden`: Insufficient permissions
- `404 Not Found`: Resource not found
- `422 Validation Error`: Request validation failed
- `429 Too Many Requests`: Rate limit exceeded
- `500 Internal Server Error`: Server error
**Error Response Format:**
```json
{
"error": {
"message": "Validation failed",
"code": "VALIDATION_ERROR",
"errors": {
"email": ["The email field is required."]
}
},
"meta": {
"timestamp": "2026-01-15T12:00:00Z"
}
}
```
## Response Format
All successful responses follow this structure:
```json
{
"data": { ... },
"message": "Operation successful",
"meta": {
"timestamp": "2026-01-15T12:00:00Z",
"version": "v1"
}
}
```
Paginated responses include additional metadata:
```json
{
"data": [ ... ],
"meta": {
"current_page": 1,
"from": 1,
"last_page": 10,
"per_page": 15,
"to": 15,
"total": 150,
"timestamp": "2026-01-15T12:00:00Z",
"version": "v1"
},
"links": { ... }
}
```
<aside>💡 **Tip**: As you scroll, you'll see code examples for working with the API in different programming languages in the dark area to the right (or as part of the content on mobile). You can switch the language used with the tabs at the top right.</aside>
Authenticating requests
To authenticate requests, include an Authorization header with the value "Bearer Bearer {YOUR_API_TOKEN}".
All authenticated endpoints are marked with a requires authentication badge in the documentation below.
You can create API tokens in your account settings. Go to Settings → API Tokens to generate a new token.
Authentication
Create a new API token.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/tokens" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"b\",
\"abilities\": [
\"architecto\"
],
\"expires_at\": \"2026-03-27T17:33:05\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/tokens"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "b",
"abilities": [
"architecto"
],
"expires_at": "2026-03-27T17:33:05"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Revoke a specific API token.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/tokens/architecto" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/tokens/architecto"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Revoke all API tokens for the authenticated user.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/tokens" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/tokens"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
CRM - Companies
Store a newly created company.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/crm/companies" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Acme Corp\",
\"email\": \"info@acme.com\",
\"phone\": \"+1234567890\",
\"website\": \"https:\\/\\/acme.com\",
\"address\": \"123 Main St\",
\"notes\": \"Important client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/companies"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Acme Corp",
"email": "info@acme.com",
"phone": "+1234567890",
"website": "https:\/\/acme.com",
"address": "123 Main St",
"notes": "Important client"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified company.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/crm/companies/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Acme Corp\",
\"email\": \"info@acme.com\",
\"phone\": \"+1234567890\",
\"website\": \"https:\\/\\/acme.com\",
\"address\": \"123 Main St\",
\"notes\": \"Important client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/companies/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Acme Corp",
"email": "info@acme.com",
"phone": "+1234567890",
"website": "https:\/\/acme.com",
"address": "123 Main St",
"notes": "Important client"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified company.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/crm/companies/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/crm/companies/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
CRM - Contacts
Store a newly created contact.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/crm/contacts" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"first_name\": \"John\",
\"last_name\": \"Doe\",
\"email\": \"john@example.com\",
\"phone\": \"+1234567890\",
\"company_id\": 1,
\"notes\": \"Important client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"first_name": "John",
"last_name": "Doe",
"email": "john@example.com",
"phone": "+1234567890",
"company_id": 1,
"notes": "Important client"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified contact.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/crm/contacts/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"first_name\": \"John\",
\"last_name\": \"Doe\",
\"email\": \"john@example.com\",
\"phone\": \"+1234567890\",
\"company_id\": 1,
\"notes\": \"Important client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"first_name": "John",
"last_name": "Doe",
"email": "john@example.com",
"phone": "+1234567890",
"company_id": 1,
"notes": "Important client"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified contact.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/crm/contacts/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bulk create contacts.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/crm/contacts/bulk" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contacts\": [
{
\"first_name\": \"John\",
\"last_name\": \"Doe\",
\"email\": \"john@example.com\"
}
]
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts/bulk"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contacts": [
{
"first_name": "John",
"last_name": "Doe",
"email": "john@example.com"
}
]
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bulk update contacts.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/crm/contacts/bulk" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contacts\": [
{
\"id\": 1,
\"first_name\": \"Jane\"
},
{
\"id\": 2,
\"email\": \"new@example.com\"
}
]
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts/bulk"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contacts": [
{
"id": 1,
"first_name": "Jane"
},
{
"id": 2,
"email": "new@example.com"
}
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Bulk delete contacts.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/crm/contacts/bulk" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"ids\": [
1,
2,
3
]
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/contacts/bulk"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"ids": [
1,
2,
3
]
};
fetch(url, {
method: "DELETE",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
CRM - Leads
Store a newly created lead.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/crm/leads" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"New Project Opportunity\",
\"value\": \"5000.00\",
\"status_id\": 1,
\"source_id\": 1,
\"company_id\": 1,
\"assigned_to\": 1,
\"description\": \"Potential client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/leads"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "New Project Opportunity",
"value": "5000.00",
"status_id": 1,
"source_id": 1,
"company_id": 1,
"assigned_to": 1,
"description": "Potential client"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified lead.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/crm/leads/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"New Project Opportunity\",
\"value\": \"5000.00\",
\"status_id\": 1,
\"source_id\": 1,
\"company_id\": 1,
\"assigned_to\": 1,
\"description\": \"Potential client\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/crm/leads/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "New Project Opportunity",
"value": "5000.00",
"status_id": 1,
"source_id": 1,
"company_id": 1,
"assigned_to": 1,
"description": "Potential client"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified lead.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/crm/leads/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/crm/leads/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Client Portal
Manage client portal access and configuration.
Get Portal Configuration
requires authentication
Get the current portal configuration for the authenticated tenant.
Example request:
curl --request GET \
--get "http://localhost/api/v1/api/v1/client-portal/config" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/client-portal/config"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
}).then(response => response.json());Example response (200):
{
"data": {
"portal_name": "Client Portal",
"primary_color": "#3B82F6",
"enabled_modules": [
"invoices",
"proposals"
],
"is_active": true
}
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Send Portal Invitation to Contact
requires authentication
Send a portal access invitation email to a contact.
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/client-portal/contacts/1/invite" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"custom_message\": \"\\\"Welcome to your client portal!\\\"\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/client-portal/contacts/1/invite"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"custom_message": "\"Welcome to your client portal!\""
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Portal invitation sent successfully",
"token": "portal-access-token-here"
}
Example response (404):
{
"message": "Contact not found"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Send Portal Invitation to Company
requires authentication
Send a portal access invitation email to a company.
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/client-portal/companies/1/invite" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"custom_message\": \"architecto\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/client-portal/companies/1/invite"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"custom_message": "architecto"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"message": "Portal invitation sent successfully",
"token": "portal-access-token-here"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Get Portal Token
requires authentication
Get or create a portal access token for a contact or company.
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/client-portal/token" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"contact\",
\"id\": \"1\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/client-portal/token"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "contact",
"id": "1"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Example response (200):
{
"token": "portal-access-token-here",
"url": "https://your-domain.com/client-portal/token-here",
"expires_at": "2026-02-19T00:00:00Z"
}
Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Endpoints
POST api/v1/projects/projects/{project_id}/approvals
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/approvals" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/approvals"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/approvals/{approval_id}/approve
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/approve" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/approve"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/approvals/{approval_id}/reject
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/reject" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/reject"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/approvals/{approval_id}/request-changes
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/request-changes" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/approvals/16/request-changes"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/revision-requests
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/revision-requests" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/revision-requests"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
PATCH api/v1/projects/projects/{project_id}/revision-requests/{revisionRequest_id}
requires authentication
Example request:
curl --request PATCH \
"http://localhost/api/v1/api/v1/projects/projects/16/revision-requests/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/revision-requests/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PATCH",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/annotations
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/annotations" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/annotations"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Upload a screenshot for use when creating an annotation.
requires authentication
Returns the path to store in annotation.screenshot_path.
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/upload-screenshot" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/upload-screenshot"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
PATCH api/v1/projects/projects/{project_id}/annotations/{id}
requires authentication
Example request:
curl --request PATCH \
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PATCH",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
DELETE api/v1/projects/projects/{project_id}/annotations/{id}
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/v1/projects/projects/{project_id}/annotations/{annotation_id}/comments
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16/comments" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/16/annotations/16/comments"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Switch user's current tenant context.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/tenant/switch/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/tenant/switch/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Register a push notification subscription
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/push/subscribe" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"endpoint\": \"http:\\/\\/www.bailey.biz\\/quos-velit-et-fugiat-sunt-nihil-accusantium-harum.html\",
\"keys\": {
\"p256dh\": \"architecto\",
\"auth\": \"architecto\"
}
}"
const url = new URL(
"http://localhost/api/v1/api/v1/push/subscribe"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"endpoint": "http:\/\/www.bailey.biz\/quos-velit-et-fugiat-sunt-nihil-accusantium-harum.html",
"keys": {
"p256dh": "architecto",
"auth": "architecto"
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Unregister a push notification subscription
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/push/unsubscribe" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"token\": \"architecto\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/push/unsubscribe"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"token": "architecto"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Resolve a connector token to a SWELL API token.
requires authentication
Called by the MCP server only (protected by X-MCP-Resolve-Secret).
Example request:
curl --request POST \
"http://localhost/api/v1/api/mcp/resolve" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"connector_token\": \"architecto\"
}"
const url = new URL(
"http://localhost/api/v1/api/mcp/resolve"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"connector_token": "architecto"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
POST api/upload-image
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/upload-image" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: multipart/form-data" \
--header "Accept: application/json" \
--form "file=@/tmp/phposan4t04930n19QyZyU" const url = new URL(
"http://localhost/api/v1/api/upload-image"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "multipart/form-data",
"Accept": "application/json",
};
const body = new FormData();
body.append('file', document.querySelector('input[name="file"]').files[0]);
fetch(url, {
method: "POST",
headers,
body,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Generate an image using DALL-E and store it locally (URLs expire after 60 min).
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/cover-image/generate-ai" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"prompt\": \"b\"
}"
const url = new URL(
"http://localhost/api/v1/api/cover-image/generate-ai"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"prompt": "b"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Finance - Estimates
Store a newly created estimate in storage.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/finance/estimates" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"contact_id\": 1,
\"company_id\": 1,
\"status\": \"draft\",
\"valid_until\": \"2026-12-31\",
\"subtotal\": \"1000.00\",
\"tax_rate\": \"10.00\",
\"currency\": \"USD\",
\"notes\": \"Estimate notes\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/finance/estimates"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"contact_id": 1,
"company_id": 1,
"status": "draft",
"valid_until": "2026-12-31",
"subtotal": "1000.00",
"tax_rate": "10.00",
"currency": "USD",
"notes": "Estimate notes"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified estimate in storage.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/finance/estimates/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/finance/estimates/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PUT",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified estimate from storage.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/finance/estimates/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/finance/estimates/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Finance - Invoices
Store a newly created invoice.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/finance/invoices" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"invoice_number\": \"INV-001\",
\"status\": \"draft\",
\"invoice_date\": \"2026-01-01\",
\"due_date\": \"2026-01-31\",
\"contact_id\": 1,
\"company_id\": 1,
\"subtotal\": \"1000.00\",
\"tax_rate\": \"10.00\",
\"tax_total\": \"100.00\",
\"total\": \"1100.00\",
\"late_fee_total\": \"0.00\",
\"currency\": \"USD\",
\"notes\": \"Payment terms\",
\"terms\": \"Net 30\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/finance/invoices"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"invoice_number": "INV-001",
"status": "draft",
"invoice_date": "2026-01-01",
"due_date": "2026-01-31",
"contact_id": 1,
"company_id": 1,
"subtotal": "1000.00",
"tax_rate": "10.00",
"tax_total": "100.00",
"total": "1100.00",
"late_fee_total": "0.00",
"currency": "USD",
"notes": "Payment terms",
"terms": "Net 30"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified invoice.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/finance/invoices/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"invoice_number\": \"INV-001\",
\"status\": \"paid\",
\"invoice_date\": \"2026-01-01\",
\"due_date\": \"2026-01-31\",
\"contact_id\": 1,
\"company_id\": 1,
\"subtotal\": \"1000.00\",
\"tax_rate\": \"10.00\",
\"tax_total\": \"100.00\",
\"total\": \"1100.00\",
\"late_fee_total\": \"0.00\",
\"currency\": \"USD\",
\"notes\": \"Payment terms\",
\"terms\": \"Net 30\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/finance/invoices/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"invoice_number": "INV-001",
"status": "paid",
"invoice_date": "2026-01-01",
"due_date": "2026-01-31",
"contact_id": 1,
"company_id": 1,
"subtotal": "1000.00",
"tax_rate": "10.00",
"tax_total": "100.00",
"total": "1100.00",
"late_fee_total": "0.00",
"currency": "USD",
"notes": "Payment terms",
"terms": "Net 30"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified invoice.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/finance/invoices/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/finance/invoices/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Forms
Store a newly created form.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/forms/forms" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Contact Form\",
\"description\": \"Main contact form\",
\"settings\": {
\"theme\": \"light\",
\"redirect_url\": \"\\/thank-you\"
},
\"structure\": {
\"fields\": [],
\"steps\": []
}
}"
const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Contact Form",
"description": "Main contact form",
"settings": {
"theme": "light",
"redirect_url": "\/thank-you"
},
"structure": {
"fields": [],
"steps": []
}
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified form.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/forms/forms/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Updated Contact Form\",
\"description\": \"Eius et animi quos velit et.\",
\"settings\": [],
\"structure\": []
}"
const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Updated Contact Form",
"description": "Eius et animi quos velit et.",
"settings": [],
"structure": []
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified form.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/forms/forms/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Duplicate a form.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/forms/forms/1/duplicate" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/1/duplicate"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Publish a form.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/forms/forms/1/publish" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/1/publish"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Forms - Integrations
Store a newly created form integration.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/forms/forms/16/integrations" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"type\": \"create_contact\",
\"name\": \"Create Contact\",
\"config\": {
\"list_ids\": [
1,
2
]
},
\"field_mapping\": {
\"email\": \"email\",
\"first_name\": \"first_name\"
},
\"conditions\": [],
\"order\": 0,
\"is_active\": true
}"
const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/16/integrations"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"type": "create_contact",
"name": "Create Contact",
"config": {
"list_ids": [
1,
2
]
},
"field_mapping": {
"email": "email",
"first_name": "first_name"
},
"conditions": [],
"order": 0,
"is_active": true
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified form integration.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/forms/forms/16/integrations/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Updated Integration\",
\"config\": [],
\"field_mapping\": [],
\"conditions\": [
\"architecto\"
],
\"order\": 16,
\"is_active\": false
}"
const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/16/integrations/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Updated Integration",
"config": [],
"field_mapping": [],
"conditions": [
"architecto"
],
"order": 16,
"is_active": false
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified form integration.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/forms/forms/16/integrations/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/forms/forms/16/integrations/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Forms - Public
Submit a form (public endpoint).
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/public/forms/contact-form/submit" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"data\": {
\"name\": \"John Doe\",
\"email\": \"john@example.com\"
},
\"started_at\": \"2026-01-21T10:00:00Z\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/public/forms/contact-form/submit"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"data": {
"name": "John Doe",
"email": "john@example.com"
},
"started_at": "2026-01-21T10:00:00Z"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Products
Store a newly created product in storage.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/products/products" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Premium Plan\",
\"description\": \"Premium subscription plan\",
\"price\": \"99.00\",
\"billing_frequency\": \"monthly\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/products/products"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Premium Plan",
"description": "Premium subscription plan",
"price": "99.00",
"billing_frequency": "monthly"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified product in storage.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/products/products/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/products/products/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PUT",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified product from storage.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/products/products/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/products/products/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Projects
Store a newly created project.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/projects" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Website Redesign\",
\"description\": \"Complete redesign of company website\",
\"status\": \"active\",
\"color\": \"#3B82F6\",
\"icon\": \"📱\",
\"start_date\": \"2026-01-01\",
\"due_date\": \"2026-12-31\",
\"contact_id\": 1,
\"company_id\": 1,
\"manager_id\": 1,
\"budget_hours\": \"100.00\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Website Redesign",
"description": "Complete redesign of company website",
"status": "active",
"color": "#3B82F6",
"icon": "📱",
"start_date": "2026-01-01",
"due_date": "2026-12-31",
"contact_id": 1,
"company_id": 1,
"manager_id": 1,
"budget_hours": "100.00"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified project.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/projects/projects/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Website Redesign\",
\"description\": \"Complete redesign\",
\"status\": \"completed\",
\"color\": \"#10B981\",
\"icon\": \"✅\",
\"start_date\": \"2026-01-01\",
\"due_date\": \"2026-12-31\",
\"contact_id\": 1,
\"company_id\": 1,
\"manager_id\": 1,
\"budget_hours\": \"120.00\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Website Redesign",
"description": "Complete redesign",
"status": "completed",
"color": "#10B981",
"icon": "✅",
"start_date": "2026-01-01",
"due_date": "2026-12-31",
"contact_id": 1,
"company_id": 1,
"manager_id": 1,
"budget_hours": "120.00"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified project.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/projects/projects/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/projects/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Projects - Tasks
Store a newly created task.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/projects/tasks" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Design homepage\",
\"description\": \"Create modern homepage design\",
\"project_id\": 1,
\"section_id\": 1,
\"parent_id\": 1,
\"status_id\": 1,
\"priority\": \"high\",
\"assigned_to\": 1,
\"due_date\": \"2026-01-15\",
\"start_date\": \"2026-01-01\",
\"estimated_hours\": \"8.00\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/projects/tasks"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Design homepage",
"description": "Create modern homepage design",
"project_id": 1,
"section_id": 1,
"parent_id": 1,
"status_id": 1,
"priority": "high",
"assigned_to": 1,
"due_date": "2026-01-15",
"start_date": "2026-01-01",
"estimated_hours": "8.00"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified task.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/projects/tasks/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Design homepage\",
\"description\": \"Create modern homepage design\",
\"project_id\": 1,
\"section_id\": 1,
\"parent_id\": 1,
\"status_id\": 1,
\"priority\": \"high\",
\"assigned_to\": 1,
\"due_date\": \"2026-01-15\",
\"start_date\": \"2026-01-01\",
\"estimated_hours\": \"8.00\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/projects/tasks/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Design homepage",
"description": "Create modern homepage design",
"project_id": 1,
"section_id": 1,
"parent_id": 1,
"status_id": 1,
"priority": "high",
"assigned_to": 1,
"due_date": "2026-01-15",
"start_date": "2026-01-01",
"estimated_hours": "8.00"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified task.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/projects/tasks/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/projects/tasks/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Proposals
Store a newly created proposal in storage.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/proposals/proposals" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Website Redesign Proposal\",
\"contact_id\": 1,
\"company_id\": 1,
\"lead_id\": 1,
\"content\": \"<p>Proposal content<\\/p>\",
\"status\": \"draft\",
\"expires_at\": \"2026-12-31\",
\"subtotal\": \"1000.00\",
\"tax_rate\": \"10.00\",
\"currency\": \"USD\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/proposals/proposals"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Website Redesign Proposal",
"contact_id": 1,
"company_id": 1,
"lead_id": 1,
"content": "<p>Proposal content<\/p>",
"status": "draft",
"expires_at": "2026-12-31",
"subtotal": "1000.00",
"tax_rate": "10.00",
"currency": "USD"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified proposal in storage.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/proposals/proposals/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"title\": \"Updated Proposal Title\",
\"status\": \"sent\",
\"content\": \"<p>Updated content<\\/p>\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/proposals/proposals/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"title": "Updated Proposal Title",
"status": "sent",
"content": "<p>Updated content<\/p>"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified proposal from storage.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/proposals/proposals/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/proposals/proposals/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Support - Tickets
Store a newly created ticket.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/support/tickets" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"subject\": \"Payment issue\",
\"inbox_id\": 1,
\"priority\": \"normal\",
\"customer_type\": \"Contact\",
\"customer_id\": 10,
\"assigned_to\": 5,
\"tags\": [
\"billing\",
\"urgent\"
],
\"message\": \"I\'m having trouble with payment\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/support/tickets"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"subject": "Payment issue",
"inbox_id": 1,
"priority": "normal",
"customer_type": "Contact",
"customer_id": 10,
"assigned_to": 5,
"tags": [
"billing",
"urgent"
],
"message": "I'm having trouble with payment"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified ticket.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/support/tickets/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"subject\": \"Updated subject\",
\"status\": \"open\",
\"priority\": \"high\",
\"assigned_to\": 5,
\"tags\": [
\"resolved\"
]
}"
const url = new URL(
"http://localhost/api/v1/api/v1/support/tickets/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"subject": "Updated subject",
"status": "open",
"priority": "high",
"assigned_to": 5,
"tags": [
"resolved"
]
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified ticket.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/support/tickets/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/support/tickets/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Templates
Store a newly created template in storage.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/templates/templates" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Standard Proposal Template\",
\"description\": \"A standard proposal template\",
\"type\": \"proposal\",
\"level\": \"full\",
\"template_data\": {
\"content\": \"...\"
},
\"is_public\": false,
\"price\": \"0.00\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/templates/templates"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Standard Proposal Template",
"description": "A standard proposal template",
"type": "proposal",
"level": "full",
"template_data": {
"content": "..."
},
"is_public": false,
"price": "0.00"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified template in storage.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/templates/templates/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Updated Template Name\",
\"description\": \"Updated description\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/templates/templates/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Updated Template Name",
"description": "Updated description"
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified template from storage.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/templates/templates/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/templates/templates/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Tenant
Update the current tenant.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/tenant/current" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"Acme Corp\",
\"domain\": \"acme\",
\"is_active\": true
}"
const url = new URL(
"http://localhost/api/v1/api/v1/tenant/current"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "Acme Corp",
"domain": "acme",
"is_active": true
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Webhooks
Store a newly created webhook subscription.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/webhooks/subscriptions" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"My Integration\",
\"url\": \"https:\\/\\/example.com\\/webhook\",
\"events\": [
\"contact.created\",
\"contact.updated\"
],
\"headers\": {
\"X-Custom-Header\": \"value\"
},
\"max_retries\": 3,
\"timeout\": 30
}"
const url = new URL(
"http://localhost/api/v1/api/v1/webhooks/subscriptions"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "My Integration",
"url": "https:\/\/example.com\/webhook",
"events": [
"contact.created",
"contact.updated"
],
"headers": {
"X-Custom-Header": "value"
},
"max_retries": 3,
"timeout": 30
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update the specified webhook subscription.
requires authentication
Example request:
curl --request PUT \
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"name\": \"My Integration\",
\"url\": \"https:\\/\\/example.com\\/webhook\",
\"events\": [
\"contact.created\"
],
\"is_active\": true,
\"headers\": {
\"X-Custom\": \"value\"
},
\"max_retries\": 3,
\"timeout\": 30
}"
const url = new URL(
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"name": "My Integration",
"url": "https:\/\/example.com\/webhook",
"events": [
"contact.created"
],
"is_active": true,
"headers": {
"X-Custom": "value"
},
"max_retries": 3,
"timeout": 30
};
fetch(url, {
method: "PUT",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Remove the specified webhook subscription.
requires authentication
Example request:
curl --request DELETE \
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "DELETE",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Regenerate the webhook secret.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1/regenerate-secret" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/webhooks/subscriptions/1/regenerate-secret"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Workspace
Create a page from template.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/workspace/pages" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"template_key\": \"meeting_notes\",
\"parent_id\": null
}"
const url = new URL(
"http://localhost/api/v1/api/v1/workspace/pages"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"template_key": "meeting_notes",
"parent_id": null
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Move a table row to a different group (board view).
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/workspace/table/move-row" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--data "{
\"block_id\": 1,
\"row_index\": 1,
\"new_group_value\": \"Done\"
}"
const url = new URL(
"http://localhost/api/v1/api/v1/workspace/table/move-row"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
let body = {
"block_id": 1,
"row_index": 1,
"new_group_value": "Done"
};
fetch(url, {
method: "POST",
headers,
body: JSON.stringify(body),
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Update a page or block.
requires authentication
Example request:
curl --request PATCH \
"http://localhost/api/v1/api/v1/workspace/pages/16" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/workspace/pages/16"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "PATCH",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Restore a version.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/workspace/pages/16/versions/architecto" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/workspace/pages/16/versions/architecto"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.
Add a comment.
requires authentication
Example request:
curl --request POST \
"http://localhost/api/v1/api/v1/workspace/pages/16/comments" \
--header "Authorization: Bearer Bearer {YOUR_API_TOKEN}" \
--header "Content-Type: application/json" \
--header "Accept: application/json"const url = new URL(
"http://localhost/api/v1/api/v1/workspace/pages/16/comments"
);
const headers = {
"Authorization": "Bearer Bearer {YOUR_API_TOKEN}",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "POST",
headers,
}).then(response => response.json());Received response:
Request failed with error:
Tip: Check that you're properly connected to the network.
If you're a maintainer of ths API, verify that your API is running and you've enabled CORS.
You can check the Dev Tools console for debugging information.