> ## Documentation Index
> Fetch the complete documentation index at: https://creatorinsights.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Workspace

Update the explicitly selected owned workspace using dashboard Workspace settings. Omitted fields are preserved; empty source strings clear them. Changed website/social sources queue asynchronous relearning. Returns the current safe settings and actual learning status. Does not expose credentials, connect publishing accounts, publish content or refresh sources on reads.

This workspace/settings/tracking read or edit has no immediate MCP charge. A later recurring refresh can still consume credits under its saved billing policy.

> [!NOTE]
>
> Examples use illustrative values. The playground sends a real request. Intelligence can consume plan credits. Publishing examples save drafts.

## Endpoint

**POST** `https://api.creatorinsights.in/api/v1/tools/update_workspace`

**Content type:** application/json

**Authentication:** `x-api-key: YOUR_SAVED_API_KEY`

**MCP tool:** `update_workspace`. See [MCP Setup](https://creatorinsights.mintlify.site/mcp-setup.md) for AI clients.

## Operation behavior

These mutations reuse the dashboard settings validation and asynchronous website/social learning pipeline. Omitted update fields are preserved. Supply an explicit workspace for updates. Creation does not change the primary workspace or connect publishing accounts. Inspect learning\_status and read context later; queued does not mean learning completed. MCP OAuth connections require creatorinsights:workspace:write; reconnect and approve it if an existing connection returns INSUFFICIENT\_SCOPE. Direct REST requests use your saved organization API key in x-api-key. Both interfaces enforce workspace ownership and plan rules.

This edit has no immediate MCP charge; later scheduled work can follow its saved billing policy.

## MCP call

```json theme={null}
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "update_workspace",
    "arguments": {
      "workspace": "YOUR_WORKSPACE_ID_OR_CURRENT_NAME",
      "website_url": "https://example.com"
    }
  }
}
```

## Request parameters

**x-workspace-id** `string`

Active workspace ID or current name in your organization. Optional header alternative to passing workspace in the body.

**workspace** `string` *required*

Workspace ID or current name in the authenticated organization. Required for paid requests when more than one active workspace exists. Call list\_workspaces to discover IDs; the selected workspace determines context, data and its spending limit for this request.

**name** `string`

Workspace name, unique within your organization.

**website\_url** `string`

Public HTTP/HTTPS website to learn from. An empty string clears it on update.

**social\_links** `object`

**brand\_context** `string`

Manual brand instructions, at most 5000 words. Omit to preserve current text; empty string intentionally clears it.

**preferred\_language** `string`

Language code, for example en.

**category** `string[]`

## Request example

Send these arguments directly as the JSON body.

```json theme={null}
{
  "workspace": "YOUR_WORKSPACE_ID_OR_CURRENT_NAME",
  "website_url": "https://example.com"
}
```

```bash cURL theme={null}
curl -X POST 'https://api.creatorinsights.in/api/v1/tools/update_workspace' \
  -H "x-api-key: $CREATOR_INSIGHTS_API_KEY" \
  -H 'Content-Type: application/json' \
  --data '{"workspace":"YOUR_WORKSPACE_ID_OR_CURRENT_NAME","website_url":"https://example.com"}'
```

```javascript Node.js theme={null}
const response = await fetch('https://api.creatorinsights.in/api/v1/tools/update_workspace', {
  method: 'POST',
  headers: { 'x-api-key': process.env.CREATOR_INSIGHTS_API_KEY, 'Content-Type': 'application/json' },
  body: JSON.stringify({
  "workspace": "YOUR_WORKSPACE_ID_OR_CURRENT_NAME",
  "website_url": "https://example.com"
})
});
const raw = await response.text();
let result;
try { result = JSON.parse(raw); } catch { throw new Error('Non-JSON response: ' + response.status); }
if (!response.ok || result.status === false) throw new Error(result.message || result.error || 'Request failed');
console.log(result.data);
```

```python Python theme={null}
import json, os, requests

arguments = json.loads("{\"workspace\":\"YOUR_WORKSPACE_ID_OR_CURRENT_NAME\",\"website_url\":\"https://example.com\"}")
response = requests.post("https://api.creatorinsights.in/api/v1/tools/update_workspace",
    headers={"x-api-key": os.environ["CREATOR_INSIGHTS_API_KEY"]},
    json=arguments, timeout=120)
response.raise_for_status()
result = response.json()
print(result["data"])
```

## Response example

HTTP 200. Illustrative values; optional fields can be omitted, null, or empty. Additional platform fields may be returned.

```json Success theme={null}
{
  "status": true,
  "tool": "update_workspace",
  "credits_deducted": 0,
  "data": {
    "success": true,
    "data": {
      "workspace_id": "507f1f77bcf86cd799439011",
      "name": "Example Brand",
      "is_primary": true,
      "website_url": "https://example.com/",
      "brand_context": "Practical tutorials for independent creators.",
      "website_context": "",
      "website_pages": [],
      "social_links": {},
      "category": [
        "education"
      ],
      "preferred_language": "en",
      "creator_dna": {},
      "platform_contexts": {},
      "context_status": "queued",
      "context_current": false,
      "updated_at": "2026-11-03T00:00:00Z"
    },
    "learning_status": "queued",
    "message": "Workspace saved. Source learning is asynchronous; read workspace context after learning completes."
  }
}
```

## Response fields

**status** `boolean` *required*

Whether this operation succeeded. Also check HTTP status and nested platform statuses.

**tool** `string` *required*

The invoked tool name.

**credits\_deducted** `number` *required*

Credits settled against the credential workspace for this call. Cache, duplicate, included-plan and read/edit operations can return zero.

**data** `object` *required*

Operation-specific payload. See the nested field table and response example below.

| Field | Type | Description |
| - | - | - |
| `status` | boolean | Example response field. Availability depends on the record and selected options. |
| `tool` | string | Example response field. Availability depends on the record and selected options. |
| `credits_deducted` | number | Example response field. Availability depends on the record and selected options. |
| `data` | object | Nested object. Expand the response schema for its fields. |
| `data.success` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.data` | object | Nested object. Expand the response schema for its fields. |
| `data.data.workspace_id` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.name` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.is_primary` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.data.website_url` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.brand_context` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.website_context` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.website_pages` | array | List of returned entries; may be empty. |
| `data.data.social_links` | object | Nested object. Expand the response schema for its fields. |
| `data.data.category` | array | List of returned entries; may be empty. |
| `data.data.preferred_language` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.creator_dna` | object | Nested object. Expand the response schema for its fields. |
| `data.data.platform_contexts` | object | Nested object. Expand the response schema for its fields. |
| `data.data.context_status` | string | Example response field. Availability depends on the record and selected options. |
| `data.data.context_current` | boolean | Example response field. Availability depends on the record and selected options. |
| `data.data.updated_at` | string | Example response field. Availability depends on the record and selected options. |
| `data.learning_status` | string | Example response field. Availability depends on the record and selected options. |
| `data.message` | string | Example response field. Availability depends on the record and selected options. |

The interactive schema includes deeper nested fields. Sample fields are descriptive, not a promise that every record includes them.

## n8n and JSON tool endpoint

**POST** `https://api.creatorinsights.in/api/v1/tools/update_workspace`. Use Header Auth with `x-api-key` and body content type JSON. This alias returns the n8n envelope below; included operations can report zero credits\_deducted.

```bash theme={null}
curl -X POST 'https://api.creatorinsights.in/api/v1/tools/update_workspace' \
  -H "x-api-key: $CREATOR_INSIGHTS_API_KEY" \
  -H 'Content-Type: application/json' \
  --data '{"workspace":"YOUR_WORKSPACE_ID_OR_CURRENT_NAME","website_url":"https://example.com"}'
```

```json theme={null}
{
  "status": true,
  "tool": "update_workspace",
  "credits_deducted": 0,
  "data": {
    "success": true,
    "data": {
      "workspace_id": "507f1f77bcf86cd799439011",
      "name": "Example Brand",
      "is_primary": true,
      "website_url": "https://example.com/",
      "brand_context": "Practical tutorials for independent creators.",
      "website_context": "",
      "website_pages": [],
      "social_links": {},
      "category": [
        "education"
      ],
      "preferred_language": "en",
      "creator_dna": {},
      "platform_contexts": {},
      "context_status": "queued",
      "context_current": false,
      "updated_at": "2026-11-03T00:00:00Z"
    },
    "learning_status": "queued",
    "message": "Workspace saved. Source learning is asynchronous; read workspace context after learning completes."
  }
}
```

## Errors

Handle non-2xx responses before mapping data. Error codes vary with the cause; these are representative examples. A 429 response may be plain text. Never treat a queued post as published or blindly retry a partial publication.

```json theme={null}
{
  "status": false,
  "error": "Unauthorized: Invalid API Key. Please verify your Creator Insights API key."
}
```

| HTTP status | Meaning |
| - | - |
| 400 | Invalid arguments |
| 401 | Missing or invalid API key |
| 402 | Insufficient Creator Insights plan credits |
| 403 | Subscription or permission required |
| 404 | Resource not found |
| 409 | Conflicting request, idempotency key, or unfinished upload |
| 410 | Managed media expired; upload the file again |
| 413 | Media too large |
| 415 | Unsupported media type |
| 422 | Account selection, connection, or platform payload needs attention |
| 500 | Authentication or server error |
| 503 | Service temporarily unavailable or operation failed; inspect saved status before retrying |
| 429 | Rate limit; inspect response headers and retry later. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.