---
title: "Edit a question template"
method: PUT
path: "/api/admin/questionnaires/question-templates/{id}"
tags: ["Administration/Questionnaire Templates"]
---

# Edit a question template

`PUT /api/admin/questionnaires/question-templates/{id}`

## Request

- Base URL: `https://api.retraced.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.retraced.com/api/admin/questionnaires/question-templates/{id}`
- Auth: none declared

Replaces a question of the admin question-template library and its options, with the same body rules as the create: optional fields left out are stored empty, and the options replace the stored ones with new rows. The category must exist: 400 `invalid_question_template_category` otherwise. Responds with the question in the `{ data, metadata }` envelope (legacy answered 201 with the bare record). 404 `question_template_not_found` for an unknown id, with nothing written (legacy: `not_found`, after rewriting the options).

## Path parameters

- `id` string, required

## Request body

- object
  - `categoryId` string, required
  - `title` string, required
  - `description` string, nullable
  - `type` 'SHORT_TEXT' | 'LONG_TEXT' | 'NUMBER' | 'NUMBER_UOM' | 'NUMBER_DYNAMIC_UOM' | 'MULTIPLE_CHOICE' | 'CHECK_BOXES' | 'SELECT' | 'ASSET_LINK' | 'YES_NO' | 'YES_NO_THEN' | 'SHORT_TEXT_DATA_MAPPING' | 'LONG_TEXT_DATA_MAPPING' | 'NUMBER_DATA_MAPPING' | 'MULTIPLE_PHOTO_UPLOAD_DATA_MAPPING' | 'SELECT_DATA_MAPPING_ENUM' | 'VIDEO_UPLOAD_DATA_MAPPING' | 'MULTIPLE_SELECT_DATA_MAPPING_ENUM' | 'NUMBER_UOM_DATA_MAPPING' | 'NUMBER_DYNAMIC_UOM_DATA_MAPPING' | 'FIXED_IS_USING_ENERGY_MANAGEMENT_SYSTEM_MAPPING' | 'FIXED_ENERGY_MANAGEMENT_SYSTEM_MAPPING' | 'FIXED_ENERGY_SOURCES_MAPPING' | 'FIXED_IS_MONITORING_GHG_EMISSIONS_MAPPING' | 'FIXED_CARBON_INTENSITY_SCOPE_1_2_MAPPING' | 'FIXED_CARBON_INTENSITY_SCOPE_1_MAPPING' | 'FIXED_CARBON_INTENSITY_SCOPE_2_MAPPING' | 'FIXED_CARBON_INTENSITY_SCOPE_3_MAPPING' | 'FIXED_IS_OFFSETTING_CARBON_EMISSIONS_MAPPING' | 'FIXED_GHG_EMISSIONS_OFFSET_SCOPE_1_2_MAPPING' | 'FIXED_GHG_EMISSIONS_OFFSET_SCOPE_1_MAPPING' | 'FIXED_GHG_EMISSIONS_OFFSET_SCOPE_2_MAPPING' | 'FIXED_GHG_EMISSIONS_OFFSET_SCOPE_3_MAPPING' | 'FIXED_IS_USING_WATER_MANAGEMENT_SYSTEM_MAPPING' | 'FIXED_WATER_MANAGEMENT_SYSTEM_MAPPING' | 'FIXED_WATER_SOURCES_MAPPING' | 'FIXED_IS_TRACKING_WASTEWATER_MAPPING' | 'FIXED_WASTEWATER_TREATMENT_MAPPING' | 'FIXED_WASTEWATER_SOURCES_MAPPING' | 'FIXED_WASTE_WATER_TREATMENT_PROFFICIENCY_MAPPING' | 'FIXED_MATERIAL_CUTOFF_MAPPING' | 'FIXED_HAS_WASTE_REDUCTION_PROGRAM_MAPPING' | 'FIXED_IS_TRACKING_WASTE_STREAMS_MAPPING' | 'FIXED_HAZARDOUS_WASTE_STREAM_VOLUME_MAPPING' | 'FIXED_NON_HAZARDOUS_WASTE_STREAM_VOLUME_MAPPING' | 'FIXED_WASTESTREAM_DISPOSAL_METHOD_MAPPING' | 'FIXED_WASTE_SOURCES_MAPPING' | 'FIXED_ENERGY_SOURCES_PEFCR_MAPPING', required
  - `unit` string, nullable
  - `attachmentFileId` string, nullable
  - `dependentQuestionOptionId` string, nullable
  - `options` object[]
    - `value` string, nullable, required
    - `linkedAsset` union
      - 'CERTIFICATEGROUP' | 'CERTIFICATE' | 'COMPANY_DOCUMENT' | 'FILE' | 'COMPANY_TABLE' | 'COMPANY_ESG_TABLE' | 'AUDIT' | 'MEMBERSHIP' | 'PRODUCT' | 'TRANSACTION' | 'COMPANY' | 'SCOPE'
      - ''
    - `idx` number, nullable, required

## Response `200`

Default Response

- object
  - `metadata` object, required
    - `success` boolean, required: True when the request succeeded.
  - `data` object, required
    - `id` string, required
    - `formTemplateQuestionCategoryId` string, required
    - `title` string, nullable, required
    - `description` string, nullable, required
    - `unit` string, nullable, required
    - `type` string, required
    - `attachmentFileId` string, nullable, required
    - `attachmentFileName` string, nullable, required
    - `attachmentFileUrl` string, nullable, required
    - `originalAttachmentFileUrl` string, nullable, required
    - `attachmentFileContentType` string, nullable, required
    - `attachmentFileType` string, nullable, required
    - `dependentQuestionOptionId` string, nullable, required
    - `options` object[], required
      - `id` string, required
      - `formTemplateQuestionId` string, required
      - `idx` number, nullable, required
      - `value` string, nullable, required
      - `linkedAsset` string, nullable, required

## Other responses

- `400`: Default Response
- `401`: Default Response
- `403`: Default Response
- `404`: Default Response

## Changes

> 108 revisions in range; 2 not diffed.

- **2026-10-16** `4078b89712a6`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/retraced/apis/api-reference/changes/api/admin/questionnaires/question-templates/:id/put.md)

---

[API](https://skmtc.dev/retraced/apis/api-reference.md) - [All operations](https://skmtc.dev/retraced/apis/api-reference/llms.txt) - [OpenAPI document](https://skmtc.dev/retraced/apis/api-reference/revisions/83309c4abd20?raw)
