-
Notifications
You must be signed in to change notification settings - Fork 2
37 Comment
A comment is a text message created by a user under an object in the system. Comments support hierarchical threading through a parent reference, allowing users to reply to previously created comments.
POST /api/v1/comment/setAdds a new comment or updates an existing one.
Request parameters:
| Name | Type | Value | Description |
|---|---|---|---|
| id | UUID | Required only for the Update action. Comment identifier. | |
| parent | UUID | Optional. Parent comment identifier. Specified when replying to a previously created comment (threading). | |
| object | UUID | Required. Object identifier. | |
| priority | INTEGER | Recommended. Comment priority. Default is 0. | |
| text | STRING | Required. Comment text. | |
| data | JSON | Optional. Data in arbitrary format. |
NOTE: If the id key is not specified or is null, the action is treated as Add; otherwise it is treated as Update.
NOTE: Values of unspecified keys are treated as null.
NOTE: For the Update action, you do not need to pass all keys -- only the ones that need to be changed.
NOTE: The response to this request will contain the data from the Get action.
POST /api/v1/comment/getReturns a comment.
Request parameters:
| Name | Type | Value | Description |
|---|---|---|---|
| id | UUID | Required. Comment identifier. |
Response format:
| Field | Type | Description |
|---|---|---|
| id | UUID |
* Comment identifier. |
| parent | UUID | Parent comment identifier. Specified when replying to a previously created comment. |
| object | UUID |
* Object identifier. |
| entity | UUID |
* Entity identifier. |
| entitycode | STRING |
* Entity code. |
| entityname | STRING |
* Entity name. |
| class | UUID |
* Class identifier. |
| classcode | STRING |
* Class code. |
| classlabel | STRING |
* Class label. |
| type | UUID |
* Type identifier. |
| typecode | STRING |
* Type code. |
| typename | STRING |
* Type name. |
| typedescription | STRING |
* Type description. |
| label | STRING | Object label. |
| owner | UUID |
* User account identifier (comment author). |
| username | STRING |
* User account name. |
| name | STRING |
* User display name. |
| given_name | STRING | User's first name. |
| family_name | STRING | User's last name. |
| patronymic_name | STRING | User's patronymic name. |
| STRING | User's email address. | |
| email_verified | BOOLEAN | Whether the user's email is verified. |
| phone | STRING | User's phone number. |
| phone_verified | BOOLEAN | Whether the user's phone is verified. |
| priority | INTEGER |
* Comment priority. Default is 0. |
| created | TIMESTAMP |
* Date and time the comment was created. |
| updated | TIMESTAMP |
* Date and time the comment was last updated. |
| text | STRING |
* Comment text. |
| data | JSON | Data in arbitrary format. |
* -- Cannot be empty.
POST /api/v1/comment/countReturns the number of comments, with optional data filtering.
Request parameters: Common list query parameters
POST /api/v1/comment/listReturns comments as a list.
Request parameters: Common list query parameters
Comments support hierarchical threading. To create a reply to an existing comment, specify the parent field with the identifier of the comment being replied to. This allows building arbitrarily deep comment trees:
Comment A (parent: null)
├── Reply B (parent: A)
│ └── Reply D (parent: B)
└── Reply C (parent: A)
- Notice -- user-targeted notices
- Notification -- system notifications about object changes
- List Query Parameters -- filtering, sorting, pagination
Concepts
API Guide
Authentication & Session
- Connection
- Registration
- Authorization (OAuth 2.0)
- Sign In
- Sign Out
- Password Recovery
- Verification Codes
- Authentication
- Authorization
- Who Am I?
Core Services
Object & Workflow Endpoints
Schema & Internals
Configuration Developer Guide
- Configuration Guide
- Creating an Entity
- Creating a Document
- Creating a Reference
- Workflow Customization
- REST Endpoint Guide
- Event Handler Guide
Operations