Sha256: 3821fad746032e7ba7e61d1bdff32c2d6d0cf621e8cf06f59ae0b705ccd0fa5c

Contents?: true

Size: 490 Bytes

Versions: 1

Compression:

Stored size: 490 Bytes

Contents

module Sesame
  class Client
    include Api

    def initialize(auth_token:)
      auth_token(auth_token)
    end

    def sesames
      get_sesames.collect do |sesame_attrs|
        Sesame.new(sesame_attrs).auth_token(@auth_token)
      end
    end

    def sesame(device_id:)
      Sesame.new('device_id' => device_id).auth_token(@auth_token).refresh!
    end

    def inspect
      %(#<#{self.class.name}:#{format('0x%<object_id>.14x', object_id: (object_id << 1))}>)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sesame-ruby-1.0.0 lib/sesame/client.rb