New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ability to post arrays of anonymous JSON objects #121
Comments
@jakubroztocil good job! you solve my problem |
@jakubroztocil, I am using the http 0.9.2 and it seens that it doesn't work that anymore. I've created a test.php with the code:
Then i tried the requests below: echo '[{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}]' | http http://localhost/CRMvTiger_Rodobens/test.php echo '[{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}]' | http --form http://localhost/CRMvTiger_Rodobens/test.php echo '[{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}]' | http --json http://localhost/CRMvTiger_Rodobens/test.php echo '{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}' | http http://localhost/CRMvTiger_Rodobens/test.php echo '{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}' | http --json http://localhost/CRMvTiger_Rodobens/test.php echo '{"feed_id": 24571, "value": 64.0}, {"feed_id":24572, "value":60.0}' | http --form http://localhost/CRMvTiger_Rodobens/test.php The only which return something is the last one, but not was i was expecting, it returned all json as a key with an empty value. |
Was trying to use httpie to post multiple events using the http://open.sen.se/ API. This accepts an array of unnamed objects in the form of:
Found that I could not seem to make httpie create JSON like this. Attempting to use the
:=
separator for raw JSON without a key name created this output:The text was updated successfully, but these errors were encountered: