Sha256: fc215a875c0ee3e118280c21df39653843a6de6d1958a2bf1701606cffae6099

Contents?: true

Size: 524 Bytes

Versions: 4

Compression:

Stored size: 524 Bytes

Contents

require "semaphore/sms/version"
require "semaphore/sms/client"

module Semaphore
  module Sms
    class ::Error < StandardError; end

    class << self
      attr_writer :api_key, :sender_name

      def setup
        yield self
        true
      end

      def client
        @client ||= Semaphore::Sms::Client.new(self)
      end

      def api_key
        raise Error, 'API Key is required for GET/POST' unless @api_key
        @api_key
      end

      def sender_name
        @sender_name
      end
    end

  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
semaphore-sms-0.1.4 lib/semaphore/sms.rb
semaphore-sms-0.1.3 lib/semaphore/sms.rb
semaphore-sms-0.1.2 lib/semaphore/sms.rb
semaphore-sms-0.1.0 lib/semaphore/sms.rb