---
title: Add or Manage Message Type in Nodinite | Encoding, Retention & Custom Fields
description: Master message type management in Nodinite! Learn how to add, edit, and document message types, configure retention and character encoding, leverage custom fields and metadata, and analyze traffic patterns for robust integration monitoring. Empower systems integration experts and customers to support and maintain end-to-end solutions with confidence.
---

# Add or manage Message Type

[Message Types][Message Type] are the foundation that enables format-independent search across your integration landscape. This guide shows you how to create, configure, and optimize Message Types to unlock powerful search capabilities.

## What you'll achieve

* ✅ **Create Message Types** for XML, JSON, EDI, flat files, and custom formats  
* ✅ **Bind [Search Field Expressions][]** to extract searchable values from specific formats  
* ✅ **Configure retention policies** for events, context, and message bodies  
* ✅ **Set the character encoding** messages of this type use  
* ✅ **Document with custom fields** and metadata for governance  
* ✅ **Analyze traffic patterns** and endpoints for operational insights  

![Adding the Message Type Contoso.Webshop.Return/1.0 from Administration, Message Types: Name, Description, then the Retention tab with 90 days for Events, 30 for Context, and 14 for Bodies, and Save, animated walkthrough (7.12)][Hero]  
*Animated walkthrough: **Add Message Type**, name it, set the three retention values on the **Retention** tab, and **Save**. The tab header then shows Events 90, Context 30, and Bodies 14.*  

>[!TIP]
>**New to Message Types?** Read [What is a Message Type?][Message Type] to understand how they enable cross-format search and correlation.

---

You can create a new [Message Type][], edit, or [delete][Show Deleted] an existing one from the [Message Types Overview][Message Type Overview]; [Manage Message Types][] has every step. :new7.12: Permanently deleting a Message Type unbinds the C4 connector Flows that carry it: they stay on their diagrams without a Message Type.

A [Message Type][] can have the following relationships:  

* [Custom Fields][]  
* [Services][]  
* [Stylesheets][]  
* [Custom Metadata][]  
* [Articles][] :new7.12:  

You will see the [Search Field Expressions][] from user-defined [Search Fields][] in read-only mode.  
![Add Message Type page with the General, Retention, and Statistics tabs, the Character encoding field, and the Custom Fields, Services, Search Field Expressions, Stylesheets, and Articles cards (7.12)][1]  
*The **General** tab of a new [Message Type][], with **Character encoding** preset to **UTF-8 (without BOM)** and a card per relation on the right.*  

## Basic data fields

* You must provide a unique **Name** to create the [Message Type][].  
* **Description**: Optionally, add a user-friendly description.  
* **Web Site**: Optionally, provide a quick link for end-users, such as a WIKI or SharePoint site with additional documentation.  
* **Tags**: :new7.12: Add [Tags][Tag] to label the Message Type. Find it later with **Filter on Tag** in the list, and tag many at once with **With Selected** > **Manage Tags**.  
* **Character encoding**: The [character encoding][Character Encoding] that messages of this type use. The default is **UTF-8 (without BOM)**. :new7.11:  

## :fa-language: Character encoding

Select the **Character encoding** that messages of this [Message Type][] normally arrive in. :Nodinite: reads the message bodies with it when they are processed, re-indexed, and viewed, when they are fed to [Stylesheets][], and as the default in the [Search Field Wizard][]. :new7.11:

![Character encoding list open on the Message Type, from UTF-8 (without BOM) to Base64 Decode into UTF-8 (with BOM), each with its Id (7.12)][6]  
*The **Character encoding** dropdown. The Id next to each option is the numeric value you can also use in the `ExtendedProperties/1.0#Encoding` context property.*  

The Message Type setting is the **lowest priority** of four levels. The first level that holds a value wins:

| Priority | Level | Default |
| :---: | --- | --- |
| 1 | `ExtendedProperties/1.0#Encoding` context property on the [Log Event][] | Not set |
| 2 | Encoding named in the XML declaration of the body, such as `<?xml version="1.0" encoding="windows-1252"?>` | Not set |
| 3 | [Character encoding][Character Encoding] on the [Endpoint][Add or manage Endpoint] | **Inherit from the Message Type** |
| 4 | [Character encoding][Character Encoding] on the Message Type (this page) | **UTF-8 (without BOM)** |

Pick one of the supported encodings, such as **UTF-8 (with BOM)**, **UTF-16 (without BOM)**, **Windows-1252**, **ISO-8859-1**, or **EBCDIC (IBM037)**. When the body is logged as Base64 text, pick the matching **Base64 Decode into …** option, for example **Base64 Decode into UTF-8 (without BOM)**. The [Character Encoding][] page lists every option.

>[!TIP]
>When the same format arrives in a different encoding on one specific [Endpoint][Endpoints], keep the common encoding here and override it on that [Endpoint][Add or manage Endpoint].

You can also set the encoding from DevOps pipelines with the [Web API][].

## :fa-trash-can: Remove old messages based on Message Type (Days to keep)

The [Logging Service][] periodically removes old **Events**, **Context**, and **Bodies**.  

* You define the retention period per [Message Type][], on the **Retention** tab. Retention is on for a new Message Type, and the tab header shows the three values (Events, Context, Bodies) at a glance.  
* The system only removes logged events that are in the processed state.  

![Retention tab of O2C.Order.Entry/1.0 with 14 days each for Events, Context, and Bodies, and the three Never remove checkboxes (7.12)][4]  
*The **Retention** tab; each value has its own **Never remove** option.*  

### :fa-envelope-open-text: Days to keep Events

Set the number of days to keep events for a given Message Type. If you set the value to zero (0), the system removes events on the next cleanup run.  
:fa-infinity: The 'Never remove Events' option keeps data in :Nodinite: forever.  

>When the system removes [Log Events][Log Event], it also deletes comments.  

### :fa-key: Days to keep Context

Set the number of days to keep context data for [Log Events][Log Event] of a given Message Type. If you set the value to zero (0), the system removes context on the next cleanup run.  
:fa-infinity: The 'Never remove Context' option keeps data in :Nodinite: forever.  

>This value cannot exceed the 'Days to keep Events'.  

### :fa-file-code: Days to keep Bodies

Set the number of days to keep bodies for events of a given Message Type. If you set the value to zero (0), the system removes bodies on the next cleanup run.  
:fa-infinity: The 'Never remove Bodies' option keeps data in :Nodinite: forever.  

>This value cannot exceed the 'Days to keep Events'.

### Visualization of the days to keep for events

```mermaid
graph TD
  subgraph "fal:fa-envelope-open-text Days to keep Events"
    baseInformation(Information about</br>the Event itself)
    searchFieldValues(Search Field Values)
    comments(Comments)
    subgraph "far:fa-key Days to keep Context"
      conntextValues(&nbsp &nbsp &nbsp Context &nbsp &nbsp &nbsp)
    end    
    subgraph "fal:fa-file-code Days to keep Bodies"
      Bodies(&nbsp &nbsp &nbsp Body &nbsp &nbsp &nbsp)
    end
end
```

The system bases the default values for a new Message Type on [System Parameters][System Parameters] from the configuration database:  

* [DaysToKeepMessageEventsDefault][]: Sets the default number of days to keep events. Deleting an event also deletes its data/body message. The system assigns this value to new message types as default. A change applies only to Message Types created afterwards; no restart is needed.  
* [DaysToKeepMessageContextDefault][]: :new5.3: Sets the default number of days to keep context for an event. The system assigns this value to new message types as default. A change applies only to Message Types created afterwards; no restart is needed.  
* [DaysToKeepMessageDataDefault][]: Sets the default number of days to keep data in an event. The system assigns this value to new message types as default. A change applies only to Message Types created afterwards; no restart is needed.  

:fa-exclamation: If you log too many Messages or Events, data searches may slow down.  

>[!TIP]
>Adjust these settings to fit your business needs. Only keep the data you need.  

## :fa-paint-roller: Custom Fields

As part of the [Repository Model][], you can add [Custom Field][Custom Fields] values to provide additional documentation about your [Message Type][].  
![Assign Custom Fields dialog for a Message Type with the Custom Field Support Team, the value Contoso ERP Team, and Add (7.12)][2]  
*Pick a [Custom Field][Custom Fields], then one or more of its values, and click **Add**.*  

## :fa-gear: Services

A [Service][Services] uses a [Message Type][] through one of its Transport Contracts. The **Services** card lists each Service whose Transport Contract carries the Message Type, with its [System][Systems] under it and links to [Mapify][] and [Mermaid][Mermaid Rendering]. Click a row to open the Service.  
![Services card of the Message Type Contoso.Webshop.Order/1.0 listing Contoso ERP Return Intake with its System Contoso ERP, the count #1, Include deleted, and the Mapify and Mermaid links (7.12)][8]  
*The Services card is read-only: it has no Edit button.*  

The Message Type's view page has the same **Services** card, to the right of the Message Type and above **Articles**. Each row opens the Service's view page and shows its System.  
![View page of the Message Type Contoso.Webshop.Order/1.0 with the Services card listing Contoso ERP Return Intake (System Contoso ERP), #1, above the Articles card (7.12)][9]  
*The view page lists the Services that use the Message Type, too.*  

* To attach or detach a Service, edit that Service's Transport Contract; see [Manage Transport Contracts][]. Neither the Message Type's edit page nor its view page can add or remove one.
* The number in the card header counts the Services listed.
* On the edit page, **Include deleted** also lists deleted Services, marked **Deleted**. When every linked Service is deleted and **Include deleted** isn't ticked, the card says *The only Service here is deleted. Tick Include deleted to list it.* (or *All N Services here are deleted…*).
* The view page has no **Include deleted** and never lists deleted Services.
* When no Service uses the Message Type, the card says *No Service uses this Message Type.* and explains that a Service uses a Message Type when one of its Transport Contracts carries it.
* The card shows only to users who may view Services.  

## :fa-file: Stylesheets

The **Stylesheets** card lists the [Stylesheets][] linked to the [Message Type][]; click **Edit** to change them. A Stylesheet linked to the Message Type **by name** isn't listed here; to change those name links, open the Stylesheet's edit page.  

## :fa-search: Search Field Expressions: The Binding That Powers Search

[Search Field Expressions][] are **bound to Message Types**: the [Logging Service][] runs only the expressions assigned to a message's Message Type, and the extracted values become searchable in [Log Views][]. [How Message Types power search][Message Type Search] explains the binding with an example. Tick **Include deleted** on the card to list deleted expressions too.

![Search Field Expressions card of O2C.Order.Entry/1.0, read-only, with O2C - Customer ID and O2C - Order ID, each listing the Message Types it is bound to (7.12)][3]  
*This section shows all [Search Field Expressions][] bound to this Message Type (read-only view).*  

### Manage Search Field Expressions

Click the [Search Field][] name to navigate to its configuration, or go to [Add or manage Search Field][] in Log Administration to create new bindings.

> :fa-link: **Learn more:** [Search Field Expressions Overview][] explains all 12 expression plugin types and when to use each.  

## :fa-tags: Custom Metadata

As part of the [Repository Model][], you can add [Custom Metadata][] to provide well-structured, additional documentation about the [Message Type][]. Click **Add Custom Metadata** in the section at the bottom of the **General** tab, and switch to **Preview** to see how it reads. See [Add or manage Custom Metadata][].  

## :fa-diagram-project: C4 Properties {#fa-diagram-project-visual-type}

:new7.12: Expand **C4 Properties** on the **General** tab and pick a **Component Type** to set how the [Message Type][] is drawn in [Mapify][]. In [C4 Diagrams][] a Message Type isn't a node: it travels on the connector Flows. The pen edits the chosen [Component Type][Component Types] and **+** creates a new one. The card was called **Visual Type** before 7.12; see [Repository Properties for C4 Diagramming][C4 Properties].  
![C4 Properties card on the Message Type edit page with the Component Type Contoso Message Hub, the pen, and + (7.12)][7]  
*The **C4 Properties** card with a Component Type.*

The card shows only with the [Mapify][] license. Without it, a Component Type that is already set stays set; you just don't see it. The view page of the Message Type shows the same card, read-only, with the Component Type, its **Component Type Description**, and its **Category**.

## :fa-newspaper: Articles

:new7.12:

The **Articles** card lists the [Articles][] that document the [Message Type][], such as a format specification or a mapping guide. Click **Edit** on the card to choose them. See [The Articles Card on Repository Entities][Articles Card].

## Statistics

Open the **Statistics** tab to see the perpetual traffic statistics for the selected [Message Type][]: the number of events per [Endpoint][Endpoints] over time, and a list of every Endpoint that carries it. Pick a date range, filter by Direction, or check **Include deleted**. [What the statistics show][Message Type Statistics] explains how to read them.  

![Statistics tab of a Message Type with events per Endpoint (7.13)][5]  
*This example shows the recorded traffic pattern and its known [Endpoints][] on the selected [Message Type][].*  

---

## :fa-hand-point-right: Next Steps

Now that you've configured your Message Type:

* :fa-magnifying-glass-plus: [Add or manage Search Field][] – Bind Search Field Expressions to this Message Type  
* :fa-puzzle-piece: [Search Field Expressions Overview][] – Explore all 12 expression plugins ([XPath][], [RegEx][], [JSON Path][], etc.)  
* :fa-gear: [Add or manage Service][] – Organize Message Types within Services  
* :fa-search: [Log Views][] – Use this Message Type to filter logs for specific teams  
* :fa-language: [Character Encoding][] – How the Message Type, Endpoint, and Log Event encodings work together  

## :fa-link-horizontal: Related Topics

* :fa-question-circle: [Message Type Conceptual Overview][Message Type] – Understand how Message Types enable cross-format search  
* :fa-lightbulb: [What is a Search Field?][Search Fields] – Learn how Search Fields extract business-critical values  
* :fa-sitemap: [Repository Model][] – See how Message Types fit into the overall architecture  
* :fa-list: [Message Types Overview][Message Type Overview] – Find and view all Message Types  
* :fa-file: [Manage Message Types][] – Delete, restore, export, and re-index Message Types  
* :fa-gear: [Services][] – Group related Message Types together  
* :fa-cube: [Systems][] – Document the systems that produce these messages  
* :fa-sign-in-alt: [Endpoints][] – View endpoints associated with this Message Type  
* :fa-hard-drive: [Logging Service][] – The engine that processes messages and extracts Search Field values  

[1]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/AddNewMessageType.png  
[2]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/CustomField.png  
[3]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/SearchFieldExpression.png  
[4]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/DaysToKeep.png  
[5]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/Statistics.png  
[6]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/EncodingOptions.png  
[7]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/MessageTypeExample_C4Properties.png  
[8]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/MessageTypeServicesCard.png  
[9]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/MessageTypeViewServices.png  

[Add or manage Custom Metadata]:{ndr}/Getting%20Started/4.%20Repository/Custom%20Metadata/Add%20or%20manage%20Custom%20Metadata.md
[Add or manage Endpoint]:{ndr}/Getting%20Started/4.%20Repository/Endpoints/Add%20or%20manage%20Endpoint.md
[Add or manage Search Field]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Add%20or%20manage%20Search%20Field.md
[Add or manage Service]:{ndr}/Getting%20Started/4.%20Repository/Services/Add%20or%20manage%20Service.md
[Articles]:{ndr}/Repository%20Model/Knowledge%20base%20Articles/Overview.md
[Articles Card]:{ndr}/Repository%20Model/Knowledge%20base%20Articles/Features/Articles%20in%20the%20Integration%20CMDB.md#fa-newspaper-the-articles-card-on-repository-entities
[C4 Diagrams]:{ndr}/Repository%20Model/C4%20Diagrams/Overview.md
[C4 Properties]:{ndr}/Repository%20Model/C4%20Diagrams/Troubleshooting/Repository%20Properties%20for%20C4%20Diagramming.md
[Character Encoding]:{ndr}/Core%20Services/Log%20Event/Features/Character%20Encoding.md
[Component Types]:{ndr}/Repository%20Model/Component%20Types/Overview.md
[Custom Fields]:{ndr}/Repository%20Model/Custom%20Fields/Overview.md
[Custom Metadata]:{ndr}/Repository%20Model/Custom%20Metadata/Overview.md
[DaysToKeepMessageContextDefault]:{ndr}/Administration/5.%20Settings/5.%20System%20Parameters/DaysToKeepMessageContextDefault.md
[DaysToKeepMessageDataDefault]:{ndr}/Administration/5.%20Settings/5.%20System%20Parameters/DaysToKeepMessageDataDefault.md
[DaysToKeepMessageEventsDefault]:{ndr}/Administration/5.%20Settings/5.%20System%20Parameters/DaysToKeepMessageEventsDefault.md
[Endpoints]:{ndr}/Repository%20Model/Endpoints/Overview.md
[Hero]:{ndm}/Documentation%20Pictures/IM/WebClient/Repository/MessageTypes/AddMessageType_Walkthrough.gif
[JSON Path]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Search%20Field%20Expressions/JSON%20Path.md
[Log Event]:{ndr}/Core%20Services/Log%20Event/Overview.md
[Log Views]:{ndr}/Administration/1.%20Log%20Management/1.%20Log%20Views/Features/What%20is%20a%20Log%20View.md
[Logging Service]:{ndr}/Core%20Services/Logging%20Service/Overview.md
[Manage Message Types]:{ndr}/Administration/7.%20Repository/Message%20Types/Overview.md
[Manage Transport Contracts]:{ndr}/Getting%20Started/4.%20Repository/Services/Add%20or%20manage%20Service.md#fa-pen-square-manage-transport-contracts
[Mapify]:{ndr}/Mapify/Overview.md
[Mermaid Rendering]:{ndr}/Mapify/Features/Mermaid%20Rendering.md
[Message Type]:{ndr}/Repository%20Model/Message%20Types/Overview.md
[Message Type Overview]:{ndr}/Getting%20Started/4.%20Repository/Message%20Types/Overview.md
[Message Type Search]:{ndr}/Repository%20Model/Message%20Types/Overview.md#in-search-search-fields
[Message Type Statistics]:{ndr}/Repository%20Model/Message%20Types/Overview.md#fa-chart-bar-statistics
[RegEx]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Search%20Field%20Expressions/RegEx.md
[Repository Model]:{ndr}/Repository%20Model/Overview.md
[Search Field]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/What%20is%20a%20Search%20Field.md
[Search Field Expressions]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Search%20Field%20Expressions/Overview.md
[Search Field Expressions Overview]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Search%20Field%20Expressions/Overview.md
[Search Field Wizard]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Getting%20started/How%20to%20use%20the%20Search%20Field%20Wizard.md
[Search Fields]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/What%20is%20a%20Search%20Field.md
[Services]:{ndr}/Repository%20Model/Services/Overview.md
[Show Deleted]:{ndr}/Administration/6.%20Tools/Show%20deleted%20records.md
[Stylesheets]:{ndr}/Administration/4.%20Customize/2.%20Stylesheets/Features/What%20is%20a%20Stylesheet.md
[System Parameters]:{ndr}/Administration/5.%20Settings/5.%20System%20Parameters/Overview.md
[Systems]:{ndr}/Repository%20Model/Systems/Overview.md
[Tag]:{ndr}/Administration/4.%20Customize/5.%20Tags/Features/What%20is%20a%20Tag.md
[Web API]:{ndr}/Core%20Services/Web%20API/Overview.md
[XPath]:{ndr}/Administration/1.%20Log%20Management/2.%20Search%20Fields/Features/Search%20Field%20Expressions/XPath.md