-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
improve http api #2803
Comments
As far as I know there was a conscious decision to use ndjson for all streaming type output. The ping is streaming the answers it gets and so if you do the request it streams in parts of ndjson, so it is consistent with other things as far as I understand. |
Same thing with Also I think that stand alone array isn't valid JSON object, as for the specs. |
@Kubuxu it is: http://www.ietf.org/rfc/rfc4627.txt ( http://stackoverflow.com/a/18202619 ) @dignifiedquire ok with the ndjson - but I still think the API is very inconsitent - and /refs/local is really wrong |
Yup, refs local is really wrong. |
yeah... refs local appears to in all cases directly write b58 marshalled keys to the output. thats... wrong |
I will fix it. |
The refs local was PRed in #2812, if you have any more notes about API state, please post them here. |
the http api is weird - already had a short conversation about this in the chat - but I think it is better to put this in an issue.
ping currently returns:
would be great if it returns just one json-object
swarm/peers currently returns
better replace Strings withPeers or just the array without the container
this could use some json wrapping
could be just a string array
the Keys is a bit weird - I think Pins would be better
The text was updated successfully, but these errors were encountered: