Download Documentation
Export the full V2 reference as Markdown or plain text for structured prompting and design-oriented planning.
V2 Workspace API
Base URL: https://www.inkpilots.com/api/v2
Scope: Workspace-scoped endpoints under /workspaces/:workspaceId
Auth: API key via x-api-key (or Authorization: Bearer ...)
- In order to get your workspaceId, go to /workspaces, click to workspace clipboard icon. It copies your workspaceId to clipboard.
- In order to get your clusterId, select workspace, go to clusters tab, select the cluster, then on the cluster details section click to clipboard icon.
Table of Contents
- Authentication and Headers
- Common Behavior
- Get Workspace
- List Articles
- Get Article by ID
- List Clusters
- Get Cluster by ID
- List Cluster Articles
- List Author Identities
- Get Author Identity by ID
- List Author Identity Articles
- OPTIONS / CORS
Authentication and Headers
Use one of the following headers:
x-api-key: ai_xxxAuthorization: Bearer ai_xxx
All endpoints are read-only and accept GET requests. No request body is required.
Common Behavior
- Every endpoint is workspace-scoped:
/api/v2/workspaces/:workspaceId/... - List endpoints return pagination:
skip(default0, min0)limit(default20, min1, max100)
- Most responses include rate-limit headers.
Data Shape
- Object ids are always returned as
id, never_id. - Article responses replace the raw
clusterIdandauthorreference fields with filledclusterandauthorobjects. - The
clusterandauthorfields are omitted entirely when the article has no reference or the referenced cluster/author no longer exists.
Cluster Object
{
"id": "665b7db6a8f0a98a5ef2c333",
"workspaceId": "665b7db6a8f0a98a5ef2c111",
"name": "Product Updates",
"description": "Product release notes and updates",
"keywords": ["updates", "product"],
"color": "blue",
"slug": "product-updates",
"isPrivate": false,
"createdByUserId": "665b7db6a8f0a98a5ef2c222",
"createdAt": "2026-05-14T00:00:00.000Z",
"updatedAt": "2026-05-14T00:00:00.000Z"
}
Author Object
{
"id": "665b7db6a8f0a98a5ef2c444",
"workspaceId": "665b7db6a8f0a98a5ef2c111",
"createdByUserId": "665b7db6a8f0a98a5ef2c222",
"name": "Jane Doe",
"role": "Writer",
"imageUrl": "https://cdn.inkpilots.com/avatars/jane.png",
"socialLinks": {
"twitter": "https://twitter.com/janedoe"
},
"createdAt": "2026-05-14T00:00:00.000Z",
"updatedAt": "2026-05-14T00:00:00.000Z"
}
Common error responses:
400invalid path or query parameters401invalid or missing API key402workspace has reached monthly API access quota403API key workspace scope does not match path workspace404resource not found429rate limited
1) Get Workspace
Method: GET
Path: /api/v2/workspaces/:workspaceId
Description
Returns the foundational workspace identity context for everything else in the reference. Use this endpoint to anchor scope, naming, and baseline context before shaping downstream interaction flows.
Use Cases
- Establish a consistent workspace anchor for experience mapping and information hierarchy.
- Feed naming and context labels used across navigation, command surfaces, and visual grouping.
- Confirm source-of-truth scope before rendering stateful interaction layers.
Path Params
workspaceId(ObjectId)
Success Response (200)
{
"workspace": {
"id": "665b7db6a8f0a98a5ef2c111",
"name": "My Workspace"
}
}
cURL
curl -X GET "https://www.inkpilots.com/api/v2/workspaces/<workspaceId>" \
-H "x-api-key: <apiKey>"
2) List Articles
Method: GET
Path: /api/v2/workspaces/:workspaceId/articles
Description
Returns a workspace-wide paginated inventory of narrative units across all clusters and author identities. Use this endpoint as the broad discovery layer for cross-topic composition and curation.
Use Cases
- Build a master content canvas with rich sorting and filtering interactions.
- Curate high-signal sets for featured story flows and highlighted experiences.
- Feed quality and consistency passes that evaluate content at portfolio scale.
Query Params
skip,limitsortBy:createdAt | updatedAt | title | statussortOrder:asc | descclusterId: ObjectId ornullstatus:draft | published | archivedlanguage: stringmodel: stringtags: comma-separated valuesslug: stringsearch: string
Success Response
- Returns
{ articles, pagination }.
Each article uses the workspace article shape: raw editor document, plain text, metadata, and (when present) filled cluster and author objects.
{
"articles": [
{
"id": "665b7db6a8f0a98a5ef2c555",
"workspaceId": "665b7db6a8f0a98a5ef2c111",
"isSkill": false,
"version": "1.0",
"title": "Our first product update",
"slug": "our-first-product-update",
"language": "en",
"coverImage": "https://cdn.inkpilots.com/covers/update.png",
"document": {
"time": 1715644800000,
"version": "2.28.2",
"blocks": [
{
"id": "p1",
"type": "paragraph",
"data": { "text": "We shipped a new editor." }
}
]
},
"notes": [],
"plainText": "We shipped a new editor.",
"meta": {
"description": "Summary of the product update",
"keywords": ["updates", "product"],
"tags": ["news"]
},
"status": "published",
"model": "gpt-4o-mini",
"promptTokens": 10,
"completionTokens": 20,
"totalTokens": 30,
"views": 0,
"likes": 0,
"createdAt": "2026-05-14T00:00:00.000Z",
"updatedAt": "2026-05-14T00:00:00.000Z",
"cluster": {
"id": "665b7db6a8f0a98a5ef2c333",
"name": "Product Updates",
"color": "blue"
},
"author": {
"id": "665b7db6a8f0a98a5ef2c444",
"name": "Jane Doe",
"role": "Writer"
}
}
],
"pagination": {
"skip": 0,
"limit": 20,
"totalCount": 42,
"totalPages": 3,
"currentPage": 1,
"hasNextPage": true,
"hasPrevPage": false
}
}
The
clusterandauthorobjects contain the full public fields shown in Common Behavior. They are omitted when the article has no cluster or author reference.
3) Get Article by ID
Method: GET
Path: /api/v2/workspaces/:workspaceId/articles/:articleId
Description
Returns one narrative unit by id within workspace scope. Use this endpoint when a detailed surface needs complete context for one selected item.
Use Cases
- Hydrate a deep detail canvas with structure, metadata, and current lifecycle state.
- Support precise edit and review loops on a single narrative artifact.
- Validate targeted references when linking related visual experiences.
Success Response (200)
- Returns
{ article }using the same workspace article shape as List Articles (including filledclusterandauthorobjects when present).
Errors
400InvalidarticleId404Article not found
4) List Clusters
Method: GET
Path: /api/v2/workspaces/:workspaceId/clusters
Description
Returns a paginated set of thematic clusters used to structure editorial intent. This endpoint supports visual planning through filters such as cycle alignment and content density.
Use Cases
- Build thematic navigation systems that guide user attention across major pillars.
- Visualize which clusters are content-rich versus content-sparse.
- Create cycle-aware planning views for phased storytelling.
Query Params
skip,limitsortBy:name | createdAt | updatedAt(defaultupdatedAt)sortOrder:asc | descsearch: stringcontentCycleId: ObjectIdcolor: stringhasArticles:true | false
Success Response
- Returns
{ clusters, pagination }
5) Get Cluster by ID
Method: GET
Path: /api/v2/workspaces/:workspaceId/clusters/:clusterId
Description
Returns the full profile for a single thematic cluster. Use this endpoint when one focused theme needs complete context before sequencing related narratives.
Use Cases
- Populate cluster overview panels with definitive taxonomy and identity data.
- Validate cluster linkages before assigning narrative units.
- Refresh one thematic context after updates to labels or structure.
Errors
400InvalidclusterId404Cluster not found
6) List Cluster Articles
Method: GET
Path: /api/v2/workspaces/:workspaceId/clusters/:clusterId/articles
Description
Returns the narrative corpus mapped to one cluster with pagination and filters. This endpoint isolates a single theme so progression and balance can be assessed clearly.
Use Cases
- Build theme-specific story arcs that show sequence and maturity.
- Track movement between lifecycle states inside one cluster lane.
- Create comparative visuals that reveal depth and coverage per theme.
Query Params
- Same article list filters as section 2 (
skip,limit, sort, status, language, model, tags, slug, search)
Success Response
- Returns
{ articles, pagination }.
Articles under this endpoint use the cluster/author article shape: structured content blocks derived from the editor document, plus metadata, and filled cluster / author objects when present.
{
"articles": [
{
"id": "665b7db6a8f0a98a5ef2c555",
"workspaceId": "665b7db6a8f0a98a5ef2c111",
"title": "Our first product update",
"status": "published",
"content": [
{
"type": "paragraph",
"text": "We shipped a new editor."
}
],
"meta": {
"description": "Summary of the product update",
"keywords": ["updates", "product"],
"tags": ["news"]
},
"createdAt": "2026-05-14T00:00:00.000Z",
"updatedAt": "2026-05-14T00:00:00.000Z",
"cluster": {
"id": "665b7db6a8f0a98a5ef2c333",
"name": "Product Updates",
"color": "blue"
},
"author": {
"id": "665b7db6a8f0a98a5ef2c444",
"name": "Jane Doe",
"role": "Writer"
}
}
],
"pagination": {
"skip": 0,
"limit": 20,
"totalCount": 3,
"totalPages": 1,
"currentPage": 1,
"hasNextPage": false,
"hasPrevPage": false
}
}
Errors
400InvalidclusterIdor invalid query params404Cluster not found
7) List Author Identities
Method: GET
Path: /api/v2/workspaces/:workspaceId/author-identities
Description
Returns a paginated list of voice identities configured for the workspace. Use this endpoint to drive attribution logic and persona-based narrative consistency.
Use Cases
- Build voice selection controls that shape tone and perspective.
- Visualize persona readiness by profile completeness and media presence.
- Segment identity sets by ownership for cleaner operational governance.
Query Params
skip,limitsortBy:name | createdAt | updatedAt(defaultupdatedAt)sortOrder:asc | descsearch: stringcreatedByUserId: ObjectIdhasImage:true | false
Success Response
- Returns
{ authorIdentities, pagination }
8) Get Author Identity by ID
Method: GET
Path: /api/v2/workspaces/:workspaceId/author-identities/:authorIdentityId
Description
Returns one voice identity by id with complete profile context. Use this endpoint when a focused persona surface requires canonical detail.
Use Cases
- Render detailed identity cards with signature tone and presentation traits.
- Validate persona references before finalizing attribution in narrative flows.
- Load authoritative identity context into editorial decision points.
Errors
400InvalidauthorIdentityId404Author identity not found
9) List Author Identity Articles
Method: GET
Path: /api/v2/workspaces/:workspaceId/author-identities/:authorIdentityId/articles
Description
Returns narrative units associated with one voice identity. This endpoint keeps retrieval scoped to a single persona, improving signal clarity for tone analysis.
Use Cases
- Curate persona-specific content streams with consistent voice characteristics.
- Compare contribution rhythm and thematic spread for one identity.
- Build targeted review lanes for drafts tied to a selected voice.
Query Params
- Same article list filters as section 2 (
skip,limit, sort, status, language, model, tags, slug, search)
Success Response
- Returns
{ articles, pagination }using the same cluster/author article shape as List Cluster Articles: structuredcontentblocks plus filledcluster/authorobjects when present.
Errors
400InvalidauthorIdentityIdor invalid query params404Author identity not found
OPTIONS / CORS
Description
Provides the preflight contract for method and header compatibility checks. Use this behavior to confirm transport expectations before operational calls are executed.
Use Cases
- Verify compatibility between external clients and API access policies.
- Diagnose blocked calls caused by mismatched headers or method declarations.
- Certify integration readiness during reliability and QA passes.
All route files expose OPTIONS and return 204 No Content with CORS headers.
Allowed methods and headers:
- Methods:
GET, OPTIONS - Headers:
Authorization, Content-Type, X-API-KEY
Quick Start Example
# 1) list articles
curl -X GET "https://www.inkpilots.com/api/v2/workspaces/<workspaceId>/articles?status=published&sortBy=updatedAt&sortOrder=desc" \
-H "x-api-key: <apiKey>"
# 2) get one article
curl -X GET "https://www.inkpilots.com/api/v2/workspaces/<workspaceId>/articles/<articleId>" \
-H "x-api-key: <apiKey>"