-
Notifications
You must be signed in to change notification settings - Fork 5
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
HTTP Request - GET/POST displayed in a view #37
Comments
I'm using https://github.com/typicode/json-server to create a local api which I can send get/post requests to. I've set the db in a {
"ios" : {
"project_name":"iOS",
"total_time":0,
"color":"blue"
},
"elm": {
"project_name": "elm",
"total_time":0,
"color":"blue"
}
}
|
I'm using json-server to create a simple db.json file that contains the following information:
Currently using localhost:3000 for getting and posting information |
OK, so I've posted a question related to convering dictionaries to json here - https://stackoverflow.com/questions/44368070/dictionary-to-json-being-serialised-twice-in-swift-3 I can't seem to get it to post correctly, the format it appears in is incorrect as you can see in the code below
|
@iteles could see that I was getting a bit deflated today because of this issue but someone has answered the question in Stack Overflow! 🎉 Can continue the work rather than putting it to the side! |
We are now able make the POST request! turns out we needed to specify that the context was in json using the following line: |
Now that we have been able to make a get request on a playground #34, we will move on to make this information show up on a view alongside making it possible to make a post request.
We will be using httpbin for making the HTTP requests.
I'll write up a process as I go along creating this demo app.
The text was updated successfully, but these errors were encountered: