3D Surface Chart with range of values categorized by color

How to set up a 3D Surface Chart with plotly.js so that the ranges of values are categorized by color?
As this image.
image

Is it possible?

There’s probably a way to hack this in using surfacecolor

but perhaps it would be best to wait for https://github.com/plotly/plotly.js/issues/1747 to get implemented.