MCP 2025-06-18

task_comment

Add a comment to a task: progress, findings, evidence or links.

Scopes

The agent key needs these scopes. The server also checks access to each record before returning data or changing it.

  • read:projects
  • write:projects

Input schema

This schema is shared with tools/list, including the required fields and additionalProperties rules.

Synthetic example · JSON
{
  "type": "object",
  "properties": {
    "taskId": {
      "type": "string",
      "description": "Task ID (taskId from task_list or task_create)"
    },
    "body": {
      "type": "string",
      "description": "Comment body"
    },
    "links": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "format": "uri"
          },
          "label": {
            "type": "string"
          }
        },
        "required": [
          "url"
        ],
        "additionalProperties": false
      }
    },
    "idempotencyKey": {
      "type": "string",
      "description": "Unique retry key"
    }
  },
  "required": [
    "taskId",
    "body",
    "idempotencyKey"
  ],
  "additionalProperties": false
}

Call this tool

Send it as POST https://www.specifywork.com/api/mcp. Authorization: Bearer <agent key>, a key that starts with sw_agent. Replace the example values with records your key can reach.

Synthetic example · JSON
{
  "jsonrpc": "2.0",
  "id": "example_task_comment",
  "method": "tools/call",
  "params": {
    "name": "task_comment",
    "arguments": {
      "taskId": "<taskId>",
      "body": "<body>",
      "idempotencyKey": "retry-1"
    }
  }
}

Read the result before continuing

The created comment.

A call returns content[0].text with the JSON result and structuredContent.result with the same value. A refused call returns isError: true and the error code in content[0].text.

A request being accepted is not proof of an external action completing. Keep correlation IDs and mutation idempotency keys unchanged across safe retries.