POST api/v2/AR/SubmitBatch

Submits a Batch of Cash Receipts to the DockMaster Cash Receipts system.

Request Information

URI Parameters

None.

Body Parameters

CashReceiptBatch
NameDescriptionTypeAdditional information
BatchId

Optional: A Batch Id to add to. A new batch will be created if the supplied Batch Id is closed or does not exist.

string

None.

LocationCode

Optional: The DockMaster Location Code where this batch should go. The default is 1 if not supplied.

string

None.

PostBatch

Optional: If true, the Batch that is created will be posted and closed. If false, it will require user intervention in DockMaster to post the batch.

boolean

None.

CashReceipts

Required: A list of Cash Receipts.

Collection of CashReceipt

Required

Request Formats

application/json, text/json

Sample:
{
  "BatchId": "sample string 1",
  "LocationCode": "sample string 2",
  "PostBatch": true,
  "CashReceipts": [
    {
      "CustomerId": "sample string 1",
      "ReferenceNum": "sample string 2",
      "PayType": "sample string 3",
      "TotalPayment": 4.0,
      "StatementDesc": "sample string 5",
      "InvPayments": [
        {
          "InvoiceId": "sample string 1",
          "DepositType": "sample string 2",
          "PaymentAmt": 3.0
        },
        {
          "InvoiceId": "sample string 1",
          "DepositType": "sample string 2",
          "PaymentAmt": 3.0
        }
      ]
    },
    {
      "CustomerId": "sample string 1",
      "ReferenceNum": "sample string 2",
      "PayType": "sample string 3",
      "TotalPayment": 4.0,
      "StatementDesc": "sample string 5",
      "InvPayments": [
        {
          "InvoiceId": "sample string 1",
          "DepositType": "sample string 2",
          "PaymentAmt": 3.0
        },
        {
          "InvoiceId": "sample string 1",
          "DepositType": "sample string 2",
          "PaymentAmt": 3.0
        }
      ]
    }
  ]
}

application/xml, text/xml

Sample:
<CashReceiptBatch xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/com.dockmaster.lib.models">
  <BatchId>sample string 1</BatchId>
  <CashReceipts>
    <CashReceipt>
      <CustomerId>sample string 1</CustomerId>
      <InvPayments>
        <InvoicePayment>
          <DepositType>sample string 2</DepositType>
          <InvoiceId>sample string 1</InvoiceId>
          <PaymentAmt>3</PaymentAmt>
        </InvoicePayment>
        <InvoicePayment>
          <DepositType>sample string 2</DepositType>
          <InvoiceId>sample string 1</InvoiceId>
          <PaymentAmt>3</PaymentAmt>
        </InvoicePayment>
      </InvPayments>
      <PayType>sample string 3</PayType>
      <ReferenceNum>sample string 2</ReferenceNum>
      <StatementDesc>sample string 5</StatementDesc>
      <TotalPayment>4</TotalPayment>
    </CashReceipt>
    <CashReceipt>
      <CustomerId>sample string 1</CustomerId>
      <InvPayments>
        <InvoicePayment>
          <DepositType>sample string 2</DepositType>
          <InvoiceId>sample string 1</InvoiceId>
          <PaymentAmt>3</PaymentAmt>
        </InvoicePayment>
        <InvoicePayment>
          <DepositType>sample string 2</DepositType>
          <InvoiceId>sample string 1</InvoiceId>
          <PaymentAmt>3</PaymentAmt>
        </InvoicePayment>
      </InvPayments>
      <PayType>sample string 3</PayType>
      <ReferenceNum>sample string 2</ReferenceNum>
      <StatementDesc>sample string 5</StatementDesc>
      <TotalPayment>4</TotalPayment>
    </CashReceipt>
  </CashReceipts>
  <LocationCode>sample string 2</LocationCode>
  <PostBatch>true</PostBatch>
</CashReceiptBatch>

Response Information

Resource Description

SubmitPaymentResult
NameDescriptionTypeAdditional information
BatchId

The Batch Id that was created.

string

None.

ReferenceIds

The reference numbers for the Cash Receipts within the batch.

Collection of string

None.

PostResult

If the PostBatch flag was true, this will contain any messages or errors encountered when posting.

string

None.

Response Formats

application/json, text/json

Sample:
{
  "BatchId": "sample string 1",
  "ReferenceIds": [
    "sample string 1",
    "sample string 2"
  ],
  "PostResult": "sample string 2"
}

application/xml, text/xml

Sample:
<SubmitPaymentResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/com.dockmaster.lib.models">
  <BatchId>sample string 1</BatchId>
  <PostResult>sample string 2</PostResult>
  <ReferenceIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>sample string 1</d2p1:string>
    <d2p1:string>sample string 2</d2p1:string>
  </ReferenceIds>
</SubmitPaymentResult>