'Post Request Returning {"error": "Expecting a string", "result":87}

I am trying to interface with the Chroma SDK released by Razer and have been running into some issues. Following the documentation that razer provides, I have been trying to change the color of my RGB mouse for a while now, and hope that someone has the answer for me. I can successfully check to see if the ChromaSDK is working through:

url = 'http://localhost:54235/razer/chromasdk'
x = requests.get(url)
print(x.text)

Then, I can initialize the connection by sending a post to the URL, following the template given on their website:

data = {
"title": "Razer Chroma SDK RESTful Test Application",
"description": "This is a REST interface test application",
"author": {
    "name": "Chroma Developer",
    "contact": "www.razerzone.com"
},
"device_supported": [
    "keyboard",
    "mouse",
    "headset",
    "mousepad",
    "keypad",
    "chromalink"],
"category": "application"
}

x = requests.post(url, json=data)
print(x.text)

This post request returns:

{"sessionid":55105,"uri":"http://localhost:55105/chromasdk"}

Then, since the connection is initialized, I SHOULD be able to change the colors of the connected Razer devices using endpoints such as /mouse or /headset. This is where it gets funky, if I were to use the url(s): http://localhost:54235/chromasdk/mouse, http://localhost:54235/razer/mouse, or http://localhost:54235/mouse then I get the error "Not Implemented", whereas if I use the URI provided by the previous post request and tag /mouse onto the end of it, it get this error:

{"error":"Expecting a string","result":87}

Or if I use http://localhost:54235/razer/chromasdk/mouse, I get:

{"author":null,"category":null,"description":null,"device_supported":null,"error":"The parameter is incorrect.","result":87,"title":null}

The endpoints SHOULD follow the URL http://localhost:54235/razer/chromasdk, and I am following the documentation to a T, so what am I doing wrong??



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source