---
title: "POST /api/ee/ai-sql-fixer/fix"
method: POST
path: "/api/ee/ai-sql-fixer/fix"
tags: ["/api/ee/ai-sql-fixer"]
---

# POST /api/ee/ai-sql-fixer/fix

`POST /api/ee/ai-sql-fixer/fix`

Suggest fixes for a SQL query.

## Request body

- object
  - `error_message` string, required
  - `query` object, required
    - `database` integer, required — value must be an integer greater than zero.

## Response `2XX`

Successful response

## Other responses

- `4XX` — Client error response
- `5XX` — Server error response

## Changes

- **2026-03-09** `78297d193ca4` — 1 info
  - api operation id `post-api-ee-ai-sql-fixer-fix` was added

[Change history](https://skmtc.dev/metabase/apis/metabase-api/changes/api/ee/ai-sql-fixer/fix/post.md)

---

[API](https://skmtc.dev/metabase/apis/metabase-api.md) · [All operations](https://skmtc.dev/metabase/apis/metabase-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/metabase/metabase-api/revisions/78297d193ca4/schema)
