My Products
Help

Are your integrations ready for Black Friday? Read this to be prepared!

by Thomas Skjørten (Updated ‎30-10-2021 12:00 by Thomas Skjørten VISMA )

We are quickly moving towards the season which sets all retailers and e-commerce actors to the test of the year.

The Friday after thanksgiving is the day when all retailers turn their accounts from red to black, hence the name Black Friday (according to the internet).

So that means a lot of inventory have to move out of the shelves and a lot of money out of the customers pockets.

Since the early Black Fridays, we have expanded the term to Black Weeks and added Cyber Mondays, which have become Cyber Weeks. You get the point, November and December are the months where the retail-systems are pushed to the limit, and your retail-integrations have to be in tip-top shape.

 

So what could be a better time to start using the new Visma.net ERP Sales Order API?

 

This brand new API is built specifically to improve the performance and usability of our APIs related to the process of creating salesorders. It is still a work-in-progress, meaning that new functionality will continue to be added to the API, but the functionality that is already there can make a huge difference for your applications.

 

Lets focus on a couple of endpoints that are vital to the e-commerce experience.

 

InventorySummary

For a long time we've had the GET InventorySummary endpoint in the Visma.net API. The functionality of this endpoint is to get information about how the availability of a product is. How many are available for sale? How many are booked on salesorders? etc. 

This endpoint is one of the absolute most used in the Visma.net API, and we traditionally see a peak during November and December.

 

But there are a few issues with the InventorySummary endpoint:

  • It only allows for asking about one item per call (and also one warehouse, if you use multiple warehouses).
    This means that you have to make a lot of API-calls.
  • It returns quite a bit of data, most often way more than you need.
    This means that the execution of the endpoint is quite slow, because a lot of data have to be collected from different corners of our database.

We've seen the pains this results in for your integrations, and the buckets of sweat that our servers have produced trying to process all these requests. So please welcome the new endpoint in the Sales Order API... /Inventory.

 

The new /Inventory endpoint, have been developed to handle these needs with ease and brilliance.

 

Now you can:

  • Get the Inventory-availability of as many items as you like per call.
  • Get information about the availability across warehouses and location at once.
  • Filter on warehouses and locations.
  • Choose how much data is returned (include locations and/or attributes).
  • Filter on availabilityModifiedSince.
  • Filter on attributes.
  • Get the results at blistering speeds.

Blistering speeds you say, how fast is that exactly?

 

Well, we've done quite a bit of testing. In the old /InventorySummary endpoint we see that the average request takes around 1 second (1000ms). And then you get only 1 item from 1 warehouse.

 

On the new /Inventory endpoint we see the average time is 60 ms, and it doesn't care much if you ask for 1 or multiple items (60 ms is the average for getting 5 items). And then you get all the warehouses where the item is stored. You can expand the location-info and attributes as well, just a few more milliseconds of processingtime.

 

So in a real world example:

 

If you have a webshop and the customer have added five items to the shopping cart. Before checking out you would like to check the availability of the items.

So with the old endpoint you would make 5 calls, each of around 1 second

(If you have multiple warehouses, you can multiply this by the number of warehouses).

In the new endpoint you make 1 call, for all five items, across all warehouses. That will take around 60 ms.

That is 5000ms (5*1000) vs 60ms. I'd say that is blistering speed. 

 

Salesorder

But of course, checking the availability does not make the accounts go from red to black. Hopefully the customers will create a lot of salesorders as well.

 

In the new API we also have a POST /SalesOrder endpoint, that does exactly that. In the current version it supports all the functionality needed to create most salesorders (as long as it is of type SO). You can add discounts, currencies and notes along with the other information needed.

 

And as you would expect, this goes quite fast as well. We've found that creating an order is about 25 times faster with the new endpoint. And the more lines in the order, the more performancegain you will see.

 

And on a final note, since the new endpoints are so much more effective this doesn't stress our servers nearly as much. That means that we can handle tons of request without breaking a sweat. Good for us, good for you and good for the customer.

 

 

The new endpoints can be used side-by-side with the existing endpoints, so you don't have to rebuild everything. You can start by using only one of the new endpoints and then rebuilt your integration over time.

 

If you are not familiar with this new API, i suggest you start by reading this article Getting started with the first neXtGen service: Visma.net ERP Sales Order API .

 

You can also check out the documentation here: https://salesorder.visma.net/swagger/index.html.

 

Happy coding! Looking forward to setting new Black Friday sales records with you!