Skip to main content
POST
Attach Comment
Use this API to attach a comment a person wrote to a check. The attached comment counts in the check’s open count and pages, lists under the check in List Check Comments, and resolves and verifies with it. Attaching a comment that is already attached to another check moves it. Only a person’s comment can be attached. An agent comment already belongs to its check and is refused. The engine never attaches a comment on its own. See Checks Overview.

Endpoint

POST https://api.velt.dev/v2/agents/checks/comments/attach

Headers

string
required
Your API key.
string
required

Body

Params

object
required
The schema uses .strict(): unknown fields are rejected.

Example Requests

Response

Success Response

The comment’s checkInfo now holds attached: true and attachedRuleKey.

Failure Response

Errors: INVALID_ARGUMENT (a body outside the schema: a missing or malformed annotationId or ruleKey, a missing userId, or an unknown field) / NOT_FOUND with CHECKS_COMMENT_NOT_FOUND (no such comment in the project) or CHECKS_WORKSPACE_NOT_FOUND (the workspace has no store database) / FAILED_PRECONDITION with CHECKS_AGENT_COMMENT_NOT_ATTACHABLE (an agent comment).