moip/moip-sdk-ruby

View on GitHub
lib/moip2/entry_api.rb

Summary

Maintainability
A
0 mins
Test Coverage
module Moip2
  class EntryApi
    attr_reader :client

    def initialize(client)
      @client = client
    end

    def base_path
      "/v2/entries"
    end

    def show(id)
      Resource::Entry.new client, client.get("#{base_path}/#{id}")
    end
    
    def find_all
      Resource::Entry.new client, client.get("#{base_path}")
    end
  end
end