Trendsic Platform Service

<back to all web services

OrderLinesRequest

The following routes are available for this service:
POST,PUT,DELETE,OPTIONS/v1/OrderLines
GET/v1/OrderLines/OrderHeaders/{OrderHeaderUID}
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    public static class OrderLinesRequest
    {
        public UUID OrderHeaderUID = null;
        public ArrayList<OrderLine> OrderLines = new ArrayList<OrderLine>();
        
        public UUID getOrderHeaderUID() { return OrderHeaderUID; }
        public OrderLinesRequest setOrderHeaderUID(UUID value) { this.OrderHeaderUID = value; return this; }
        public ArrayList<OrderLine> getOrderLines() { return OrderLines; }
        public OrderLinesRequest setOrderLines(ArrayList<OrderLine> value) { this.OrderLines = value; return this; }
    }

    public static class OrderLine
    {
        public Integer ID = null;
        public UUID OrderHeaderID = null;
        public Short OrderLineNumber = null;
        public Short ProductID = null;
        public String StripeProductId = null;
        public Short ProductCategory = null;
        public Short ProductSubCategory = null;
        public Short Quantity = null;
        public BigDecimal TotalOrderLineCost = null;
        public BigDecimal ProductCost = null;
        public BigDecimal PerUnitProductCost = null;
        public BigDecimal OrderLineTax = null;
        public BigDecimal OrderLineShippingCost = null;
        public BigDecimal PerUnitShippingCost = null;
        public Short OrderLineStatusID = null;
        public Short ShipMethodID = null;
        public Date EstimatedShipDate = null;
        public Date EstimatedDeliveryDate = null;
        public Date ActualShipDate = null;
        public Date ActualDeliveryDate = null;
        public Date OrderLineCreatedDate = null;
        public Date OrderLineModifiedDate = null;
        public UUID UID = null;
        public String ProductName = null;
        public Integer AgentId = null;
        public String Street = null;
        public String City = null;
        public String State = null;
        public String Zip = null;
        public String PhoneNumber = null;
        public Integer AddressId = null;
        public String ShippingAddress = null;
        public String FullName = null;
        
        public Integer getId() { return ID; }
        public OrderLine setId(Integer value) { this.ID = value; return this; }
        public UUID getOrderHeaderID() { return OrderHeaderID; }
        public OrderLine setOrderHeaderID(UUID value) { this.OrderHeaderID = value; return this; }
        public Short getOrderLineNumber() { return OrderLineNumber; }
        public OrderLine setOrderLineNumber(Short value) { this.OrderLineNumber = value; return this; }
        public Short getProductID() { return ProductID; }
        public OrderLine setProductID(Short value) { this.ProductID = value; return this; }
        public String getStripeProductId() { return StripeProductId; }
        public OrderLine setStripeProductId(String value) { this.StripeProductId = value; return this; }
        public Short getProductCategory() { return ProductCategory; }
        public OrderLine setProductCategory(Short value) { this.ProductCategory = value; return this; }
        public Short getProductSubCategory() { return ProductSubCategory; }
        public OrderLine setProductSubCategory(Short value) { this.ProductSubCategory = value; return this; }
        public Short getQuantity() { return Quantity; }
        public OrderLine setQuantity(Short value) { this.Quantity = value; return this; }
        public BigDecimal getTotalOrderLineCost() { return TotalOrderLineCost; }
        public OrderLine setTotalOrderLineCost(BigDecimal value) { this.TotalOrderLineCost = value; return this; }
        public BigDecimal getProductCost() { return ProductCost; }
        public OrderLine setProductCost(BigDecimal value) { this.ProductCost = value; return this; }
        public BigDecimal getPerUnitProductCost() { return PerUnitProductCost; }
        public OrderLine setPerUnitProductCost(BigDecimal value) { this.PerUnitProductCost = value; return this; }
        public BigDecimal getOrderLineTax() { return OrderLineTax; }
        public OrderLine setOrderLineTax(BigDecimal value) { this.OrderLineTax = value; return this; }
        public BigDecimal getOrderLineShippingCost() { return OrderLineShippingCost; }
        public OrderLine setOrderLineShippingCost(BigDecimal value) { this.OrderLineShippingCost = value; return this; }
        public BigDecimal getPerUnitShippingCost() { return PerUnitShippingCost; }
        public OrderLine setPerUnitShippingCost(BigDecimal value) { this.PerUnitShippingCost = value; return this; }
        public Short getOrderLineStatusID() { return OrderLineStatusID; }
        public OrderLine setOrderLineStatusID(Short value) { this.OrderLineStatusID = value; return this; }
        public Short getShipMethodID() { return ShipMethodID; }
        public OrderLine setShipMethodID(Short value) { this.ShipMethodID = value; return this; }
        public Date getEstimatedShipDate() { return EstimatedShipDate; }
        public OrderLine setEstimatedShipDate(Date value) { this.EstimatedShipDate = value; return this; }
        public Date getEstimatedDeliveryDate() { return EstimatedDeliveryDate; }
        public OrderLine setEstimatedDeliveryDate(Date value) { this.EstimatedDeliveryDate = value; return this; }
        public Date getActualShipDate() { return ActualShipDate; }
        public OrderLine setActualShipDate(Date value) { this.ActualShipDate = value; return this; }
        public Date getActualDeliveryDate() { return ActualDeliveryDate; }
        public OrderLine setActualDeliveryDate(Date value) { this.ActualDeliveryDate = value; return this; }
        public Date getOrderLineCreatedDate() { return OrderLineCreatedDate; }
        public OrderLine setOrderLineCreatedDate(Date value) { this.OrderLineCreatedDate = value; return this; }
        public Date getOrderLineModifiedDate() { return OrderLineModifiedDate; }
        public OrderLine setOrderLineModifiedDate(Date value) { this.OrderLineModifiedDate = value; return this; }
        public UUID getUid() { return UID; }
        public OrderLine setUid(UUID value) { this.UID = value; return this; }
        public String getProductName() { return ProductName; }
        public OrderLine setProductName(String value) { this.ProductName = value; return this; }
        public Integer getAgentId() { return AgentId; }
        public OrderLine setAgentId(Integer value) { this.AgentId = value; return this; }
        public String getStreet() { return Street; }
        public OrderLine setStreet(String value) { this.Street = value; return this; }
        public String getCity() { return City; }
        public OrderLine setCity(String value) { this.City = value; return this; }
        public String getState() { return State; }
        public OrderLine setState(String value) { this.State = value; return this; }
        public String getZip() { return Zip; }
        public OrderLine setZip(String value) { this.Zip = value; return this; }
        public String getPhoneNumber() { return PhoneNumber; }
        public OrderLine setPhoneNumber(String value) { this.PhoneNumber = value; return this; }
        public Integer getAddressId() { return AddressId; }
        public OrderLine setAddressId(Integer value) { this.AddressId = value; return this; }
        public String getShippingAddress() { return ShippingAddress; }
        public OrderLine setShippingAddress(String value) { this.ShippingAddress = value; return this; }
        public String getFullName() { return FullName; }
        public OrderLine setFullName(String value) { this.FullName = value; return this; }
    }

    public static class OrderLinesResponse
    {
        public ResponseStatus ResponseStatus = null;
        public ArrayList<OrderLine> OrderLines = new ArrayList<OrderLine>();
        
        public ResponseStatus getResponseStatus() { return ResponseStatus; }
        public OrderLinesResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
        public ArrayList<OrderLine> getOrderLines() { return OrderLines; }
        public OrderLinesResponse setOrderLines(ArrayList<OrderLine> value) { this.OrderLines = value; return this; }
    }

}

