Skip to main content

Update Workspace

Update the name, interaction tracking, and conversion tracking settings for the workspace associated with your API key.


Endpoint​

PATCH https://api.campaignlark.com/v1/workspace

Request Body​

FieldTypeRequiredDescription
namestringrequiredWorkspace name (2–50 characters).
conversion_trackingbooleanrequiredWhether conversion tracking is enabled. Your plan must include conversion tracking to enable it, and interaction_tracking must be enabled.
interaction_trackingbooleanoptionalWhether open and click tracking is enabled for email and SMS campaigns and automations. When omitted, the current value is kept. Disabling it also requires conversion_tracking to be false.

Sample Request​

PATCH https://api.campaignlark.com/v1/workspace
Content-Type: application/json

{
"name": "Acme Marketing",
"conversion_tracking": true,
"interaction_tracking": true
}

Response​

Success — 200 OK​

{
"error": null,
"data": {
"id": 42,
"name": "Acme Marketing",
"conversion_tracking": true,
"interaction_tracking": true,
"is_approved": true,
"is_suspended": false,
"created_at": "2025-01-15T10:30:00Z"
}
}

Workspace Object​

FieldTypeDescription
idintegerUnique workspace ID.
namestringWorkspace name.
conversion_trackingbooleanWhether conversion tracking is enabled for the workspace.
interaction_trackingbooleanWhether open and click tracking is enabled for the workspace. When false, no tracking pixel is inserted into emails and links in emails and SMS messages are not rewritten, so opens and clicks are not recorded.
is_approvedbooleanWhether the workspace has been approved.
is_suspendedbooleanWhether the workspace is suspended.
created_atstringWorkspace creation timestamp in ISO 8601 format.

Errors​

StatusMessageCause
400Invalid request body.Request body could not be parsed.
400Workspace name must be between 2 and 50 characters.name is outside the allowed length.
400Your plan does not support conversion tracking. Please upgrade to enable this feature.Conversion tracking is not included in the workspace plan.
400Conversion tracking cannot be enabled while interaction tracking is disabled.conversion_tracking is true while interaction_tracking is (or is being set to) false.
404The workspace does not exist.The API key's workspace could not be found.