Company logoTrust Center Documentation
API v1 ReferenceDocumentsIdVersioning

Toggle document versioning

Disable versioning to resume editing the promoted document directly. When disabled, existing versions are archived but remain available for review or reactivation.

PATCH
/api/v1/documents/{id}/versioning

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Document ID

Formatuuid

Request Body

application/json

versioning*boolean

Set to false to disable versioning. Set to true to enable versioning without creating a draft.

Response Body

application/json

application/json

application/json

application/json

package mainimport (  "fmt"  "net/http"  "io/ioutil"  "strings")func main() {  url := "https://app.orbiqhq.com/api/v1/documents/3fa85f64-5717-4562-b3fc-2c963f66afa6/versioning"  body := strings.NewReader(`{    "versioning": false  }`)  req, _ := http.NewRequest("PATCH", url, body)  req.Header.Add("Content-Type", "application/json")  res, _ := http.DefaultClient.Do(req)  defer res.Body.Close()  body, _ := ioutil.ReadAll(res.Body)  fmt.Println(res)  fmt.Println(string(body))}
{
  "success": true,
  "data": {
    "versioning": false
  }
}
{
  "type": "string",
  "code": "string",
  "message": "string",
  "doc_url": "string"
}
Empty
{
  "type": "string",
  "code": "string",
  "message": "string",
  "doc_url": "string"
}
{
  "type": "string",
  "code": "string",
  "message": "string",
  "doc_url": "string"
}
Empty

How is this guide?