Skip to Content
SDKs & ExamplesOverview

SDKs & Code Examples

VelaFlows does not have official SDK packages yet, but the REST API is straightforward to use from any language. This section provides complete, copy-paste-ready code examples for the most common operations.

Available Languages

LanguageBest For
JavaScript / TypeScriptNode.js backends, Next.js apps, browser-based integrations
PythonData pipelines, automation scripts, Django/Flask apps
cURLQuick testing, CI/CD scripts, shell automation

Quick Example

Here’s a taste of what each language looks like:

JavaScript

const res = await fetch('https://api.velaflows.com/api/v1/inbox/conversations', { headers: { 'Authorization': `Bearer ${process.env.VELAFLOWS_API_TOKEN}`, 'x-workspace-id': process.env.VELAFLOWS_WORKSPACE_ID, }, }) const { data } = await res.json() console.log(`Found ${data.pagination.total} conversations`)

Python

import requests res = requests.get( "https://api.velaflows.com/api/v1/inbox/conversations", headers={ "Authorization": f"Bearer {os.environ['VELAFLOWS_API_TOKEN']}", "x-workspace-id": os.environ["VELAFLOWS_WORKSPACE_ID"], }, ) data = res.json()["data"] print(f"Found {data['pagination']['total']} conversations")

cURL

curl -s "https://api.velaflows.com/api/v1/inbox/conversations" \ -H "Authorization: Bearer $VELAFLOWS_API_TOKEN" \ -H "x-workspace-id: $VELAFLOWS_WORKSPACE_ID" | jq '.data.pagination.total'

API Patterns

All code examples follow these conventions from the VelaFlows API:

  • Base URL: https://api.velaflows.com/api/v1
  • Auth headers: Authorization: Bearer <token> + x-workspace-id: <id>
  • Response wrapper: { success: true, data: { ... } }
  • Pagination: ?page=1&limit=20 with response data.pagination
  • Errors: { success: false, error: { code, message, details } }

Coming Soon

We’re working on official SDK packages for:

  • @velaflows/node — TypeScript-first Node.js client with full type safety
  • velaflows-python — Python client with async support

In the meantime, the code examples in this section provide production-ready patterns you can use directly.