Forum Discussion
TP-101
Helper I
2 years agoM Query Post REST API, return format not JSON with Expression.Error
I'm attempting a POST to a REST API which should return data in JSON. The POST appears to succeed however, receiving an Expression.Error trying to convert the response to binary. Can this query be ...
TP-101
Helper I
2 years agoIs this what you are looking for? The variables form a complete https URL to the endpoint. Screenshot 1. Then, we're posting some JSON data to the endpoint. Screenshot 2.
Then it should return JSON data. By the look of the Expression.Error, it appears to be data I'm POST'ing that it's trying to first convert to binary. I'm wondering if the "Content=Text.FromBinary" is the culpret. I dont believe there is a "Text.FromJSON" equivalent.
lbendlin
Super User
2 years agono, I am looking for a sample response text with the \u000a etc.
- TP-1012 years ago
Helper I
I think the problem is not with the response. The \u000a seems to be coming from the data section which is formatted JSON we are trying to POST to the REST API. The API should return something totally different.