v51

latestOpenAPI 3.1.0raw.githubusercontent.com2026-08-011189403.1 MB
versioning

Revert a commit in the local repository

Revert a commit in the local repository by creating a new commit that undoes the changes introduced by the specified commit.<br/><br/>Use the <code>force</code> field to proceed even when the working directory is not clean.

post/version/revert

Request body

commitstring required

SHA-1 hash of the commit to revert.

forceboolean

If <code>true</code>, force the revert even when the working directory is not clean. Otherwise, <code>false</code>.

messagestring

Custom message to use for the revert commit. If omitted, a default message is generated.

Response

The created GitRevertResult object in a single-item list.

countinteger required

number of items present in the items array