Sha256: e5a0daa2524fec3c5fa0d477988d8aedd8f88a114a0a514f72313b85fb9e9eb1

Contents?: true

Size: 401 Bytes

Versions: 16

Compression:

Stored size: 401 Bytes

Contents

require 'wework/token/base'

module Wework
  module Token
    class CorpToken < Base

      def redis_key
        @redis_key ||= Digest::MD5.hexdigest "WX_CORP_TOKEN_#{client.corp_id}_#{client.permanent_code}"
      end

      def token_key
        'access_token'
      end

      def refresh_token
        client.suite.get_corp_token(client.corp_id, client.permanent_code)
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
wework-next-1.2.6 lib/wework/token/corp_token.rb
wework-1.2.8 lib/wework/token/corp_token.rb
wework-1.2.5 lib/wework/token/corp_token.rb
wework-1.2.3 lib/wework/token/corp_token.rb
wework-1.2.2 lib/wework/token/corp_token.rb
wework-1.2.1 lib/wework/token/corp_token.rb
wework-1.2.0 lib/wework/token/corp_token.rb
wework-1.1.9 lib/wework/token/corp_token.rb
wework-1.1.8 lib/wework/token/corp_token.rb
wework-1.1.7 lib/wework/token/corp_token.rb
wework-1.1.6 lib/wework/token/corp_token.rb
wework-1.1.5 lib/wework/token/corp_token.rb
wework-1.1.3 lib/wework/token/corp_token.rb
wework-1.1.2 lib/wework/token/corp_token.rb
wework-1.1.1 lib/wework/token/corp_token.rb
wework-1.1.0 lib/wework/token/corp_token.rb