Skip to content

Instantly share code, notes, and snippets.

@zwily
Created July 10, 2013 20:05
Show Gist options
  • Save zwily/5969811 to your computer and use it in GitHub Desktop.
Save zwily/5969811 to your computer and use it in GitHub Desktop.
class AwsController < ApplicationController
def call
service = AWS.const_get(params[:service]).new(params[:service_params] || {})
result = service.client.send(params[:method].to_sym, params[:options] || {})
respond_to do |format|
format.json { render :json => result.data }
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment