Skip to main content

Agent and tool webhooks

We generally send review results to the webhook you set up for each agent. Additionally, you can optionally set up a tool webhook to be called for executing this tool:
  • Tool webhook (optional) — called when a tool review is approved
  • Agent webhook — receives all review completions for that agent; if a tool webhook is called, its response body is also included in the agent webhook as toolResult

Payload

The webhook is a POST request to your endpoint with Content-Type: application/json.
Values in reviewResult.data follow the same shape as the data object in your review request — plus any reviewer edits or selections.
{
  "event": "review.completed",
  "accountId": "abFMvLv4HafQymWxKDAov",
  "reviewId": "123456abcdef",
  "agentId": "agent123456abcdef",
  "sessionId": "session789abcdef",
  "formId": "123456abcdef",
  "formName": "Review AI Draft",
  "reviewResult": {
    "response": "approved",
    "respondingUser": "[email protected]",
    "respondedAt": "2024-10-05T14:48:00.000Z",
    "data": {
      "blogPost": "Regarding the very interesting topic of...",
      "rating": 7.5,
      "decisionSelect": "approve"
    }
  },
  "meta": {
    "example": "LLM thread id"
  },
  "gthLink": "https://app.gotohuman.com/accounts/abFMvLv4HafQymWxKDAov/inbox/agents/all/reviews/123456abcdef"
}

n8n

If you are using n8n to build your AI workflow, read how to handle completed reviews in our n8n integration guide.

Make

When using Make to create your workflow, read our Make integration guide on how to handle submitted reviews.