Log in    Register
ChipFind

Connection Type: "Online Warehouse"

Every supplier company that has a warehouse database on their server can deploy a search script accessible on the internet. The database format, programming language, and operating system are entirely up to you, so you can host this script even on a regular corporate server that is constantly connected to the internet. For ease of administration and server security enhancement, you can specify any non-standard port during warehouse registration.

How does it work?
When a user requests a component on the ChipFind website, our search robot sends parallel requests to all system participants. Upon receiving responses from them, it displays the search results. Data retrieval from warehouses occurs via the HTTP 1.1 protocol, where the ChipFind server sends a GET or POST request to your web server with the search query.

In response, the script on your website should perform the following actions:

  1. As a precaution, verify the correctness of the transmitted data: the length of the string should be at least 4 characters, remove database-dangerous characters (*,’,«|,&,\,/,?,%), remove leading and trailing spaces and tab characters. ChipFind also performs all these actions, sending a clean and validated string, but for script security, it's advisable to perform them on your website as well.
  2. Make a query to your local database with the passed parameters.
  3. Output the data formatted in XML format to the stream (usually using print or echo functions), as described below.
That's all. Please note that ChipFind accepts only the first 20 lines of the data you output, so it's recommended not to output unnecessary data to save your server resources.

XML Package Format
The XML file generated by your online store should generally look something like this:

<?xml version="1.0" encoding="Windows-1251"?>
<data>  обязательный элемент
    <line>
        <mfr>XILINX</mfr>
        <part>XC1736ESO8I</part>  обязательный элемент
        <note>Микросхема XILINX 8SO</note>
        <pack>1</pack>
        <min>3</min>
        <img>http://картинка.gif</img>
        <pdf>http://документация.pdf</pdf>
        <dc>2001</dc>
        <cur>euro</cur>
        <p1>12.25</p1>
        <p2>12.05</p2>
        <p3>11.65</p3>
        <stock>2-3 недели</stock>
        <instock>0</instock>
    </line>
    <line>
        <part>XC1701LPD8I0718</part>  обязательный элемент
    </line>
    <line>
        <part>XC170222</part>  обязательный элемент
        <mfr>XILINX</mfr>
        <note/>
    </line>
    ...
</data>
The tag is the root element and may appear in the XML document no more than once. In case the requested component is not available in the warehouse, a block (or ) or an empty document should be output.

The tag encloses information about each found component and may appear in the document no more than 20 times. Inside the tag, elements can be arranged in any sequence. The presence of spaces and line breaks does not matter. To reduce the size of transmitted information, it is desirable not to insert empty tags into the document.

Information about the component is contained in the following tags:
  • <part> - mandatory tag, contains the component name. The rest of the tags are optional.
  • <mfr> - the name of the manufacturing company.
  • <note> - component description, additional information (e.g., minimum order quantity).
  • <pack> - quantity of components in the package (positive number).
  • <min> - minimum order (positive number).
  • <img> - link to the image or to the page with a detailed description of the component. You can also provide a direct link to order the component in your online store.
  • <pdf> - link to the technical documentation.
  • <cur> - currency, possible values:
    «$» - USD
    «euro» - Euro (€)
    «gbp» - GBP (£)
    «RUB» - Rubles

    By default (if not specified otherwise), the value is substituted with «$».
  • <p1> - The retail price. A positive number containing no more than 4 digits in the fractional part, with a dot as the separator for the fractional part.
  • <p2> - The small wholesale price (see requirements for <p1>).
  • <p3> - Wholesale price (see requirements for <p1>).
  • <stock> - The stock availability, which can take the following values:
    - A positive integer: the quantity of components in stock (pieces).
    - 0, if the component is not available in stock.
    - Any text regarding the quantity or arrival time of the component to the company's stock ("1-2 weeks", ">100").
  • <dc> - The year of the component's production. It can be a date, year, or any text.
  • <instock> - Stock availability flag. Possible values: 0 and 1. It can be used in case the tag contains text, and thus, the ChipFind search robot cannot determine whether the component is in stock during document processing. It still makes sense to specify the value of this tag even if text is present in the <stock>> tag and the requested component is available in stock. This ensures clarity and consistency in the data structure, allowing for easier parsing and processing of information by search robots and other systems.
In addition, it is necessary to adhere to all rules of forming XML documents. For example, do not forget to encode the symbols < and > as &lt; and &gt;.
Download the brochure with a detailed description of the service


© 2006 — 2024 ChipFind Ltd.
Contact phone, e-mail, ICQ
RegisterAdvertising