---
title: "Fixer"
method: POST
path: "/v1/fixer"
tags: ["fixer", "PUBLIC"]
---

# Fixer

`POST /v1/fixer`

Handle fixer requests - supports two formats: 1) JSON with inline file contents in files array, 2) multipart/form-data with tar.zst bundle and manifest (same as Sandbox API). Use multipart for better performance with large projects.

## Request body

- object
  - `files` object[], nullable — List of files to process (JSON format with inline contents). For large projects, use multipart/form-data with manifest + bundle instead.
    - `path` string, required — Path to the file
    - `contents` string, required — File contents
  - `fixes` string[] — Configuration for which fix types to apply
  - `bundle` boolean — Whether to bundle the project (experimental)
  - `event_id` string — Unique identifier for the event
  - `template_id` string, nullable — ID of the template to use
  - `template_path` string — Full path to the template
  - `response_format` 'DIFF' | 'CHANGED_FILES' | 'ALL_FILES' — Format for the response (diff, changed_files, or all_files)
  - `mode` 'project' | 'files' — Fixer operating mode
  - `meta` object, nullable — Meta information for the request
    - `external_id` string, nullable — Customer tracking identifier
  - `response_encoding` 'json' | 'multipart' — Response encoding: "json" for inline file contents in JSON, "multipart" for multipart/form-data with tar.zst bundle + manifest

## Response `200`

Successful Response - returns JSON when response_encoding is "json", or multipart/form-data when response_encoding is "multipart"

- object
  - `data` object, required — The actual response data
    - `status` object, required — Final per-file status after fixing
      - `file_to_composite_status` object — Status of each file
      - `composite_status` 'FIXED_EVERYTHING' | 'FIXED_REQUESTED' | 'PARTIALLY_FIXED' | 'NO_REQUESTED_ISSUES' | 'NO_ISSUES' | 'FAILED', required — Overall composite status
    - `file_to_strategy_statistics` object — Per-file strategy statistics
    - `initial_diagnostics` object, nullable — Diagnostics before fixing, split into relevant vs other based on requested fix types
      - `requested` object, nullable — Diagnostics that match the requested fix types
        - `file_to_diagnostics` object — Diagnostics grouped by file
      - `not_requested` object, nullable — Diagnostics that do not match the requested fix types
        - `file_to_diagnostics` object — Diagnostics grouped by file
    - `final_diagnostics` object, nullable — Diagnostics after fixing, split into relevant vs other based on requested fix types
      - `requested` object, nullable — Diagnostics that match the requested fix types
        - `file_to_diagnostics` object — Diagnostics grouped by file
      - `not_requested` object, nullable — Diagnostics that do not match the requested fix types
        - `file_to_diagnostics` object — Diagnostics grouped by file
    - `fixer_version` string, required — Version of the fixer
    - `suggested_changes` object, required — Suggested changes to fix the issues
      - `all_files` object[], nullable — List of all files with their current contents. Only present when response_encoding is "json".
        - `path` string, required — Path of the file
        - `contents` string, required — Contents of the file
      - `changed_files` object[], nullable — List of changed files with their new contents. Only present when response_encoding is "json".
        - `path` string, required — Path of the file
        - `contents` string, required — Contents of the file
      - `diff` string, nullable — Unified diff of changes. Only present when response_encoding is "json".
    - `bundle` object, nullable — Bundle information if bundling was requested
      - `build_system` string, required
      - `files` object[]
        - `path` string, required — Path of the file
        - `contents` string, required — Contents of the file
      - `bundle_url` string, nullable
      - `status` 'SUCCESS' | 'FAILED' | 'NOT_ATTEMPTED' | 'PARTIAL_SUCCESS', required
      - `template_path` string, required
      - `debug` object
    - `fix_types_used` string[] — Fix types that were used
  - `meta` object — Meta information
    - `trace_id` string, nullable — Unique trace identifier for the request
    - `external_id` string, nullable — Customer tracking identifier
  - `error` object, nullable — The error from the API query
    - `code` string, required — The error code
    - `message` string, required — The error message
    - `details` object — Details about what caused the error

## Other responses

- `400` — Invalid request
- `401` — Unauthorized
- `404` — Not found
- `422` — Validation Error
- `429` — Rate limited
- `500` — Server error

---

[API](https://skmtc.net/benchify/apis/benchify-api.md) · [All operations](https://skmtc.net/benchify/apis/benchify-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/benchify/benchify-api/versions/1a65aea8dd7d/schema)
