---
title: "Update a workflow version name"
method: PATCH
path: "/v1/workflow-templates/{id}/versions/{versionId}"
tags: ["Workflows"]
---

# Update a workflow version name

`PATCH /v1/workflow-templates/{id}/versions/{versionId}`

## Request

- Base URL: `https://api.emma.ms/external`
- URL: `https://api.emma.ms/external/v1/workflow-templates/{id}/versions/{versionId}`
- Auth: HTTP bearer

Updates the name of an existing version. 

Names are validated against the pattern: length 2-20 characters, alphanumerics plus `.`, `_`, `-`. Duplicate names within the same workflow template are allowed.

## Path parameters

- `id` integer, required
- `versionId` integer, required

## Request body

- WorkflowTemplateVersionRename
  - `name` string, required: New name for the workflow version. Length 2–20 characters. Allowed characters — alphanumerics, `.`, `_`, `-`.

## Response `200`

Workflow version name updated successfully

- WorkflowTemplateVersionListItem
  - `id` integer, required: ID of the version.
  - `name` string, required: Name of the version.
  - `createdAt` string, required: Date and time of the version creation.
  - `createdById` integer, required: ID of the user or service application that initiated creation of the version.
  - `createdByName` string, required: Name of the user or service application that initiated creation of the version.
  - `isActive` boolean, required: Indicates whether the version is active.
  - `secretsChanged` boolean, required: Indicates whether the secrets were changed in this version.
  - `sequenceNumber` integer, required: A sequential number assigned to each version in creation order.
  - `restoredFrom` integer, nullable: ID of the source version. Present only if this version was created by restoring another version; null otherwise.
  - `restoredFromName` string, nullable: Name of the source version. Present only if this version was created by restoring another version; null otherwise.

## Other responses

- `400`: Bad request
- `401`: Unauthorized
- `403`: Forbidden - Access is denied
- `404`: Not found
- `500`: Internal server error
- `503`: InternalError
- `504`: Timeout

---

[API](https://skmtc.dev/emma/apis/public-emma-api.md) - [All operations](https://skmtc.dev/emma/apis/public-emma-api/llms.txt) - [OpenAPI document](https://skmtc.dev/emma/apis/public-emma-api/revisions/9e55f0920078?raw)
