Class: Fastlane::Particle
- Inherits:
-
Object
- Object
- Fastlane::Particle
- Defined in:
- lib/fastlane/plugin/pixie/helper/particle.rb
Instance Method Summary collapse
- #function(name, value) ⇒ Object
-
#initialize(access_token, device_id) ⇒ Particle
constructor
A new instance of Particle.
Constructor Details
#initialize(access_token, device_id) ⇒ Particle
Returns a new instance of Particle.
7 8 9 10 |
# File 'lib/fastlane/plugin/pixie/helper/particle.rb', line 7 def initialize(access_token, device_id) @access_token = access_token @device_id = device_id end |
Instance Method Details
#function(name, value) ⇒ Object
12 13 14 |
# File 'lib/fastlane/plugin/pixie/helper/particle.rb', line 12 def function(name, value) post("https://api.particle.io/v1/devices/#{@device_id}/#{name}", { arg: value, access_token: @access_token }) end |