Coline Docs
API Reference

Overview

Base URL, authentication, and response format for the Coline API.

API Overview

The Coline API is a RESTful API that gives you access to the full Coline platform. Build integrations, automate workflows, or create entirely new experiences on top of Coline.

Base URL

All API requests should be made to:

https://api.coline.app

Versioning

The current API version is v1. Include the version in the URL path:

https://api.coline.app/v1/workspaces/{workspaceSlug}/...

Authentication

All API requests require authentication. Coline supports two authentication methods:

API Keys

For server-to-server integrations, use API keys:

curl https://api.coline.app/v1/workspaces/acme/drives \
  -H "Authorization: Bearer col_ws_xxx"

See API Keys for details.

OAuth 2.0

For apps acting on behalf of users, use OAuth:

curl https://api.coline.app/v1/workspaces/acme/drives \
  -H "Authorization: Bearer col_at_xxx"

See OAuth 2.0 for details.

Response Format

All responses are JSON with a consistent envelope:

Success Response

{
  "data": {
    "id": "file_123",
    "name": "Project Brief",
    "fileType": "doc"
  }
}

Error Response

{
  "error": {
    "code": "not_found",
    "message": "File not found"
  }
}

List Response

List endpoints return paginated results:

{
  "data": {
    "files": [...],
    "page": {
      "limit": 50,
      "hasMore": true,
      "nextCursor": "eyJpZCI6..."
    }
  }
}

HTTP Methods

The API uses standard HTTP methods:

MethodDescription
GETRetrieve a resource or list
POSTCreate a new resource
PUTFull update of a resource
PATCHPartial update of a resource
DELETERemove a resource

Status Codes

CodeMeaning
200 OKRequest succeeded
201 CreatedResource created successfully
204 No ContentRequest succeeded, no body returned
400 Bad RequestInvalid request (check your parameters)
401 UnauthorizedAuthentication failed or missing
403 ForbiddenAuthenticated but not authorized
404 Not FoundResource doesn't exist
429 Too Many RequestsRate limit exceeded
500 Internal Server ErrorServer error (retry with backoff)

Request Headers

Required headers for all requests:

Authorization: Bearer {token}
Content-Type: application/json  # For POST/PUT/PATCH

Optional headers:

Accept: application/json
X-Request-ID: {uuid}  # For request tracing

Rate Limit Headers

Response headers include rate limit information:

X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1640995200
Retry-After: 60  # When rate limited

Pagination

List endpoints support cursor-based pagination using limit and cursor query parameters:

# First page
curl "https://api.coline.app/v1/workspaces/acme/drives/d123/files?limit=50"

# Next page
curl "https://api.coline.app/v1/workspaces/acme/drives/d123/files?limit=50&cursor=eyJpZCI6..."

IDs and References

Most resources have IDs starting with a prefix:

PrefixResource Type
ws_Workspace
drive_Drive
file_File
channel_Channel
dm_Direct Message
user_User
taskboard_Taskboard
task_Task
note_Note
doc_Doc
event_Calendar Event
message_Message

Time Format

All timestamps are ISO 8601 format in UTC:

2026-04-05T14:30:00Z

SDK

Use the official SDK for easier integration:

import { ColineApiClient } from '@colineapp/sdk'

const client = new ColineApiClient({
  baseUrl: 'https://api.coline.app',
  apiKey: process.env.COLINE_API_KEY
})

const ws = client.workspace('ws_abc123')
const files = await ws.listDriveFiles('drive_xyz')

API Categories

The API is organized into these categories:

  • Files & Drives — File management, uploads, organization
  • Channels & Messages — Team communication
  • Direct Messages — Private conversations
  • Calendar — Events and scheduling
  • Tasks — Taskboards and project management
  • Notes & Docs — Content creation
  • Search — Cross-workspace search
  • Apps — App platform for integrations

Next Steps

On this page