---
title: "Closes the room as solved on the assistant's behalf."
method: POST
path: "/api/chat/rooms/{roomId}/genai-resolve"
tags: ["GenAiResolve"]
---

# Closes the room as solved on the assistant's behalf.

`POST /api/chat/rooms/{roomId}/genai-resolve`

## Request

- Base URL: `https://api.infoset.app` (the document declares no server; this is the origin it was published from)
- URL: `https://api.infoset.app/api/chat/rooms/{roomId}/genai-resolve`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-Api-Key`
- TypeScript: <https://skmtc.dev/infoset/apis/infoset-rest-api/docs/api/chat/rooms/:roomId/genai-resolve/post.ts> (a function with typed inputs; its response is checked against the schema)

Every field of the `200` body can be false and none of them is an error:
`closed: false` with `alreadyClosed: false` is "a human owns it now",
`alreadyClosed: true` is the idempotent no-op, `alreadyHandled: true` is "you already
sent this". A caller must not retry on any of them — only a 5xx is a failure here, and the
`503` is the one branch that MUST be retried.

## Path parameters

- `roomId` integer, required

## Query parameters

- `accountId` integer
- `departmentId` integer

## Request body

- GenAiResolveRequestDto: Wire body for `POST /api/chat/rooms/{roomId}/genai-resolve`: the assistant closing a conversation it holds and marking it solved. `accountId` and `departmentId` travel as query parameters, matching the ownership and handoff routes.
  - `aiBotId` integer
  - `summary` string, nullable
  - `idempotencyKey` string, nullable
  - `closeMessageId` string, nullable

## Response `200`

OK

- GenAiResolveResponseDto: Wire response for the resolve.
  - `closed` boolean
  - `alreadyClosed` boolean
  - `alreadyHandled` boolean

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `503`: Service Unavailable

---

[API](https://skmtc.dev/infoset/apis/infoset-rest-api.md) - [All operations](https://skmtc.dev/infoset/apis/infoset-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/infoset/apis/infoset-rest-api/revisions/709c8123f593?raw)
