Skip to content

Real time Price & Availability Request

Introduction

The real time stock check is very useful before accepting an order from your client. Why? Because it allows you to see if there is stock available at the Nedis warehouses hence preventing backorders and allowing to maintain customer satisfaction. In order to use the service please contact your local Nedis office for more information.

Example process of Realtime stock check implemented in an online environment

Screenshot

Nedis API

The Nedis API is the gateway to usage of the Nedis Connect services. To make use of the Nedis Connect services an access token has to be obtained from the API. When successfully authenticated as a user the access token will be granted by Nedis. The token can be used for the duration of 60 minutes to make requests. After 60 minutes the token expires and a new token needs to be obtained before any new requests can be made using the API. It’s also possible to acquire an access token per separate request, do note however that this will take slightly longer to process.

IP Address Authentication

When applying for the API services one or more IP addresses have to be provided to Nedis from where requests will be made. We accept only requests from prelisted IP addresses. In case of IP address changes, please communicate this timely to prevent loss of service.

Authentication Request

A connection needs to be established between your system and the Nedis API. Depending on the desired response this can be done using one of the following URL’s:

XML api.nedis-connect.com/oauth2/token.xml

JSON api.nedis-connect.com/oauth2/token.json

The following variables need to be posted here (make sure to use a POST request)

grant_type This parameter has a fixed value; authorization_code client_id This is your specific client id. This is not the Nedis customer number but a separate ID which will be provided by Nedis with the confirmation of the usage for this service. code This is the API Key specific to your account and will be provided by Nedis with the confirmation of the usage for this service.

Authentication Response

In case the authentication as described above was successful an Access Token is granted in the response message.

Authentication Successful

For all successful responses an HTTP Response code 200 will be communicated by the server together with the following parameters and values.

<access_token>
This is the generated key that can be used to make requests

<expires_in>
Time in seconds the token will be valid

<token_type>
This tag will be filled by default with the value bearer

<scope>
Tag will be displayed but will be left empty (currently not in use)

<refresh_token>
Tag will be displayed with a value (currently not being used)

Example XML Response: Screenshot

Example JSON Response: Screenshot

Note

On all errors an HTTP Response code 400 will be communicated by the server together with the following parameters and values.

<error>
Possible error messages are:
- invalid_request
- invalid_client
- invalid_grant

<error_description>
- Invalid grant_type parameter or parameter missing
- The client credentials are invalid
- Code doesn't exist or is invalid for the client

Example XML Response: Screenshot

Example JSON Response: Screenshot

Nedis Connect: Price & Availabillity Check

The following items apply to the entire P&A check service.

Limitations

With the activation of your API account a daily request limit for the P&A check is set and communicated to you. In case this limit is reached no more request can be made for that day. We always strive to come to a mutual beneficial and fair number of requests in order to do business.

Error Responses

Below are the possible error responses that could be encountered while using the service.

Status Code Counts as Request Description
200 Yes Success
400 No Missing or incorrect parameter: (parameter name)
401 No Authentication error / Unauthorized
403 No IP Address not allowed
600 Yes Request limit reached
601 Yes Item not found
620 No System error

Note

these are not HTTP server status codes but status codes communicated in the response messaging (XML/JSON)

Obtaining Price Information

Using the realtime price check allows you to obtain actual pricing information for your specific account. This includes customer specific price agreements / discounts.

Price Request

Depending on the desired response this can be acquired by using one of the following urls

XML

api.nedis-connect.com/articles/price.json

JSON

api.nedis-connect.com/articles/price.xml

The following variables need to be posted here (make sure to use a POST request)

request_type (string) possible values here are:

  • articleid NedisArtlid as being communicated in the Article Datafeeds

  • nedispartnumber NedisPartnr / Productcode as being communicated in the Article Datafeeds

  • eancode EAN13 code of the item

  • vendorpartnumber the partnumber of the vendor / manufacturer, in case of Nedis brands this is the same as the nedispartnumber

request_value (string) value of the request_type as chosen at option 1

quantity (int) This concerns the quantity of articles you are requesting the price for ( > 0 )

