1

I understand content types has nothing equivalent to fields internal name, they only have Name, which is like a title.
This can be changed, and alters between locales.
My impression is that the safe approach is to use ID, however it would be nice to use some kind of internal name, and so my question is: Is there any internal name-like solution I can use (filter by and read) in REST/JSOM, and if so how?

I've been experimenting some myself, and this is what I got so far:
When I create a content type, I can specify a name, and this name is stored in SchemaXml like this (NAME):

<ContentType ...><Folder TargetName="_cts/NAME"/></ContentType>

This value does not change, even with different local resources. I'm able to $filter by this value, although I'm only able to do that through SchemaXml, which is quite bad. I'm also only able to read the value by parsing SchemlaXml, yet again quite bad.

Example: _api/Web/AvailableContentTypes?$filter=substringof(%27Item%27,SchemaXml). Applies to List/ContentTypes and Web/ContentTypes as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.