POST api/CustomerAdvanceDeposit

Creates an CustomerAdvanceDeposit record. Customer, Bill Address, and Site records must exist in order to create an CustomerAdvanceDeposit.

Request Information

URI Parameters

None.

Body Parameters

CustomerAdvanceDeposit
NameDescriptionTypeAdditional information
AdvanceDepositId

Sedona internal autonumber for the Advance Deposit record

integer

None.

DepositCheckId

Foreign key from AR_Deposit_Check table

integer

None.

CustomerId

Foreign key from AR_Customer table

integer

Required

DepositDate

Defaults to today's date, but can be overridden

string

None.

JobNumber

Job_Code from OE_Job table

string

None.

Amount

decimal number

Required

UsedAmount

decimal number

None.

BranchCode

Value from AR_Branch table; defaults to config setting for branchCode if not supplied; list of valid options can be retrieved from GET: api/branch

string

Required

String length: inclusive between 0 and 25

UsedDate

string

None.

AdvanceDepositDetailItems

list of Detail lines

Collection of CustomerAdvanceDepositDetail

Required

Request Formats

application/json, text/json

Sample:
{
  "AdvanceDepositId": 1,
  "DepositCheckId": 2,
  "CustomerId": 3,
  "DepositDate": "sample string 4",
  "JobNumber": "sample string 5",
  "Amount": 6.0,
  "UsedAmount": 7.0,
  "BranchCode": "sample string 8",
  "UsedDate": "sample string 9",
  "AdvanceDepositDetailItems": [
    {
      "AdvanceDepositDetailId": 1,
      "AdvanceDepositId": 2,
      "Date": "sample string 3",
      "TypeUIM": "sample string 4",
      "UnappliedCashId": 1,
      "InvoiceNumber": 1,
      "IncomeAccountCode": "sample string 5",
      "Amount": 1.0,
      "CategoryCode": "sample string 6",
      "Reversed": "sample string 7",
      "UserCode": "sample string 8"
    },
    {
      "AdvanceDepositDetailId": 1,
      "AdvanceDepositId": 2,
      "Date": "sample string 3",
      "TypeUIM": "sample string 4",
      "UnappliedCashId": 1,
      "InvoiceNumber": 1,
      "IncomeAccountCode": "sample string 5",
      "Amount": 1.0,
      "CategoryCode": "sample string 6",
      "Reversed": "sample string 7",
      "UserCode": "sample string 8"
    }
  ]
}

application/xml, text/xml

Sample:
<CustomerAdvanceDeposit xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SedonaServices.Models">
  <AdvanceDepositDetailItems>
    <CustomerAdvanceDepositDetail>
      <AdvanceDepositDetailId>1</AdvanceDepositDetailId>
      <AdvanceDepositId>2</AdvanceDepositId>
      <Amount>1</Amount>
      <CategoryCode>sample string 6</CategoryCode>
      <Date>sample string 3</Date>
      <IncomeAccountCode>sample string 5</IncomeAccountCode>
      <InvoiceNumber>1</InvoiceNumber>
      <Reversed>sample string 7</Reversed>
      <TypeUIM>sample string 4</TypeUIM>
      <UnappliedCashId>1</UnappliedCashId>
      <UserCode>sample string 8</UserCode>
    </CustomerAdvanceDepositDetail>
    <CustomerAdvanceDepositDetail>
      <AdvanceDepositDetailId>1</AdvanceDepositDetailId>
      <AdvanceDepositId>2</AdvanceDepositId>
      <Amount>1</Amount>
      <CategoryCode>sample string 6</CategoryCode>
      <Date>sample string 3</Date>
      <IncomeAccountCode>sample string 5</IncomeAccountCode>
      <InvoiceNumber>1</InvoiceNumber>
      <Reversed>sample string 7</Reversed>
      <TypeUIM>sample string 4</TypeUIM>
      <UnappliedCashId>1</UnappliedCashId>
      <UserCode>sample string 8</UserCode>
    </CustomerAdvanceDepositDetail>
  </AdvanceDepositDetailItems>
  <AdvanceDepositId>1</AdvanceDepositId>
  <Amount>6</Amount>
  <BranchCode>sample string 8</BranchCode>
  <CustomerId>3</CustomerId>
  <DepositCheckId>2</DepositCheckId>
  <DepositDate>sample string 4</DepositDate>
  <JobNumber>sample string 5</JobNumber>
  <UsedAmount>7</UsedAmount>
  <UsedDate>sample string 9</UsedDate>
</CustomerAdvanceDeposit>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'CustomerAdvanceDeposit'.

Response Information

Resource Description

CustomerAdvanceDeposit
NameDescriptionTypeAdditional information
AdvanceDepositId

Sedona internal autonumber for the Advance Deposit record

integer

None.

DepositCheckId

Foreign key from AR_Deposit_Check table

integer

None.

CustomerId

Foreign key from AR_Customer table

integer

Required

DepositDate

Defaults to today's date, but can be overridden

string

None.

JobNumber

Job_Code from OE_Job table

string

None.

Amount

decimal number

Required

UsedAmount

decimal number

None.

BranchCode

Value from AR_Branch table; defaults to config setting for branchCode if not supplied; list of valid options can be retrieved from GET: api/branch

string

Required

String length: inclusive between 0 and 25

UsedDate

string

None.

AdvanceDepositDetailItems

list of Detail lines

Collection of CustomerAdvanceDepositDetail

Required

Response Formats

application/json, text/json

Sample:
{
  "AdvanceDepositId": 1,
  "DepositCheckId": 2,
  "CustomerId": 3,
  "DepositDate": "sample string 4",
  "JobNumber": "sample string 5",
  "Amount": 6.0,
  "UsedAmount": 7.0,
  "BranchCode": "sample string 8",
  "UsedDate": "sample string 9",
  "AdvanceDepositDetailItems": [
    {
      "AdvanceDepositDetailId": 1,
      "AdvanceDepositId": 2,
      "Date": "sample string 3",
      "TypeUIM": "sample string 4",
      "UnappliedCashId": 1,
      "InvoiceNumber": 1,
      "IncomeAccountCode": "sample string 5",
      "Amount": 1.0,
      "CategoryCode": "sample string 6",
      "Reversed": "sample string 7",
      "UserCode": "sample string 8"
    },
    {
      "AdvanceDepositDetailId": 1,
      "AdvanceDepositId": 2,
      "Date": "sample string 3",
      "TypeUIM": "sample string 4",
      "UnappliedCashId": 1,
      "InvoiceNumber": 1,
      "IncomeAccountCode": "sample string 5",
      "Amount": 1.0,
      "CategoryCode": "sample string 6",
      "Reversed": "sample string 7",
      "UserCode": "sample string 8"
    }
  ]
}

application/xml, text/xml

Sample:
<CustomerAdvanceDeposit xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SedonaServices.Models">
  <AdvanceDepositDetailItems>
    <CustomerAdvanceDepositDetail>
      <AdvanceDepositDetailId>1</AdvanceDepositDetailId>
      <AdvanceDepositId>2</AdvanceDepositId>
      <Amount>1</Amount>
      <CategoryCode>sample string 6</CategoryCode>
      <Date>sample string 3</Date>
      <IncomeAccountCode>sample string 5</IncomeAccountCode>
      <InvoiceNumber>1</InvoiceNumber>
      <Reversed>sample string 7</Reversed>
      <TypeUIM>sample string 4</TypeUIM>
      <UnappliedCashId>1</UnappliedCashId>
      <UserCode>sample string 8</UserCode>
    </CustomerAdvanceDepositDetail>
    <CustomerAdvanceDepositDetail>
      <AdvanceDepositDetailId>1</AdvanceDepositDetailId>
      <AdvanceDepositId>2</AdvanceDepositId>
      <Amount>1</Amount>
      <CategoryCode>sample string 6</CategoryCode>
      <Date>sample string 3</Date>
      <IncomeAccountCode>sample string 5</IncomeAccountCode>
      <InvoiceNumber>1</InvoiceNumber>
      <Reversed>sample string 7</Reversed>
      <TypeUIM>sample string 4</TypeUIM>
      <UnappliedCashId>1</UnappliedCashId>
      <UserCode>sample string 8</UserCode>
    </CustomerAdvanceDepositDetail>
  </AdvanceDepositDetailItems>
  <AdvanceDepositId>1</AdvanceDepositId>
  <Amount>6</Amount>
  <BranchCode>sample string 8</BranchCode>
  <CustomerId>3</CustomerId>
  <DepositCheckId>2</DepositCheckId>
  <DepositDate>sample string 4</DepositDate>
  <JobNumber>sample string 5</JobNumber>
  <UsedAmount>7</UsedAmount>
  <UsedDate>sample string 9</UsedDate>
</CustomerAdvanceDeposit>