I need to use an API that wants to have one parameter containing a json string:
def function data = params['data']
config.rb:
match "/thing" => "controller#function", :via => :post
I searched and read the documentation, I can not find a way to do this. I was looking for a form_for or form_tag function and this seems impossible. I tried both approaches using remote => true, but it does not do what I want.
I also tried to do this using jquery $ .ajax, but it sends the parameters in json format, not the json string.
Are there any ways to do this?
thanks
Roger source share