Property format
Describes the property format resource in CMS (SaaS) and how to work with them.
A property format is a set of rules that apply to a content type's property. It can define validation rules, which editor to use, and settings for that editor. A property format is associated with a specific data type.
The available property formats are limited to formats defined by Optimizely Content Management System (SaaS) and cannot be modified.
The property format resource contains the following fields:
key– A string identifying the property group in the API.dataType– The data type to which you can apply this format. It must be one of the data types. See Data types in Content types.displayName– A user-friendly name for the group displayed to end users.
Pre-defined formats
The following formats represent pre-defined behaviors in the system. You can assign these to a content type property when such a behavior is preferable.
selectOne(string) – Indicates that the string should be one of a list of pre-defined values.selectMany(string) – Indicates that the string should be one or more values of a list of pre-defined values.
List property formats
Retrieve a list of property formats through the propertyformats API. See List property formats API reference.
GET https://api.cms.optimizely.com/preview3/propertyformats[
{
"key": "shortString",
"dataType": "string",
"displayName": "Short string"
},
{
"key": "switch",
"dataType": "boolean",
"displayName": "Switch"
},
]Get a property format
Retrieve a specific property format through the propertyformats API using its unique key. See Get property format API reference.
GET https://api.cms.optimizely.com/preview3/propertyformats/shortstring{
"key": "shortString",
"dataType": "string",
"displayName": "Short string"
}Updated 13 days ago