Class: PlatformAPI::OrganizationMember

Inherits:
Object
  • Object
show all
Defined in:
lib/platform-api/client.rb

Overview

An organization member is an individual with access to an organization.

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ OrganizationMember



1885
1886
1887
# File 'lib/platform-api/client.rb', line 1885

def initialize(client)
  @client = client
end

Instance Method Details

#create(organization_name_or_organization_id, body = {}) ⇒ Object

Create a new organization member.



1901
1902
1903
# File 'lib/platform-api/client.rb', line 1901

def create(organization_name_or_organization_id, body = {})
  @client.organization_member.create(organization_name_or_organization_id, body)
end

#create_or_update(organization_name_or_organization_id, body = {}) ⇒ Object

Create a new organization member, or update their role.



1893
1894
1895
# File 'lib/platform-api/client.rb', line 1893

def create_or_update(organization_name_or_organization_id, body = {})
  @client.organization_member.create_or_update(organization_name_or_organization_id, body)
end

#delete(organization_name_or_organization_id, organization_member_email_or_organization_member_id) ⇒ Object

Remove a member from the organization.



1917
1918
1919
# File 'lib/platform-api/client.rb', line 1917

def delete(organization_name_or_organization_id, organization_member_email_or_organization_member_id)
  @client.organization_member.delete(organization_name_or_organization_id, organization_member_email_or_organization_member_id)
end

#list(organization_name_or_organization_id, organization_member_email_or_organization_member_id) ⇒ Object

List the apps of a member.



1925
1926
1927
# File 'lib/platform-api/client.rb', line 1925

def list(organization_name_or_organization_id, organization_member_email_or_organization_member_id)
  @client.organization_member.list(organization_name_or_organization_id, organization_member_email_or_organization_member_id)
end

#update(organization_name_or_organization_id, body = {}) ⇒ Object

Update an organization member.



1909
1910
1911
# File 'lib/platform-api/client.rb', line 1909

def update(organization_name_or_organization_id, body = {})
  @client.organization_member.update(organization_name_or_organization_id, body)
end