Unicat API Reference

Up - API Reference - Home


/api/p/<project gid>/definitions/metadata/clear

Requires JWT

Remove a metadata field from a definition.

If the metadata field name wasn't set on this definition, the definition is returned unchanged.

Request

POST /api/p/<project gid>/definitions/metadata/clear
Authorization: Bearer <JWT>

{
    "definition": "<definition gid>",
    "name": "group.code",
}

definition gid of the definition to remove the metadata field from
name name for the metadata field

Success response

Authorization: <JWT>

{
    "success": true,
    "result": {
        "definition": "<definition gid>"
    },
    "data": {
        "definitions": {
            "<definition gid>": {}
        },
        "layouts": {
            
        }
    }
}

result

definition the definition with the metadata field removed - this is usually a working copy.

data

definitions Definition info with name, classes, fields, metadata.
layouts Layout info with hierarchy, if the layout changed to a working copy.

Error responses

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