How can i post a json data to rails app?
try this one,
curl -H 'Content-Type: application/json' -X POST http://localhost:3000/users.json -d "{\"user\":{\"email\":\"sample@example.com\", \"password\":\"qwerty\",\"password_confirmation\":\"qwerty\"}}"
Problem was with the parameters parsing, need to be within quotes.