-
Notifications
You must be signed in to change notification settings - Fork 3
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
application/xml ContentType example #5
Comments
For any data format, a data type needs to be defined representing that format. Furthermore If you look in the module |
We will soon bring in XML data type into the |
Thank you for taking the time to provide the example, much appreciated.
I'm afraid I don't see how to implement these. |
I have updated the gist with missing definitions. Please note that there is no standard way of encoding to XML from data types. The user is free to use any style (by giving the instances of Encode and Decode for their types). WebApi library does not make any opinionated stand on this. In the gist, I have used a style where field names form the tags and values come inside them. You can see the encodings and decodings in a repl session. Download the gist and in that directory run
The reason why PS: Not sure if you are aware of this, but you can see the whole code in action by
|
How'd you use this package to build a client for an API that responds in XML?
The text was updated successfully, but these errors were encountered: