# Money market blotter records

This page describes the FX API's money market blotter records.

This documentation is for the FX Integration API 12.10.0.

## Money market blotter record

A record in the money market blotter of Caplin's FX Professional web application.

```json
{
  "message_origin": "server",
  "java_class": "com.caplin.generated.motif.mm.blotter.BlotterTypesDef.BlotterRecord",
  "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.BlotterRecord.html",
  "instantiation_pattern": "Builder (via .newBuilder())",
  "code_example": "https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/examples/fxapi/generated/motif/mm/blotter/BlotterTypesDef/BlotterRecordExample.html",
  "parts": [
    {
      "part_name": "CommonBlotterFields",
      "java_class": "com.caplin.generated.motif.mm.blotter.BlotterPartsDef.CommonBlotterFields",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterPartsDef.CommonBlotterFields.html",
      "fields": [
        {
          "name": "Status",
          "type": "string",
          "flags": "",
          "definition": "Indicates the actual status of the trade from the trade model.",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "SettlementStatus",
          "type": "string",
          "flags": "",
          "definition": "Caplin supported statuses are [PENDING, AFFIRMED, CONFIRMED, DISPUTED, CANCELLED, REPLACED, AUTO_CONFIRMED, OVERDUE, REJECTED]",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "CanLaunchTradeConfirmation",
          "type": "boolean",
          "flags": "",
          "definition": "Indicates whether the user can launch the trade confirmation ticket",
          "example_value": "true",
          "deprecated": false
        },
        {
          "name": "AmountDPS",
          "type": "integer",
          "flags": "",
          "definition": "The precision for a specified currency",
          "example_value": "2",
          "deprecated": false
        }
      ]
    },
    {
      "part_name": "TradeConfirmation",
      "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef.TradeConfirmation",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfTypesDef.TradeConfirmation.html",
      "parts": [
        {
          "part_name": "CommonTradeConfirmationFields",
          "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef.CommonTradeConfirmationFields",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfPartsDef.CommonTradeConfirmationFields.html",
          "fields": [
            {
              "name": "TOBOUser",
              "type": "string",
              "flags": "",
              "definition": "The client who the trade is for.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "TraderUsername",
              "type": "string",
              "flags": "",
              "definition": "The name of the trader providing the price to the user, or NO_TRADER if there is none.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Account",
              "type": "string",
              "flags": "",
              "definition": "The used account for the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Action",
              "type": "string",
              "flags": "",
              "definition": "Withdraw or deposit for Call Deposit.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CallAccount",
              "type": "string",
              "flags": "",
              "definition": "The account which is being withdrawn from or deposited to.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Currency",
              "type": "string",
              "flags": "",
              "definition": "The currency in which the trade is made.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "MaturityDate",
              "type": "date",
              "flags": "",
              "definition": "The maturity date of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "MaturityTenor",
              "type": "string",
              "flags": "",
              "definition": "The maturity tenor of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "StartDate",
              "type": "date",
              "flags": "",
              "definition": "The start date of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "StartTenor",
              "type": "string",
              "flags": "",
              "definition": "The start tenor of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "TradeID",
              "type": "string",
              "flags": "",
              "definition": "The unique id identifying the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PrincipalAmount",
              "type": "decimal",
              "flags": "",
              "definition": "The original amount that the trade was created with specified in the provided Currency.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestRate",
              "type": "decimal",
              "flags": "",
              "definition": "Interest rate on the given PrincipalAmount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "IndicativeProfitRate",
              "type": "string",
              "flags": "",
              "definition": "Indicative profit rate on the given PrincipalAmount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestRateDPS",
              "type": "decimal",
              "flags": "",
              "definition": "The precision for a specified InterestRate.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestAmount",
              "type": "decimal",
              "flags": "",
              "definition": "Interest amount (specified in the provided Currency) calculated from the interest rate and principal amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PrincipalPlusInterest",
              "type": "decimal",
              "flags": "",
              "definition": "Composite amount between principal amount and interest amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PaymentFrequency",
              "type": "string",
              "flags": "",
              "definition": "Interest payment frequencies for term deposits, this could be ZERO-COUPON, MONTHLY, QUARTERLY, SEMI-ANNUALLY or ANNUALLY.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "AllocationMode",
              "type": "string",
              "flags": "",
              "definition": "Determines whether the amount will be alLocated to a single or multiple accounts. Supported types are [SINGLE, MULTIPLE] and is defaulted to SINGLE.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "NumberOfDays",
              "type": "string",
              "flags": "",
              "definition": "The number of days between the start and maturity dates.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ExecutionDateTime",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160322123621",
              "deprecated": false
            },
            {
              "name": "EntityId",
              "type": "string",
              "flags": "",
              "definition": "The entity the trade is on behalf of. For example, if the logged in user user1@customer.co.za wishes to make a trade on behalf of entity CUSTONE, then the value of this field will be CUSTONE. If this field is absent on a leg then the default entity should be presumed.",
              "example_value": "CUSTONE",
              "deprecated": false
            },
            {
              "name": "EntityDescription",
              "type": "string",
              "flags": "",
              "definition": "The description of a trade on behalf of entity.",
              "example_value": "Customer 1",
              "deprecated": false
            },
            {
              "name": "TradeDate",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160314",
              "deprecated": false
            },
            {
              "name": "TradingType",
              "type": "string",
              "flags": "",
              "definition": "The type of the trade. Supported types are [LOAN, DEPOSIT, CALL-DEPOSIT, TERM-DEPOSIT, FLEXI-NOTICE-DEPOSIT, TREASURY-BILL or GOVERNMENT-BOND].",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "QuoteID",
              "type": "string",
              "flags": "",
              "definition": "Unique id for a quote, used to determine which quote has been used for trade execution.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "QuoteDateTime",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160314013000",
              "deprecated": false
            },
            {
              "name": "CanAffirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Affirm the Trade Details are as agreed.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "DisplayFields",
              "type": "string",
              "flags": "",
              "definition": "Configuration for a frontend to display label-value pairs. Use DefaultDisplayFields builders to provide Caplin default and/or custom fields.",
              "example_value": "method={'import':'static com.caplin.motif.mm.config.DefaultDisplayFields.addDefaultMMTermSummaryDisplayFields','name':'addDefaultMMTermSummaryDisplayFields','comment':'See DefaultDisplayFields javadoc for parameters and available builder methods.'}",
              "deprecated": false
            },
            {
              "name": "CanCapitalIncrease",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Capital Increase the Trade amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanRollOver",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Roll Over the Trade amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanChangeSSI",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Change the Settlement Instructions.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanGiveNotice",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Give notice for Money Market trades.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "HasPostTradeHistory",
              "type": "boolean",
              "flags": "",
              "definition": "Define whether post-trade history (related deals) is available.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "NoticePeriodDescription",
              "type": "string",
              "flags": "",
              "definition": "The notice period description for the trade, sent as the raw display value or a translation token.",
              "example_value": "32 Days",
              "deprecated": false
            },
            {
              "name": "NoticePeriod",
              "type": "string",
              "flags": "",
              "definition": "The notice period for the trade.",
              "example_value": "32D",
              "deprecated": false
            },
            {
              "name": "IsShariaTrade",
              "type": "boolean",
              "flags": "",
              "definition": "Indicates whether the trade is a Sharia trade",
              "example_value": "true",
              "deprecated": false
            },
            {
              "name": "CanConfirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Confirm the Settlement Details are now final.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ConfirmedBy",
              "type": "string",
              "flags": "",
              "definition": "The name of the user who confirmed a trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Tags",
              "type": "string",
              "flags": "",
              "definition": "Tags for a trade.",
              "example_value": "method={'import':'static com.caplin.motif.fx.config.definitions.common.Tag','name':'Arrays.asList'}",
              "deprecated": false
            },
            {
              "name": "ConfirmedDateTime",
              "type": "datetime",
              "flags": "",
              "definition": "The time at which a trade was confirmed in ISO-8601 format",
              "example_value": "2018-03-16T07:25:16+00:00",
              "deprecated": false
            },
            {
              "name": "CanUnwind",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Unwind the Trade amount.",
              "example_value": "true",
              "deprecated": false
            },
            {
              "name": "Fees",
              "type": "decimal",
              "flags": "",
              "definition": "Fees on the given PrincipalAmount for unwind.",
              "example_value": "10.0",
              "deprecated": false
            },
            {
              "name": "ParentTradeID",
              "type": "string",
              "flags": "",
              "definition": "The unique id identifying the parent trade of this trade in the case of post trade workflows.",
              "example_value": "00002456",
              "deprecated": false
            },
            {
              "name": "NoticeGiven",
              "type": "boolean",
              "flags": "",
              "definition": "Reflects if notice has been given.",
              "example_value": "true",
              "deprecated": false
            }
          ]
        },
        {
          "part_name": "SettlementTradeFields",
          "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementTradeFields",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementTradeFields.html",
          "parts": [
            {
              "part_name": "SettlementFields",
              "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
              "fields": [
                {
                  "name": "Un_PaySettlementId",
                  "type": "string",
                  "flags": "",
                  "definition": "The identifier for the settlement instruction.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PayIsDefaultSettlementInstruction",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Is this the default settlement instruction for this currency",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementInstructionType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                  "example_value": "EXISTING",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                  "example_value": "PRINCIPAL",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementRemarks",
                  "type": "string",
                  "flags": "",
                  "definition": "The remarks corresponding to the settlement details",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementDisplayName",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the settlement instruction. This field can be omitted.",
                  "example_value": "[CCY] Account 1",
                  "deprecated": false
                }
              ]
            },
            {
              "part_name": "SettlementFields",
              "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
              "fields": [
                {
                  "name": "Un_ReceiveSettlementId",
                  "type": "string",
                  "flags": "",
                  "definition": "The identifier for the settlement instruction.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveIsDefaultSettlementInstruction",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Is this the default settlement instruction for this currency",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementInstructionType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                  "example_value": "EXISTING",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                  "example_value": "PRINCIPAL",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementRemarks",
                  "type": "string",
                  "flags": "",
                  "definition": "The remarks corresponding to the settlement details",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementDisplayName",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the settlement instruction. This field can be omitted.",
                  "example_value": "[CCY] Account 1",
                  "deprecated": false
                }
              ]
            }
          ],
          "fields": [
            {
              "name": "Un_CanAffirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Affirm the Trade Details are as agreed.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Un_IsReceiveInterestSplit",
              "type": "boolean",
              "flags": "",
              "definition": "Whether the receive Settlement Instruction has been split into separate Principal and Interest instructions.",
              "example_value": "",
              "deprecated": false
            }
          ]
        }
      ]
    }
  ]
}
```

