Class: Sydecar::Profile::Entity

Inherits:
Object
  • Object
show all
Defined in:
lib/sydecar/profile/entity.rb

Constant Summary collapse

URL =
'/v1/profiles/entity'

Class Method Summary collapse

Class Method Details

.create(body:) ⇒ Object

Parameters:

  • body (Hash)


10
11
12
# File 'lib/sydecar/profile/entity.rb', line 10

def create(body:)
  Connection.instance.post(URL, body)
end

.update(id:, body:) ⇒ Object



14
15
16
# File 'lib/sydecar/profile/entity.rb', line 14

def update(id:, body:)
  Connection.instance.patch(update_url(id: id), body)
end

.update_url(id:) ⇒ Object



18
19
20
# File 'lib/sydecar/profile/entity.rb', line 18

def update_url(id:)
  "/v1/profiles/#{id}/entity"
end