Content Item Types

A content type in Oracle Content Management basically represents a "content model" for a specific kind of content. The content model defines what constitutes a piece of content of that type.

Say, you want to create a set of articles. Each article has a specific (structured) format: it has a title, a body, an author, and a picture. You can then define a content type that includes these properties. If content authors want to create an article, they must include all these elements for the article to be complete and valid.

Users can easily filter their repositories in the Oracle Content Management web interface to show only structured content items based on content types.


Description of content-item-types-repository.png follows
Description of the illustration content-item-types-repository.png

Create Content Item Types

If you have the required administrative privileges, you can create content item types in the Oracle Content Management web interface (under Administration > Content).


Description of assets-admin-page.png follows
Description of the illustration assets-admin-page.png

When creating a new asset type, you choose to create either a content item type or a digital asset type:


Description of create-content-item-type.png follows
Description of the illustration create-content-item-type.png

Let’s have a closer look at a content item type called "Article". It could have four data fields: article_title, article_body, article_author, and article_picture. The Author data field is a reference to a content type called "Author", which itself has three data fields: author_name, author_photo, and author_bio


Description of content-item-type-article.png follows
Description of the illustration content-item-type-article.png

This is what the "Article" content item type definition looks like:

Description of content-item-type-definition-article.png follows
Description of the illustration content-item-type-definition-article.png

And here’s the "Author" content item type:


Description of content-item-type-definition-author.png follows
Description of the illustration content-item-type-definition-author.png

Each content item type consists of a set of field definitions. Fields support various data types and relationships along with constraints and validation rules. In the preceding example, four fields have been defined for the content item type named "Article": Article Title (article_title), Article Body (article_body), Article Author (article_author), and Article Picture (article_picture).

A content type can have any number of fields, and each field can be any of the supported data types (Text, Large Text, Media, Reference, Date, and so on). Fields can also have a single value or multiple values. Among field types, Reference is a special type. References make it possible for types to link to each other. For example, the Article content type has a field called Author of type Reference, which allows instances of the Author content type to be linked to instances of the Article content type. In relational database terms, this is similar to a foreign key. References, like any other field, can have multiple values. You can create sophisticated data models using content types and references.

Oracle Content Management automatically creates data entry forms with the defined fields for a content type, along with content discovery and smart suggestions. Content authors use these forms to create pieces of content based on that content type. These structured content items are managed by Oracle Content Management as individual units, and they can be published and used in any channel just like any other content.

Create Content Items

Once a content type is defined and made available to a repository, content authors can go into the repository that the content type is associated with and create a new content item based on the Author or Article content type, as well as any media content associated with them (for example, photos).

Description of create-content-item-types.png follows
Description of the illustration create-content-item-types.png

This will open auto-generated forms for creating assets of a specific content type, showing all data fields defined for that content type. For example, the Article form would look as shown in the following image, where each field type shows up with a specific editor (as configured when the content type was created), so content authors can create content in a way that makes sense.

Description of content-item-new-article.png follows
Description of the illustration content-item-new-article.png

Once created, all content items appear in the associated asset repository. From there, they can be published so they become available in their assigned channels.


Description of content-items-assets-view.png follows
Description of the illustration content-items-assets-view.png

It’s important to note that a content type only dictates what content of that type consists of, and not how the content is presented. For that purpose, a content type can have any number of content layouts associated with it, which determine how the content appears and what information is used in that particular layout. This allows for easy reuse of information.


Description of content-layouts.png follows
Description of the illustration content-layouts.png

Content API for Content Items

Content items behave exactly like any other asset in Oracle Content Management: they can be part of a workflow, they can be discovered and routed using API calls, and so on.

Once published, each content item is available as a REST resource. The address to the resource can be found as part of the content item properties.

Description of content-item-api-properties.png follows
Description of the illustration content-item-api-properties.png

You can see the full JSON response data for a content item by clicking the { } brackets next to the delivery URL. Here’s an example of what the JSON response looks like for a content item (note "ContentType" in the typeCategory field and the content item type name in the type field):

{
  "id": "CORE662AF63A872D4A1692CAB0E9FA0AEFFE",
  "type": "Article",
  "typeCategory": "ContentType",
  "name": "The Power of Coffee",
  "description": "Article 'The Power of Coffee' for marketing material",
  "slug": "3000000150001-the-power-of-coffee",
  "language": "en-US",
  "translatable": true,
  "createdDate": {
    "value": "2021-04-06T05:14:02.433Z",
    "timezone": "UTC"
  },
  "updatedDate": {
    "value": "2021-04-06T05:14:02.433Z",
    "timezone": "UTC"
  },
  "fields": {
    "article_title": "The Power of Coffee!",
    "article_author": {
      "id": "CORE9D70A006F41D43268922AB55DBA0A100",
      "type": "Author",
      "typeCategory": "ContentType",
      "name": "David Smith",
      "links": [
        {
          "href": "https://.../content/published/api/v1.1/items/CORE9D70A006F41D43268922AB55DBA0A100?channelToken=1c92bb5b68b245da87ffb8672ff2fddb",
          "rel": "self",
          "method": "GET",
          "mediaType": "application/json"
        }
      ]
    },
    "article_picture": {
      "id": "CONTA37AC23CE5284C46ACF4D3C3B10A9950",
      "type": "Image",
      "typeCategory": "DigitalAssetType",
      "name": "Coffee Beans and Ground Coffee.jpg",
      "links": [
        {
          "href": "https://.../content/published/api/v1.1/items/CONTA37AC23CE5284C46ACF4D3C3B10A9950?channelToken=1c92bb5b68b245da87ffb8672ff2fddb",
          "rel": "self",
          "method": "GET",
          "mediaType": "application/json"
        }
      ]
    },
    "article_body": "Our annual \"Power of Coffee\" fundraiser raised over $1 million to help families in need. With your donations last month, and Cafe Supremo's dollar for dollar matching, we hit our highest numbers ever! Thank you for being a part of our community and giving back to our community. Our annual \"Power of Coffee\" fundraiser raised over $1 million to help families in need. With your donations last month, and Cafe Supremo's dollar for dollar matching, we hit our highest numbers ever! Thank you for being a part of our community and giving back to our community."
  },
  "links": [
    {
      "href": "https://.../content/published/api/v1.1/items/CORE662AF63A872D4A1692CAB0E9FA0AEFFE?channelToken=1c92bb5b68b245da87ffb8672ff2fddb",
      "rel": "self",
      "method": "GET",
      "mediaType": "application/json"
    },
    {
      "href": "https://.../content/published/api/v1.1/items/CORE662AF63A872D4A1692CAB0E9FA0AEFFE?channelToken=1c92bb5b68b245da87ffb8672ff2fddb",
      "rel": "canonical",
      "method": "GET",
      "mediaType": "application/json"
    },
    {
      "href": "https://.../content/published/api/v1.1/metadata-catalog/items/CORE662AF63A872D4A1692CAB0E9FA0AEFFE?channelToken=1c92bb5b68b245da87ffb8672ff2fddb",
      "rel": "describedby",
      "method": "GET",
      "mediaType": "application/schema+json"
    }
  ]
}

Learn More...