JavaScript and Python examples are given below. Examples for other languages and frameworks can be found in the IIIF Cookbook.
At the moment, we are not providing examples of reference implementations in other languages, and the cookbook group is not sure that it is a good idea to have reference implementations in different places. It would be interesting to discuss how to proceed; users who are currently (and in the future) reading this sentence might lose time trying to find examples in the cookbook.
Drafting https://github.com/IIIF/cookbook-recipes/issues/485 we realized that in section 6.3 of content state API is written about Content State Encoding example:
At the moment, we are not providing examples of reference implementations in other languages, and the cookbook group is not sure that it is a good idea to have reference implementations in different places. It would be interesting to discuss how to proceed; users who are currently (and in the future) reading this sentence might lose time trying to find examples in the cookbook.