Table of contents

Add a new document type

The document type describes what a page on GOV.UK looks like.

Add the document type in the govuk-content-schema repo

You need to add the document type into the allowed document types in govuk-content-schemas.

Once you have added the document type you should:

  • commit the change
  • run bundle exec rake to generate the schemas again
  • commit this update separately

Examples of implementation:

Create a new rake task in the publishing app

The rake task will publish the route using the new document type.

Before you begin, you must identify which publishing and rendering applications will use the document type. You need to include these as parameters (payload) when you generate the route.

Examples of implementation:

You should publish your new content item with your document type to the Publishing API, especially if you want it to be part of search, as it makes it easy to integrate search this way.

Note

Having a document type with placeholder prefix will not publish routes. More information can be found here under placeholder items.

Add a new content schema

See “Adding a new schema

Se┬že “Make a new document type available to search

This page was last reviewed . It needs to be reviewed again by the page owner #govuk-2ndline.