Up - API Reference - Home
Requires JWT
Revert all changes to a definition.
We used a copy to keep track of the changes; we delete the copy and return the original.
This will also revert the accompanying layout.
Note: you cannot revert an unmodified definition.
Note: you cannot revert an extended definition (use the records/definition api).
POST /api/p/<project gid>/definitions/revert
Authorization: Bearer <JWT>
{
"definition": "<definition gid>"
}
definition
the definition to revert
Authorization: <JWT>
{
"success": true,
"result": {
"definition": "<definition gid>"
},
"data": {
"definitions": {
"<definition gid>": {
"gid": "<definition gid>",
…
}
}
}
}
definition
the original definition, no longer a working copy.
Note: if you revert a newly created definition, it is removed and you'll get
null
for the definition result - and no data either.
definitions
Definition info with name, classes, fields.
400
Bad request - missing parameters or wrong type or value
401
Unauthorized - missing or expired JWT
403
Forbidden - not a member of this project
422
Unprocessable entity - can't work with this item