Interfaces - JSONPOST

Text only available in english

With the JSONPOST interface type, details of the selected item(s) are posted from the client (browser) to the URL specified via the hookUrl parameter.

After importing the items, the details of, for example, the article, can be retrieved using the web service "TradeItem/DetailsByGLNAndTradeItemIdA"


Article, Selection list, Product

Action POST the result to the specified hookUrl (fire-and-forget, no feedback within Unifeed), from the Client
Content 2BA JSON containing one or more articles
Example opening Unifeed
Example response For articles and selection list:
	"SupplierName":"Grundfos Nederland",
	"SupplierName":"Technische Unie",
Voor product:
	"Description":"ALPHA2 25-40 130 1x230V 50Hz 6H"


With the interfaceType=JSONPOST the POST is executed in the background from the client (browser).
Using this method, the customer remains on the current page in Unifeed. No navigation takes place.
The session, complete with all filters etc. remains intact.

A client-side post was chosed because it allows the use of internal/local IP addresses.
Another advantage is that this method (usually) does not require any firewall adjustments.

POSTing from the client, howerver, involves CORS (
The receiving application needs to accept the browser's POST.
This is achieved via a so-called preflight; First, an OPTIONS request is sent, specifying Unifeed as Origin.
The application should respond to this options request by suppliying an "Access-Control-Allow-Origin" header, containing the Unifeed website as specified in the OPTIONS request.
Only if this response makes it back to the browser will the true POST request take place.

Interface=JSON makes a direct POST, which does not involve CORS.

Testing using

To use the JSONPOST, the receiving server must have CORS enabled and your URL(s) specified at 2BA in Policies:connect-src and frame-ancestors. By using " ", the post request can be tested easily, example URL:
After the post, the directory below will contain a file containing the contents of the POST.!/88b15f6f-12a6-4df0-8a09-f0cb6c0085d2


Energieweg 3
3542 DZ Utrecht
+31 88 222 00 00

Word lid van onze community