Java class: [com.caplin.generated.motif.mm.blotter.BlotterTypesDef.BlotterRecord](https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.BlotterRecord.html)

Instantiation pattern: Static Factory Method (via `BlotterTypesDef.BlotterRecord.newBuilder()`)

Java code example:

```java
package com.caplin.examples.fxapi.generated.motif.mm.blotter.BlotterTypesDef; 

import java.math.BigInteger;
import static com.caplin.motif.fx.config.DefaultDisplayFields.addDefaultSalesAllocationDetailsUpdateFields;
import static com.caplin.motif.fx.config.definitions.common.Tag;

import com.caplin.generated.motif.mm.blotter.BlotterPartsDef;
import com.caplin.generated.motif.mm.blotter.BlotterTypesDef;
import com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef;

public class BlotterRecordExample {
    public static void main(String[] args) {
                    		
		BlotterTypesDef.BlotterRecord blotterRecord =
		BlotterTypesDef.BlotterRecord
			.newBuilder()
			.setCommonFields(
			BlotterPartsDef.CommonBlotterFields
				.newBuilder()
				.setAmountDPS("2")
				.setCanLaunchTradeConfirmation(true)
				.setSettlementStatus("")
				.setStatus("Completed")
				.setStatusCategory("SUCCESS")
				.setStatusIsFinal("true")
				.build())
			.setTradeConfirmation(
			TradeConfTypesDef.TradeConfirmation
				.newBuilder()
				.addSettlementTradeFields(
				SettlementInstructionsPartsDef.SettlementTradeFields
					.newBuilder()
					.setCanAffirm(true)
					.setIsReceiveInterestSplit("")
					.setPay(
					SettlementInstructionsPartsDef.SettlementFields
						.newBuilder()
						.setIsDefaultSettlementInstruction("")
						.setSettlementDisplayName("[CCY] Account 1")
						.setSettlementId("")
						.setSettlementInstructionType("EXISTING")
						.setSettlementRemarks("")
						.setSettlementType("")
						.build())
					.setReceive(
					SettlementInstructionsPartsDef.SettlementFields
						.newBuilder()
						.build())
					.build())
				.setCommonFields(
				TradeConfPartsDef.CommonTradeConfirmationFields
					.newBuilder()
					.setAccount("Garfields|GARF")
					.setAction("")
					.setAllocationMode("")
					.setCallAccount("")
					.setCanAffirm(true)
					.setCanCapitalIncrease("")
					.setCanChangeSSI(true)
					.setCanConfirm("")
					.setCanGiveNotice("")
					.setCanRollOver(true)
					.setCanUnwind("")
					.setConfirmedBy("")
					.setConfirmedDateTime("2018-03-16T07:25:16+00:00")
					.setCurrency("USD")
					.setDisplayFields(addDefaultSalesAllocationDetailsUpdateFields(/* See DefaultDisplayFields javadoc for parameters and available builder methods. */))
					.setEntityDescription("Customer 1")
					.setEntityId("CUSTONE")
					.setExecutionDateTime("20160322123621")
					.setExtraFields("")
					.setFees("")
					.setHasPostTradeHistory("")
					.setIndicativeProfitRate("")
					.setInterestAmount(BigDecimal.valueOf(0.0))
					.setInterestRate(BigDecimal.valueOf(0.0))
					.setInterestRateDPS("")
					.setIsShariaTrade("")
					.setMaturityDate(LocalDate.now())
					.setMaturityTenor("")
					.setNoticeGiven("")
					.setNoticePeriod("")
					.setNoticePeriodDescription("")
					.setNumberOfDays("")
					.setParentTradeID("")
					.setPaymentFrequency("")
					.setPrincipalAmount(BigDecimal.valueOf(0.0))
					.setPrincipalPlusInterest("")
					.setQuoteDateTime("")
					.setQuoteID("")
					.setStartDate(LocalDate.now())
					.setStartTenor("1W")
					.setTOBOUser("client@customer.co.za")
					.setTags(Arrays.asList(/* ... */))
					.setTradeDate("20160314")
					.setTradeID("00001561")
					.setTraderUsername("sales_trader@novobank.co.za")
					.setTradingType("SPOT")
					.build())
				.setSettlementTradeFields(
				SettlementInstructionsPartsDef.SettlementTradeFields
					.newBuilder()
					.build(), 0)
				.build())
			.build();
            
    }
}
```

## Money market sales blotter record

A record in the money market blotter of Caplin's FX Sales web application.

```json
{
  "message_origin": "server",
  "java_class": "com.caplin.generated.motif.mm.blotter.BlotterTypesDef.SalesBlotterRecord",
  "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.SalesBlotterRecord.html",
  "instantiation_pattern": "Builder (via .newBuilder())",
  "code_example": "https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/examples/fxapi/generated/motif/mm/blotter/BlotterTypesDef/SalesBlotterRecordExample.html",
  "parts": [
    {
      "part_name": "CommonBlotterFields",
      "java_class": "com.caplin.generated.motif.mm.blotter.BlotterPartsDef.CommonBlotterFields",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterPartsDef.CommonBlotterFields.html",
      "fields": [
        {
          "name": "Status",
          "type": "string",
          "flags": "",
          "definition": "Indicates the actual status of the trade from the trade model.",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "SettlementStatus",
          "type": "string",
          "flags": "",
          "definition": "Caplin supported statuses are [PENDING, AFFIRMED, CONFIRMED, DISPUTED, CANCELLED, REPLACED, AUTO_CONFIRMED, OVERDUE, REJECTED]",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "CanLaunchTradeConfirmation",
          "type": "boolean",
          "flags": "",
          "definition": "Indicates whether the user can launch the trade confirmation ticket",
          "example_value": "true",
          "deprecated": false
        },
        {
          "name": "AmountDPS",
          "type": "integer",
          "flags": "",
          "definition": "The precision for a specified currency",
          "example_value": "2",
          "deprecated": false
        }
      ]
    },
    {
      "part_name": "SalesTradeConfirmation",
      "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef.SalesTradeConfirmation",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfTypesDef.SalesTradeConfirmation.html",
      "parts": [
        {
          "part_name": "TradeConfirmation",
          "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef.TradeConfirmation",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfTypesDef.TradeConfirmation.html",
          "parts": [
            {
              "part_name": "CommonTradeConfirmationFields",
              "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef.CommonTradeConfirmationFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfPartsDef.CommonTradeConfirmationFields.html",
              "fields": [
                {
                  "name": "TOBOUser",
                  "type": "string",
                  "flags": "",
                  "definition": "The client who the trade is for.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "TraderUsername",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the trader providing the price to the user, or NO_TRADER if there is none.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Account",
                  "type": "string",
                  "flags": "",
                  "definition": "The used account for the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Action",
                  "type": "string",
                  "flags": "",
                  "definition": "Withdraw or deposit for Call Deposit.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "CallAccount",
                  "type": "string",
                  "flags": "",
                  "definition": "The account which is being withdrawn from or deposited to.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Currency",
                  "type": "string",
                  "flags": "",
                  "definition": "The currency in which the trade is made.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "MaturityDate",
                  "type": "date",
                  "flags": "",
                  "definition": "The maturity date of the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "MaturityTenor",
                  "type": "string",
                  "flags": "",
                  "definition": "The maturity tenor of the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "StartDate",
                  "type": "date",
                  "flags": "",
                  "definition": "The start date of the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "StartTenor",
                  "type": "string",
                  "flags": "",
                  "definition": "The start tenor of the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "TradeID",
                  "type": "string",
                  "flags": "",
                  "definition": "The unique id identifying the trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "PrincipalAmount",
                  "type": "decimal",
                  "flags": "",
                  "definition": "The original amount that the trade was created with specified in the provided Currency.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "InterestRate",
                  "type": "decimal",
                  "flags": "",
                  "definition": "Interest rate on the given PrincipalAmount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "IndicativeProfitRate",
                  "type": "string",
                  "flags": "",
                  "definition": "Indicative profit rate on the given PrincipalAmount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "InterestRateDPS",
                  "type": "decimal",
                  "flags": "",
                  "definition": "The precision for a specified InterestRate.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "InterestAmount",
                  "type": "decimal",
                  "flags": "",
                  "definition": "Interest amount (specified in the provided Currency) calculated from the interest rate and principal amount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "PrincipalPlusInterest",
                  "type": "decimal",
                  "flags": "",
                  "definition": "Composite amount between principal amount and interest amount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "PaymentFrequency",
                  "type": "string",
                  "flags": "",
                  "definition": "Interest payment frequencies for term deposits, this could be ZERO-COUPON, MONTHLY, QUARTERLY, SEMI-ANNUALLY or ANNUALLY.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "AllocationMode",
                  "type": "string",
                  "flags": "",
                  "definition": "Determines whether the amount will be alLocated to a single or multiple accounts. Supported types are [SINGLE, MULTIPLE] and is defaulted to SINGLE.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "NumberOfDays",
                  "type": "string",
                  "flags": "",
                  "definition": "The number of days between the start and maturity dates.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "ExecutionDateTime",
                  "type": "string",
                  "flags": "",
                  "definition": "",
                  "example_value": "20160322123621",
                  "deprecated": false
                },
                {
                  "name": "EntityId",
                  "type": "string",
                  "flags": "",
                  "definition": "The entity the trade is on behalf of. For example, if the logged in user user1@customer.co.za wishes to make a trade on behalf of entity CUSTONE, then the value of this field will be CUSTONE. If this field is absent on a leg then the default entity should be presumed.",
                  "example_value": "CUSTONE",
                  "deprecated": false
                },
                {
                  "name": "EntityDescription",
                  "type": "string",
                  "flags": "",
                  "definition": "The description of a trade on behalf of entity.",
                  "example_value": "Customer 1",
                  "deprecated": false
                },
                {
                  "name": "TradeDate",
                  "type": "string",
                  "flags": "",
                  "definition": "",
                  "example_value": "20160314",
                  "deprecated": false
                },
                {
                  "name": "TradingType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of the trade. Supported types are [LOAN, DEPOSIT, CALL-DEPOSIT, TERM-DEPOSIT, FLEXI-NOTICE-DEPOSIT, TREASURY-BILL or GOVERNMENT-BOND].",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "QuoteID",
                  "type": "string",
                  "flags": "",
                  "definition": "Unique id for a quote, used to determine which quote has been used for trade execution.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "QuoteDateTime",
                  "type": "string",
                  "flags": "",
                  "definition": "",
                  "example_value": "20160314013000",
                  "deprecated": false
                },
                {
                  "name": "CanAffirm",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Affirm the Trade Details are as agreed.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "DisplayFields",
                  "type": "string",
                  "flags": "",
                  "definition": "Configuration for a frontend to display label-value pairs. Use DefaultDisplayFields builders to provide Caplin default and/or custom fields.",
                  "example_value": "method={'import':'static com.caplin.motif.mm.config.DefaultDisplayFields.addDefaultMMTermSummaryDisplayFields','name':'addDefaultMMTermSummaryDisplayFields','comment':'See DefaultDisplayFields javadoc for parameters and available builder methods.'}",
                  "deprecated": false
                },
                {
                  "name": "CanCapitalIncrease",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Capital Increase the Trade amount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "CanRollOver",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Roll Over the Trade amount.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "CanChangeSSI",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Change the Settlement Instructions.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "CanGiveNotice",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Give notice for Money Market trades.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "HasPostTradeHistory",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Define whether post-trade history (related deals) is available.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "NoticePeriodDescription",
                  "type": "string",
                  "flags": "",
                  "definition": "The notice period description for the trade, sent as the raw display value or a translation token.",
                  "example_value": "32 Days",
                  "deprecated": false
                },
                {
                  "name": "NoticePeriod",
                  "type": "string",
                  "flags": "",
                  "definition": "The notice period for the trade.",
                  "example_value": "32D",
                  "deprecated": false
                },
                {
                  "name": "IsShariaTrade",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Indicates whether the trade is a Sharia trade",
                  "example_value": "true",
                  "deprecated": false
                },
                {
                  "name": "CanConfirm",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Confirm the Settlement Details are now final.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "ConfirmedBy",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the user who confirmed a trade.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Tags",
                  "type": "string",
                  "flags": "",
                  "definition": "Tags for a trade.",
                  "example_value": "method={'import':'static com.caplin.motif.fx.config.definitions.common.Tag','name':'Arrays.asList'}",
                  "deprecated": false
                },
                {
                  "name": "ConfirmedDateTime",
                  "type": "datetime",
                  "flags": "",
                  "definition": "The time at which a trade was confirmed in ISO-8601 format",
                  "example_value": "2018-03-16T07:25:16+00:00",
                  "deprecated": false
                },
                {
                  "name": "CanUnwind",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Unwind the Trade amount.",
                  "example_value": "true",
                  "deprecated": false
                },
                {
                  "name": "Fees",
                  "type": "decimal",
                  "flags": "",
                  "definition": "Fees on the given PrincipalAmount for unwind.",
                  "example_value": "10.0",
                  "deprecated": false
                },
                {
                  "name": "ParentTradeID",
                  "type": "string",
                  "flags": "",
                  "definition": "The unique id identifying the parent trade of this trade in the case of post trade workflows.",
                  "example_value": "00002456",
                  "deprecated": false
                },
                {
                  "name": "NoticeGiven",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Reflects if notice has been given.",
                  "example_value": "true",
                  "deprecated": false
                }
              ]
            },
            {
              "part_name": "SettlementTradeFields",
              "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementTradeFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementTradeFields.html",
              "parts": [
                {
                  "part_name": "SettlementFields",
                  "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
                  "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
                  "fields": [
                    {
                      "name": "Un_PaySettlementId",
                      "type": "string",
                      "flags": "",
                      "definition": "The identifier for the settlement instruction.",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_PayIsDefaultSettlementInstruction",
                      "type": "boolean",
                      "flags": "",
                      "definition": "Is this the default settlement instruction for this currency",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_PaySettlementInstructionType",
                      "type": "string",
                      "flags": "",
                      "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                      "example_value": "EXISTING",
                      "deprecated": false
                    },
                    {
                      "name": "Un_PaySettlementType",
                      "type": "string",
                      "flags": "",
                      "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                      "example_value": "PRINCIPAL",
                      "deprecated": false
                    },
                    {
                      "name": "Un_PaySettlementRemarks",
                      "type": "string",
                      "flags": "",
                      "definition": "The remarks corresponding to the settlement details",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_PaySettlementDisplayName",
                      "type": "string",
                      "flags": "",
                      "definition": "The name of the settlement instruction. This field can be omitted.",
                      "example_value": "[CCY] Account 1",
                      "deprecated": false
                    }
                  ]
                },
                {
                  "part_name": "SettlementFields",
                  "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
                  "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
                  "fields": [
                    {
                      "name": "Un_ReceiveSettlementId",
                      "type": "string",
                      "flags": "",
                      "definition": "The identifier for the settlement instruction.",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_ReceiveIsDefaultSettlementInstruction",
                      "type": "boolean",
                      "flags": "",
                      "definition": "Is this the default settlement instruction for this currency",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_ReceiveSettlementInstructionType",
                      "type": "string",
                      "flags": "",
                      "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                      "example_value": "EXISTING",
                      "deprecated": false
                    },
                    {
                      "name": "Un_ReceiveSettlementType",
                      "type": "string",
                      "flags": "",
                      "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                      "example_value": "PRINCIPAL",
                      "deprecated": false
                    },
                    {
                      "name": "Un_ReceiveSettlementRemarks",
                      "type": "string",
                      "flags": "",
                      "definition": "The remarks corresponding to the settlement details",
                      "example_value": "",
                      "deprecated": false
                    },
                    {
                      "name": "Un_ReceiveSettlementDisplayName",
                      "type": "string",
                      "flags": "",
                      "definition": "The name of the settlement instruction. This field can be omitted.",
                      "example_value": "[CCY] Account 1",
                      "deprecated": false
                    }
                  ]
                }
              ],
              "fields": [
                {
                  "name": "Un_CanAffirm",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Ability to Affirm the Trade Details are as agreed.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_IsReceiveInterestSplit",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Whether the receive Settlement Instruction has been split into separate Principal and Interest instructions.",
                  "example_value": "",
                  "deprecated": false
                }
              ]
            }
          ]
        },
        {
          "part_name": "SalesCommonTradeConfirmationFields",
          "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef.SalesCommonTradeConfirmationFields",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfPartsDef.SalesCommonTradeConfirmationFields.html",
          "fields": [
            {
              "name": "TraderInterestRate",
              "type": "decimal",
              "flags": "",
              "definition": "Interest rate on the given PrincipalAmount with no client margin applied to it.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestMargin",
              "type": "decimal",
              "flags": "Editable",
              "definition": "Interest margin on the given InterestRate.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "StreamingMode",
              "type": "string",
              "flags": "",
              "definition": "Indicates whether the rates/margins of this trade have been manually set",
              "example_value": "MANUAL, STREAMING",
              "deprecated": false
            },
            {
              "name": "Profit",
              "type": "decimal",
              "flags": "",
              "definition": "The sales profit in the specified currency.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ProfitCurrency",
              "type": "string",
              "flags": "",
              "definition": "The profit currency that the ProfitRate is being provided for.",
              "example_value": "USD",
              "deprecated": false
            },
            {
              "name": "ProfitCurrencyDPS",
              "type": "integer",
              "flags": "",
              "definition": "The number of decimal places that should be used for formatting the amount in profit currency field.",
              "example_value": "2",
              "deprecated": false
            },
            {
              "name": "ProfitIsHouse",
              "type": "boolean",
              "flags": "",
              "definition": "Whether the field ProfitCurrency is the system/house currency or not.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ProfitRate",
              "type": "decimal",
              "flags": "",
              "definition": "The conversion rate between the contra currency and the profit currency. This can be used for entering profit in an amount of settlement currency.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "TradeStatus",
              "type": "string",
              "flags": "",
              "definition": "The current status of the trade. Supported types are [AWAITING-TRADER, AWAITING-PRICE, PRICED, EXECUTING, CLOSED, REJECTED, ERRORED, COMPLETED]. CLOSED means the client cancelled the trade request, REJECTED indicates it was rejected by the dealer.",
              "example_value": "AWAITING-PRICE",
              "deprecated": false
            },
            {
              "name": "Reasons",
              "type": "string",
              "flags": "",
              "definition": "A JSON structure containing all the reasons and information about why the trade requires intervention. Use DefaultDisplayFields builders to provide Caplin default and/or custom fields.",
              "example_value": "method={'import':'static com.caplin.motif.mm.config.DefaultDisplayFields.addDefaultReasonsHeaderDisplayFields','name':'addDefaultReasonsHeaderDisplayFields','comment':'See DefaultDisplayFields javadoc for parameters and available builder methods.'}",
              "deprecated": false
            },
            {
              "name": "DisplayFields",
              "type": "string",
              "flags": "",
              "definition": "Configuration for a frontend to display label-value pairs. Use DefaultDisplayFields builders to provide Caplin default and/or custom fields.",
              "example_value": "method={'import':'static com.caplin.motif.mm.config.DefaultDisplayFields.addDefaultMMTermSummaryDisplayFields','name':'addDefaultMMTermSummaryDisplayFields','comment':'See DefaultDisplayFields javadoc for parameters and available builder methods.'}",
              "deprecated": false
            }
          ]
        }
      ]
    }
  ]
}
```

