class Warcraft::ApiRequest

Public Class Methods

new(client, region) click to toggle source
# File lib/warcraft/api_request.rb, line 5
def initialize(client, region)
  @client = client
  @region = region
end

Public Instance Methods

get(url, region: nil, token: nil, namespace: "profile- click to toggle source
# File lib/warcraft/api_request.rb, line 10
def get(url, region: nil, token: nil, namespace: "profile-#{region}")
  region ||= @region
  @client.get("#{url}?namespace=#{namespace}", region: region, token: token)
end