Doclyn LogoDoclyn
FeaturesPricingFAQAPI
LoginGet Started Free
PrivacyTermsCookies

© 2025 Doclyn. All rights reserved.

Start Free Trial

Doclyn API Documentation

Integrate Doclyn's powerful RAG capabilities into your applications. Query documents, manage folders, and leverage AI-powered chat programmatically.

Try the API

Authentication

All API requests require authentication using a Bearer token. You can generate API keys from your organization settings.

Getting Your API Key

  1. Log in to your Doclyn account
  2. Navigate to Settings → API Keys
  3. Click "Create New API Key"
  4. Copy your key (it will only be shown once)
API keys are scoped to your organization. All requests made with your key will have access to your organization's documents and folders.

Using Your API Key

Include your API key in the Authorization header:

Header Format
Authorization: Bearer zp_org_your_api_key_here

Example request:

cURL Example
curl -X GET "https://app.doclyn.com/api/v1/documents" \
  -H "Authorization: Bearer zp_org_your_api_key_here" \
  -H "Content-Type: application/json"

Endpoints

The Doclyn API provides endpoints for managing documents, folders, and RAG-powered chat.

Retrieve a paginated list of all documents in your organization. Optionally filter by folder.

Retrieve detailed information about a specific document by its ID.

Retrieve a paginated list of all folders in your organization. Optionally filter by parent folder.

Retrieve detailed information about a specific folder including its documents.

Send a RAG-powered query to search your documents and get AI-generated responses with source citations.

Try It Out

Test the API directly in your browser using your API key.

API Playground

Base URLhttps://doclyn.ai

Your API key is only used client-side and is never stored.

Error Codes

All errors follow a consistent format with a code and message.

CodeStatusDescription
invalid_api_key
401
The API key provided is invalid or has been revoked.
api_access_disabled
403
API access has not been enabled for this organization.
organization_read_only
403
This organization is in read-only mode.
organization_not_found
404
Organization not found.
document_not_found
404
Document not found.
folder_not_found
404
Folder not found.
rate_limit_exceeded
429
Rate limit exceeded. Please try again later.
quota_exceeded
429
Monthly quota exceeded. Please upgrade your plan.
invalid_request
400
Invalid request format.
invalid_scope
400
Invalid scope or scope_context.
message_too_long
400
Message exceeds maximum length of 10,000 characters.
request_too_large
413
Request body exceeds maximum size.
internal_error
500
An internal error occurred.

Rate Limits & Quotas

API requests are rate limited to ensure fair usage and system stability.

Rate Limits

  • Requests per minute60
  • Max message length10,000 chars
  • Max request body50 KB

Rate Limit Headers

Each response includes rate limit information in headers:

X-RateLimit-Limit: 60
X-RateLimit-Remaining: 58
X-RateLimit-Reset: 1703865600

Monthly Quotas

Chat API usage counts against your organization's monthly message quota. Quota limits depend on your subscription plan. When quota is exceeded, requests return a 429 status with error code quota_exceeded.

Table of Contents