Creating Custom Message Header Fields
To create a custom message header field, you can create a map with custom user properties fields. The user properties are carried in the message separate from the payload.
C and .NET APIs
When using the C and .NET APIs, you can create a user property map for a message through a single function or method call. Each field in a user properties map is a SDT field. Once the map is created, data for fields in the map can be added with the C and .NET API container functions and methods. For a comprehensive list of the available container methods and functions, see the following in the PubSub+ Messaging APIs documentation for the appropriate messaging API.
JavaScript and Node.js APIs
To create custom message header fields, first create an SDT map with custom user properties fields, then pass it to the setUserPropertyMap
function.
PubSub+ Messaging API | Use |
---|---|
C |
|
.NET |
IMessage.CreateUserPropertyMap() |
JavaScript and Node.js |
|