access_token (string) This concerns the access token as received back from Nedis after successfully completing the authentication process.

Example of the parameters with their values: Screenshot

Price Response

For all successful responses an HTTP Response code 200 will be communicated by the server together with the following parameters and values.

<response>

  • Start of main message

<status>

  • Start of status messaging

<code>

  • Status code of the response

<description>

  • Status

<requestcount>

  • Quantity of requests done so far

<requestlimit>

  • Quantity of maximum requests that can be made with this API key

<data>

  • Start of data messaging

<locale>

  • Language / Country of the messaging (Eg. En-US)

<nedispartnr> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • The NEDIS productcode

<articleid>

  • The NEDIS Article Id as communicated in the Article Datafeeds

<vendorpartnumber> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • The Vendor / Manufacturer’s product code

<eancode>

  • EAN13 code

<brandname> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Brandname of the requested article

<shortdescription> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Short description to identify the requested product

<productstatus>

  • Start of productstatus messaging

<statuscode>

  • This concerns the status of the product options here are: NORMAL / GOTO / OOP

<replacement> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Product identifier of the replacement article (this will be in the same format as the request has been done for) in case the statuscode is GOTO

<pricing>

  • Start of pricing messaging

<currency>

  • Currency the monetary values are communicated in

<price>

  • Start of price line

<amount>

  • Monetary value

<quantity>

  • Quantity the price is valid for

<tax>

  • Start of tax messaging

<description> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Description of the TAX charged

<advisedsalesprice>

  • Start of advised sales price messaging

<specialoffers>

In case a special offer is active this is the start of the special offer messaging Every price level will receive it’s own entry consisting out of

  • <entry> Start of a new special offer price entry

  • <amount> Monetary value

  • <quantity> Quantity the price is valid for

  • <validTo> Special offer pricing valid until; in format YYYY-MM-DD

Screenshot

Obtaining Availability (Stock) Information

Using the realtime availability check allows you to obtain actual stock information from Nedis.

Stock Request

Depending on the desired response this can be acquired by using one of the following urls

XML

api.nedis-connect.com/articles/stock.json

JSON

api.nedis-connect.com/articles/stock.xml

The following variables need to be posted here (make sure to use a POST request)

request_type (string) possible values here are:

  • articleid NedisArtlid as being communicated in the Article Datafeeds

  • nedispartnumber NedisPartnr / Productcode as being communicated in the Article Datafeeds

  • eancode EAN13 code of the item

  • vendorpartnumber the partnumber of the vendor / manufacturer, in case of Nedis brands this is the same as the nedispartnumber

request_value (string) value of the request_type as chosen at option 1

access_token (string) This concerns the access token as received back from Nedis after successfully completing the authentication process.

Example of the parameters with their values: Screenshot

Stock Response

For all successful responses an HTTP Response code 200 will be communicated by the server together with the following parameters and values.

<response>

  • Start of main message

<status>

  • Start of status messaging

<code>

  • Status code of the response

<description>

  • Status

<requestcount>

  • Quantity of requests done so far

<requestlimit>

  • Quantity of maximum requests that can be made with this API key

<data>

  • Start of data messaging

<locale>

  • Language / Country of the messaging (Eg. En-US)

<nedispartnr> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • The Nedis productcode

<articleid>

  • The Nedis Article Id as communicated in the Article Datafeeds

<vendorpartnumber> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • The Vendor / Manufacturer’s product code

<eancode>

  • EAN13 code

<brandname> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Brandname of the requested article

<shortdescription> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Short description to identify the requested product

<productstatus>

  • Start of productstatus messaging

<statuscode>

  • This concerns the status of the product options here are: NORMAL / GOTO / OOP

<replacement> Attention for XML Responses; Since this is a !CDATA field it can contain HTML or non-standard characters.

  • Product identifier of the replacement article (this will be in the same format as the request has been done for) in case the statuscode is GOTO

<stock>

  • Start of stock messaging

<centralstock>

  • Start of central stock messaging; stock available in the central warehouse in the Netherlands (only appears when your Nedis office also has a local warehouse)

<freestock>

  • stock value of freestock available

Screenshot