Java class: [com.caplin.generated.motif.mm.blotter.BlotterTypesDef.SalesBlotterRecord](https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.SalesBlotterRecord.html)

Instantiation pattern: Static Factory Method (via `BlotterTypesDef.SalesBlotterRecord.newBuilder()`)

Java code example:

```java
package com.caplin.examples.fxapi.generated.motif.mm.blotter.BlotterTypesDef; 

import java.math.BigInteger;
import static com.caplin.motif.fx.config.DefaultDisplayFields.addDefaultSalesAllocationDetailsUpdateFields;
import static com.caplin.motif.fx.config.definitions.common.Tag;

import com.caplin.generated.motif.mm.blotter.BlotterPartsDef;
import com.caplin.generated.motif.mm.blotter.BlotterTypesDef;
import com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef;

public class SalesBlotterRecordExample {
    public static void main(String[] args) {
                    		
		BlotterTypesDef.SalesBlotterRecord salesBlotterRecord =
		BlotterTypesDef.SalesBlotterRecord
			.newBuilder()
			.setCommonFields(
			BlotterPartsDef.CommonBlotterFields
				.newBuilder()
				.setAmountDPS("2")
				.setCanLaunchTradeConfirmation(true)
				.setSettlementStatus("")
				.setStatus("Completed")
				.setStatusCategory("SUCCESS")
				.setStatusIsFinal("true")
				.build())
			.setSalesTradeConfirmation(
			TradeConfTypesDef.SalesTradeConfirmation
				.newBuilder()
				.setSalesCommonFields(
				TradeConfPartsDef.SalesCommonTradeConfirmationFields
					.newBuilder()
					.setDisplayFields(addDefaultSalesAllocationDetailsUpdateFields(/* See DefaultDisplayFields javadoc for parameters and available builder methods. */))
					.setInterestMargin(BigDecimal.valueOf(0.0), true)
					.setInterestMarginEditable()
					.setProfit(BigDecimal.valueOf(1000))
					.setProfitCurrency("USD")
					.setProfitCurrencyDPS(5)
					.setProfitIsHouse(true)
					.setProfitRate("1.091790")
					.setReasons(arg)
					.setStreamingMode("MANUAL, STREAMING")
					.setTradeStatus("AWAITING-PRICE")
					.setTraderInterestRate("")
					.build())
				.setTradeConfirmation(
				TradeConfTypesDef.TradeConfirmation
					.newBuilder()
					.addSettlementTradeFields(
					SettlementInstructionsPartsDef.SettlementTradeFields
						.newBuilder()
						.setCanAffirm(true)
						.setIsReceiveInterestSplit("")
						.setPay(
						SettlementInstructionsPartsDef.SettlementFields
							.newBuilder()
							.setIsDefaultSettlementInstruction("")
							.setSettlementDisplayName("[CCY] Account 1")
							.setSettlementId("")
							.setSettlementInstructionType("EXISTING")
							.setSettlementRemarks("")
							.setSettlementType("")
							.build())
						.setReceive(
						SettlementInstructionsPartsDef.SettlementFields
							.newBuilder()
							.build())
						.build())
					.setCommonFields(
					TradeConfPartsDef.CommonTradeConfirmationFields
						.newBuilder()
						.setAccount("Garfields|GARF")
						.setAction("")
						.setAllocationMode("")
						.setCallAccount("")
						.setCanAffirm(true)
						.setCanCapitalIncrease("")
						.setCanChangeSSI(true)
						.setCanConfirm("")
						.setCanGiveNotice("")
						.setCanRollOver(true)
						.setCanUnwind("")
						.setConfirmedBy("")
						.setConfirmedDateTime("2018-03-16T07:25:16+00:00")
						.setCurrency("USD")
						.setDisplayFields(addDefaultSalesAllocationDetailsUpdateFields(/* See DefaultDisplayFields javadoc for parameters and available builder methods. */))
						.setEntityDescription("Customer 1")
						.setEntityId("CUSTONE")
						.setExecutionDateTime("20160322123621")
						.setExtraFields("")
						.setFees("")
						.setHasPostTradeHistory("")
						.setIndicativeProfitRate("")
						.setInterestAmount(BigDecimal.valueOf(0.0))
						.setInterestRate(BigDecimal.valueOf(0.0))
						.setInterestRateDPS("")
						.setIsShariaTrade("")
						.setMaturityDate(LocalDate.now())
						.setMaturityTenor("")
						.setNoticeGiven("")
						.setNoticePeriod("")
						.setNoticePeriodDescription("")
						.setNumberOfDays("")
						.setParentTradeID("")
						.setPaymentFrequency("")
						.setPrincipalAmount(BigDecimal.valueOf(0.0))
						.setPrincipalPlusInterest("")
						.setQuoteDateTime("")
						.setQuoteID("")
						.setStartDate(LocalDate.now())
						.setStartTenor("1W")
						.setTOBOUser("client@customer.co.za")
						.setTags(Arrays.asList(/* ... */))
						.setTradeDate("20160314")
						.setTradeID("00001561")
						.setTraderUsername("sales_trader@novobank.co.za")
						.setTradingType("SPOT")
						.build())
					.setSettlementTradeFields(
					SettlementInstructionsPartsDef.SettlementTradeFields
						.newBuilder()
						.build(), 0)
					.build())
				.build())
			.build();
            
    }
}
```

