---
title: "Update an activity (legacy path)"
method: PATCH
path: "/activities_v2/{activityId}"
tags: ["Activity Records"]
deprecated: true
---

# Update an activity (legacy path)

`PATCH /activities_v2/{activityId}`

## Request

- Base URL: `https://api.surense.com/api/v1`
- URL: `https://api.surense.com/api/v1/activities_v2/{activityId}`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `https://api.surense.com/oauth/token`

> **Deprecated.**

## Path parameters

- `activityId` string, uuid, required

## Request body

- UpdateActivityRequest: Request to replace the content (and, if provided, the mentions) of an activity record
  - `jsonContent` JsonNode: Rich-text content of the activity as JSON (the editor's document model), stored alongside htmlContent
    - `empty` boolean
    - `array` boolean
    - `null` boolean
    - `object` boolean
    - `float` boolean
    - `container` boolean
    - `string` boolean
    - `pojo` boolean
    - `floatingPointNumber` boolean
    - `short` boolean
    - `int` boolean
    - `long` boolean
    - `valueNode` boolean
    - `missingNode` boolean
    - `nodeType` 'ARRAY' | 'BINARY' | 'BOOLEAN' | 'MISSING' | 'NULL' | 'NUMBER' | 'OBJECT' | 'POJO' | 'STRING'
    - `integralNumber` boolean
    - `double` boolean
    - `bigDecimal` boolean
    - `bigInteger` boolean
    - `textual` boolean
    - `boolean` boolean
    - `binary` boolean
    - `number` boolean
    - `embeddedValue` boolean
  - `htmlContent` string, required: New activity content as HTML. Sanitized on save as on creation; must not be blank.
  - `mentions` ActivityMention[]: Mentions present in the activity
    - `type` string
    - `entityId` string, uuid
    - `label` string
    - `order` integer

## Response `200`

OK

- ActivityRecordValue: An activity record logged against an employer, customer, lead, workflow or meeting, with its replies and reactions
  - `tenantId` string, uuid
  - `createdDate` string, date-time
  - `createdBy` string, uuid
  - `creatorName` string
  - `lastModifiedDate` string, date-time
  - `lastModifiedBy` string, uuid
  - `version` integer
  - `id` string, uuid: Activity record ID
  - `typeId` string, uuid: ID of the activity type
  - `employerId` string, uuid: Employer the activity is logged against, if any
  - `customerId` string, uuid: Customer the activity is linked to, if any (also set for lead, workflow and meeting activities that relate to a customer)
  - `leadId` string, uuid: Lead the activity is linked to, if any
  - `workflowId` string, uuid: Workflow the activity is logged against, if any
  - `meetingId` string, uuid: Meeting the activity is logged against, if any
  - `activityDate` string, date-time: When the activity was logged (ISO-8601, UTC)
  - `jsonContent` JsonNode: Rich-text content of the activity as JSON (the editor's document model), stored alongside htmlContent
    - `empty` boolean
    - `array` boolean
    - `null` boolean
    - `object` boolean
    - `float` boolean
    - `container` boolean
    - `string` boolean
    - `pojo` boolean
    - `floatingPointNumber` boolean
    - `short` boolean
    - `int` boolean
    - `long` boolean
    - `valueNode` boolean
    - `missingNode` boolean
    - `nodeType` 'ARRAY' | 'BINARY' | 'BOOLEAN' | 'MISSING' | 'NULL' | 'NUMBER' | 'OBJECT' | 'POJO' | 'STRING'
    - `integralNumber` boolean
    - `double` boolean
    - `bigDecimal` boolean
    - `bigInteger` boolean
    - `textual` boolean
    - `boolean` boolean
    - `binary` boolean
    - `number` boolean
    - `embeddedValue` boolean
  - `htmlContent` string: Sanitized HTML content of the activity
  - `lastEditedAt` string, date-time: When the content was last edited (ISO-8601, UTC); null if never edited
  - `lastEditedBy` string, uuid: ID of the user who last edited the content; null if never edited
  - `reactions` ActivityReaction[]: Reactions of users on the activity, oldest first
    - `id` string, uuid
    - `userId` string, uuid
    - `userName` string
    - `reaction` string
    - `reactedAt` string, date-time
  - `replies` ActivityReply[]: Replies to the activity, oldest first
    - `id` string, uuid
    - `userId` string, uuid
    - `userName` string
    - `jsonContent` JsonNode: Rich-text content of the activity as JSON (the editor's document model), stored alongside htmlContent
      - `empty` boolean
      - `array` boolean
      - `null` boolean
      - `object` boolean
      - `float` boolean
      - `container` boolean
      - `string` boolean
      - `pojo` boolean
      - `floatingPointNumber` boolean
      - `short` boolean
      - `int` boolean
      - `long` boolean
      - `valueNode` boolean
      - `missingNode` boolean
      - `nodeType` 'ARRAY' | 'BINARY' | 'BOOLEAN' | 'MISSING' | 'NULL' | 'NUMBER' | 'OBJECT' | 'POJO' | 'STRING'
      - `integralNumber` boolean
      - `double` boolean
      - `bigDecimal` boolean
      - `bigInteger` boolean
      - `textual` boolean
      - `boolean` boolean
      - `binary` boolean
      - `number` boolean
      - `embeddedValue` boolean
    - `htmlContent` string
    - `createdAt` string, date-time
    - `updatedAt` string, date-time
    - `mentions` ActivityMention[]
      - `type` string
      - `entityId` string, uuid
      - `label` string
      - `order` integer
    - `reactions` ActivityReaction[]
      - `id` string, uuid
      - `userId` string, uuid
      - `userName` string
      - `reaction` string
      - `reactedAt` string, date-time

---

[API](https://skmtc.dev/surense/apis/activity-api.md) - [All operations](https://skmtc.dev/surense/apis/activity-api/llms.txt) - [OpenAPI document](https://skmtc.dev/surense/apis/activity-api/revisions/1fa9c003b93b?raw)
