Method: ItemBuilder::LazadaQuantityService#credential
- Defined in:
- lib/item_builder/lazada_quantity_service.rb
#credential ⇒ Object
31 32 33 34 35 36 37 38 |
# File 'lib/item_builder/lazada_quantity_service.rb', line 31 def credential return @credential if @credential account_id = listings[0].profile_channel_association_id host = ENV['CREDENTIAL_URL'] || raise('credential url is not set') url = "#{host}/credential?account_id=#{account_id}" @credential = rest_client(method: :get, url: url) end |