## Money market sales-intervention blotter record

A record in the money market [sales intervention](../fx-sales/st-sales-intervention) blotter of Caplin's FX Sales web application. 

```json
{
  "message_origin": "server",
  "java_class": "com.caplin.generated.motif.mm.blotter.BlotterTypesDef.InterventionBlotterRecord",
  "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.InterventionBlotterRecord.html",
  "instantiation_pattern": "Builder (via .newBuilder())",
  "code_example": "https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/examples/fxapi/generated/motif/mm/blotter/BlotterTypesDef/InterventionBlotterRecordExample.html",
  "parts": [
    {
      "part_name": "InterventionBlotterFields",
      "java_class": "com.caplin.generated.motif.mm.blotter.BlotterPartsDef.InterventionBlotterFields",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/blotter/BlotterPartsDef.InterventionBlotterFields.html",
      "fields": [
        {
          "name": "TradeStatus",
          "type": "string",
          "flags": "",
          "definition": "The current status of the trade. Supported types are [AWAITING-TRADER, AWAITING-PRICE, PRICED, EXECUTING, CLOSED, REJECTED, ERRORED, COMPLETED]. CLOSED means the client cancelled the trade request, REJECTED indicates it was rejected by the dealer.",
          "example_value": "AWAITING-PRICE",
          "deprecated": false
        },
        {
          "name": "IntervenerUsername",
          "type": "string",
          "flags": "",
          "definition": "The user who is currently intervening on and potentially pricing a trade.",
          "example_value": "head_trader@novobank.co.za",
          "deprecated": false
        },
        {
          "name": "Dealable",
          "type": "boolean",
          "flags": "",
          "definition": "Determines whether the trade is dealable or not.",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "Source",
          "type": "string",
          "flags": "",
          "definition": "The source the trade to be intervened originated",
          "example_value": "",
          "deprecated": false
        },
        {
          "name": "Competition",
          "type": "boolean",
          "flags": "",
          "definition": "Whether there is competition to price the trade to be intervened",
          "example_value": "",
          "deprecated": false
        }
      ]
    },
    {
      "part_name": "TradeConfirmation",
      "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef.TradeConfirmation",
      "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfTypesDef.TradeConfirmation.html",
      "parts": [
        {
          "part_name": "CommonTradeConfirmationFields",
          "java_class": "com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef.CommonTradeConfirmationFields",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/tradeconfirmation/TradeConfPartsDef.CommonTradeConfirmationFields.html",
          "fields": [
            {
              "name": "TOBOUser",
              "type": "string",
              "flags": "",
              "definition": "The client who the trade is for.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "TraderUsername",
              "type": "string",
              "flags": "",
              "definition": "The name of the trader providing the price to the user, or NO_TRADER if there is none.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Account",
              "type": "string",
              "flags": "",
              "definition": "The used account for the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Action",
              "type": "string",
              "flags": "",
              "definition": "Withdraw or deposit for Call Deposit.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CallAccount",
              "type": "string",
              "flags": "",
              "definition": "The account which is being withdrawn from or deposited to.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Currency",
              "type": "string",
              "flags": "",
              "definition": "The currency in which the trade is made.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "MaturityDate",
              "type": "date",
              "flags": "",
              "definition": "The maturity date of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "MaturityTenor",
              "type": "string",
              "flags": "",
              "definition": "The maturity tenor of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "StartDate",
              "type": "date",
              "flags": "",
              "definition": "The start date of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "StartTenor",
              "type": "string",
              "flags": "",
              "definition": "The start tenor of the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "TradeID",
              "type": "string",
              "flags": "",
              "definition": "The unique id identifying the trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PrincipalAmount",
              "type": "decimal",
              "flags": "",
              "definition": "The original amount that the trade was created with specified in the provided Currency.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestRate",
              "type": "decimal",
              "flags": "",
              "definition": "Interest rate on the given PrincipalAmount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "IndicativeProfitRate",
              "type": "string",
              "flags": "",
              "definition": "Indicative profit rate on the given PrincipalAmount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestRateDPS",
              "type": "decimal",
              "flags": "",
              "definition": "The precision for a specified InterestRate.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "InterestAmount",
              "type": "decimal",
              "flags": "",
              "definition": "Interest amount (specified in the provided Currency) calculated from the interest rate and principal amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PrincipalPlusInterest",
              "type": "decimal",
              "flags": "",
              "definition": "Composite amount between principal amount and interest amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "PaymentFrequency",
              "type": "string",
              "flags": "",
              "definition": "Interest payment frequencies for term deposits, this could be ZERO-COUPON, MONTHLY, QUARTERLY, SEMI-ANNUALLY or ANNUALLY.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "AllocationMode",
              "type": "string",
              "flags": "",
              "definition": "Determines whether the amount will be alLocated to a single or multiple accounts. Supported types are [SINGLE, MULTIPLE] and is defaulted to SINGLE.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "NumberOfDays",
              "type": "string",
              "flags": "",
              "definition": "The number of days between the start and maturity dates.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ExecutionDateTime",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160322123621",
              "deprecated": false
            },
            {
              "name": "EntityId",
              "type": "string",
              "flags": "",
              "definition": "The entity the trade is on behalf of. For example, if the logged in user user1@customer.co.za wishes to make a trade on behalf of entity CUSTONE, then the value of this field will be CUSTONE. If this field is absent on a leg then the default entity should be presumed.",
              "example_value": "CUSTONE",
              "deprecated": false
            },
            {
              "name": "EntityDescription",
              "type": "string",
              "flags": "",
              "definition": "The description of a trade on behalf of entity.",
              "example_value": "Customer 1",
              "deprecated": false
            },
            {
              "name": "TradeDate",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160314",
              "deprecated": false
            },
            {
              "name": "TradingType",
              "type": "string",
              "flags": "",
              "definition": "The type of the trade. Supported types are [LOAN, DEPOSIT, CALL-DEPOSIT, TERM-DEPOSIT, FLEXI-NOTICE-DEPOSIT, TREASURY-BILL or GOVERNMENT-BOND].",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "QuoteID",
              "type": "string",
              "flags": "",
              "definition": "Unique id for a quote, used to determine which quote has been used for trade execution.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "QuoteDateTime",
              "type": "string",
              "flags": "",
              "definition": "",
              "example_value": "20160314013000",
              "deprecated": false
            },
            {
              "name": "CanAffirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Affirm the Trade Details are as agreed.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "DisplayFields",
              "type": "string",
              "flags": "",
              "definition": "Configuration for a frontend to display label-value pairs. Use DefaultDisplayFields builders to provide Caplin default and/or custom fields.",
              "example_value": "method={'import':'static com.caplin.motif.mm.config.DefaultDisplayFields.addDefaultMMTermSummaryDisplayFields','name':'addDefaultMMTermSummaryDisplayFields','comment':'See DefaultDisplayFields javadoc for parameters and available builder methods.'}",
              "deprecated": false
            },
            {
              "name": "CanCapitalIncrease",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Capital Increase the Trade amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanRollOver",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Roll Over the Trade amount.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanChangeSSI",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Change the Settlement Instructions.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "CanGiveNotice",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Give notice for Money Market trades.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "HasPostTradeHistory",
              "type": "boolean",
              "flags": "",
              "definition": "Define whether post-trade history (related deals) is available.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "NoticePeriodDescription",
              "type": "string",
              "flags": "",
              "definition": "The notice period description for the trade, sent as the raw display value or a translation token.",
              "example_value": "32 Days",
              "deprecated": false
            },
            {
              "name": "NoticePeriod",
              "type": "string",
              "flags": "",
              "definition": "The notice period for the trade.",
              "example_value": "32D",
              "deprecated": false
            },
            {
              "name": "IsShariaTrade",
              "type": "boolean",
              "flags": "",
              "definition": "Indicates whether the trade is a Sharia trade",
              "example_value": "true",
              "deprecated": false
            },
            {
              "name": "CanConfirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Confirm the Settlement Details are now final.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "ConfirmedBy",
              "type": "string",
              "flags": "",
              "definition": "The name of the user who confirmed a trade.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Tags",
              "type": "string",
              "flags": "",
              "definition": "Tags for a trade.",
              "example_value": "method={'import':'static com.caplin.motif.fx.config.definitions.common.Tag','name':'Arrays.asList'}",
              "deprecated": false
            },
            {
              "name": "ConfirmedDateTime",
              "type": "datetime",
              "flags": "",
              "definition": "The time at which a trade was confirmed in ISO-8601 format",
              "example_value": "2018-03-16T07:25:16+00:00",
              "deprecated": false
            },
            {
              "name": "CanUnwind",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Unwind the Trade amount.",
              "example_value": "true",
              "deprecated": false
            },
            {
              "name": "Fees",
              "type": "decimal",
              "flags": "",
              "definition": "Fees on the given PrincipalAmount for unwind.",
              "example_value": "10.0",
              "deprecated": false
            },
            {
              "name": "ParentTradeID",
              "type": "string",
              "flags": "",
              "definition": "The unique id identifying the parent trade of this trade in the case of post trade workflows.",
              "example_value": "00002456",
              "deprecated": false
            },
            {
              "name": "NoticeGiven",
              "type": "boolean",
              "flags": "",
              "definition": "Reflects if notice has been given.",
              "example_value": "true",
              "deprecated": false
            }
          ]
        },
        {
          "part_name": "SettlementTradeFields",
          "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementTradeFields",
          "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementTradeFields.html",
          "parts": [
            {
              "part_name": "SettlementFields",
              "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
              "fields": [
                {
                  "name": "Un_PaySettlementId",
                  "type": "string",
                  "flags": "",
                  "definition": "The identifier for the settlement instruction.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PayIsDefaultSettlementInstruction",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Is this the default settlement instruction for this currency",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementInstructionType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                  "example_value": "EXISTING",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                  "example_value": "PRINCIPAL",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementRemarks",
                  "type": "string",
                  "flags": "",
                  "definition": "The remarks corresponding to the settlement details",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_PaySettlementDisplayName",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the settlement instruction. This field can be omitted.",
                  "example_value": "[CCY] Account 1",
                  "deprecated": false
                }
              ]
            },
            {
              "part_name": "SettlementFields",
              "java_class": "com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef.SettlementFields",
              "javadoc": "https://docs.caplin.com/developer/api/fxintegration/com/caplin/generated/motif/mm/settlementinstructions/SettlementInstructionsPartsDef.SettlementFields.html",
              "fields": [
                {
                  "name": "Un_ReceiveSettlementId",
                  "type": "string",
                  "flags": "",
                  "definition": "The identifier for the settlement instruction.",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveIsDefaultSettlementInstruction",
                  "type": "boolean",
                  "flags": "",
                  "definition": "Is this the default settlement instruction for this currency",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementInstructionType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement instruction attached to a trade. Supported types are [EXISTING, ADHOC, NONE]",
                  "example_value": "EXISTING",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementType",
                  "type": "string",
                  "flags": "",
                  "definition": "The type of settlement attached to a trade. Supported types are [PRINCIPAL, INTEREST]",
                  "example_value": "PRINCIPAL",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementRemarks",
                  "type": "string",
                  "flags": "",
                  "definition": "The remarks corresponding to the settlement details",
                  "example_value": "",
                  "deprecated": false
                },
                {
                  "name": "Un_ReceiveSettlementDisplayName",
                  "type": "string",
                  "flags": "",
                  "definition": "The name of the settlement instruction. This field can be omitted.",
                  "example_value": "[CCY] Account 1",
                  "deprecated": false
                }
              ]
            }
          ],
          "fields": [
            {
              "name": "Un_CanAffirm",
              "type": "boolean",
              "flags": "",
              "definition": "Ability to Affirm the Trade Details are as agreed.",
              "example_value": "",
              "deprecated": false
            },
            {
              "name": "Un_IsReceiveInterestSplit",
              "type": "boolean",
              "flags": "",
              "definition": "Whether the receive Settlement Instruction has been split into separate Principal and Interest instructions.",
              "example_value": "",
              "deprecated": false
            }
          ]
        }
      ]
    }
  ]
}
```

