GET api-v1/results/sample?property={property}&value={value}&pageNumber={pageNumber}&pageSize={pageSize}
A basic search function to retrieve samples. Supports pagination so that large datasets can be traversed. Samples returned in the order that they have been uploaded to labPortal. Therefore the first sample will be the most recently updated Sample.
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
property |
The sample property name that you want to search by |
string |
Required |
value |
The sample property value that you want to search on |
string |
Required |
pageNumber |
A numerical value indicating the page number; default is 1 |
integer |
Default value is 1 |
pageSize |
A numerical value indicating the number of samples to return within a page; default is 10 |
integer |
Default value is 10 |
Body Parameters
None.
Response Information
Resource Description
A containing the result of the specified search
SampleResponseMessageName | Description | Type | Additional information |
---|---|---|---|
Text | string |
None. |
|
Samples | Collection of SampleMessage |
None. |
|
Grid | DataTable |
None. |
|
TotalPages | decimal number |
None. |
|
SampleCount | decimal number |
None. |
|
NextPage | URI |
None. |
|
PreviousPage | URI |
None. |
|
Breaches | Dictionary of CellColour [key] and Collection of string [value] |
None. |
|
string |
None. |
||
EmailSubject | string |
None. |
|
SiteTitle | string |
None. |
|
SiteKey | string |
None. |
Response Formats
application/json,text/json
{ "Text": "sample string 1", "Samples": [ { "Attachment": true, "Comments": [ { "Author": "sample string 1", "Text": "sample string 2" }, { "Author": "sample string 1", "Text": "sample string 2" } ], "Id": 2, "LimsId": "sample string 3", "Properties": { "sample string 1": {}, "sample string 3": {} }, "Results": [ { "Text": "sample string 1", "Val": {}, "Det": "sample string 3", "Suite": "sample string 4", "Unit": "sample string 5", "ShortName": "sample string 6", "LongName": "sample string 7" }, { "Text": "sample string 1", "Val": {}, "Det": "sample string 3", "Suite": "sample string 4", "Unit": "sample string 5", "ShortName": "sample string 6", "LongName": "sample string 7" } ], "Status": "sample string 4" }, { "Attachment": true, "Comments": [ { "Author": "sample string 1", "Text": "sample string 2" }, { "Author": "sample string 1", "Text": "sample string 2" } ], "Id": 2, "LimsId": "sample string 3", "Properties": { "sample string 1": {}, "sample string 3": {} }, "Results": [ { "Text": "sample string 1", "Val": {}, "Det": "sample string 3", "Suite": "sample string 4", "Unit": "sample string 5", "ShortName": "sample string 6", "LongName": "sample string 7" }, { "Text": "sample string 1", "Val": {}, "Det": "sample string 3", "Suite": "sample string 4", "Unit": "sample string 5", "ShortName": "sample string 6", "LongName": "sample string 7" } ], "Status": "sample string 4" } ], "Grid": null, "TotalPages": 2.0, "SampleCount": 3.0, "NextPage": "http://webapihelppage4.com", "PreviousPage": "http://webapihelppage5.com", "Breaches": { "None": [ "sample string 1", "sample string 2" ] }, "Email": "sample string 6", "EmailSubject": "sample string 7", "SiteTitle": "sample string 8", "SiteKey": "sample string 9" }
application/xml,text/xml
<SampleResponseMessage xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/labPortal.Api.Export"> <Breaches xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:KeyValueOfCellColourArrayOfstring8TOjTIaw> <d2p1:Key>None</d2p1:Key> <d2p1:Value> <d2p1:string>sample string 1</d2p1:string> <d2p1:string>sample string 2</d2p1:string> </d2p1:Value> </d2p1:KeyValueOfCellColourArrayOfstring8TOjTIaw> </Breaches> <Email>sample string 6</Email> <EmailSubject>sample string 7</EmailSubject> <Grid i:nil="true" /> <NextPage>http://webapihelppage4.com/</NextPage> <PreviousPage>http://webapihelppage5.com/</PreviousPage> <SampleCount>3</SampleCount> <Samples> <SampleMessage> <Attachment>true</Attachment> <Comments> <CommentMessage> <Author>sample string 1</Author> <Text>sample string 2</Text> </CommentMessage> <CommentMessage> <Author>sample string 1</Author> <Text>sample string 2</Text> </CommentMessage> </Comments> <Id>2</Id> <LimsId>sample string 3</LimsId> <Properties xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:KeyValueOfstringanyType> <d4p1:Key>sample string 1</d4p1:Key> <d4p1:Value /> </d4p1:KeyValueOfstringanyType> <d4p1:KeyValueOfstringanyType> <d4p1:Key>sample string 3</d4p1:Key> <d4p1:Value /> </d4p1:KeyValueOfstringanyType> </Properties> <Results> <ResultMessage> <Det>sample string 3</Det> <LongName>sample string 7</LongName> <ShortName>sample string 6</ShortName> <Suite>sample string 4</Suite> <Text>sample string 1</Text> <Unit>sample string 5</Unit> <Val /> </ResultMessage> <ResultMessage> <Det>sample string 3</Det> <LongName>sample string 7</LongName> <ShortName>sample string 6</ShortName> <Suite>sample string 4</Suite> <Text>sample string 1</Text> <Unit>sample string 5</Unit> <Val /> </ResultMessage> </Results> <Status>sample string 4</Status> </SampleMessage> <SampleMessage> <Attachment>true</Attachment> <Comments> <CommentMessage> <Author>sample string 1</Author> <Text>sample string 2</Text> </CommentMessage> <CommentMessage> <Author>sample string 1</Author> <Text>sample string 2</Text> </CommentMessage> </Comments> <Id>2</Id> <LimsId>sample string 3</LimsId> <Properties xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d4p1:KeyValueOfstringanyType> <d4p1:Key>sample string 1</d4p1:Key> <d4p1:Value /> </d4p1:KeyValueOfstringanyType> <d4p1:KeyValueOfstringanyType> <d4p1:Key>sample string 3</d4p1:Key> <d4p1:Value /> </d4p1:KeyValueOfstringanyType> </Properties> <Results> <ResultMessage> <Det>sample string 3</Det> <LongName>sample string 7</LongName> <ShortName>sample string 6</ShortName> <Suite>sample string 4</Suite> <Text>sample string 1</Text> <Unit>sample string 5</Unit> <Val /> </ResultMessage> <ResultMessage> <Det>sample string 3</Det> <LongName>sample string 7</LongName> <ShortName>sample string 6</ShortName> <Suite>sample string 4</Suite> <Text>sample string 1</Text> <Unit>sample string 5</Unit> <Val /> </ResultMessage> </Results> <Status>sample string 4</Status> </SampleMessage> </Samples> <SiteKey>sample string 9</SiteKey> <SiteTitle>sample string 8</SiteTitle> <Text>sample string 1</Text> <TotalPages>2</TotalPages> </SampleResponseMessage>