Field permissions

Update permissions for writing field values and form visibility for a specific field. This endpoint is used to restrict the ability to modify field values to the roles defined. It also makes it possible to decide if the field can be exposed in forms or not.

This is a enterprise feature.

patch/api/field-permissions/{field_id}/

Path parameters

field_idinteger required

The ID of the field to update the permissions for.

Request body

role'ADMIN' | 'BUILDER' | 'EDITOR' | 'CUSTOM' | 'NOBODY'
  • ADMIN - Admin
  • BUILDER - Builder
  • EDITOR - Editor
  • CUSTOM - Custom
  • NOBODY - Nobody
allow_in_formsboolean

Whether to allow this field to be shown in forms. Default is False. This setting is only relevant if the role is not 'EDITOR'.

Response

role'ADMIN' | 'BUILDER' | 'EDITOR' | 'CUSTOM' | 'NOBODY' required
  • ADMIN - Admin
  • BUILDER - Builder
  • EDITOR - Editor
  • CUSTOM - Custom
  • NOBODY - Nobody
allow_in_formsboolean

Whether to allow this field to be shown in forms. Default is False. This setting is only relevant if the role is not 'EDITOR'.

field_idinteger required

The ID of the field whose permissions were updated.

can_write_valuesboolean

Whether the user can write values to this field.

Changes

Changed in 1 of the 6 revisions of this API.37

  • f3396317d93237See the full diff
    • added the new CUSTOM enum value to the role/allOf[RoleEnum]/ response property for the response status 200

      response-property-enum-value-added

    • added the new ERROR_SUBJECT_DOES_NOT_EXIST enum value to the error response property for the response status 404

      response-property-enum-value-added

    • added the new ERROR_SUBJECT_TYPE_UNSUPPORTED enum value to the error response property for the response status 400

      response-property-enum-value-added

    • added the new optional request property subjects (media type: application/json)

      new-optional-request-property

    • added the new optional request property subjects (media type: application/x-www-form-urlencoded)

      new-optional-request-property

    • added the new optional request property subjects (media type: multipart/form-data)

      new-optional-request-property

    • added the new CUSTOM enum value to the request property role/allOf[RoleEnum]/ (media type: application/json)

      request-property-enum-value-added

    • added the new CUSTOM enum value to the request property role/allOf[RoleEnum]/ (media type: application/x-www-form-urlencoded)

      request-property-enum-value-added

    • added the new CUSTOM enum value to the request property role/allOf[RoleEnum]/ (media type: multipart/form-data)

      request-property-enum-value-added

    • added the required property subjects to the response with the 200 status

      response-required-property-added

    This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog