POST api/Purchases/InsertPurContracts?vUserID={vUserID}&IsOpen={IsOpen}

Request Information

URI Parameters

NameDescriptionTypeAdditional information
vUserID

integer

Required

IsOpen

boolean

Required

Body Parameters

PContracts
NameDescriptionTypeAdditional information
ContractId

integer

None.

ContractDate

date

None.

CommodityId

integer

None.

BrokerId

integer

None.

Brokerage

decimal number

None.

IsBrokeragePerBag

boolean

None.

PartyId

integer

None.

RateUnitId

integer

None.

ContractMode

string

None.

Quantity

integer

None.

RatePerUnit

decimal number

None.

IsWithBags

boolean

None.

IsDeliveryInMill

boolean

None.

DeliveryStartDate

date

None.

DeliveryEndDate

date

None.

ModeOfPayment

string

None.

IsPaymentOnSite

boolean

None.

OtherTerms

string

None.

IsPosted

boolean

None.

BagsDeduction

decimal number

None.

OtherDeduction

decimal number

None.

IsCompleted

boolean

None.

Crop

integer

None.

vehicletype

integer

None.

GstRatio

decimal number

None.

IncludeGst

boolean

None.

PerBag

decimal number

None.

fees

decimal number

None.

BrokerageCondition

integer

None.

BrokenCondition

string

None.

PartyName

string

None.

BrokerName

string

None.

CropName

string

None.

CommodityName

string

None.

IsPercentage

boolean

None.

IsPerBag

boolean

None.

IsPerMound

boolean

None.

IsPerVeh

boolean

None.

IsPer100KG

boolean

None.

RemainingBags

string

None.

RemainingWeight

string

None.

ListBroken

Collection of PCBroken

None.

Request Formats

application/json, text/json

Sample:
{
  "ContractId": 1,
  "ContractDate": "2025-12-11T01:02:52.2232376-08:00",
  "CommodityId": 3,
  "BrokerId": 4,
  "Brokerage": 5.0,
  "IsBrokeragePerBag": true,
  "PartyId": 7,
  "RateUnitId": 8,
  "ContractMode": "sample string 9",
  "Quantity": 10,
  "RatePerUnit": 11.0,
  "IsWithBags": true,
  "IsDeliveryInMill": true,
  "DeliveryStartDate": "2025-12-11T01:02:52.2232376-08:00",
  "DeliveryEndDate": "2025-12-11T01:02:52.2232376-08:00",
  "ModeOfPayment": "sample string 16",
  "IsPaymentOnSite": true,
  "OtherTerms": "sample string 18",
  "IsPosted": true,
  "BagsDeduction": 20.0,
  "OtherDeduction": 21.0,
  "IsCompleted": true,
  "Crop": 23,
  "vehicletype": 24,
  "GstRatio": 25.0,
  "IncludeGst": true,
  "PerBag": 27.0,
  "fees": 28.0,
  "BrokerageCondition": 29,
  "BrokenCondition": "sample string 30",
  "PartyName": "sample string 31",
  "BrokerName": "sample string 32",
  "CropName": "sample string 33",
  "CommodityName": "sample string 34",
  "IsPercentage": true,
  "IsPerBag": true,
  "IsPerMound": true,
  "IsPerVeh": true,
  "IsPer100KG": true,
  "RemainingBags": "sample string 40",
  "RemainingWeight": "sample string 41",
  "ListBroken": [
    {
      "ContractID": 1,
      "BrokPer": "sample string 2",
      "BrokRate": "sample string 3",
      "BrokRup": "sample string 4"
    },
    {
      "ContractID": 1,
      "BrokPer": "sample string 2",
      "BrokRate": "sample string 3",
      "BrokRup": "sample string 4"
    }
  ]
}

application/xml, text/xml

Sample:
<PContracts xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RiceMillsERP_API.Models">
  <BagsDeduction>20</BagsDeduction>
  <BrokenCondition>sample string 30</BrokenCondition>
  <BrokerId>4</BrokerId>
  <BrokerName>sample string 32</BrokerName>
  <Brokerage>5</Brokerage>
  <BrokerageCondition>29</BrokerageCondition>
  <CommodityId>3</CommodityId>
  <CommodityName>sample string 34</CommodityName>
  <ContractDate>2025-12-11T01:02:52.2232376-08:00</ContractDate>
  <ContractId>1</ContractId>
  <ContractMode>sample string 9</ContractMode>
  <Crop>23</Crop>
  <CropName>sample string 33</CropName>
  <DeliveryEndDate>2025-12-11T01:02:52.2232376-08:00</DeliveryEndDate>
  <DeliveryStartDate>2025-12-11T01:02:52.2232376-08:00</DeliveryStartDate>
  <GstRatio>25</GstRatio>
  <IncludeGst>true</IncludeGst>
  <IsBrokeragePerBag>true</IsBrokeragePerBag>
  <IsCompleted>true</IsCompleted>
  <IsDeliveryInMill>true</IsDeliveryInMill>
  <IsPaymentOnSite>true</IsPaymentOnSite>
  <IsPer100KG>true</IsPer100KG>
  <IsPerBag>true</IsPerBag>
  <IsPerMound>true</IsPerMound>
  <IsPerVeh>true</IsPerVeh>
  <IsPercentage>true</IsPercentage>
  <IsPosted>true</IsPosted>
  <IsWithBags>true</IsWithBags>
  <ListBroken>
    <PCBroken>
      <BrokPer>sample string 2</BrokPer>
      <BrokRate>sample string 3</BrokRate>
      <BrokRup>sample string 4</BrokRup>
      <ContractID>1</ContractID>
    </PCBroken>
    <PCBroken>
      <BrokPer>sample string 2</BrokPer>
      <BrokRate>sample string 3</BrokRate>
      <BrokRup>sample string 4</BrokRup>
      <ContractID>1</ContractID>
    </PCBroken>
  </ListBroken>
  <ModeOfPayment>sample string 16</ModeOfPayment>
  <OtherDeduction>21</OtherDeduction>
  <OtherTerms>sample string 18</OtherTerms>
  <PartyId>7</PartyId>
  <PartyName>sample string 31</PartyName>
  <PerBag>27</PerBag>
  <Quantity>10</Quantity>
  <RatePerUnit>11</RatePerUnit>
  <RateUnitId>8</RateUnitId>
  <RemainingBags>sample string 40</RemainingBags>
  <RemainingWeight>sample string 41</RemainingWeight>
  <fees>28</fees>
  <vehicletype>24</vehicletype>
</PContracts>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

HttpResponseMessage
NameDescriptionTypeAdditional information
Version

Version

None.

Content

HttpContent

None.

StatusCode

HttpStatusCode

None.

ReasonPhrase

string

None.

Headers

Collection of Object

None.

RequestMessage

HttpRequestMessage

None.

IsSuccessStatusCode

boolean

None.