2Service Services API

<back to all web services

GetSearchParts

The following routes are available for this service:
GET/dealers/parts/searchSearches for articles by keyword(s).
GetSearchParts Parameters:
NameParameterData TypeRequiredDescription
SearchTextquerystringYesKeyword(s)
ArticleTypequeryintYesArticle type (1=part, 2=accessory, 3=tool, 4=device)
PageSizequeryintYesNumber of parts to return (max 100).
PagequeryintYesPage number.
AuthenticatedRequest Parameters:
NameParameterData TypeRequiredDescription
SessionTokenquerystringYesSession token received from successful authentication.
PartResults Parameters:
NameParameterData TypeRequiredDescription
TotalNumberOfPartsformintNoTotal number of parts available.
HasMoreRecordsformboolNoIndication if there are more parts to retrieve.
PartsformList<PartInfoResult>NoPart records.
PartInfoResult Parameters:
NameParameterData TypeRequiredDescription
IdformintNoUnique ID for the part.
PartNumberformstringNoPart number.
DescriptionformstringNoDescription of the part.
ManufacturerformstringNoPart manufacturer.
CanBeOrderedformboolNoDetermines if the part can be ordered.
StatusTextformstringNoTextual representation of the status of the part.
AvailableStockQuantityformintNoAvailable stock to order.
AverageDeliveryInDaysformint?NoAverage days needed for delivery.
UnitPriceformdecimal?NoPrice of a single unit, excluding VAT.
EanNumberformstringNoEAN number.
ImagesformList<PartInfoResultImage>NoImages
SecondaryArticleNumbersformList<string>NoSecondary article numbers
ReplacementArticleNumbersformList<string>NoReplacement article numbers
PartInfoResultImage Parameters:
NameParameterData TypeRequiredDescription
ImageNumberformintNoImage number
ImageUrlformstringNoImage URL

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.

GET /dealers/parts/search HTTP/1.1 
Host: services.acct.2service.nl 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<PartResults xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/_2Service.Webservices.ServiceModel.Dealers">
  <HasMoreRecords>false</HasMoreRecords>
  <Parts>
    <PartInfoResult>
      <AvailableStockQuantity>0</AvailableStockQuantity>
      <AverageDeliveryInDays>0</AverageDeliveryInDays>
      <CanBeOrdered>false</CanBeOrdered>
      <Description>String</Description>
      <EanNumber>String</EanNumber>
      <Id>0</Id>
      <Images>
        <PartInfoResultImage>
          <ImageNumber>0</ImageNumber>
          <ImageUrl>String</ImageUrl>
        </PartInfoResultImage>
      </Images>
      <Manufacturer>String</Manufacturer>
      <PartNumber>String</PartNumber>
      <ReplacementArticleNumbers xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:string>String</d4p1:string>
      </ReplacementArticleNumbers>
      <SecondaryArticleNumbers xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:string>String</d4p1:string>
      </SecondaryArticleNumbers>
      <StatusText>String</StatusText>
      <UnitPrice>0</UnitPrice>
    </PartInfoResult>
  </Parts>
  <TotalNumberOfParts>0</TotalNumberOfParts>
</PartResults>