module Aws::RefreshingToken

def near_expiration?

def near_expiration?
  if @token && @token.expiration
    # are we within 5 minutes of expiration?
    (Time.now.to_i + 5 * 60) > @token.expiration.to_i
  else
    true
  end
end