---
updatedAt: 2026-07-12T09:38:47.000Z
agentTools:
  siteIndex: https://docs.jfrog.com/llms.txt
  projectIndex: https://docs.jfrog.com/governance/llms.txt
---

# Rollback Application Version

Rolls back the latest promotion of the specified application version to its previous stage. This action removes the promotion record, but the audit log will retain a history of the rollback. The behavior of the rollback on the artifacts in the application version depends on the original promotion type:<br><br>- Copy promotion: Artifacts in the current stage's repositories are deleted.<br>- Move promotion: Artifacts are removed from the current stage's repositories and restored to the previous stage's repositories from a secure internal repository.<br><br>Note: Rollback can be performed from the PROD stage, if needed.<br><br>Note: If an artifact in the target stage has been overwritten by a newer promotion (i.e., the artifact's SHA-256 no longer matches the version's original manifest), that artifact is skipped during rollback and a warning is returned. This prevents accidental deletion of artifacts that now belong to a different version.

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "contact": {},
    "description": "This is the API documentation for the AppTrust Service.",
    "title": "AppTrust Service API",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://{jfrog_url}/apptrust/api",
      "description": "JFrog Platform",
      "variables": {
        "jfrog_url": {
          "default": "myserver.jfrog.io",
          "description": "Your JFrog Platform hostname (e.g., mycompany.jfrog.io)"
        }
      }
    }
  ],
  "paths": {
    "/v1/applications/{application_key}/versions/{version}/rollback": {
      "post": {
        "description": "Rolls back the latest promotion of the specified application version to its previous stage. This action removes the promotion record, but the audit log will retain a history of the rollback. The behavior of the rollback on the artifacts in the application version depends on the original promotion type:<br><br>- Copy promotion: Artifacts in the current stage's repositories are deleted.<br>- Move promotion: Artifacts are removed from the current stage's repositories and restored to the previous stage's repositories from a secure internal repository.<br><br>Note: Rollback can be performed from the PROD stage, if needed.<br><br>Note: If an artifact in the target stage has been overwritten by a newer promotion (i.e., the artifact's SHA-256 no longer matches the version's original manifest), that artifact is skipped during rollback and a warning is returned. This prevents accidental deletion of artifacts that now belong to a different version.",
        "operationId": "rollbackApplicationVersion",
        "parameters": [
          {
            "description": "The unique identifier for the application.",
            "in": "path",
            "name": "application_key",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "The application version.",
            "in": "path",
            "name": "version",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Determines whether the operation should be asynchronous (true) or synchronous (false).<br>The default value is false, which means that Artifactory waits for application version promotion to complete before allowing you to move on to the next task.",
            "in": "query",
            "name": "async",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/request.RollbackAppVersionRequest"
              }
            }
          },
          "description": "Rollback Application Version Request",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/response.RollbackAppVersionResponse"
                }
              }
            },
            "description": "Rollback completed synchronously"
          },
          "202": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/response.RollbackAppVersionResponse"
                }
              }
            },
            "description": "Rollback started asynchronously"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/errors.Errors"
                }
              }
            },
            "description": "Bad Request"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/errors.Errors"
                }
              }
            },
            "description": "Bad Credentials"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/errors.Errors"
                }
              }
            },
            "description": "Permission Denied"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/errors.Errors"
                }
              }
            },
            "description": "Not Found"
          }
        },
        "summary": "Rollback Application Version",
        "tags": [
          "Application version rollback"
        ],
        "x-codegen-request-body-name": "RollbackAppVersionRequest"
      }
    }
  },
  "components": {
    "schemas": {
      "errors.Error": {
        "example": {
          "details": [
            "details",
            "details"
          ],
          "message": "message"
        },
        "properties": {
          "details": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "message": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "errors.Errors": {
        "example": {
          "errors": [
            {
              "details": [
                "details",
                "details"
              ],
              "message": "message"
            },
            {
              "details": [
                "details",
                "details"
              ],
              "message": "message"
            }
          ]
        },
        "properties": {
          "errors": {
            "items": {
              "$ref": "#/components/schemas/errors.Error"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "request.RollbackAppVersionRequest": {
        "properties": {
          "from_stage": {
            "description": "The name of the stage from which to roll back the application version.<br>Note: This parameter acts as a safety check to ensure the rollback targets the correct stage. The request will fail if this value does not match the current stage.",
            "example": "production",
            "type": "string"
          }
        },
        "type": "object"
      },
      "response.RollbackAppVersionResponse": {
        "example": {
          "rollback_from_stage": "production",
          "message": "Rollback completed.",
          "rollback_to_stage": "staging",
          "application_key": "inventory-api",
          "version": "3.0.0"
        },
        "properties": {
          "application_key": {
            "description": "The application key.",
            "example": "inventory-api",
            "type": "string"
          },
          "message": {
            "description": "A human-readable summary of the rollback outcome.",
            "example": "Rollback completed.",
            "type": "string"
          },
          "rollback_from_stage": {
            "description": "The stage from which the version was rolled back.",
            "example": "production",
            "type": "string"
          },
          "rollback_to_stage": {
            "description": "The stage to which the version was rolled back.",
            "example": "staging",
            "type": "string"
          },
          "version": {
            "description": "The application version identifier.",
            "example": "3.0.0",
            "type": "string"
          }
        },
        "type": "object"
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "x-original-swagger-version": "2.0",
  "security": [
    {
      "bearerAuth": []
    }
  ]
}
```