<commit_before>require 'dogecoin_api/version'
require 'httparty'

module DogecoinApi
  @api_key = ENV['DOGE_API_KEY']
  @PIN = ENV['PIN']
  @base_url = "https://dogeapi.com/wow/v2/?api_key="

  def self.create_user(user_id)
    endpoint = "create_user&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.get_user_address(user_id)
    endpoint = "get_user_address&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.get_user_balance(user_id)
    endpoint = "get_user_balance&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.withdraw_from_user(user_id, amount, payment_address)
    endpoint = "withdraw_from_user&user_id=#{user_id}&pin=#{@PIN}&amount_doge=#{amount}&payment_address=#{payment_address}"
    self.call(endpoint)
  end

  def self.move_to_user(amount, from_user_id, to_user_id)
    endpoint = "move_to_user&to_user_id=#{to_user_id}&from_user_id=#{from_user_id}&amount_doge=#{amount}"
    self.call(endpoint)
  end

  def self.get_info
    endpoint = "get_info"
    self.call(endpoint)
  end

  private

  def self.call(endpoint)
    response = HTTParty.get("#{@base_url + @api_key + "&a=" + endpoint}")
    response.body
  end
end<commit_msg>fix string concat<commit_after>require 'dogecoin_api/version'
require 'httparty'

module DogecoinApi
  @api_key = ENV['DOGE_API_KEY']
  @PIN = ENV['PIN']
  @base_url = "https://dogeapi.com/wow/v2/?api_key="

  def self.create_user(user_id)
    endpoint = "create_user&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.get_user_address(user_id)
    endpoint = "get_user_address&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.get_user_balance(user_id)
    endpoint = "get_user_balance&user_id=#{user_id}"
    self.call(endpoint)
  end

  def self.withdraw_from_user(user_id, amount, payment_address)
    endpoint = "withdraw_from_user&user_id=#{user_id}&pin=#{@PIN}&amount_doge=#{amount}&payment_address=#{payment_address}"
    self.call(endpoint)
  end

  def self.move_to_user(amount, from_user_id, to_user_id)
    endpoint = "move_to_user&to_user_id=#{to_user_id}&from_user_id=#{from_user_id}&amount_doge=#{amount}"
    self.call(endpoint)
  end

  def self.get_info
    endpoint = "get_info"
    self.call(endpoint)
  end

  private

  def self.call(endpoint)
    response = HTTParty.get(@base_url + @api_key + "&a=" + endpoint)
    response.body
  end
end
{'fraction_non_alphanumeric': 0.13454238717840575, 'fraction_numerical': 0.0008435259384226065, 'mean_word_length': 4.9448621553884715, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6050651', 'n_tokens_mistral': 928, 'n_tokens_neox': 910, 'n_words': 127}