module CodePicnic

Constants

VERSION

Attributes

client_id[RW]
client_secret[RW]

Public Class Methods

get_token() click to toggle source
# File lib/codepicnic.rb, line 24
def get_token
  Token.new(@client_id, @client_secret)
end
refresh_token() click to toggle source
# File lib/codepicnic.rb, line 20
def refresh_token
  @token_client = get_token
end
token() click to toggle source
# File lib/codepicnic.rb, line 14
def token
  @token_client ||= get_token
  refresh_token if @token_client.expired?
  @token_client.access_token
end