Java OrderLinesRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/OrderLines HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<OrderLinesRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <OrderHeaderUID>00000000-0000-0000-0000-000000000000</OrderHeaderUID>
  <OrderLines>
    <OrderLine>
      <ActualDeliveryDate>0001-01-01T00:00:00</ActualDeliveryDate>
      <ActualShipDate>0001-01-01T00:00:00</ActualShipDate>
      <AddressId>0</AddressId>
      <AgentId>0</AgentId>
      <City>String</City>
      <EstimatedDeliveryDate>0001-01-01T00:00:00</EstimatedDeliveryDate>
      <EstimatedShipDate>0001-01-01T00:00:00</EstimatedShipDate>
      <FullName>String</FullName>
      <ID>0</ID>
      <OrderHeaderID>00000000-0000-0000-0000-000000000000</OrderHeaderID>
      <OrderLineCreatedDate>0001-01-01T00:00:00</OrderLineCreatedDate>
      <OrderLineModifiedDate>0001-01-01T00:00:00</OrderLineModifiedDate>
      <OrderLineNumber>0</OrderLineNumber>
      <OrderLineShippingCost>0</OrderLineShippingCost>
      <OrderLineStatusID>0</OrderLineStatusID>
      <OrderLineTax>0</OrderLineTax>
      <PerUnitProductCost>0</PerUnitProductCost>
      <PerUnitShippingCost>0</PerUnitShippingCost>
      <PhoneNumber>String</PhoneNumber>
      <ProductCategory>0</ProductCategory>
      <ProductCost>0</ProductCost>
      <ProductID>0</ProductID>
      <ProductName>String</ProductName>
      <ProductSubCategory>0</ProductSubCategory>
      <Quantity>0</Quantity>
      <ShipMethodID>0</ShipMethodID>
      <ShippingAddress>String</ShippingAddress>
      <State>String</State>
      <Street>String</Street>
      <StripeProductId>String</StripeProductId>
      <TotalOrderLineCost>0</TotalOrderLineCost>
      <UID>00000000-0000-0000-0000-000000000000</UID>
      <Zip>String</Zip>
    </OrderLine>
  </OrderLines>
</OrderLinesRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<OrderLinesResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <OrderLines>
    <OrderLine>
      <ActualDeliveryDate>0001-01-01T00:00:00</ActualDeliveryDate>
      <ActualShipDate>0001-01-01T00:00:00</ActualShipDate>
      <AddressId>0</AddressId>
      <AgentId>0</AgentId>
      <City>String</City>
      <EstimatedDeliveryDate>0001-01-01T00:00:00</EstimatedDeliveryDate>
      <EstimatedShipDate>0001-01-01T00:00:00</EstimatedShipDate>
      <FullName>String</FullName>
      <ID>0</ID>
      <OrderHeaderID>00000000-0000-0000-0000-000000000000</OrderHeaderID>
      <OrderLineCreatedDate>0001-01-01T00:00:00</OrderLineCreatedDate>
      <OrderLineModifiedDate>0001-01-01T00:00:00</OrderLineModifiedDate>
      <OrderLineNumber>0</OrderLineNumber>
      <OrderLineShippingCost>0</OrderLineShippingCost>
      <OrderLineStatusID>0</OrderLineStatusID>
      <OrderLineTax>0</OrderLineTax>
      <PerUnitProductCost>0</PerUnitProductCost>
      <PerUnitShippingCost>0</PerUnitShippingCost>
      <PhoneNumber>String</PhoneNumber>
      <ProductCategory>0</ProductCategory>
      <ProductCost>0</ProductCost>
      <ProductID>0</ProductID>
      <ProductName>String</ProductName>
      <ProductSubCategory>0</ProductSubCategory>
      <Quantity>0</Quantity>
      <ShipMethodID>0</ShipMethodID>
      <ShippingAddress>String</ShippingAddress>
      <State>String</State>
      <Street>String</Street>
      <StripeProductId>String</StripeProductId>
      <TotalOrderLineCost>0</TotalOrderLineCost>
      <UID>00000000-0000-0000-0000-000000000000</UID>
      <Zip>String</Zip>
    </OrderLine>
  </OrderLines>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
</OrderLinesResponse>