| POST | /api/claim/search | Search for claims based on parameters |
|---|
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;
import com.google.gson.annotations.*;
import com.google.gson.reflect.*;
public class dtos
{
/**
* Claim
*/
@Api(Description="Claim")
@ApiResponse(Description="Claim search results", StatusCode=200)
public static class SearchClaim
{
@ApiMember(ParameterType="model")
public SearchClaimQuery query = null;
public SearchClaimQuery getQuery() { return query; }
public SearchClaim setQuery(SearchClaimQuery value) { this.query = value; return this; }
}
public static class SearchClaimQuery
{
public String receiverGln = null;
public Date fromDate = null;
public Date toDate = null;
public String claimsNotificationTypeCode = null;
public String claimsNotificationIdentification = null;
public _Buyer buyer = null;
public _ClaimNotification claimNotification = null;
public _Invoice invoice = null;
public Boolean excludeLinkedToCreditNote = null;
public String senderGln = null;
public ArrayList<String> partnerGln = new ArrayList<String>();
public Integer requestedPage = null;
public Integer numberOfRecordsPerPage = null;
public String getReceiverGln() { return receiverGln; }
public SearchClaimQuery setReceiverGln(String value) { this.receiverGln = value; return this; }
public Date getFromDate() { return fromDate; }
public SearchClaimQuery setFromDate(Date value) { this.fromDate = value; return this; }
public Date getToDate() { return toDate; }
public SearchClaimQuery setToDate(Date value) { this.toDate = value; return this; }
public String getClaimsNotificationTypeCode() { return claimsNotificationTypeCode; }
public SearchClaimQuery setClaimsNotificationTypeCode(String value) { this.claimsNotificationTypeCode = value; return this; }
public String getClaimsNotificationIdentification() { return claimsNotificationIdentification; }
public SearchClaimQuery setClaimsNotificationIdentification(String value) { this.claimsNotificationIdentification = value; return this; }
public _Buyer getBuyer() { return buyer; }
public SearchClaimQuery setBuyer(_Buyer value) { this.buyer = value; return this; }
public _ClaimNotification getClaimNotification() { return claimNotification; }
public SearchClaimQuery setClaimNotification(_ClaimNotification value) { this.claimNotification = value; return this; }
public _Invoice getInvoice() { return invoice; }
public SearchClaimQuery setInvoice(_Invoice value) { this.invoice = value; return this; }
public Boolean isExcludeLinkedToCreditNote() { return excludeLinkedToCreditNote; }
public SearchClaimQuery setExcludeLinkedToCreditNote(Boolean value) { this.excludeLinkedToCreditNote = value; return this; }
public String getSenderGln() { return senderGln; }
public SearchClaimQuery setSenderGln(String value) { this.senderGln = value; return this; }
public ArrayList<String> getPartnerGln() { return partnerGln; }
public SearchClaimQuery setPartnerGln(ArrayList<String> value) { this.partnerGln = value; return this; }
public Integer getRequestedPage() { return requestedPage; }
public SearchClaimQuery setRequestedPage(Integer value) { this.requestedPage = value; return this; }
public Integer getNumberOfRecordsPerPage() { return numberOfRecordsPerPage; }
public SearchClaimQuery setNumberOfRecordsPerPage(Integer value) { this.numberOfRecordsPerPage = value; return this; }
}
public static class _Buyer implements IBuyer
{
public String gln = null;
public String getGln() { return gln; }
public _Buyer setGln(String value) { this.gln = value; return this; }
}
public static class _ClaimNotification implements IClaimNotification
{
public String entityIdentification = null;
public String getEntityIdentification() { return entityIdentification; }
public _ClaimNotification setEntityIdentification(String value) { this.entityIdentification = value; return this; }
}
public static class _Invoice implements IInvoice
{
public String entityIdentification = null;
public String getEntityIdentification() { return entityIdentification; }
public _Invoice setEntityIdentification(String value) { this.entityIdentification = value; return this; }
}
public static class PagedQueryResult<T>
{
public Long startIndex = null;
public Long endIndex = null;
public Integer numberOfRecordsReturned = null;
public Integer totalNumberOfPages = null;
public Long totalNumberOfRecords = null;
public ArrayList<ResultItem<ClaimMessage>> results = new ArrayList<ResultItem<ClaimMessage>>();
public Long getStartIndex() { return startIndex; }
public PagedQueryResult<T> setStartIndex(Long value) { this.startIndex = value; return this; }
public Long getEndIndex() { return endIndex; }
public PagedQueryResult<T> setEndIndex(Long value) { this.endIndex = value; return this; }
public Integer getNumberOfRecordsReturned() { return numberOfRecordsReturned; }
public PagedQueryResult<T> setNumberOfRecordsReturned(Integer value) { this.numberOfRecordsReturned = value; return this; }
public Integer getTotalNumberOfPages() { return totalNumberOfPages; }
public PagedQueryResult<T> setTotalNumberOfPages(Integer value) { this.totalNumberOfPages = value; return this; }
public Long getTotalNumberOfRecords() { return totalNumberOfRecords; }
public PagedQueryResult<T> setTotalNumberOfRecords(Long value) { this.totalNumberOfRecords = value; return this; }
public ArrayList<ResultItem<ClaimMessage>> getResults() { return results; }
public PagedQueryResult<T> setResults(ArrayList<ResultItem<ClaimMessage>> value) { this.results = value; return this; }
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/claim/search HTTP/1.1
Host: stf-api-uat.data-xchange.co.za
Accept: application/json
Content-Type: application/json
Content-Length: length
{"query":{"receiverGln":"String","claimsNotificationTypeCode":"String","claimsNotificationIdentification":"String","buyer":{"gln":"String"},"claimNotification":{"entityIdentification":"String"},"invoice":{"entityIdentification":"String"},"excludeLinkedToCreditNote":false,"senderGln":"String","partnerGln":["String"],"requestedPage":0,"numberOfRecordsPerPage":0}}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"startIndex":0,"endIndex":0,"numberOfRecordsReturned":0,"totalNumberOfPages":0,"totalNumberOfRecords":0,"results":[{}]}