GET PurchaseContract/GetPurchaseContractByContractByLocationID?Contract={Contract}&Location={Location}

Returns a purchase contract by contract number and location.

Request Information

URI Parameters

NameDescriptionTypeAdditional Information
Contract

string

Required

Location

string

Required

Body Parameters

Response Information

Resource Description

Returns a purchase contract by contract number and location.

AgvPurchaseContractDetails
NameDescriptionTypeAdditional Information
Status

0 - Success; 1 - An error occurred; 2 - An error occurred; 3 - Descriptive message, process was successful

string
Message

Informational message that corresponds to the Status returned; 0 - Message will be "OK"; 1 - Detailed message returned to give user an indication of what went wrong; 2 - Less detailed message returned that may not mean anything to the user but that the application might use to take a corrective action; 3 - Not an error but something the user might need to know

string
Count

The number of results returned.

string
PurchaseContract

ClsGrPurCon

Response Formats

application/json, text/json

Sample:
{
  "Status": "sample string 1",
  "Message": "sample string 2",
  "Count": "1",
  "PurchaseContract": {
    "Contract": "sample string 1",
    "CustID": "sample string 2",
    "Location": "sample string 3",
    "Commodity": "sample string 4",
    "Dateest": "sample string 5",
    "ExpireDate": "sample string 6",
    "ContractStatus": "sample string 7",
    "ContractType": "sample string 8",
    "CashPrice": 9.1,
    "ContractQuantity": 10.1,
    "QuantityRecvd": 11.1,
    "Basisprice": 12.1,
    "FuturesMonth": "sample string 13",
    "Exchange": "sample string 15",
    "StrikePrice": 16.1,
    "Futuresprice": 17.1,
    "ContractSigned": true,
    "BidCriteria": "sample string 19",
    "ShipDestination": "sample string 20",
    "OriginContract": "sample string 21",
    "OriginLocation": "sample string 22",
    "SalesmanID": "sample string 23",
    "PricingNotes": "sample string 24",
    "IsSpot": true,
    "originalContractQuantity": 26.1,
    "PurchaseContractGuid": "dac3aa13-7d1c-4d79-ac42-e122975c5f21",
    "ContractFormat": "sample string 35",
    "DirectShipped": true,
    "LastModifiedUTC": "2022-12-08T04:02:30.2483578+00:00",
    "PurchaseContractDeliveryDates": [
      {
        "Contract": "sample string 1",
        "Location": "sample string 2",
        "Lineitem": "3",
        "StartDate": "sample string 4",
        "Quantity": "5.1",
        "CompleteDate": "sample string 6"
      },
      {
        "Contract": "sample string 1",
        "Location": "sample string 2",
        "Lineitem": "3",
        "StartDate": "sample string 4",
        "Quantity": "5.1",
        "CompleteDate": "sample string 6"
      }
    ],
    "PurchaseContractGradeFactors": [
      {
        "Contract": "sample string 1",
        "Location": "sample string 2",
        "Lineitem": "3",
        "GradFact": "sample string 4",
        "Schedule": "sample string 5",
        "Commodity": "sample string 6"
      },
      {
        "Contract": "sample string 1",
        "Location": "sample string 2",
        "Lineitem": "3",
        "GradFact": "sample string 4",
        "Schedule": "sample string 5",
        "Commodity": "sample string 6"
      }
    ],
    "PurchaseContractComments": [
      {
        "CommentDate": "sample string 4",
        "Comment": "sample string 5"
      },
      {
        "CommentDate": "sample string 4",
        "Comment": "sample string 5"
      }
    ]
  }
}

application/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'application/xml'. Exception message: No set method for property 'QuantityAsStringForApi' in type 'SKY.Core.Grain.ClsGrPurCon+ClsGrPurConDd'.

text/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'text/xml'. Exception message: No set method for property 'QuantityAsStringForApi' in type 'SKY.Core.Grain.ClsGrPurCon+ClsGrPurConDd'.