Java class: [com.caplin.generated.motif.mm.blotter.BlotterTypesDef.InterventionBlotterRecord](https://docs.caplin.com/developer/api/fxintegration/latest/com/caplin/generated/motif/mm/blotter/BlotterTypesDef.InterventionBlotterRecord.html)

Instantiation pattern: Static Factory Method (via `BlotterTypesDef.InterventionBlotterRecord.newBuilder()`)

Java code example:

```java
package com.caplin.examples.fxapi.generated.motif.mm.blotter.BlotterTypesDef; 

import java.math.BigInteger;
import static com.caplin.motif.fx.config.DefaultDisplayFields.addDefaultSalesAllocationDetailsUpdateFields;
import static com.caplin.motif.fx.config.definitions.common.Tag;

import com.caplin.generated.motif.mm.blotter.BlotterPartsDef;
import com.caplin.generated.motif.mm.blotter.BlotterTypesDef;
import com.caplin.generated.motif.mm.settlementinstructions.SettlementInstructionsPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfPartsDef;
import com.caplin.generated.motif.mm.tradeconfirmation.TradeConfTypesDef;

public class InterventionBlotterRecordExample {
    public static void main(String[] args) {
                    		
		BlotterTypesDef.InterventionBlotterRecord interventionBlotterRecord =
		BlotterTypesDef.InterventionBlotterRecord
			.newBuilder()
			.setInterventionBlotterFields(
			BlotterPartsDef.InterventionBlotterFields
				.newBuilder()
				.setCompetition(true)
				.setDealable(true)
				.setIntervenerUsername("head_trader@novobank.co.za")
				.setSource("WMR 8am London Time")
				.setTradeStatus("AWAITING-PRICE")
				.build())
			.setTradeConfirmation(
			TradeConfTypesDef.TradeConfirmation
				.newBuilder()
				.addSettlementTradeFields(
				SettlementInstructionsPartsDef.SettlementTradeFields
					.newBuilder()
					.setCanAffirm(true)
					.setIsReceiveInterestSplit("")
					.setPay(
					SettlementInstructionsPartsDef.SettlementFields
						.newBuilder()
						.setIsDefaultSettlementInstruction("")
						.setSettlementDisplayName("[CCY] Account 1")
						.setSettlementId("")
						.setSettlementInstructionType("EXISTING")
						.setSettlementRemarks("")
						.setSettlementType("")
						.build())
					.setReceive(
					SettlementInstructionsPartsDef.SettlementFields
						.newBuilder()
						.build())
					.build())
				.setCommonFields(
				TradeConfPartsDef.CommonTradeConfirmationFields
					.newBuilder()
					.setAccount("Garfields|GARF")
					.setAction("")
					.setAllocationMode("")
					.setCallAccount("")
					.setCanAffirm(true)
					.setCanCapitalIncrease("")
					.setCanChangeSSI(true)
					.setCanConfirm("")
					.setCanGiveNotice("")
					.setCanRollOver(true)
					.setCanUnwind("")
					.setConfirmedBy("")
					.setConfirmedDateTime("2018-03-16T07:25:16+00:00")
					.setCurrency("USD")
					.setDisplayFields(addDefaultSalesAllocationDetailsUpdateFields(/* See DefaultDisplayFields javadoc for parameters and available builder methods. */))
					.setEntityDescription("Customer 1")
					.setEntityId("CUSTONE")
					.setExecutionDateTime("20160322123621")
					.setExtraFields("")
					.setFees("")
					.setHasPostTradeHistory("")
					.setIndicativeProfitRate("")
					.setInterestAmount(BigDecimal.valueOf(0.0))
					.setInterestRate(BigDecimal.valueOf(0.0))
					.setInterestRateDPS("")
					.setIsShariaTrade("")
					.setMaturityDate(LocalDate.now())
					.setMaturityTenor("")
					.setNoticeGiven("")
					.setNoticePeriod("")
					.setNoticePeriodDescription("")
					.setNumberOfDays("")
					.setParentTradeID("")
					.setPaymentFrequency("")
					.setPrincipalAmount(BigDecimal.valueOf(0.0))
					.setPrincipalPlusInterest("")
					.setQuoteDateTime("")
					.setQuoteID("")
					.setStartDate(LocalDate.now())
					.setStartTenor("1W")
					.setTOBOUser("client@customer.co.za")
					.setTags(Arrays.asList(/* ... */))
					.setTradeDate("20160314")
					.setTradeID("00001561")
					.setTraderUsername("sales_trader@novobank.co.za")
					.setTradingType("SPOT")
					.build())
				.setSettlementTradeFields(
				SettlementInstructionsPartsDef.SettlementTradeFields
					.newBuilder()
					.build(), 0)
				.build())
			.build();
            
    }
}
```
