| GET,OPTIONS | /v1/dispatch/track/{Token}/json |
|---|
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;
public class dtos
{
public static class DispatchTrackRequest
{
public String Token = null;
public String getToken() { return Token; }
public DispatchTrackRequest setToken(String value) { this.Token = value; return this; }
}
public static class DispatchTrackResponse
{
public String Kind = null;
public String Code = null;
public String What = null;
public String FromLoc = null;
public String ToLoc = null;
public Integer Bags = null;
public BigDecimal Fare = null;
public String PayMode = null;
public String CardLast4 = null;
public Boolean Charged = null;
public String Stage = null;
public String Headline = null;
public String Sub = null;
public Boolean IsClosed = null;
public String Eta = null;
public String DriverName = null;
public String CustomerName = null;
public ArrayList<DispatchTrackStepView> Steps = new ArrayList<DispatchTrackStepView>();
public Boolean Expired = null;
public Boolean Invalid = null;
public ResponseStatus ResponseStatus = null;
public String getKind() { return Kind; }
public DispatchTrackResponse setKind(String value) { this.Kind = value; return this; }
public String getCode() { return Code; }
public DispatchTrackResponse setCode(String value) { this.Code = value; return this; }
public String getWhat() { return What; }
public DispatchTrackResponse setWhat(String value) { this.What = value; return this; }
public String getFromLoc() { return FromLoc; }
public DispatchTrackResponse setFromLoc(String value) { this.FromLoc = value; return this; }
public String getToLoc() { return ToLoc; }
public DispatchTrackResponse setToLoc(String value) { this.ToLoc = value; return this; }
public Integer getBags() { return Bags; }
public DispatchTrackResponse setBags(Integer value) { this.Bags = value; return this; }
public BigDecimal getFare() { return Fare; }
public DispatchTrackResponse setFare(BigDecimal value) { this.Fare = value; return this; }
public String getPayMode() { return PayMode; }
public DispatchTrackResponse setPayMode(String value) { this.PayMode = value; return this; }
public String getCardLast4() { return CardLast4; }
public DispatchTrackResponse setCardLast4(String value) { this.CardLast4 = value; return this; }
public Boolean isCharged() { return Charged; }
public DispatchTrackResponse setCharged(Boolean value) { this.Charged = value; return this; }
public String getStage() { return Stage; }
public DispatchTrackResponse setStage(String value) { this.Stage = value; return this; }
public String getHeadline() { return Headline; }
public DispatchTrackResponse setHeadline(String value) { this.Headline = value; return this; }
public String getSub() { return Sub; }
public DispatchTrackResponse setSub(String value) { this.Sub = value; return this; }
public Boolean getIsClosed() { return IsClosed; }
public DispatchTrackResponse setIsClosed(Boolean value) { this.IsClosed = value; return this; }
public String getEta() { return Eta; }
public DispatchTrackResponse setEta(String value) { this.Eta = value; return this; }
public String getDriverName() { return DriverName; }
public DispatchTrackResponse setDriverName(String value) { this.DriverName = value; return this; }
public String getCustomerName() { return CustomerName; }
public DispatchTrackResponse setCustomerName(String value) { this.CustomerName = value; return this; }
public ArrayList<DispatchTrackStepView> getSteps() { return Steps; }
public DispatchTrackResponse setSteps(ArrayList<DispatchTrackStepView> value) { this.Steps = value; return this; }
public Boolean isExpired() { return Expired; }
public DispatchTrackResponse setExpired(Boolean value) { this.Expired = value; return this; }
public Boolean isInvalid() { return Invalid; }
public DispatchTrackResponse setInvalid(Boolean value) { this.Invalid = value; return this; }
public ResponseStatus getResponseStatus() { return ResponseStatus; }
public DispatchTrackResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
}
public static class DispatchTrackStepView
{
public String Name = null;
public Date At = null;
public Boolean Done = null;
public Boolean Current = null;
public String getName() { return Name; }
public DispatchTrackStepView setName(String value) { this.Name = value; return this; }
public Date getAt() { return At; }
public DispatchTrackStepView setAt(Date value) { this.At = value; return this; }
public Boolean isDone() { return Done; }
public DispatchTrackStepView setDone(Boolean value) { this.Done = value; return this; }
public Boolean isCurrent() { return Current; }
public DispatchTrackStepView setCurrent(Boolean value) { this.Current = value; return this; }
}
}
Java DispatchTrackRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/dispatch/track/{Token}/json HTTP/1.1
Host: api.dev.dynamics.trendsic.com
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length
<DispatchTrackResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
<Bags>0</Bags>
<CardLast4>String</CardLast4>
<Charged>false</Charged>
<Code>String</Code>
<CustomerName>String</CustomerName>
<DriverName>String</DriverName>
<Eta>String</Eta>
<Expired>false</Expired>
<Fare>0</Fare>
<FromLoc>String</FromLoc>
<Headline>String</Headline>
<Invalid>false</Invalid>
<IsClosed>false</IsClosed>
<Kind>String</Kind>
<PayMode>String</PayMode>
<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>
<Stage>String</Stage>
<Steps>
<DispatchTrackStepView>
<At>0001-01-01T00:00:00</At>
<Current>false</Current>
<Done>false</Done>
<Name>String</Name>
</DispatchTrackStepView>
</Steps>
<Sub>String</Sub>
<ToLoc>String</ToLoc>
<What>String</What>
</DispatchTrackResponse>