Is there a way with the request service to read POSTed JSON from php://input?

1 Answer 1


Yes, you can use getRestParams() like so: $input = craft()->request->getRestParams()

A bit confusing naming there, which is why it's changing to getBodyParams() in Yii 2.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.