Try TT Now

Tag Rules: Assigning Values to Tags

How to Add Tags and Assign Tag Values

This tag rule allows you change the value of a tag before forwarding the message on to the receiving party or to add a tag isn’t sent by one party before sending the message to the counter-party. The classic example of that would be adding tag 1 (Account) on order messages sent by a FIX client, when the FIX client system doesn't send tag 1 on its orders, because TT FIX Adapter requires tag 1 on order messages.

To assign a new value of a tag or to add a tag that is not included in the message from the sending party:

  1. Locate the row in the Tag Rules section containing the Tag and Direction you want to modify, and click the Edit icon.
  2. From the Editing Tag Rule dialog, select the Assign action.
  3. Enter the value you want to assign to the tag.

  4. Choose any desired options.
    • Apply when Tag 1 (Account) is already present on input message

      If this option is left disabled, Flexible FIX will not override a tag 1 (Account) value if the FIX client's New Order Single (D) message already contained tag 1 (Account). When selected, Flexible FIX will override any FIX client-provided tag 1 (Account) value with the value entered in the Flexible FIX assign tag rule.

    • Apply to all order routing messages (D, F and G)

      When left disabled, Flexible FIX will only apply the assign tag rule to New Order Single (D) messages. When enabled, Flexible FIX will also apply the assign tag rule to Order Cancel Request (F) and Order Cancel/Replace Request (G) messages. Note, this option is only available when creating a tag rule within a New Order Single (D), Order Cancel Request (F), or Order Cancel/Replace Request (G) message.

    • Apply to all messages in the same direction

      When left disabled, Flexible FIX will only apply the assign tag rule to New Order Single (D) messages. When enabled, Flexible FIX will also apply the assign tag rule to all other messages in the same message direction that support this tag.

Example: Assigning an Account Number to All Order Routing Messages

Suppose your company requires all traders to use account number HK33W for all order routing messages. You can configure Flexible FIX to assign the required account number to tag 1 (Account) for all order routing messages before sending them to TT FIX Adapter. In this case, you want to assign the value if missing from the incoming message sent by the FIX client and to overwrite the value if it is present.

To assign an account number to order routing messages:

  1. Navigate to the Rules tab for the profile, if necessary.
  2. In the Tag Rules section, locate the row containing the Account tag for the New Order Single message, similar to the following:

  3. Click the edit icon to open the tag rule editor.

  4. Select the Assign action.

  5. Enter HK33W for the new value. In this example, you want to use this account number for all new orders, even if the order message sent by the FIX client contained a different value in tag 1 (Account), so check the Apply when Tag 1 (Account) is already present on input message option.

  6. As you want to assign this account number for all order routing messages, you check the Apply to all order routing messages (D, F and G) option to apply this rule also on Order Cancel Request (F) ad Order Cancel Replace Request (G) messages.

  7. After saving the tag rule for the New Order Single message, the action is updated for the message, as shown.

  8. To verify that the change was also made to the other order routing messages, you can change to the display filter as shown.

    As you can see, the three order routing messages updated their rules for the Account tag, while the tag rule for the Order Status Request message did not change.