Skip to main content
POST
/
v2
/
workspace
/
activityconfig
/
update
Update Activity Config
curl --request POST \
  --url https://api.velt.dev/v2/workspace/activityconfig/update \
  --header 'Content-Type: application/json' \
  --header 'x-velt-api-key: <x-velt-api-key>' \
  --header 'x-velt-auth-token: <x-velt-auth-token>' \
  --data '
{
  "data": {
    "activityServiceConfig": {
      "isEnabled": true,
      "enabledTime": 123,
      "immutable": true,
      "triggers": {}
    }
  }
}
'
{
  "result": {
    "status": "success",
    "message": "Activity logs configuration updated successfully.",
    "data": {
      "activityServiceConfig": {
        "isEnabled": true,
        "immutable": false,
        "enabledTime": 1717520000000
      }
    }
  }
}
Use this API to update the activity logs configuration for a workspace. The activityServiceConfig object must contain at least one sub-field. The config is deep-merged with the existing value, so omitted sub-fields are preserved (including enabledTime when you omit it).
This endpoint uses API-key-level auth: pass x-velt-api-key and x-velt-auth-token as headers. You can obtain these from the Get Auth Tokens endpoint.
Defaults on first enable. If you enable activity logs (activityServiceConfig.isEnabled: true) and no activityServiceConfig exists yet, defaults are seeded automatically: the standard comment triggers are turned on (including the comment_annotation.suggestion_accept / comment_annotation.suggestion_reject triggers, which are active by default for activity logs), immutable is set to true, and enabledTime is stamped with the current timestamp when you don’t provide one. Any values you send in the same request (including immutable: false or your own enabledTime) are merged on top of these defaults.
The response data echoes the latest post-write state as { activityServiceConfig } — the same shape returned by Get Activity Config, including any seeded defaults. isEnabled is always present (defaults to false when neither your request nor the stored config sets it).

Endpoint

POST https://api.velt.dev/v2/workspace/activityconfig/update

Headers

x-velt-api-key
string
required
Your API key.
x-velt-auth-token
string
required

Body

Params

data
object
required

Example Request

{
  "data": {
    "activityServiceConfig": {
      "isEnabled": true,
      "immutable": false
    }
  }
}

Example Response

Success Response

{
  "result": {
    "status": "success",
    "message": "Activity logs configuration updated successfully.",
    "data": {
      "activityServiceConfig": {
        "isEnabled": true,
        "immutable": false,
        "enabledTime": 1717520000000
      }
    }
  }
}

Failure Response

If activityServiceConfig has no sub-fields
{
  "error": {
    "status": "INVALID_ARGUMENT",
    "message": "At least one field must be provided for update"
  }
}
{
  "result": {
    "status": "success",
    "message": "Activity logs configuration updated successfully.",
    "data": {
      "activityServiceConfig": {
        "isEnabled": true,
        "immutable": false,
        "enabledTime": 1717520000000
      }
    }
  }
}