Data Models

Complete reference for all data structures and schemas used across the API

User Model

User account and profile information

_id ObjectId Unique user identifier
username String Required User's login username
email String Required User's email address
fullName String User's full name
role String User role: 'user', 'admin', 'super-admin'
stripeKeys Object Stripe API configuration for payments
stripeKeys.publishableKey String Stripe publishable key
stripeKeys.secretKey String Stripe secret key (encrypted)
stripeKeys.isConfigured Boolean Whether Stripe is configured
createdAt Date Account creation timestamp

Document Model

Document editor and signature request with payment support

_id ObjectId Unique document identifier
name String Required Document name/title
userId ObjectId Required Document owner reference
status String Status: 'draft', 'sent', 'completed', 'cancelled'
canvasData Object Document canvas configuration and elements
signingOrder Array Array of signer objects with order, email, name, status
paymentSettings Object Payment collection settings
paymentSettings.requirePayment Boolean Whether payment is required
paymentSettings.amount Number Payment amount
paymentSettings.currency String Currency code (e.g., 'USD', 'CAD')
paymentSettings.paymentProvider String Provider: 'stripe', 'paypal', etc.
paymentSettings.collectPaymentBefore String Timing: 'signing' or 'submission'
paymentTransactions Array Array of payment transaction records
createdAt Date Document creation timestamp

SignatureRequest Model

Individual signature request for document signers with payment tracking

_id ObjectId Unique signature request identifier
documentId ObjectId Required Reference to parent document
signer.email String Required Signer's email address
signer.name String Signer's full name
status String Status: 'pending', 'signed', 'declined', 'expired'
accessToken String Unique access token for signing
paymentTracking.required Boolean Whether payment is required
paymentTracking.status String Payment status: 'pending', 'completed', 'failed'
paymentTracking.paymentIntentId String Stripe payment intent ID
signedAt Date Signature completion timestamp

Listing Model

Virtual office and space listing information

name String Required Listing title/name
category String Required Category: 'virtual-office', 'office-space', 'meeting-room', 'coworking'
price Number Required Price per billing period
location.address String Street address
location.city String City name
amenities Array Array of amenity strings
availability String Availability status: 'available', 'booked', 'unavailable'

Booking Model

Booking and reservation information

listingId ObjectId Required Reference to listing
startDate Date Required Booking start date
endDate Date Required Booking end date
status String Status: 'pending', 'confirmed', 'cancelled', 'completed'
paymentStatus String Payment status: 'pending', 'paid', 'refunded'

Appointment Model

Appointment booking and scheduling information

title String Required Appointment title
startTime Date Required Appointment start time
endTime Date Required Appointment end time
status String Status: 'scheduled', 'confirmed', 'cancelled', 'completed'
attendees Array Array of attendee objects

Form Model

Dynamic form builder configuration

name String Required Form name/title
fields Array Required Array of form field configurations
fields[].type String Field type: 'text', 'email', 'textarea', 'select'
fields[].required Boolean Whether field is required
submissionSettings Object Form submission configuration

Authentication APIs

Secure user authentication and session management endpoints

POST /login
Stable

Authenticate user credentials and establish session

Parameters
email string required
password string required
Response

Redirects to dashboard on success or returns error message

POST /signup
Stable

Register new user account with validation

Parameters
username string required
email string required
password string required
firstName string optional
lastName string optional
Response

Creates new user account and sends welcome email

GET /logout
Stable

Terminate user session and clear authentication

Authentication

User session required

Response

Destroys session and redirects to login page

API Keys Management

Generate and manage API keys for programmatic access to your account

Quick Start: Generate an API key from your User Profile and use it in your requests with the X-API-Key header or Authorization: Bearer YOUR_KEY header.
POST /api/user/generate-api-key
New

Generate a new API key or regenerate existing one

Authentication

User session required

Response
{
  "success": true,
  "apiKey": "sk_1234567890abcdef...",
  "message": "API key generated successfully"
}

Save the API key securely - it will only be shown once!

GET /api/user/api-key
New

Check API key status and metadata

Authentication

User session required

Response
{
  "success": true,
  "apiEnabled": true,
  "hasApiKey": true,
  "apiKeyCreatedAt": "2024-01-15T10:30:00Z",
  "apiKeyLastUsed": "2024-01-20T15:45:00Z"
}
DELETE /api/user/api-key
New

Permanently revoke your API key

Authentication

User session required

Response
{
  "success": true,
  "message": "API key revoked successfully"
}

Variables Management API

Manage document variables programmatically using API key authentication

Authentication: All endpoints require API key authentication. Include your API key in the request header: X-API-Key: your_api_key
GET /api/v1/documents/:documentId/variables
New

Retrieve all variables for a specific document

Authentication

API key required (X-API-Key header)

URL Parameters
documentId string required - Document ID
Response
{
  "success": true,
  "variables": [
    {
      "id": "var_123",
      "name": "customerName",
      "type": "custom",
      "value": "John Doe",
      "description": "Customer full name",
      "editable": true,
      "createdAt": "2024-01-15T10:30:00Z",
      "recipientId": null
    }
  ],
  "count": 1
}
POST /api/v1/documents/:documentId/variables
New

Create a new variable in a document

Authentication

API key required (X-API-Key header)

URL Parameters
documentId string required - Document ID
Request Body
name string required - Variable name
value string optional - Variable value
description string optional - Description
type string optional - Type: 'system', 'role', 'custom' (default: 'custom')
recipientId string optional - Link to recipient/signer
Example Request
{
  "name": "contractAmount",
  "value": "$10,000",
  "description": "Total contract amount",
  "type": "custom"
}
Response
{
  "success": true,
  "variable": {
    "id": "var_456",
    "name": "contractAmount",
    "type": "custom",
    "value": "$10,000",
    "description": "Total contract amount",
    "editable": true,
    "createdAt": "2024-01-20T14:30:00Z",
    "recipientId": null
  },
  "message": "Variable created successfully"
}
PUT /api/v1/documents/:documentId/variables/:variableId
New

