Skip to Content
API ReferenceOverview

API Reference

Interactive reference for all 34 VelaFlows microservices. Each service exposes REST endpoints through the API gateway.

Base URL

All API requests go through the gateway:

https://api.velaflows.com/api/v1

For local development, the gateway runs on port 4000:

http://localhost:4000/api/v1

Authentication

Every authenticated request requires two headers:

HeaderDescriptionExample
AuthorizationBearer token from login or API tokenBearer eyJhbGciOiJIUzI1NiIs...
x-workspace-idThe workspace to operate in6612a1b2c3d4e5f6a7b8c9d0

Obtain tokens via the Auth API login endpoint, or create long-lived API tokens in Settings > API Tokens in the dashboard.

Response Format

Success Response

All successful responses follow this envelope:

{ "success": true, "data": { "user": { "_id": "abc123", "email": "john@example.com" } } }

Paginated Response

List endpoints return paginated results:

{ "success": true, "data": { "items": [ { "_id": "abc123", "name": "Item 1" }, { "_id": "def456", "name": "Item 2" } ], "pagination": { "page": 1, "limit": 20, "total": 100, "totalPages": 5 } } }

Query parameters for pagination:

ParameterTypeDefaultDescription
pageinteger1Page number (1-indexed)
limitinteger20Items per page (max 100)
searchstring—Full-text search query
sortBystringcreatedAtField to sort by
sortOrderstringdescSort direction: asc or desc

Error Response

Errors return a structured error object:

{ "success": false, "error": { "code": "NOT_FOUND", "message": "Resource not found", "details": { "resourceId": "abc123" } } }

Common error codes:

HTTP StatusCodeDescription
400BAD_REQUESTInvalid request body or parameters
401UNAUTHORIZEDMissing or invalid authentication token
403FORBIDDENInsufficient permissions for this action
404NOT_FOUNDResource does not exist
409CONFLICTResource already exists or state conflict
422VALIDATION_ERRORRequest body failed validation
429TOO_MANY_REQUESTSRate limit exceeded
500INTERNAL_ERRORServer error

Validation Errors

When request validation fails (422), the details object contains field-level errors:

{ "success": false, "error": { "code": "VALIDATION_ERROR", "message": "Validation failed", "details": { "errors": [ { "path": "email", "message": "Invalid email address" }, { "path": "password", "message": "Must be at least 8 characters" } ] } } }

Rate Limits

Rate limiting is applied at the gateway level. Default limits:

ScopeLimitWindow
General API100 requests15 seconds
Authentication5 requests15 minutes
File uploads10 requests1 minute

When rate-limited, the response includes a 429 status code. Wait and retry after the window resets.

Services

ServiceBase PathEndpointsDescription
Auth/auth90Authentication, workspaces, members, roles, permissions
API Tokens/api-tokens11API token management
Custom Properties/custom-properties17Custom fields for entities
Tags/tags20Entity tagging system
Macros/macros8Quick reply templates
Inbox/inbox68Conversations, messages, assignments, SLA
Channels/channels138WhatsApp, Telegram, Instagram, Messenger
Broadcast/broadcast23WhatsApp bulk messaging
Mail/mail13Email integration via Unipile
Live Chat/live-chat28Live chat widget management
Widget Gateway/widget-gateway1WebSocket gateway for chat widgets
Telegram Bot/telegram-bot19Native Telegram bot management
CRM/crm51Pipelines, leads, activities, tasks
Customer/customers29Contact management
Registration/registrations15Lead registrations
Broker/brokers18Broker management
FTD Tiers/ftd-tiers11FTD tier configuration
Bonus/bonus7Bonus scheme management
Postback/postback14Postback handling
AI Assistant/ai-assistant111AI features, knowledge base, RAG
Data Enrichment/data-enrichment26Apollo.io, ZeroBounce, Lusha
Analytics/analytics26Aggregated analytics
Stripe Accounts/stripe-accounts41Stripe integration and payments
Shopify/shopify26Shopify store integration
Scheduling/scheduling32Cal.com scheduling integration
Meta Ad Accounts/meta-ad-accounts18Facebook/Instagram ad accounts
LinkedIn Prospecting/linkedin-prospecting99LinkedIn outreach and campaigns
X (Twitter)/x-integration37X DMs, mentions, content scheduling
Reddit/reddit8Reddit social listening
Notion/notion17Notion workspace integration
Forms/forms16Typeform and JotForm integration
Tracking/tracking21Meta Pixel CAPI and GA4 tracking
Integrations/integrations11Zapier and Make.com webhooks
Workflows/workflows11Workflow automation engine