Class: Singly::Profiles::Service

Inherits:
Object
  • Object
show all
Includes:
Endpoint
Defined in:
lib/singly/api/profiles/service.rb

Instance Attribute Summary

Attributes included from Endpoint

#options, #path

Instance Method Summary collapse

Methods included from Endpoint

#fetch, #initialize, #url, #validate

Instance Method Details

#delete(id = nil) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/singly/api/profiles/service.rb', line 8

def delete(id=nil)
  if id
    Singly::Profiles::DeleteProfile.new(creds.merge({service: @service, id: id.to_s}))
  else
    Singly::Profiles::DeleteService.new(creds.merge({service: @service}))
  end
end

#service=(service) ⇒ Object



16
17
18
# File 'lib/singly/api/profiles/service.rb', line 16

def service=(service)
  @service = service
end