Update an existing variable

Authentication

API key required (X-API-Key header)

URL Parameters
documentId string required - Document ID
variableId string required - Variable ID
Request Body
name string optional - Updated variable name
value string optional - Updated value
description string optional - Updated description
Response
{
  "success": true,
  "variable": {
    "id": "var_456",
    "name": "contractAmount",
    "value": "$12,000",
    "description": "Updated contract amount"
  },
  "message": "Variable updated successfully"
}
DELETE /api/v1/documents/:documentId/variables/:variableId
New

Delete a variable from a document

Authentication

API key required (X-API-Key header)

URL Parameters
documentId string required - Document ID
variableId string required - Variable ID
Response
{
  "success": true,
  "message": "Variable deleted successfully"
}
Additional Document Endpoints

You can also access these document-related endpoints with your API key:

  • GET /api/v1/documents - List all your documents
  • GET /api/v1/documents/:documentId - Get document details

Listings APIs

Property listing management and search functionality

GET /listings
Stable

Retrieve all approved property listings with pagination

Authentication

None required - Public endpoint

Response

HTML page with paginated listing results

POST /create-listing
Stable

Submit new property listing for admin review

Authentication

User session required

Parameters
title string required
description text required
price number required
images file[] optional
Response

Creates listing with pending status for admin approval

GET /listings/details/:id
Stable

Get comprehensive details for a specific property listing

Authentication

None required - Public endpoint

Parameters
id string required Listing ID in URL path
Response

Detailed listing page with images, contact forms, and booking options

GET /listings/cities
Stable

Get all cities that have available property listings

Authentication

None required - Public endpoint

Response

HTML page displaying cities with listing counts

Messages APIs

Customer inquiry and communication management system

POST /api/listings/:listingId/messages
Stable

Send inquiry or viewing request for a property listing

Authentication

None required - Public endpoint for customer inquiries

Parameters
name string required
email email required
phone string optional
message text required
messageType enum required contact_inquiry | viewing_request
Response

Creates message for admin review and sends confirmation email

GET /admin/messages
Stable

Admin dashboard for managing all customer messages and inquiries

Authentication

Admin role required

Response

HTML page with message management interface, filtering, and response tools

PATCH /admin/messages/:messageId/read
Stable

Mark a customer message as read for tracking purposes

Authentication

Admin role required

Parameters
messageId string required Message ID in URL path
Response

Updates message read status and timestamp

POST /admin/messages/:messageId/reply
Stable

Send email response to customer inquiry with automated tracking

Authentication

Admin role required

Parameters
messageId string required Message ID in URL path
reply text required Admin response content
Response

Sends email reply to customer and logs response in system

Website Builder APIs

Complete website creation and management system with AI assistance

POST /website-builder/save
Stable

Save website content and configuration to database

Authentication

User session required

Parameters
content html required Complete website HTML
name string optional
isPublished boolean optional
Response

Saves website data with versioning and backup

POST /website-builder/publish
Stable

Toggle website publication status for public access

Authentication

User session required

Parameters
isPublished boolean required
Response

Updates publication status and generates public URL

GET /website-builder/export
Stable

Download complete website as exportable ZIP archive

Authentication

User session required

Response

ZIP file containing HTML, CSS, JS, and assets

POST /website-builder/domain-settings
Stable

Configure custom domain with DNS verification

Authentication

User session required

Parameters
domain string required Custom domain name
Response

Validates domain and provides DNS configuration instructions

Widget APIs

Comprehensive API endpoints for managing website widgets including form builders, appointment booking, product catalogs, and interactive components

GET /api/form-builder/test
Stable

Test endpoint to verify form builder API availability and list all available endpoints.

Response Example
{
  "success": true,
  "message": "Form Builder API is working",
  "endpoints": [
    "POST /api/form-builder/create",
    "GET /api/form-builder/list",
    "PUT /api/form-builder/:formId"
  ]
}
POST /api/form-builder/create
Stable

Create a new form builder widget with custom fields, SendGrid integration, and email templates.

Request Parameters
widgetId string required Unique identifier for the widget
title string required Form title displayed to users
description string optional Form description or instructions
fields array required Array of form field objects with type, label, required, placeholder
sendgridConfig object optional SendGrid API key configuration for email delivery
emailNotifications object optional Email notification settings and templates
Authentication

Requires user login session

GET /api/form-builder/list
Stable

Retrieve all form builder widgets for the authenticated user.

Authentication

Requires user login session

GET /api/form-builder/:formId
Stable

Get details of a specific form builder widget by form ID.

Path Parameters
formId string required Unique form identifier
Authentication

Requires user login session

PUT /api/form-builder/:formId
Stable

Update an existing form builder widget configuration, fields, and settings.

Path Parameters
formId string required Form ID to update
Authentication

Requires user login session

DELETE /api/form-builder/:formId
Stable

Delete a form builder widget and all associated data.

Path Parameters
formId string required Form ID to delete
Authentication

Requires user login session

POST /api/form-submissions
Stable

Submit form data to a published form widget. Supports file uploads and triggers email notifications.

Request Parameters
formId string required Target form ID for submission
formData object required Form field values matching form configuration
files multipart optional File uploads (max 10 files)
Rate Limiting

Limited by IP address and daily submission limits configured per form

GET /api/form-builder/:formId/submissions
Stable

Retrieve paginated list of form submissions with analytics data.

Query Parameters
page number optional Page number (default: 1)
limit number optional Results per page (default: 10)
Authentication

Requires user login session

POST /api/form-builder/test-sendgrid
Stable

Validate SendGrid API key before saving to form configuration.

Request Parameters
apiKey string required SendGrid API key to validate
Authentication

