Open DavidBiesack opened 10 years ago
looks like it's hard-coded on line 669 of app.js if (['POST','PUT'].indexOf(httpMethod) !== -1) { var requestBody; requestBody = (options.headers['Content-Type'] === 'application/json') ? JSON.stringify(bodyParams) : query.stringify(bodyParams); } I think the structure of this part of the code needs some love.
Thanks, @phairow. You saved me some digging. "Example #2" in the readme doesn't have that header, so it doesn't work either.
If a method is defined as
where the request body is defined in the "schemas" section
if Content-Type is application/vnd.sas.mus+json , I/O Docs will not send the request body as JSON. Rather, it encodes it as
MicroUrls=&MicroUrls=
(I added two objects and set their required member properties)
(unfortunately, I cannot add application/json here)