Sha256: b2b698c552fb9a6dd39964abde5d3caff65f14bf1810b9b388f829e4a3dc8ac2
Contents?: true
Size: 737 Bytes
Versions: 1
Compression:
Stored size: 737 Bytes
Contents
# stdlib require "date" require "json" require "net/http" require "time" # modules require_relative "trend/client" require_relative "trend/version" module Trend class Error < StandardError; end def self.anomalies(*args) client.anomalies(*args) end def self.forecast(*args) client.forecast(*args) end def self.correlation(*args) client.correlation(*args) end def self.url @url ||= ENV["TREND_URL"] || "https://trendapi.org" end def self.url=(url) @url = url @client = nil end def self.api_key @api_key ||= ENV["TREND_API_KEY"] end def self.api_key=(api_key) @api_key = api_key @client = nil end # private def self.client @client ||= Client.new end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
trend-0.2.0 | lib/trend.rb |