Requires user login session

GET /api/appointment-types
Stable

Get all available appointment types for booking widgets with pricing and duration information.

Response Example
{
  "success": true,
  "appointmentTypes": [
    {
      "id": "consultation",
      "name": "Business Consultation",
      "description": "One-on-one consultation for business development",
      "price": 150,
      "duration": 60,
      "icon": "fa-handshake-o"
    }
  ]
}
GET /api/appointment-slots/:date
Stable

Get available time slots for appointment booking on a specific date.

Path Parameters
date string required Date in YYYY-MM-DD format
Query Parameters
duration number optional Appointment duration in minutes (default: 60)
POST /api/create-appointment-payment-intent
Stable

Create Stripe payment intent for appointment booking with automatic slot validation.

Request Parameters
appointmentTypeId string required Type of appointment to book
date string required Appointment date
time string required Appointment time
duration number required Duration in minutes
Authentication

Requires user login session

GET /api/website/:websiteId/checkout-widget-info
Stable

Get checkout widget configuration and payment information for e-commerce widgets.

Path Parameters
websiteId string required Website identifier
POST /api/upload-image
Stable

Upload images for website widgets with automatic optimization and CDN delivery.

Request Parameters
image file required Image file (JPG, PNG, GIF, WebP - max 5MB)
File Constraints

Maximum file size: 5MB
Supported formats: JPG, PNG, GIF, WebP
Automatic optimization and resizing to 1200x800px

Authentication

Requires user login session

AI Services APIs

Artificial intelligence powered content generation and enhancement

POST /api/ai/improve-text
Stable

Enhance text content using advanced AI language models

Authentication

User session required

Parameters
currentText text required
prompt string required Improvement instruction
Response

Enhanced text with improved grammar, tone, and clarity

POST /api/ai/generate-html
Stable

Generate HTML content from natural language descriptions

Authentication

User session required

Parameters
prompt text required Description of desired HTML
Response

Generated HTML code with proper structure and styling

POST /api/ai-website-builder
Stable

Generate complete website using AI with images and content

Authentication

User session required

Parameters
businessName string required
businessType string required
description text required
Response

Complete website HTML with curated images from Unsplash

POST /api/ai/generate-products
Stable

Generate product listings with descriptions and pricing

Authentication

User session required

Parameters
productType string required
count number required
details object optional
Response

Array of generated products with names, descriptions, and prices

Bookings APIs

Property tour and boardroom reservation management system

POST /create-booking
Stable

Schedule property tour with automated email confirmations

Authentication

None required - Public booking endpoint

Parameters
name string required
email email required
phone string optional
date date required
time time required
message text optional
Response

Creates booking and sends confirmation email to customer and admin

POST /create-boardroom-booking
Stable

Reserve boardroom with time slot validation and conflict checking

Authentication

None required - Public booking endpoint

Parameters
name string required
email email required
date date required
startTime time required
endTime time required
Response

Creates boardroom reservation with availability validation

GET /api/user-boardroom-bookings
Stable

Retrieve user's boardroom bookings with status and details

Authentication

User session required

Response

JSON array of user's bookings with dates, times, and status

POST /update-booking-status/:id
Stable

Update booking status with automated customer notifications

Authentication

Admin role required

Parameters
id string required Booking ID in URL path
status enum required confirmed | cancelled | pending
Response

Updates booking status and sends notification email to customer

Appointments APIs

Professional appointment scheduling with calendar integration

GET /api/appointment-types
Stable

Retrieve available appointment types with pricing and duration

Authentication

None required - Public endpoint

Response

JSON array of appointment types with pricing and availability

GET /api/appointment-slots/:date
Stable

Get available time slots for specific date with real-time availability

Authentication

None required - Public endpoint

Parameters
date date required Date in URL path (YYYY-MM-DD)
Response

JSON array of available time slots with provider availability

POST /api/create-appointment-payment-intent
Stable

Create Stripe payment intent for appointment booking with secure payment

Authentication

User session required

Parameters
appointmentTypeId string required Appointment type to book
date date required Appointment date
time time required Appointment time
Response

Stripe payment intent with client secret for secure payment processing

GET /api/user-appointments
Stable

Retrieve user's appointments with status tracking and details

Authentication

User session required

Response

JSON array of user appointments with payment status and provider details

Video Conferences APIs

Manage video conferences, meetings, and virtual collaboration sessions

GET /api/video-conferences
Stable

Retrieve all video conferences where you are the organizer or a participant

Query Parameters
status string optional Filter by status: scheduled, in-progress, completed, cancelled
upcoming boolean optional Show only upcoming conferences (true/false)
Authentication

User session required

Response Example
{
  "success": true,
  "conferences": [
    {
      "_id": "60f7b3e4c8d4a20015f5e3a1",
      "title": "Q1 Strategy Meeting",
      "description": "Quarterly business review and planning",
      "organizer": {
        "_id": "60f7b3e4c8d4a20015f5e3a0",
        "username": "john_doe",
        "email": "john@example.com",
        "firstName": "John",
        "lastName": "Doe"
      },
      "scheduledStartTime": "2026-02-01T14:00:00.000Z",
      "scheduledEndTime": "2026-02-01T15:00:00.000Z",
      "duration": 60,
      "timezone": "America/Edmonton",
      "status": "scheduled",
      "roomId": "vc-1705489200-abc123xyz",
      "maxParticipants": 100,
      "participants": [
        {
          "userId": "60f7b3e4c8d4a20015f5e3a2",
          "status": "accepted",
          "email": "jane@example.com"
        }
      ]
    }
  ]
}
POST /api/video-conferences
Stable

Create a new video conference with scheduling and participant invitations

Request Body
{
  "title": "Q1 Strategy Meeting",
  "description": "Quarterly business review and planning",
  "scheduledStartTime": "2026-02-01T14:00:00.000Z",
  "scheduledEndTime": "2026-02-01T15:00:00.000Z",
  "duration": 60,
  "timezone": "America/Edmonton",
  "provider": "built-in",
  "participants": [
    {
      "userId": "60f7b3e4c8d4a20015f5e3a2",
      "email": "jane@example.com",
      "name": "Jane Smith"
    }
  ],
  "recordingEnabled": false,
  "waitingRoomEnabled": true,
  "requirePassword": true,
  "allowScreenShare": true,
  "allowChat": true,
  "maxParticipants": 100,
  "reminderTime": 15,
  "notes": "Please review Q4 report before meeting"
}
Required Fields
title string required Conference title
scheduledStartTime date required Start date and time (ISO 8601 format)
scheduledEndTime date required End date and time (ISO 8601 format)
Response
{
  "success": true,
  "conference": {
    "_id": "60f7b3e4c8d4a20015f5e3a1",
    "title": "Q1 Strategy Meeting",
    "roomId": "vc-1705489200-abc123xyz",
    "meetingPassword": "ABC12345",
    "status": "scheduled"
  }
}
GET /api/video-conferences/:id
Stable

Get detailed information about a specific video conference

Path Parameters
id string required Conference ID
Authorization

User must be the organizer or a participant

PUT /api/video-conferences/:id
Stable

Update video conference details (organizer only)

Request Body

Any conference field can be updated. Example:

{
  "title": "Updated Meeting Title",
  "scheduledStartTime": "2026-02-01T15:00:00.000Z",
  "maxParticipants": 150
}
Authorization

Only the conference organizer can update

DELETE /api/video-conferences/:id
Stable

Cancel a video conference and notify all participants

Authorization

Only the conference organizer can cancel

Response
{
  "success": true,
  "message": "Conference cancelled successfully"
}
POST /api/video-conferences/:id/start
Stable

Start a scheduled video conference (organizer only)

Response
{
  "success": true,
  "conference": {
    "_id": "60f7b3e4c8d4a20015f5e3a1",
    "status": "in-progress",
    "actualStartTime": "2026-01-17T14:05:00.000Z"
  }
}
POST /api/video-conferences/:id/end
Stable

End an in-progress video conference (organizer only)

Response
{
  "success": true,
  "conference": {
    "_id": "60f7b3e4c8d4a20015f5e3a1",
    "status": "completed",
    "actualEndTime": "2026-01-17T15:05:00.000Z"
  }
}
VideoConference Model

Complete data structure for video conference objects

Schema Fields
_id ObjectId Unique conference identifier
title String required Conference title
description String Conference description
organizer ObjectId required User ID of conference organizer
participants Array Array of participant objects with userId, email, status
scheduledStartTime Date required Scheduled start time
scheduledEndTime Date required Scheduled end time
actualStartTime Date Actual start time (set when conference starts)
actualEndTime Date Actual end time (set when conference ends)
duration Number Duration in minutes (default: 60)
timezone String Timezone (default: America/Edmonton)
provider String Meeting provider: zoom, google-meet, microsoft-teams, built-in, custom
roomId String Unique room identifier (auto-generated)
meetingPassword String Meeting password (if required)
status String Status: scheduled, in-progress, completed, cancelled, no-show
recordingEnabled Boolean Enable recording (default: false)
recordingUrl String Recording URL (if available)
waitingRoomEnabled Boolean Enable waiting room (default: true)
requirePassword Boolean Require password to join (default: true)
allowScreenShare Boolean Allow screen sharing (default: true)
allowChat Boolean Allow chat (default: true)
maxParticipants Number Maximum participants (default: 100)
isRecurring Boolean Recurring meeting (default: false)
recurrencePattern Object Recurrence pattern (frequency, interval, daysOfWeek, endDate)
notes String Meeting notes or agenda
attachments Array Meeting attachments (name, url, uploadedAt)

User Services APIs

User service management and provider operations platform

GET /api/services
Stable

Retrieve user's services with comprehensive details and statistics

Authentication

User session required

Response

JSON array of user's services with pricing, bookings, and status

POST /api/services
Stable

Create new service offering with full configuration

Authentication

User session required

Parameters
name string required Service name
description text required Service description
price number required Service price in cents
duration number required Duration in minutes
Response

Creates new service and makes it available for booking

PUT /api/services/:id
Stable

Update service details with validation and notification

Authentication

User session required - Service owner only

Parameters
id string required Service ID in URL path
name string optional Updated service name
description text optional Updated description
price number optional Updated price
duration number optional Updated duration
Response

Updates service details and notifies existing customers

PATCH /api/services/:id/toggle
Stable

Toggle service active status with booking impact handling

Authentication

User session required - Service owner only

Parameters
id string required Service ID in URL path
Response

Toggles service status and manages existing bookings accordingly

E-commerce APIs

Complete e-commerce solution with product management and payment processing

GET /api/websites/:websiteId/products
Stable

Retrieve products for specific website with inventory and pricing

Authentication

Website owner authentication required

Parameters
websiteId string required Website ID in URL path
category string optional Filter by category
inStock boolean optional Filter by stock status
Response

JSON array of products with images, pricing, and inventory data

POST /api/websites/:websiteId/products
Stable

Create new product with image upload and inventory management

Authentication

Website owner authentication required

Parameters
websiteId string required Website ID in URL path
name string required Product name
description text required Product description
price number required Price in cents
images file[] optional Product images
inventory number optional Stock quantity
Response

Creates product with image processing and inventory tracking

GET /api/websites/:websiteId/cart
Stable

Retrieve shopping cart with items and calculated totals

Authentication

None required - Session-based cart

Parameters
websiteId string required Website ID in URL path
Response

Cart items with quantities, pricing, and calculated totals

POST /api/websites/:websiteId/cart/add
Stable

Add product to cart with inventory validation

Authentication

None required - Session-based cart

Parameters
websiteId string required Website ID in URL path
productId string required Product to add to cart
quantity number required Quantity to add
Response

Updates cart with inventory validation and total calculation

POST /api/websites/:websiteId/orders
Stable

Create order from cart with payment processing and fulfillment

Authentication

None required - Guest checkout supported

Parameters
websiteId string required Website ID in URL path
customerInfo object required Customer details (name, email, address)
paymentMethod string required Stripe payment method ID
Response

Creates order, processes payment, and sends confirmation emails

Billing APIs

Subscription management and payment processing with Stripe integration

GET /api/subscription-plans
Stable

Retrieve available subscription plans with pricing and features

Authentication

User session required

Response

JSON array of subscription plans with pricing tiers and feature lists

GET /api/user-subscriptions
Stable

Get user's active subscriptions with status and billing details

Authentication

User session required

Response

JSON array of user subscriptions with billing cycles and payment status

POST /subscriptions/create
Stable

Create new subscription with automated billing setup

Authentication

User session required

Parameters
planId string required Subscription plan ID
paymentMethod string required Stripe payment method ID
billingCycle enum optional monthly | yearly
Response

Creates subscription and sets up recurring billing with confirmation

POST /api/user/stripe-settings
Stable

Configure Stripe API keys for payment processing

Authentication

User session required

Parameters
publishableKey string required Stripe publishable key
secretKey string required Stripe secret key (encrypted)
webhookSecret string optional Webhook endpoint secret
Response

Securely stores encrypted Stripe keys for payment processing

Admin APIs

Administrative operations for platform management and moderation

POST /admin/approve-listing/:id
Stable

Approve pending listing for public display with notifications

Authentication

Admin role required

Parameters
id string required Listing ID in URL path
Response

Approves listing and sends confirmation email to listing owner

POST /admin/reject-listing/:id
Stable

Reject listing with reason and automated user notification

Authentication

Admin role required

Parameters
id string required Listing ID in URL path
rejectionReason text required Reason for rejection
Response

Rejects listing and sends detailed feedback to listing owner

POST /admin/ai-scrape-url
Stable

AI-powered web scraping for automatic listing data extraction

Authentication

Super Admin role required

Parameters
url url required URL to scrape for listing data
dataType enum optional property | business | service
Response

Extracted and structured listing data with AI confidence scores

GET /admin/messages/unread-count
Stable

Get unread message count for admin dashboard notifications

Authentication

Admin role required

Response

Number of unread messages requiring admin attention

GET /api/admin/service-requests
Stable

Retrieve all service requests for admin review and management

Authentication

Admin role required

Parameters
status enum optional pending | approved | rejected
page number optional Page number for pagination
Response

JSON array of service requests with user details and status

Phone System APIs

Comprehensive phone management, calling, messaging, and AI receptionist features

GET /api/phone/available-numbers
Stable

Search for available phone numbers by country, region, or area code

Authentication

User session required

Query Parameters
country string optional ISO country code (e.g., CA, US)
areaCode string optional Area code for the phone number
region string optional State/Province code
Response
{
  "success": true,
  "availableNumbers": [
    {
      "phoneNumber": "+1234567890",
      "region": "Ontario",
      "country": "CA",
      "price": 1.00,
      "capabilities": ["voice", "SMS", "MMS"]
    }
  ],
  "count": 25
}
POST /api/phone/purchase-number
Stable

Purchase and configure a new phone number with subscription

Authentication

User session required

Request Body
phoneNumber string required Phone number to purchase (e.g., +1234567890)
friendlyName string optional Label for the phone number
Response
{
  "success": true,
  "phoneNumber": "+1234567890",
  "sid": "PN1234567890abcdef",
  "subscription": {
    "status": "active",
    "currentPeriodEnd": "2026-02-28T00:00:00Z"
  },
  "message": "Phone number purchased successfully"
}
GET /api/phone/my-numbers
Stable

Get all phone numbers owned by the authenticated user with emergency address status

Authentication

User session required

Response
{
  "success": true,
  "phoneNumbers": [
    {
      "phoneNumber": "+1234567890",
      "sid": "PN1234567890abcdef",
      "friendlyName": "Main Business Line",
      "emergencyAddressSid": "AD1234567890abcdef",
      "emergencyStatus": "registered",
      "status": "active",
      "capabilities": ["voice", "SMS"]
    }
  ],
  "count": 1
}
GET /api/phone/emergency-address
Stable

Retrieve emergency address for a specific phone number (E911/PSAP)

Authentication

User session required

Query Parameters
phoneNumber string optional Specific phone number to query (defaults to primary)
Response
{
  "success": true,
  "emergencyAddress": {
    "sid": "AD1234567890abcdef",
    "friendlyName": "Main Office",
    "street": "123 Business St",
    "city": "Calgary",
    "region": "AB",
    "postalCode": "T2P 1M4",
    "isoCountry": "CA"
  },
  "registered": true
}
POST /api/phone/emergency-address
Stable

Create or update emergency address for a phone number. Creates new address and swaps assignment if needed.

Authentication

User session required

Request Body
phoneNumber string required Phone number to assign address to
friendlyName string required Address label (e.g., "Main Office")
street string required Street address
city string required City
region string required State/Province code (e.g., AB, ON)
postalCode string required Postal code
isoCountry string required ISO country code (e.g., CA, US)
Response
{
  "success": true,
  "emergencyAddress": {
    "sid": "AD1234567890abcdef",
    "friendlyName": "Main Office",
    "street": "123 Business St",
    "city": "Calgary",
    "region": "AB",
    "postalCode": "T2P 1M4",
    "isoCountry": "CA"
  },
  "message": "Emergency address saved successfully"
}
POST /api/phone/make-call
Stable

Initiate an outbound phone call from a user's Twilio number

Authentication

User session required

Request Body
toNumber string required Recipient phone number
fromNumber string optional Sender's Twilio number (defaults to primary)
Response
{
  "success": true,
  "callSid": "CA1234567890abcdef",
  "status": "initiated",
  "message": "Call initiated successfully"
}
POST /api/phone/send-sms
Stable

Send an SMS text message from a user's Twilio number

Authentication

User session required

Request Body
toNumber string required Recipient phone number
message string required SMS message content (max 160 characters)
fromNumber string optional Sender's Twilio number (defaults to primary)
Response
{
  "success": true,
  "messageSid": "SM1234567890abcdef",
  "status": "sent",
  "message": "SMS sent successfully"
}
GET /api/phone/call-history
Stable

Retrieve call history for all of user's phone numbers

Authentication

User session required

Query Parameters
limit integer optional Results per page (default: 25)
offset integer optional Pagination offset (default: 0)
Response
{
  "success": true,
  "calls": [
    {
      "callSid": "CA1234567890abcdef",
      "from": "+1234567890",
      "to": "+0987654321",
      "status": "completed",
      "duration": 300,
      "startTime": "2026-01-30T10:30:00Z",
      "endTime": "2026-01-30T10:35:00Z",
      "direction": "inbound"
    }
  ],
  "total": 150,
  "limit": 25,
  "offset": 0
}
GET /api/phone/ai-receptionist-settings
Stable

Get current AI receptionist configuration settings

Authentication

User session required

Response
{
  "success": true,
  "settings": {
    "enabled": true,
    "enableLanguageSelection": true,
    "captureName": true,
    "captureReason": true,
    "intentTagging": true,
    "spamScoring": true,
    "priorityTagging": true,
    "voicemailSummary": true,
    "sentimentTagging": true,
    "routeNotifications": true,
    "whisperPromptTuning": true
  }
}
POST /api/phone/ai-receptionist-settings
Stable

Update AI receptionist configuration and features

Authentication

User session required

Request Body
enabled boolean optional Enable/disable AI receptionist
enableLanguageSelection boolean optional Allow caller language selection
captureName boolean optional Capture caller name
captureReason boolean optional Capture reason for call
spamScoring boolean optional Enable spam detection
voicemailSummary boolean optional Generate AI voicemail summaries
Response
{
  "success": true,
  "settings": {
    "enabled": true,
    "enableLanguageSelection": true,
    "captureName": true,
    "captureReason": true
  },
  "message": "AI receptionist settings updated successfully"
}

Domain Management APIs (Name cheap)

Complete domain registration, DNS management, and configuration through Namecheap integration

GET /api/domains/namecheap/search
Stable

Search for domain availability and pricing information

Authentication

User session required

Query Parameters
domain string required Domain name to check
Response
{
  "success": true,
  "domain": "example.com",
  "available": true,
  "price": 12.98,
  "currency": "USD"
}
GET /api/domains/namecheap/payment-config
Stable

Get available payment methods for domain purchases (Stripe/PayPal)

Response
{
  "success": true,
  "paymentMethods": ["stripe", "paypal"],
  "stripeAvailable": true,
  "paypalAvailable": true
}
POST /api/domains/namecheap/payment-intent
Stable

Create Stripe payment intent for domain purchase

Body Parameters
domain string required
years number required
privacy boolean optional
POST /api/domains/namecheap/paypal-order
Stable

Create PayPal order for domain purchase

POST /api/domains/namecheap/paypal-capture
Stable

Capture approved PayPal payment for domain

POST /api/domains/namecheap/purchase
Stable

Complete domain registration after payment

Body Parameters
domain required
paymentProvider enum stripe | paypal
contact object required Registrant contact information
GET /api/domains/namecheap/:domain/dns/hosts
Stable

Get DNS host records for a domain

POST /api/domains/namecheap/:domain/dns/hosts
Stable

Update DNS host records for a domain

GET /api/domains/namecheap/:domain/nameservers
Stable

Get current nameservers for a domain

POST /api/domains/namecheap/:domain/nameservers
Stable

Update nameservers for a domain

GET /api/domains/namecheap/registrations
Stable

Get all domain registrations for current user

POST /api/domains/namecheap/configure-dns
Stable

Automatically configure DNS for website integration

Website Pages Management APIs

Multi-page website management with bulk operations and publishing

GET /api/pages
Stable

Get all pages for current website

Response
{
  "success": true,
  "pages": [
    {
      "_id": "page123",
      "title": "Home",
      "slug": "home",
      "published": true,
      "content": "..."
    }
  ]
}
POST /api/pages
Stable

Create a new page in website

PUT /api/pages/:pageId
Stable

Update page content and settings

DELETE /api/pages/:pageId
Stable

Delete a page from website

POST /api/pages/:pageId/duplicate
Stable

Duplicate an existing page

POST /api/pages/bulk-delete
Beta

Delete multiple pages at once

POST /api/pages/bulk-export
Beta

Export multiple pages as HTML

POST /api/pages/bulk-status
Beta

Publish/unpublish multiple pages

Unsplash Integration APIs

Free high-quality stock photos from Unsplash

GET /api/unsplash/search
Stable

Search for photos on Unsplash

Query Parameters
query string required Search term
page number optional
perPage number optional
GET /api/unsplash/featured
Stable

Get featured/curated photos

POST /api/unsplash/download
Stable

Track photo download (required by Unsplash API terms)

Additional AI APIs

Extended AI capabilities for code, text, images, and content enhancement

POST /api/ai/generate-code
Stable

Generate code snippets with AI

POST /api/ai/developer-code
Stable

Advanced code generation for developers

POST /api/ai/generate-text
Stable

Generate text content with AI

POST /api/ai-assistance
Stable

General AI assistance and Q&A

POST /api/ai/enhance-description
Stable

Enhance product descriptions with AI

POST /api/ai-image-process
Beta

Process images with AI (background removal, enhancement, etc.)

POST /api/ai-image-save
Beta

Save AI-processed images

POST /api/ai/improve-email
Stable

Improve email content with AI suggestions

Sitemap Management APIs

SEO sitemap configuration and generation

GET /api/website-builder/sitemap-settings
Stable

Get current sitemap configuration

POST /api/website-builder/sitemap-settings
Stable

Update sitemap configuration and generate new sitemap

GET /api/website-builder/sitemap-preview
Stable

Preview sitemap XML before publishing

GET /api/websites/:websiteId/sitemap-settings
Stable

Get sitemap settings for specific website

Product Management APIs

Product CRUD operations for e-commerce

PUT /api/products/:productId
Stable

Update product details, pricing, and inventory

DELETE /api/products/:productId
Stable

Delete a product from inventory

Document Editor APIs

Document creation, editing, signing, templates, and collaboration features

POST /api/documents/create
Stable

Create a new document with initial content and metadata

Authentication

User session required

Request Body
title string required Document title
content string optional Initial HTML or plain text content
documentType string optional contract | agreement | form | template
Response
{
  "success": true,
  "document": {
    "_id": "doc1234567890abcdef",
    "title": "Service Agreement",
    "content": "

Agreement content...

", "createdAt": "2026-01-30T10:30:00Z", "updatedAt": "2026-01-30T10:30:00Z", "status": "draft" }, "message": "Document created successfully" }
GET /api/documents
Stable

Retrieve paginated list of user's documents with metadata

Authentication

User session required

Query Parameters
limit integer optional Results per page (default: 10)
offset integer optional Pagination offset (default: 0)
status string optional draft | pending | signed | archived
Response
{
  "success": true,
  "documents": [
    {
      "_id": "doc1234567890abcdef",
      "title": "Service Agreement",
      "status": "draft",
      "createdAt": "2026-01-30T10:30:00Z",
      "updatedAt": "2026-01-30T10:30:00Z",
      "recipients": [],
      "signatureStatus": "unsigned"
    }
  ],
  "total": 42,
  "limit": 10,
  "offset": 0
}
GET /api/documents/:id
Stable

Retrieve full document content and metadata by ID

Authentication

User session required

URL Parameters
id string required Document MongoDB ID
Response
{
  "success": true,
  "document": {
    "_id": "doc1234567890abcdef",
    "title": "Service Agreement",
    "content": "

Full agreement content...

", "status": "draft", "createdAt": "2026-01-30T10:30:00Z", "recipients": [], "comments": [], "variables": [] } }
POST /api/documents/:id/upload
Stable

Upload or update document file (PDF, DOCX, etc.)

Authentication

User session required

Request Body
document file required File upload (multipart/form-data)
Response
{
  "success": true,
  "document": {
    "_id": "doc1234567890abcdef",
    "originalName": "agreement.pdf",
    "fileUrl": "https://cdn.example.com/docs/doc1234567890abcdef.pdf",
    "fileSize": 245000,
    "mimeType": "application/pdf"
  },
  "message": "Document uploaded successfully"
}
POST /api/documents/:id/send
Stable

Send document to recipients for review and signature with email notifications

Authentication

User session required

Request Body
recipients array required Array of recipient objects with email and name
message string optional Custom message to include in email
expiresIn integer optional Expiration time in days (default: 30)
Response
{
  "success": true,
  "document": {
    "_id": "doc1234567890abcdef",
    "status": "pending",
    "recipients": [
      {
        "email": "recipient@example.com",
        "name": "John Doe",
        "status": "sent",
        "sentAt": "2026-01-30T10:30:00Z"
      }
    ]
  },
  "message": "Document sent to recipients successfully"
}
GET /api/documents/:id/signature-status
Stable

Check signature status for all recipients on a document

Authentication

User session required

Response
{
  "success": true,
  "documentId": "doc1234567890abcdef",
  "status": "pending",
  "recipients": [
    {
      "email": "recipient@example.com",
      "name": "John Doe",
      "status": "signed",
      "signedAt": "2026-01-30T11:00:00Z",
      "ipAddress": "192.168.1.1"
    },
    {
      "email": "recipient2@example.com",
      "name": "Jane Smith",
      "status": "pending",
      "sentAt": "2026-01-30T10:30:00Z"
    }
  ],
  "allSigned": false
}
GET /api/documents/:id/download-signed
Stable

Download the fully signed document with all signatures embedded

Authentication

User session required

Response

Binary PDF file with embedded signatures and audit trail

POST /api/documents/:id/comments
Stable

Add comments or annotations to a document during review

Authentication

User session required

Request Body
content string required Comment text
page integer optional Page number for comment location
x number optional X coordinate on page
y number optional Y coordinate on page
Response
{
  "success": true,
  "comment": {
    "_id": "comment123",
    "content": "Please revise this section",
    "author": "user@example.com",
    "createdAt": "2026-01-30T11:00:00Z",
    "page": 1,
    "x": 100,
    "y": 200
  },
  "message": "Comment added successfully"
}
POST /api/documents/:id/save-as-template
Stable

Save current document as a reusable template with variables

Authentication

User session required

Request Body
templateName string required Template name for future reference
templateCategory string optional Category for organization (e.g., contracts, agreements)
isPublic boolean optional Make available to organization (default: false)
Response
{
  "success": true,
  "template": {
    "_id": "template123",
    "templateName": "Standard Service Agreement",
    "templateCategory": "contracts",
    "originalDocumentId": "doc1234567890abcdef",
    "createdAt": "2026-01-30T11:00:00Z",
    "variables": ["{{clientName}}", "{{serviceDate}}", "{{amount}}"]
  },
  "message": "Template saved successfully"
}
POST /api/documents/:id/share
Stable

Generate shareable link or grant access to specific users

Authentication

User session required

Request Body
userEmails array optional Array of email addresses to share with
accessLevel string optional view | comment | edit (default: view)
expiresIn integer optional Expiration in days (optional - no expiry if omitted)
Response
{
  "success": true,
  "shareLink": "https://officespaces.co/doc/share/abc123def456",
  "sharedWith": [
    {
      "email": "user@example.com",
      "accessLevel": "view",
      "sharedAt": "2026-01-30T11:00:00Z"
    }
  ],
  "message": "Document shared successfully"
}
GET /api/v1/documents/:documentId/variables
Stable

Get all template variables defined in a document (API Key authentication)

Authentication

API Key required (X-API-Key header)

Response
{
  "success": true,
  "variables": [
    {
      "name": "clientName",
      "type": "text",
      "value": "",
      "description": "Name of the client"
    },
    {
      "name": "serviceDate",
      "type": "date",
      "value": "",
      "description": "Date of service"
    }
  ],
  "count": 2
}
POST /api/v1/documents/:documentId/variables
Stable

Create or update template variables in a document (API Key authentication)

Authentication

API Key required (X-API-Key header)

Request Body
name string required Variable name (e.g., clientName)
type string required text | number | date | email | phone
value string optional Default value for variable
description string optional Description of variable usage
Response
{
  "success": true,
  "variable": {
    "name": "clientName",
    "type": "text",
    "value": "Default Client Name",
    "description": "Name of the client",
    "createdAt": "2026-01-30T11:00:00Z"
  },
  "message": "Variable created successfully"
}
POST /api/documents/:id/create-payment-intent
Stable

Create a payment intent for document signature fees supporting multiple payment providers (Stripe, PayPal, Square, Global Payments)

Authentication

Public access (no authentication required for recipients)

Request Body
recipientId string required Recipient ID from signature request
signatureRequestToken string required Access token for signature request verification
Supported Payment Providers
stripe Stripe Payment Platform (default)
paypal PayPal Checkout
square Square Payments
globalpayments Global Payments (Heartland)
Response
{
  "success": true,
  "paymentIntentId": "pi_1234567890abcdef",
  "provider": "stripe",
  "clientSecret": "pi_1234567890abcdef_secret_xxxx",
  "amount": 2999,
  "currency": "USD",
  "paymentUrl": "https://checkout.stripe.com/...",
  "message": "Payment intent created successfully"
}
Notes

Document owner must configure payment provider API keys before recipients can pay. Returns provider-specific payment information for client-side integration.

POST /api/documents/:id/verify-payment
Stable

Verify payment completion with payment provider and unlock document for signing

Authentication

Public access (no authentication required for recipients)

Request Body
recipientId string required Recipient ID from signature request
paymentIntentId string required Stripe/PayPal payment intent ID
transactionId string optional Global Payments transaction ID (if using GlobalPayments)
Response
{
  "success": true,
  "status": "succeeded",
  "receiptUrl": "https://receipt.stripe.com/...",
  "message": "Payment verified successfully"
}
Notes

Verifies payment status with the provider, updates document workflow, and enables signing. Records payment transaction with provider-specific metadata including receipt URL.

GET /api/documents/:id/payment-status
Stable

Check payment status and transaction history for a document

Authentication

User session required (document owner only)

Response
{
  "success": true,
  "paymentSummary": {
    "requiresPayment": true,
    "amount": 2999,
    "currency": "USD",
    "provider": "stripe",
    "transactions": [
      {
        "recipientId": "recipient123",
        "amount": 2999,
        "currency": "USD",
        "status": "succeeded",
        "paidAt": "2026-01-30T11:30:00Z",
        "receiptUrl": "https://receipt.stripe.com/..."
      }
    ]
  }
}

Webhooks

Real-time event notifications and third-party integration endpoints

POST /webhook/stripe
Stable

Stripe webhook endpoint for payment event processing and subscription updates

Authentication

Stripe signature verification required

Parameters
stripe-signature header required Stripe webhook signature
event object required Stripe event data payload
Supported Events
payment_intent.succeeded Payment confirmation
invoice.payment_succeeded Subscription payment
customer.subscription.deleted Subscription cancellation
payment_intent.payment_failed Payment failure
Response

Processes payment events and updates user accounts, orders, and subscriptions

API Usage Guidelines

Best practices, rate limits, and integration guidelines for optimal API usage

Rate Limiting
  • Standard APIs: 100 requests per minute
  • Media Upload: 20 uploads per minute
  • AI Services: 10 requests per minute
  • Webhooks: No rate limit

Rate limits are per user session or API key.

Authentication
  • Session-based: Browser cookie authentication
  • API Keys: For webhook and third-party integrations
  • JWT Tokens: For mobile and SPA applications
  • Role-based Access: Admin, user, and guest permissions

Always use HTTPS for API communications.

Error Handling
  • 400: Bad Request - Invalid parameters
  • 401: Unauthorized - Authentication required
  • 403: Forbidden - Insufficient permissions
  • 429: Too Many Requests - Rate limit exceeded
  • 500: Internal Server Error - Contact support

All errors include detailed JSON error messages.

Best Practices
  • Pagination: Use limit and offset parameters
  • Caching: Respect cache headers for better performance
  • Idempotency: Use idempotency keys for critical operations
  • Validation: Client-side validation before API calls

Monitor API response times and adjust request frequency accordingly.

Data Formats
  • Request: JSON with UTF-8 encoding
  • Response: JSON with consistent field naming
  • Dates: ISO 8601 format (YYYY-MM-DDTHH:mm:ssZ)
  • Files: Multipart form-data for uploads

All timestamps are in UTC timezone.

Support & SDKs
  • Documentation: Always up-to-date with examples
  • Status Page: Real-time API status monitoring
  • Developer Support: Email support for integration help
  • SDKs: JavaScript, Python, and PHP libraries available

Join our developer Discord for community support.