Sha256: 18c25289b761043efb7c79325dc77b0d7dfefd326678d2a243b0b8b5aba63f0d

Contents?: true

Size: 255 Bytes

Versions: 7

Compression:

Stored size: 255 Bytes

Contents

class UserController < ApplicationController
  # It will works with respond_with.
  # Your action should looks like any other one: A model with a method call. =D
  def index
    @users = User.get("api.example.com/users")
    respond_with(@users)
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
api-client-1.7.0 examples/controllers/user_controller.rb
api-client-1.6.1 examples/controllers/user_controller.rb
api-client-1.6.0 examples/controllers/user_controller.rb
api-client-1.5.4 examples/controllers/user_controller.rb
api-client-1.5.3 examples/controllers/user_controller.rb
api-client-1.5.2 examples/controllers/user_controller.rb
api-client-1.5.1 examples/controllers/user_controller.rb