Skip to content
This repository has been archived by the owner on Apr 3, 2020. It is now read-only.

Failed curl request in README #45

Open
Jcornmanhomonoff opened this issue Apr 18, 2017 · 0 comments
Open

Failed curl request in README #45

Jcornmanhomonoff opened this issue Apr 18, 2017 · 0 comments

Comments

@Jcornmanhomonoff
Copy link
Contributor

The curl requested listed in the README fails as a result of missing a parameter (user_id). Using this as a teaching moment to show how to reference the files in the back end to find the proper parameters to pass through for a successful POST.

Correct script:

curl http://localhost:4741/posts \
--include \
--request POST \
--header "Content-Type: application/json" \
--data '{
    "post": {
      "title": "a sample title",
      "body": "a sample body",
      "user_id": 1
    }
  }'
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant