Available Content Type operations:
You can use name and id as an identifier, meaning they have to be unique in the system. You should that you specify an id since that makes renaming of Content Types easier. If a Content Type does not have an id and you rename it, a new Content Type is created and you might have to convert content that used the old name.
Creates a new content type in the system.
See Semantic versioning.
Supported types are:
See Property Data Types for available types and how to use them.
- groupName. Controls in which tab the property should be displayed in the editing user interface. The name is the identifier of the property group, see Property Groups.
- hint. Used to select either editor, renderer, or both by defining a hint string. You can use this hint to select an Editor Definitions. Also see Property Data Types.
Validation works on the most common properties and list properties. For lists, you need to prefix the name with 'item' for validating each item in the list, for example, itemRegularExpression. Possible names:
- regularExpression. Has a pattern setting. Regular expression can only validate string properties.
- length. Has a minimum and maximum setting. The length of string properties can be validated and also how many items a list or link collection property should have.
- range. Has a minimum and maximum setting. Range validation can be applied to numerical and date properties.
Changes to validation settings are not covered by versioning.
Validation defined here is not the same as data annotation; that is, decorating properties in C# classes with validation attributes. These work in conjunction with each other, but you should choose one over the other.
Also known as upsert. Updates the content type at the current location or create a new one if it does not already exist.
If you only want to return a subset of all content types, you can use the top parameter. In the response, you get back a continuation token in the header x-epi-continuation. Use this token in subsequent requests to get the next subset.
List all content types in the system.
Gets the content type at the current location.
Deletes the content type at this location.
See also Content Definitions API class library for the REST API service layer.
Updated about 2 months ago