Update form display

Request

POST https://www.activityinfo.org/resources/form/{formId}/displays

Request body

application/json

object
id string required
label string optional
ownerId string optional
visibility string Values:
PRIVATE
SHARED
optional
formDisplay object optional

Successful response

application/json

object
formId string The id of the form to which this display belongs. required
id string The id of the display. required
type string Values:
TABLE
MAP
READER
required
label string The human-readable label of this display. required
visibility string The visibility of this display. Whether personal or shared. Values:
PRIVATE
SHARED
required
ownerId string If this is a personal display, then this the id of the user who owns the report. optional
ownerName string If this is a personal display, then this is the name of the user who owns the report. optional
deleted boolean Value is true when this display has been deleted required
lastUpdateTime float The last update time, in seconds since 1970-01-01 that the display was updated. required
version integer The monotonically-increasing version of the form display. The version number is incremented whenever a change is made that affects the display meta data or model. required

Error responses

Status Code Error Code Description
400 ILLEGAL_MODEL_ID The form display request id does not match the model id
400 INVALID_ID
400 MISSING_LABEL A form display cannot be added without a label or updated with an empty label
400 MISSING_MODEL A form display cannot be without a display model
400 MISSING_USER_ID A form display with private visibility should have an owner
400 MISSING_VISIBILITY A form display cannot be without visibility
400 USER_ID_NOT_APPLICABLE_FOR_SHARED_DISPLAY A shared form display cannot have an owner
400 VISIBILITY_CAN_NOT_BE_UPDATED The visibility of a shared form display cannot be updated to private
401 AUTHENTICATION_REQUIRED The request must be authenticated
403 PERMISSION_DENIED You do not have permission to add or update this form display
403 USER_ID_CAN_NOT_BE_UPDATED The user id specified in {@link ReportOwnerUpdate} doesn't match authenticated user.
403 USER_NOT_AUTHENTICATED The user id specified doesn't match authenticated user.
Next item
Update form schema